From 0250dd00663fe0410ec778bd174fd6622d7c299d Mon Sep 17 00:00:00 2001 From: Steve Date: Tue, 22 Sep 2020 14:00:28 -0400 Subject: [PATCH] we know what the user attr is so use it --- ldap.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ldap.go b/ldap.go index d2b372e..a652a31 100644 --- a/ldap.go +++ b/ldap.go @@ -67,7 +67,7 @@ func loginLDAPAccount(uname string, pwd string) error { 0, 0, false, - fmt.Sprintf("(&(objectClass=organizationalPerson)(uid=%s))", uname), + fmt.Sprintf("(&(objectClass=organizationalPerson)(%s=%s))", Conf.Ldap.UserAttr, uname), []string{"dn"}, nil, ))