apache / apache/hugegraph

Gremlin console 不能连接启用了用户验证与授权的HugeGraph 0.11.2

Open
#1,911 3 comments 0 reactions 0 assignees View on GitHub
feature
Dominant language
Java
Stars
3.2k
Forks
636
Avg merge
3d 11h
Merged PRs (30d)
14

Description

### Problem Type (问题类型)

configs (配置项 / 文档相关)

### Before submit

- [X] 我已经确认现有的 [Issues](https://github.com/hugegraph/hugegraph/issues) 与 [FAQ](https://hugegraph.github.io/hugegraph-doc/guides/faq.html) 中没有相同 / 重复问题

### Environment (环境信息)

- Server Version: v0.11.x
- Backend: RocksDB x nodes, HDD or SSD
- OS: windows11 wsl -ubutun20.03,x86 8-core CPU, 16 G RAM
- Data Size: 6000 vertices, 60000 edges

### Your Question (问题描述)

不启用验证与授权,console是可以正常访问server的。启用验证与授权后,console不能正常访问server。(curl/postman两种情况下都是可以正常访问server的)
Gremlin Server 配置
# authentication
authentication: {
authenticator: com.baidu.hugegraph.auth.StandardAuthenticator,
authenticationHandler: com.baidu.hugegraph.auth.WsAndHttpBasicAuthHandler,
config: {tokens: conf/rest-server.properties}
}
rest Server 配置
# authentication:StandardAuthenticator
auth.authenticator=com.baidu.hugegraph.auth.StandardAuthenticator
auth.graph_store=hugegraph

console配置:remote-secure.yaml
hosts: [localhost]
port: 8182
username: admin
password: hugeadmin
serializer: {
className: org.apache.tinkerpop.gremlin.driver.ser.GraphSONMessageSerializerV1d0,
config: {
serializeResultToString: false,
ioRegistries: [com.baidu.hugegraph.io.HugeGraphIoRegistry]
}
}
其它根据文档描述配置。
1、init-store.sh启动正常,设置admin密码。
2、启动Server正常。使用curl/postman工具进行验证授权等的使用是正常的。但是hubble工具只能使用admin进行操作,如果使用创建好的其它用户是不能连接访问的,总是提示用户验证和授权错误。
3、启动Console
$ bin/gremlin-console.sh

\,,,/
(o o)
-----oOOo-(3)-oOOo-----
plugin activated: HugeGraph
plugin activated: tinkerpop.server
plugin activated: tinkerpop.utilities
plugin activated: tinkerpop.tinkergraph
gremlin> :remote connect tinkerpop.server conf/remote-secure.yaml
==>Configured localhost/127.0.0.1:8182
gremlin> :remote console
==>All scripts will now be sent to Gremlin Server - [localhost/127.0.0.1:8182] - type ':remote console' to return to local mode
gremlin> hugegraph
Authenticator is not ready to handle requests
Type ':help' or ':h' for help.
Display stack trace? [yN]
gremlin>

### Vertex/Edge example (问题点 / 边数据举例)

_No response_

### Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.