SASL LDAP身份验证失败

编程入门 行业动态 更新时间:2024-10-27 23:29:47
本文介绍了SASL LDAP身份验证失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

尝试使用 SASL 和 LDAP 在来验证用户的RedHat的Linux 。到目前为止,我已经设置了 saslauthd 服务和它的启动和运行。我的 /etc/saslauthd.conf 看起来如下:

Trying to use SASL AND LDAP to authenticate user in RedHat Linux. So far I've setup the saslauthd service and its up and running. My /etc/saslauthd.conf looks like follows:

ldap_servers: ldaps://test.ldap.server:1234 ldap_use_sasl: yes ldap_mech: DIGEST-MD5 ldap_auth_method: fastbind ldap_search_base: Ou=PeopleAuthSrch,DC=abc,DC=com

我的 /etc/sasl2/smtpd.conf 如下所示:

pwcheck_method: saslauthd mech_list: plain login

现在,当我尝试测试用下面的命令验证:

Now when I try to test the authentication with following command:

testsaslauthd -u用户名-p密码-f / var / run中/ saslauthd / MUX

我得到 0:NO验证失败

和当我看到日志它说:

Retrying authentication do_auth :auth failure: [user:myuser] [service=imap] [realm=] [mech=ldap] [reason=unknown]

我缺少的是在这里吗?在此先感谢!

What am i missing here? thanks in advance!!

更新:

安装OpenLDAP的做用下面的命令搜索:

installed OpenLdap to do a search with the following command:

的ldapsearch -x -h LDAPS://my.ldap.server:端口〜D8

ldapsearch -x -h ldaps://my.ldap.server:port -d8

有关ldapsearch命令的工作我修改 /etc/openldap/ldap.conf中文件如下:

for ldapsearch command to work i modified /etc/openldap/ldap.conf file as follows:

tls_reqcert allow TLS_CACERTDIR /home/myuser/cacertss LDAPTLS_CACERT /home/myuser/cacertss

它返回的所有条目,但我使用仍然无法进行身份验证

It returns all the entries but i still cant authenticate using

testsaslauthd -u用户名-p密码-f / var / run中/ saslauthd / MUX

testsaslauthd -u username -p password -f /var/run/saslauthd/mux

什么我需要在这里做得到这个认证?

推荐答案

在奋斗了5天发现我使用的设置是活动目录我应该是使用 LDAP 设置如下:

After 5 days of struggle found out that the settings i used was for Active directory where i should be using settings for LDAP as following:

ldap_servers: ldaps://test.ldap.server:1234 ldap_search_base: Ou=PeopleAuthSrch,DC=abc,DC=com ldap_filters: (uid=%u) ldap_tls_cacert_file: /path/to/my/certificate

我没有安装赛勒斯-SASL-MD5 作为贝托尔德Kolics提到的,我不知道如果在认证用户所扮演的角色。

I did install cyrus-sasl-md5 as Bertold Kolics mentioned, i'm not sure if that played the part on authenticating the user.

更多推荐

SASL LDAP身份验证失败

本文发布于:2023-10-13 00:37:30,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1486313.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:身份验证   SASL   LDAP

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!