我有一个使用LDAP进行用户authentication的计算机networking(Free IPA v1.2)。 我为Web门户的外部用户使用相同的LDAP服务器,但使用了不同的DN子树。 我刚刚添加了一个新的第三方Web应用程序使用PAM来validation用户,所以我补充说
auth required pam_ldap.so account required pam_ldap.so
到/etc/pam.d/new_webapp PAMconfiguration文件。 问题是,它使用/etc/ldap.conf ,它看起来是从系统的基本DN(也就是可以使用用户名/密码的SSH用户)validation用户,但是我希望它使用不同的基本DN:与门户网站用户相关的一个。 我希望/etc/pam_ldap.conf可以帮助我,但没有运气。 如果我能做到这样的话,那将是美丽的事情:
auth required pam_ldap.so conf /etc/ldap_web.conf
要么
auth required pam_ldap.so base "cn=accounts, cn=webportal, dc=example, dc=com"
我正在寻找如何解决这个问题的build议。 我唯一能想到的另一件事就是编译一个替代的pam_ldap.so ,它查看另一个configuration文件。
预先感谢对这个问题的任何反馈。
伊恩
当我尝试使用仅在webportal(web i / f)上的用户login时,出现以下exception:
Apr 29 02:22:31 portal rserver[7341]: ERROR pam_authenticate failed: User not known to the underlying authentication module; LOGGED FROM: int server::pam_auth:: <unnamed>::PAMAuth::login(const std::string&, const std::string&) /root/rstudio/src/cpp/server/ServerPAMAuth.cpp:201
当我尝试使用具有系统帐户的用户login时,这是错误:
Apr 29 02:22:48 portal rserver[7342]: ERROR pam_authenticate failed: Module is unknown; LOGGED FROM: int server::pam_auth::<unnamed>::PAMAuth::login(const std::string& const std::string&) /root/rstudio/src/cpp/server/ServerPAMAuth.cpp:201
你可以做你正在问的东西。 使用:
auth required pam_ldap.so config=/etc/ldap_web.conf
有关更多详细信息,请参阅man page 。