Я боюсь, что конфигурация php.ini не позволила бы Вам сделать это из поля.
Вы могли изменить источник PHP (в зависимости от Вашего знания C), но это сделало обновление навсегда раздражающим в будущем, поскольку необходимо будет исправить каждую версию.
According to http://httpd.apache.org/docs/2.2/mod/mod_auth_basic.html, "the order of processing is determined in the modules' source code and is not configurable."
The above quote is not talking about what you're asking:
This should only be necessary when combining
mod_auth_basic
with third-party modules that are not configured with theAuthBasicProvider
directive. When using such modules, the order of processing is определяется в исходном коде модулей и не настраивается.
Начиная с версии 2.2, Apache позволяет использовать несколько провайдеров . Я тестировал свою систему (Apache 2.2.20), она работает нормально:
<Location />
AuthType Basic
AuthBasicProvider file ldap
AuthUserFile /etc/httpd/passwords
AuthzLDAPAuthoritative Off
AuthLDAPURL ldap://ip:389/dc=x,dc=y?cn
AuthLDAPBindDN cn=anonymous,ou=z,dc=x,dc=y
AuthLDAPBindPassword pa$$w0rd
AuthName "Restricted Area"
AuthzLDAPGroupBase ou=z,dc=x,dc=y
AuthzLDAPGroupkey cn
AuthzLDAPMemberKey member
AuthzLDAPSetGroupAuth user
require valid-user
AuthzLDAPLogLevel error
</Location>
Остановить OpenLDAP, я все еще могу войти в систему с пользователями в / etc / httpd / passwords
.