apache的網頁帳密功能(mod_auth)搭配使用WindowsAD作認證

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
評論: 0 | 引用: 0 | 閱讀: 137 | 列印 | 文件 | 轉發

發表評論
暱 稱: 密 碼:
網 址: E - mail:
驗證碼: 驗證碼圖片 選 項:
頭 像:
內 容:
  • 粗體
  • 斜體
  • 底線
  • 插入圖片
  • 超連結
  • 電子郵件
  • 插入引用
  • 表情符號