Answers:
尝试这个:
AuthType Basic
AuthName "LDAP and file
AuthBasicProvider file ldap
AuthUserFile /path/to/htpassword/file
AuthLDAPBindDN <your bind dn>
AuthLDAPBindPassword <your password>
AuthLDAPURL "<your ldap url>"
AuthzLDAPAuthoritative off
Require valid-user
Satisfy any
也许您要切换AuthBasicProvider file ldap
到AuthBasicProvider ldap file
,这取决于您首先要搜索的位置。
如果还需要检查该用户是否在特定的LDAP组中,则可以使用以下命令:
AuthType Basic
AuthName "LDAP and file"
AuthBasicProvider file ldap
AuthUserFile /path/to/htpassword/file
AuthLDAPBindDN <your bind dn>
AuthLDAPBindPassword <your password>
AuthLDAPURL "<your ldap url>"
AuthzLDAPAuthoritative off
AuthLDAPGroupAttributeIsDN off
AuthLDAPGroupAttribute memberUid
Require valid-user
Require ldap-group cn=svn,cn=groups,dc=ldapsvr,dc=example,dc=com
Require ldap-group
被忽略