feat: support LDAP with SSL/TLS enabled (#1655)

This commit is contained in:
Yaodong Yu
2023-03-15 11:12:31 +08:00
committed by GitHub
parent a8a8f39963
commit 295a69c5f7
15 changed files with 46 additions and 8 deletions

View File

@ -196,7 +196,7 @@ func checkLdapUserPassword(user *User, password string, lang string) (*User, str
ldaps := GetLdaps(user.Owner)
ldapLoginSuccess := false
for _, ldapServer := range ldaps {
conn, err := GetLdapConn(ldapServer.Host, ldapServer.Port, ldapServer.Admin, ldapServer.Passwd)
conn, err := ldapServer.GetLdapConn()
if err != nil {
continue
}