1。安裝 mod_authz_ldap

yum install mod_authz_ldap

2。設定 apache ,vi /etc/httpd/conf.d/htaccess.conf

<Directory /var/www/html/test>
AuthzLDAPMethod ldap
AuthzLDAPAuthoritative on
AuthzLDAPServer 10.10.10.123:389            # AD 的IP
AuthzLDAPUserBase “DC=cross,DC=local”   # AD的網域名稱,我的是 cross.local
AuthzLDAPUserKey sAMAccountName
AuthzLDAPUserScope subtree
AuthzLDAPBindDN “cross”                             # AD 管理者的帳號
AuthzLDAPBindPassword “crosspassword”   # AD 管理者的密碼
AuthName “Need Password with using AD”
AuthType Basic
require valid-user
</Directory>

3。重啟apache

4。瀏覽 http://10.10.10.111/test ,測試登入帳密是否可以成功用AD的帳密登入

ref : http://www.extmail.org/forum/thread-12794-1-1.html

Related posts 相關文章
驗證 AD ldap
More...
打擊 google youtube 看廣告的作法
More...
apache httpd 2.4.58 有些安全性更新
More...
Apache 有 path traversal 目錄遍歷的漏洞
More...

作者

留言

撰寫回覆或留言

發佈留言必須填寫的電子郵件地址不會公開。