如何在Python Elasticsearch下使用Kerberos?
我可以通过浏览器, curl
( curl -negotiate -U
)和来达到
带有 es
请求 requests_kerberos
(使用共同可选
config),但带有python elasticsearch软件包,调用简单 es.cat。 health()
我得到 401
authenticationException
...
我的问题是:
- 我在哪里错了,我想念什么?
- 甚至有可能迫使ES Python Lib使用Kerberos还是在引擎盖下起作用?
提前致谢。
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
看来我们已经找到了一个解决方案,但基本上不是来自文档。
我已经在文档中阅读了有关
elasticsearch
对象可以接收http_auth
输入的,但不幸的是,我没有找到它的确切等待。因此,您可以将
elasticsearch
强制使用httpkerberosauth
从request> requests_kerberos
lib以相同的方式使用,以便将其用于简单的获取请求>它运行良好,但是欢迎任何其他建议,知识共享或评论。
It seems We've found a solution, but basically not from the docs.
I've read in the doc about the
Elasticsearch
object can receivehttp_auth
input, but unfortunately I didn't find what it exactly waits for.So, you can force the
Elasticsearch
to use theHTTPKerberosAuth
class from therequests_kerberos
lib in same way as you can use that for a simple get request >It works well, but any other suggestions, knowledge share or comments are welcomed.