jellyfin / jellyfin-plugin-ldapauth

LDAP Authentication for Jellyfin
https://jellyfin.org
MIT License
117 stars 33 forks source link

Search Filter Missing Left Parenthesis #162

Open professornope opened 5 months ago

professornope commented 5 months ago

Hello,

I just updated jellyfin to 10.9.6 and LDAP plugin to v19 and left everything alone expecting it to "just work".

However my known good config ran into problems and I discovered that there is a messing parenthesis in the search filter. I'm am able to see several logs of the following text in the main jellyfin.log file. Not sure if the first part is related.

[2024-06-07 12:20:11.142 -07:00] [WRN] Ldap Test Failed to Connect or Bind to server
LdapReferralException: Search result reference received, and referral following is off (10) Referral
LdapReferralException: Referral: ldap://ForestDnsZones.domain.tld/DC=ForestDnsZones,DC=domain,DC=tld`
`[2024-06-07 12:21:01.324 -07:00] [ERR] Failed to filter users with: "(&memberOf=cn=JellyfinUsers,ou=group,dc=domain,dc=tld(|(sAMAccountName=test)))"
LdapLocalException: Expecting left parenthesis, found "m" (87) Filter Error`
`[2024-06-07 12:21:07.174 -07:00] [ERR] Failed to filter users with: "(&memberOf=cn=JellyfinUsers,ou=group,dc=domain,dc=tld(|(sAMAccountName=test)))"
LdapLocalException: Expecting left parenthesis, found "m" (87) Filter Error`
`[2024-06-07 12:21:11.692 -07:00] [ERR] Failed to filter users with: "(&memberOf=cn=JellyfinUsers,ou=group,dc=domain,dc=tld(|(sAMAccountName=test)))"
LdapLocalException: Expecting left parenthesis, found "m" (87) Filter Error`
`[2024-06-07 12:23:54.063 -07:00] [ERR] Failed to filter users with: "(&memberOf=cn=JellyfinUsers,ou=group,dc=domain,dc=tld(|(displayName=test)))"
LdapLocalException: Expecting left parenthesis, found "m" (87) Filter Error

I can confirm that the UI is connecting correctly and then able to see users in the search parameters I have. image image

But what lead me to discover this was failing authenications and being unable to search/query users within the plugin. image

Again, I am using a known good ldap config, but updated to 10.9.6 and v19 ldap plug. Ldap is being served on a windows AD server. Thank you for the help.

professornope commented 5 months ago

Also to note is I see the correct string in the documentation in the plugin. image

professornope commented 5 months ago

Adding Parenthesis on both sides of the search filter will fix the issue temporary to get authentication working on my server. The following is what I entered in my LDAP Search Filter. image image