免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1637 | 回复: 1
打印 上一主题 下一主题

[系统管理] Postfix+saslauthd: pam_unix(smtp:auth): authentication failure [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2017-05-03 22:13 |只看该作者 |倒序浏览

各位专家,请教一个问题。
我在Oracle Linux 7上运行postfix 2.10 + Cyrus sasl 2.1 + Dovecot 2.2。
Deovcot跟saslauthd工作正常,通过POP3+TLS可以正常的收邮件,但是Postfix和saslauthd始终认证失败,希望有人帮忙诊断一下。
测试步骤如下:

+++++++++
telnet tiger 25
220 tiger.cwcloud.com ESMTP Postfix
ehlo tiger
250-tiger.cwcloud.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH PLAIN LOGIN
250-AUTH=PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
auth login
334 VXNlcm5hbWU6
eXVuLndhbmcK
334 UGFzc3dvcmQ6
eXVud2FuZ3Bhc3N3b3JkCg==
535 5.7.8 Error: authentication failed: authentication failure
++++++++
/var/log/maillog里的错误信息如下:
++++++++
May  3 09:50:01 tiger postfix/smtpd[29814]: connect from unknown[10.0.0.11]
May  3 09:50:52 tiger postfix/smtpd[29814]: warning: unknown[10.0.0.11]: SASL login authentication failed: authentication failure
++++++++
/var/log/messages里的错误信息如下:
++++++++
May  3 09:50:52 tiger saslauthd[25162]: do_auth         : auth failure: [user=yun.wang@tiger.cwcloud.com] [service=smtp] [realm=tiger.cwcloud.com] [mech=pam] [reason=PAM auth error]
++++++++
/var/log/secure里的错误信息如下:
++++++++
May  3 09:50:49 tiger saslauthd[25162]: pam_unix(smtp:auth): check pass; user unknown
May  3 09:50:49 tiger saslauthd[25162]: pam_unix(smtp:auth): authentication failure; logname= uid=0 euid=0 tty= ruser= rhost=
++++++++
运行testsaslauthd验证用户名,成功:
++++++++
[root@tiger sysconfig]# testsaslauthd -u yun.wang -p yunwangpassword -s smtp
0: OK "Success."
++++++++
postfix的配置信息如下:
++++++++
[root@tiger postfix]# postconf -n
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd $daemon_directory/$process_name $process_id & sleep 5
html_directory = no
inet_interfaces = all
inet_protocols = ipv4
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mydomain = cwcloud.com
myhostname = tiger.cwcloud.com
mynetworks = 127.0.0.0/8
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.10.1/README_FILES
sample_directory = /usr/share/doc/postfix-2.10.1/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated, reject
smtpd_helo_required = no
smtpd_helo_restrictions = permit_mynetworks, reject
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, reject
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = smtpd
smtpd_sasl_security_options = noanonymous
smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks, reject
unknown_local_recipient_reject_code = 550
+++++++
非常感谢!

论坛徽章:
0
2 [报告]
发表于 2017-05-05 20:36 |只看该作者
自己顶一下
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP