Apache2.4和LDAPw/ActiveDirectory
创始人
2024-09-05 05:30:25
0
  1. 首先需要安装并启用mod_authnz_ldap模块,可以使用以下命令进行安装:

sudo apt-get install libapache2-mod-authnz-ldap

  1. 在Apache的配置文件中添加以下内容:

LDAPTrustedGlobalCert CERT_BASE64 /path/to/cert/file.pem LDAPTrustedMode SSL LDAPVerifyServerCert on

LDAPReferrals off AuthType Basic AuthName "LDAP Authentication" AuthLDAPURL "ldap://example.com/dc=example,dc=com?sAMAccountName?sub?(objectClass=person)" AuthLDAPBindDN "cn=binduser,ou=users,dc=example,dc=com" AuthLDAPBindPassword "binduserpassword" Require valid-user

其中,LDAPTrustedGlobalCert、LDAPTrustedMode和LDAPVerifyServerCert用于配置SSL加密连接。LDAPReferrals off禁用重定向,AuthLDAPURL指定LDAP服务器的URL,AuthLDAPBindDN和AuthLDAPBindPassword指定绑定用户的DN和密码。

  1. 配置LDAP用户组

可以使用mod_authnz_ldap模块的Require ldap-group指令来限定LDAP组成员才能访问资源:

AuthType Basic AuthName "LDAP Authentication" AuthLDAPURL "ldap://example.com/dc=example,dc=com?sAMAccountName?sub?(objectClass=person)" AuthLDAPBindDN "cn=binduser,ou=users,dc=example,dc=com" AuthLDAPBindPassword "binduserpassword"

Require ldap-group cn=ldap_group,ou=groups,dc=example,dc=com

其中,Require ldap-group指定LDAP组的DN。

  1. 检查权限

可以使用“ldapsearch”等工具来检查LDAP服务器的连接、配置和组成员等情况:

ldapsearch -H ldap://ldap_server:389 -x -D "cn=binduser,ou=users,dc=example,dc=com" -w binduserpassword -b "dc=example,dc=com" "memberof=cn=ldap_group,ou=groups,dc=example,dc

相关内容

热门资讯

现有关情况通报如下!we po... 现有关情况通报如下!we poker辅助器v3.3,智星菠萝有挂吗,果然真的有挂(揭秘有挂)智星菠萝...
备受关注的!wepoker辅助... 备受关注的!wepoker辅助软件视频,德普之星辅助器app,本来是有挂(新版有挂)运德普之星辅助器...
2026版复盘!wepoker... 2026版复盘!wepoker手机插件,德普之星有透视辅助吗,好像真的有挂(有挂讲解)1、任何德普之...
为了进一步!wepoker游戏... 为了进一步!wepoker游戏安装教程,德普之星透视辅助软件,确实确实有挂(有挂分析)该软件可以轻松...
近年来!pokemmo内置修改... 近年来!pokemmo内置修改器,德扑之星透视软件免费入口官网,竟然是真的有挂(有挂方针)1)德扑之...
插件辅助挂!wpk辅助软件,德... 插件辅助挂!wpk辅助软件,德扑之星透视免费,确实真的有挂(有挂方法)1、打开软件启动之后找到中间准...
现有关情况通报如下!wpk安卓... 您好,德普之星透视辅助软件是真的吗这款游戏可以开挂的,确实是有挂的,需要了解加去威信【1367043...
2026版软件!pokemmo... 2026版软件!pokemmo脚本辅助器下载,德普之星私人局透视,确实真的是有挂(有挂方略)1、很好...
据悉!wepoker黑侠破解,... 据悉!wepoker黑侠破解,德普之星app安卓版破解版,总是确实有挂(新版有挂)1、金币登录送、破...
目前来看!hhpoker辅助器... 目前来看!hhpoker辅助器视频,德扑之星怎么设置埋牌,一贯存在有挂(详细教程)进入游戏-大厅左侧...