Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WikiJS LDAP failing authentication #114

Closed
abbiewade opened this issue Feb 1, 2022 · 1 comment · Fixed by #117
Closed

WikiJS LDAP failing authentication #114

abbiewade opened this issue Feb 1, 2022 · 1 comment · Fixed by #117

Comments

@abbiewade
Copy link

abbiewade commented Feb 1, 2022

Hi @nitnelave!

I'm using the standard WikiJS setup, and have gone to manually configure LDAP and run into issues.

image

The LDAP logs are:

lldap             | 2022-02-01T10:35:04.673732Z DEBUG lldap::infra::ldap_server: Received LDAP message: LdapMsg { msgid: 1, op: BindRequest(LdapBindRequest { dn: "cn=admin,ou=people,dc=example,dc=com", cred: Simple("********") }), ctrl: [] }    
lldap             | 2022-02-01T10:35:04.673760Z DEBUG lldap::infra::ldap_handler: Received bind request for "cn=admin,ou=people,dc=example,dc=com"    
lldap             | 2022-02-01T10:35:04.673790Z DEBUG lldap::infra::ldap_server: Replying with LDAP op: BindResponse(LdapBindResponse { res: LdapResult { code: Success, matcheddn: "", message: "", referral: [] }, saslcreds: None })    
lldap             | 2022-02-01T10:35:04.675053Z DEBUG lldap::infra::ldap_server: Received LDAP message: LdapMsg { msgid: 2, op: SearchRequest(LdapSearchRequest { base: "ou=people, dc=example, dc=com", scope: Subtree, aliases: Never, sizelimit: 0, timelimit: 10, typesonly: false, filter: And([Or([Equality("uid", "admin"), Equality("mail", "{{username}")]), Equality("objectClass", "person")]), attrs: [] }), ctrl: [] }    
lldap             | 2022-02-01T10:35:04.675082Z DEBUG lldap::infra::ldap_handler: Received search request: LdapSearchRequest { base: "ou=people, dc=example, dc=com", scope: Subtree, aliases: Never, sizelimit: 0, timelimit: 10, typesonly: false, filter: And([Or([Equality("uid", "admin"), Equality("mail", "{{username}")]), Equality("objectClass", "person")]), attrs: [] }    
lldap             | 2022-02-01T10:35:04.675098Z  WARN lldap::infra::ldap_handler: The specified search tree [("ou", "people"), (" dc", "example"), (" dc", "com")] is not under the common subtree [("dc", "example"), ("dc", "com")]    
lldap             | 2022-02-01T10:35:04.675111Z DEBUG lldap::infra::ldap_server: Replying with LDAP op: SearchResultDone(LdapResult { code: Success, matcheddn: "", message: "", referral: [] })    
lldap             | 2022-02-01T10:35:04.675507Z DEBUG lldap::infra::ldap_server: Received LDAP message: LdapMsg { msgid: 3, op: UnbindRequest, ctrl: [] }   

As you pointed out in discord, the wiki seems to be adding a space which may be the issue. Are you able to help out?

Thank you!

@nitnelave
Copy link
Member

After testing with OpenLDAP, they seem to be trimming spaces everywhere they can, so, "dc=example,dc=com" is equivalent to " dc = example , dc = com ".

I'll fix that in LLDAP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants