我有一台RedHat 7.1机器上运行的sendmail。 我想将其configuration为使用PLAIN或CRAM-MD5进行身份validation。 我有PLAIN的工作(所以我知道客户端工作,我有正确的用户名/密码等),但CRAM-MD5总是返回“535 5.7.0authentication失败”。 为了testing,我使用了一个简单的使用smtplib模块的python脚本; 我假设他们的CRAM-MD5的实施是正确的。
它以“AUTH DIGEST-MD5 CRAM-MD5 LOGIN PLAIN”响应EHLO,并在发送“AUTH CRAM-MD5”时发送质询,因此它接受CRAM-MD5请求,但拒绝authentication它们。
我知道CRAM-MD5需要服务器访问明文密码; 有没有可能? 我怎么知道,如果没有,我怎么configuration机器,以便它呢?
我已将用户名/密码添加到/ etc / mail / authinfo中,并运行map hash /etc/mail/authinfo < /etc/mail/authinfo
。 / var / log / maillog文件中没有错误消息。
根据系统pipe理员文档 ,
For simplicity sake, the Cyrus SASL library stores plaintext passwords only in the /etc/sasldb2 database. These passwords are then shared among all mechanisms which choose to use it. ... The "saslpasswd" utility is provided to change the secrets in sasldb. It does not affect PAM, /etc/passwd, or any other standard system library; it only affects secrets stored in sasldb.
然而,一些供应商可能会在编译时改变事物的位置,所以sasl二进制文件或strace
上的strings
可能是必要的,以揭示saslauthd
正在查找的位置。