Procházet zdrojové kódy

先去掉验证,因为如果默认跳过在bind_dn和password为默认值时会跳过密码验证

huangrf před 6 roky
rodič
revize
42b0a7cd1b
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      utils/auth/ldap_auth.go

+ 1 - 1
utils/auth/ldap_auth.go

@@ -92,7 +92,7 @@ func (h ldapHandler) Search(boundDN string, searchReq ldap.SearchRequest, conn n
 			}
 			entries := []*ldap.Entry{
 				&ldap.Entry{dn, []*ldap.EntryAttribute{
-					&ldap.EntryAttribute{"uid", []string{}},
+					//&ldap.EntryAttribute{"uid", []string{}},
 				}},
 			}
 			return ldap.ServerSearchResult{entries, []string{}, []ldap.Control{}, ldap.LDAPResultSuccess}, nil