LDAP Login witch samaccountname or eMail

373 views
Skip to first unread message

CR

unread,
Mar 19, 2021, 5:28:32 AM3/19/21
to pwm-general

Hello I have connected the tool via LDAP and an MS Activ Directory. The user can log in with the sAMAccountName. Is there also the option of logging in with the sAMAccountName or the email address ? Do I have to change the LDAP search filter to do this?  What does the filter have to look like then?

Reinis Grauds

unread,
Mar 22, 2021, 12:27:24 AM3/22/21
to pwm-general
In  LDAP ⇨ LDAP Directories ⇨ default ⇨ Login Setup 
try adding userPrincipalName=%USERNAME% to the User Name Search Filter

CR

unread,
Mar 22, 2021, 7:17:52 AM3/22/21
to pwm-general
I have adjusted the search filter but it is not possible to login with the email address. The CN is first name.surname  and the email address consists of first name.s...@vxvxb.com.
Loginwith  first name.surname  is possible but not with the entire email address.

The new Search Filter:

(& (objectClass = person) (| (sAMAccountName =% USERNAME%) (cn =% USERNAME%) (mail =% USERNAME%) (userPrincipalName =% USERNAME%)))
Reply all
Reply to author
Forward
0 new messages