This commit is contained in:
Chris Mann 2023-07-23 13:08:29 +02:00
parent f66f51019b
commit dd6f84d25b

View file

@ -88,6 +88,9 @@ func passwordFound(user User, config *ConfigFile, ldapConn *ldap.Conn) (bool, er
if err != nil { if err != nil {
return false, err return false, err
} }
if user.DN == "" && user.UID != "" {
user.DN = "uid=" + user.UID + ",ou=invitations,dc=resdigita,dc=org"
}
err = l.Bind(user.DN, user.Password) err = l.Bind(user.DN, user.Password)
if err != nil { if err != nil {
return false, err return false, err