Postfix“SASLauthentication失败:找不到合适的机器”

试图使用与SMTP的后缀连接到谷歌的SMTP。 当试图发送邮件,我得到这个错误:

Sep 15 14:04:41 zedsaid postfix/smtp[20271]: certificate verification failed for smtp.gmail.com[74.125.95.109]:587: untrusted issuer /C=US/O=Equifax/OU=Equifax Secure Certificate Authority Sep 15 14:04:42 zedsaid postfix/smtp[20271]: warning: SASL authentication failure: No worthy mechs found Sep 15 14:04:42 zedsaid postfix/smtp[20271]: 1BACD968B23: to=<[email protected]>, relay=smtp.gmail.com[74.125.95.109]:587, delay=0.92, delays=0.06/0.03/0.83/0, dsn=4.7.0, status=deferred (SASL authentication failed; cannot authenticate to server smtp.gmail.com[74.125.95.109]: no mechanism available) 

运行Debian 4.0。

想法?

看起来线索就在这里:

 untrusted issuer /C=US/O=Equifax/OU=Equifax Secure Certificate Authority 

您需要获得equifax证书并将其添加到您信任的CA证书列表中。

我认为这些可以在这里find: http : //www.geotrust.com/resources/root-certificates/

(新用户,不能发表评论回复sebix。也删除所有链接。)

对于使用Postfix作为SMTP客户端并通过SASL-auth连接到远程服务器的现代安装(例如Ubuntu 16.04)(例如Debian wiki上显示的那样),可能确实需要指定

 smtp_sasl_security_options = noanonymous 

然而,这样做是删除noplaintext选项(目前默认是noplaintext, noanonymous按照postconf手册noplaintext, noanonymous )。 smtp_sasl_tls_security_options默认为$smtp_sasl_security_options 。 这可能会成为某些(错误)configuration下的问题,或者如果默认值更改将来会成为问题。

编辑:目前,似乎不太可能,特别是如果SASL在TLS会话中完成。 如果远程服务器有smtpd_tls_auth_onlysmtpd_enforce_tls (这意味着前者)或任何非Postfix等价物,则这是强制的。

要检查Postfix默认的内容,请使用postconf -d ( via )。

这里可能有多个问题,证书可能与smtp_sasl_security_options有关。 我曾经通过设置smtp_sasl_security_options=noanonymous来解决一个涉及到“没有机械”信息的问题,在linuxquestions.org上find一条线索

这解决了它对我来说(在Centos 7不是默认的,在旧的Centos版本上可以)

 yum install cyrus-sasl{,-plain} service postfix restart