无效的命令“AuthzLDAPAuthoritative”

N.S*_*hik 7 apache-2.2

规格:Apache 2.24 O/s:Suse /RedHat /Windows

Windows:Apache httpd Linux:Apache DS (LDAP)

Apache Httpd + LDAP + SSO 实现任务(mod_session.so)

得到如下错误

"Invalid command 'AuthzLDAPAuthoritative', perhaps misspelled or defined by a module not included in the server configuration"
Run Code Online (Sandbox Code Playgroud)

该设置在 apache Httpd 2.22 + LDAP - SSO 中运行,因此根据文档,mod_session 假设可与 apache 2.24 一起使用 ..... :(

有没有机构有解决办法

关于 karthik

小智 12

你应该阅读这个:http : //httpd.apache.org/docs/2.4/upgrading.html#run-time

该指令在 2.4 之后被删除;


luc*_*ino 5

不确定是否是同样的问题,因为我切换到 2.4 而不是 2.2.24。httpd 2.2.22 一切正常,2.4.4 停止工作。

我正在我的 httpd.conf 中加载必要的模块:

LoadModule authnz_ldap_module modules/mod_authnz_ldap.so
LoadModule ldap_module modules/mod_ldap.so
Run Code Online (Sandbox Code Playgroud)

我的 LDAP Conf 如下所示:

<Location />
       AuthType Basic
       AuthName "LDAP Authentication"
       AuthBasicProvider ldap file
       AuthzLDAPAuthoritative off
       AuthLDAPURL "URL"
       AuthLDAPBindDN "BindDN"
       AuthLDAPBindPassword "BindPassword"
       Require valid-user 
       Order allow,deny
       Allow from all
</Location>
Run Code Online (Sandbox Code Playgroud)

错误消息说:

/opt/httpd/dev/bin/apachectl -f /opt/httpd/UAT/conf/httpd.conf -k start
AH00526: Syntax error on line 60 of /opt/httpd/UAT/conf/vhosts/_hobbit.conf:
Invalid command 'AuthzLDAPAuthoritative', perhaps misspelled or defined by a module not included in the server configuration
make: *** [start] Error 1
Run Code Online (Sandbox Code Playgroud)

我在邮件列表中发现了同样的错误:链接到邮件列表
看起来他找到了解决方案:链接到解决方案

我已经按照他所说的进行编译,使用我自己的 apr/apr-util 和所有 ldap 标志(--with-ldap、--enable-ldap,...),但我仍然无法让它工作。

也许有人可以想出一些办法?

编辑/解决方案:好的..从我​​的虚拟主机配置中删除“AuthzLDAPAuthoritative off”有效。看起来这个设置在 2.4 中被删除了。

设置存在于 2.2 mod_authnz_ldap 文档中,不存在于 2.4 mod_authnz_ldap 文档中。(由于信誉不佳,无法发布链接)

不知道你是否可以从你的配置中删除它,但我认为它应该在之后工作。


qua*_*nta 4

看起来您还没有加载authnz_ldap_module

LoadModule authnz_ldap_module modules/mod_authnz_ldap.so
Run Code Online (Sandbox Code Playgroud)