【发布时间】:2023-04-04 05:42:01
【问题描述】:
我是 Elastic 搜索的新手,使用的是 Elastic 搜索 7.7.1 版
我想通过关注Elastic Search documentation来生成OAuth令牌
当我尝试通过 Kibana 调用下面的方法以根据文档获取 OAuth 令牌时:
POST /_security/oauth2/token
{
"grant_type" : "password",
"username" : "elastic",
"password" : "password_for_elastic_super_user"
}
然后低于错误:
{
"error" : {
"root_cause" : [
{
"type" : "invalid_index_name_exception",
"reason" : "Invalid index name [_security], must not start with '_', '-', or '+'",
"index_uuid" : "_na_",
"index" : "_security"
}
],
"type" : "invalid_index_name_exception",
"reason" : "Invalid index name [_security], must not start with '_', '-', or '+'",
"index_uuid" : "_na_",
"index" : "_security"
},
"status" : 400
}
谁能帮忙解决这个问题?
【问题讨论】:
-
您需要在弹性搜索节点中启用安全性。你的
elasticsearch.yml配置是什么样的?用它更新你的问题。 -
如果我启用了安全性然后会出现另一个问题,请检查:stackoverflow.com/questions/62575068/…
标签: java spring-boot elasticsearch oauth-2.0 kibana