【问题标题】:Setting up Postfix/SMTP Auth service using ldap使用 ldap 设置 Postfix/SMTP Auth 服务
【发布时间】:2013-10-26 05:17:35
【问题描述】:

如何配置服务器以允许用户根据 postfix 进行身份验证并从任何客户端软件发送邮件。我想我错过了一些小东西,但我需要帮助。我已经断断续续地解决这个问题大约 8 周了,但无法弄清楚我的问题。

从远程机器(我的笔记本电脑)进行 Telnet 测试

imac:~ jtolson $ echo -ne '\0sogo1\0sogo' | openssl enc -base64
AHNvZ28xAHNvZ28=

imac:~ jtolson $ telnet 10.1.2.130 25
Trying 10.1.2.130...
Connected to 10.1.2.130.
Escape character is '^]'.
220 *********************************
EHLO tcusit.com
250-tcusit.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH DIGEST-MD5 CRAM-MD5 NTLM LOGIN PLAIN
250-AUTH=DIGEST-MD5 CRAM-MD5 NTLM LOGIN PLAIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
AUTH PLAIN AHNvZ28xAHNvZ28=
535 5.7.8 Error: authentication failed: authentication failure

来自服务器 10.1.2.130 上的 /var/log/syslog

Oct 17 11:21:41 sogo postfix/smtpd[14957]: connect from unknown[172.16.1.8]
Oct 17 11:21:59 sogo postfix/smtpd[14957]: warning: SASL authentication failure: Password verification failed
Oct 17 11:21:59 sogo postfix/smtpd[14957]: warning: unknown[172.16.1.8]: SASL PLAIN authentication failed: authentication failure

来自邮件服务器文件 /etc/saslauthd.conf

ldap_servers: ldap://127.0.0.1:3389/
ldap_version: 3
ldap_auth_method: bind
ldap_search_base: dc=tcusit,dc=com
ldap_filter: (|(uid=%U)(cn=%U))
ldap_scope: sub

来自 10.1.2.130 邮件服务器

root@sogo:~# testsaslauthd -u sogo1 -p sogo
0: OK "Success."

假设 testsaslauthd 返回“0: OK”成功。告诉我 ldap 和 saslauthd 工作正常。我知道 POSTFIX/SMTP 正在使用 SASL 身份验证,并且在日志文件中的密码上失败. Postfix/SMTPD 配置了 SASL 身份验证,并且通过 ldap 的 SASL 身份验证在我的 testaslauthd 测试中工作。我缺少什么?我只是想设置一个简单的邮件服务器,我可以与来自移动设备、mac 和窗户。

感谢您提供任何指导。

【问题讨论】:

  • 这是旧的,但我现在面临同样的问题。解决方案是什么?

标签: email authentication postfix-mta smtp-auth


【解决方案1】:

解决办法

  1. 服务 saslauthd 停止

  2. rm -rf /var/spool/postfix/var/run/saslauthd

  3. 编辑 /etc/default/saslauthdenter code hereSTART=yes

DESC="SASL 身份验证守护程序"

NAME="saslauthd"

机制="ldap"

MECH_OPTIONS=""

线程=5

OPTIONS="-r -V -c -m /var/spool/postfix/var/run/saslauthd"

  1. dpkg-statoverride --force --update --add root sasl 755 /var/spool/postfix/var/run/

  2. 服务 saslauthd 启动

【讨论】:

    猜你喜欢
    • 2020-09-03
    • 2012-08-10
    • 2012-05-27
    • 2012-05-10
    • 2015-10-24
    • 2014-07-16
    • 1970-01-01
    • 2016-08-04
    • 1970-01-01
    相关资源
    最近更新 更多