
我在 Active Directory 上設定了安全性 LDAP。
我正在嘗試使用ldapsearch
Ubuntu 上的命令來查詢它。
以下是虛擬詳細資訊:
Domain Name: dc=qwerty,dc=com
LDAP Server: ldap_server.qwerty.com
LDAP Type: AD
Query User Name: [email protected]
Password:Qwerty_12345
Port Number: 636
Admin Group Name: abc_admin
當我嘗試執行以下命令時:
`ldapsearch -x -W [email protected] -h ldap_server.qwerty.com`
系統要求我輸入密碼,但輸入正確的密碼後,出現以下錯誤:輸入 LDAP 密碼:擴充 LDIF
LDAPv3
base <> (default) with scope subtree
filter: [email protected]
requesting: ALL
search result
search: 2
result: 1 Operations error
text: 000004DC: LdapErr: DSID-0C0907E9, comment: In order to perform this opera
tion a successful bind must be completed on the connection., data 0, v2580
numResponses: 1
答案1
如果您使用 amdin 帳戶,您可能會缺少 -D。
這是我過去用作範例的頁面。可能有幫助。
https://devconnected.com/how-to-search-ldap-using-ldapsearch-examples/
作為使用者管理員。
$ ldapsearch -x -b“dc=devconnected,dc=com”-H ldap://192.168.178.29 -D“cn=admin,dc=devconnected,dc=com”-W