启动 stf 时使用 ldap 单点登录模式,启动指令:auth-ldap --port 7120 --secret kute --app-url http://xx.xx.xx.xx:7100/ --ldap-url "xxxx" --ldap-bind-dn "xxxx" --ldap-search-dn "xxxx" --ldap-bind-credentials "xxxx" --ldap-search-class "user" --ldap-search-field "mail"
然后登陆的时候报如下错误信息
Debugger listening on [::]:35295
2018-01-19T02:15:49.942Z INF/auth-ldap 27140 [*] Listening on port 7120
2018-01-19T02:17:02.863Z ERR/auth-ldap 27140 [::ffff:10.3.10.59] Unexpected error InvalidCredentialsError: 80090308: LdapErr: DSID-0C090421, comment: AcceptSecurityContext error, data 52e, v23f0
at messageCallback (/home/liuxu/stf/stf/node_modules/ldapjs/lib/client/client.js:1419:45)
at Parser.onMessage (/home/liuxu/stf/stf/node_modules/ldapjs/lib/client/client.js:1089:14)
at emitOne (events.js:96:13)
at Parser.emit (events.js:188:7)
at Parser.write (/home/liuxu/stf/stf/node_modules/ldapjs/lib/messages/parser.js:111:8)
at Socket.onData (/home/liuxu/stf/stf/node_modules/ldapjs/lib/client/client.js:1076:22)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at readableAddChunk (_stream_readable.js:176:18)
at Socket.Readable.push (_stream_readable.js:134:10)
at TCP.onread (net.js:548:20)
events.js:160
throw er; // Unhandled 'error' event
备注:相同启动放在在服务器启动再登录就没有问题,但是本地调试的时候就会报上述错误,希望大家帮忙看看