这个问题似乎是微软的Outlook 2007不发送SMTP AUTH的一个奇怪的原因,只有一个特定的域名。
我运行iRedMail服务器(它使用股票debian 7 / wheezy,后缀2.9.6-2)为我的域和几十个客户端域。 问题是我有一个客户端无法发送电子邮件给自己(不只是我的电子邮件,但整个域) – 它被拒绝reject_non_fqdn_helo_hostname但客户端使用SMTP AUTH并正确设置,所以它应该绕过FQDN检查。 它看起来像MUA没有使用SMTP AUTH只为我和我的coleaques电子邮件地址。
有没有人见过这个? 我该如何解决这个问题? 任何input是高度赞赏!
难道它是连接到MUA? 她正在使用Outlook(不是Express)?
看看下面的日志显示不同的情况。 所有被捕获在相同的configuration/相同的MUA / IP的,…:
1)这是好的:我的客户发送电子邮件到第三方服务器; 使用SMTP AUTH
5月28日13:02:13 email2 postfix / smtpd [1191]:连接从<censored> 5月28日13:02:13电子邮件2后缀/ smtpd [1191]:28A5D35E61DC:客户端= <censored>,sasl_method = LOGIN,sasl_username = <[email protected]> May 28 13:02:26 email2 postfix / cleanup [1435]:28A5D35E61DC:message-id = <006c01ce5b92 $ d33805e0 $ 79a811a0 $ @ cz> May 28 13:02:44 email2 postfix / qmgr [376]:28A5D35E61DC:from = <[email protected]>,size = 4392922,nrcpt = 7(队列激活) 5月28日13时02分44秒email2后缀/ smtp [1580]:28A5D35E61DC:to = <[email protected]>,继电器= 127.0.0.1 [127.0.0.1]:10024,延迟= 32,延迟= 31 / 0/0 / 0.88,dsn = 2.0.0,status =发送(来自MTA的250 2.0.0(smtp:[127.0.0.1]:10025):250 2.0.0 Ok:排队等候为B061435E61DE) 5月28日13:02:47 email2 postfix / qmgr [376]:28A5D35E61DC:删除
2)这是好的:我的客户发送电子邮件到本地帐户(她的coleque); 她正在使用SMTP AUTH
5月28日13:06:18 email2 postfix / smtpd [2519]:连接从<censored> 5月28日13:06:18电子邮件2后缀/ smtpd [2519]:49CE735E61D4:客户端= <censored>,sasl_method = LOGIN,sasl_username = <[email protected]> 5月28日13:06:18 email2 postfix / cleanup [429]:49CE735E61D4:message-id = <007201ce5b93 $ 5df069c0 $ 19d13d40 $ @ cz> 5月28 13:06:19 email2 postfix / qmgr [376]:49CE735E61D4:from = <[email protected]>,size = 10875,nrcpt = 1(队列激活) 5月28日13:06:19电子邮件2后缀/ smtp [2295]:49CE735E61D4:到= <[email protected]>,继电器= 127.0.0.1 [127.0.0.1]:10024,延迟= 1.6,延迟= 1.2 / 0/0 / 0.43,dsn = 2.0.0,status =发送(来自MTA的250 2.0.0(smtp:[127.0.0.1]:10025):250 2.0.0 OK:排队为CC61F35E61D7) 5月28日13:06:19 email2 postfix / qmgr [376]:49CE735E61D4:删除
3)问题,电子邮件发送到我的帐户(相同的服务器,但不同的域名),不使用SMTP AUTH ???:
5月28日13:04:38 email2 postfix / smtpd [1433]:连接从<censored> 5月28日13:04:38 email2 postfix / smtpd [1433]:NOQUEUE:拒绝:来自<censored>的RCPT:554 5.7.1 <my_email >>:收件人地址被拒绝:无效的HELO / EHLO; 必须是FQDN或地址字面值,而不是'xxx'; 从= <[email protected]>到= <my_address> proto = ESMTP helo = 5月28日13:04:41 email2 postfix / smtpd [1433]:从<censored>断开连接
部分postfixconfiguration:
smtpd_sender_restrictions = permit_mynetworks,
reject_authenticated_sender_login_mismatch,
permit_sasl_authenticated
smtpd_recipient_restrictions = reject_unknown_sender_domain,
reject_unknown_recipient_domain,
reject_non_fqdn_sender,
reject_non_fqdn_recipient,
reject_unlisted_recipient,
check_policy_service inet:127.0.0.1:7777,
check_policy_service inet:127.0.0.1:10031,
permit_mynetworks,
permit_sasl_authenticated,
reject_unauth_destination
smtpd_helo_restrictions = permit_mynetworks,
permit_sasl_authenticated,
reject_non_fqdn_helo_hostname,
reject_invalid_helo_hostname,
check_helo_access pcre:/etc/postfix/helo_access.pcre
查看postconf和cat main.cfg的输出
HELO / EHLO发生在 SMTPauthentication之前 。 如果您的服务器configuration了reject_non_fqdn_helo_hostname = yes ,则在到达SMTP AUTH部分之前 ,它将拒绝具有无效主机名的任何连接。
虽然保持这种拒绝将减less一些垃圾邮件,它也将阻止一些合法的邮件。 你应该仔细看看postfix文档中的reject_invalid_helo_hostname和smtp_helo_restrictions来找出你想如何工作。
您的smtpd_recipient_restrictions是可以的,假设您的所有客户都performance良好。 由于他们不是(不发送正确的HELO),你至less应该有这样的东西
smtpd_recipient_restrictions = reject_unknown_sender_domain, reject_unknown_recipient_domain, permit_sasl_authenticated, reject_non_fqdn_sender, reject_non_fqdn_recipient, reject_unlisted_recipient, check_policy_service inet:127.0.0.1:7777, check_policy_service inet:127.0.0.1:10031, permit_mynetworks, reject_unauth_destination
更好:
smtpd_recipient_restrictions = check_recipient_access hash:/etc/postfix/access-recipient-rfc, check_client_access cidr:/etc/postfix/access-client, check_helo_access hash:/etc/postfix/access-helo, check_sender_access hash:/etc/postfix/access-sender, check_recipient_access hash:/etc/postfix/access-recipient, permit_mynetworks, permit_sasl_authenticated, reject_unknown_sender_domain, reject_non_fqdn_sender, reject_unknown_recipient_domain, reject_non_fqdn_recipient, reject_rbl_client zen.spamhaus.org, reject_rbl_client ix.dnsbl.manitu.net, # greylisting check_policy_service inet:127.0.0.1:10023, # policyd-weight check_policy_service inet:127.0.0.1:12525, reject_unauth_destination, reject_unverified_recipient, permit
此外,您应该将所有限制集成在smtpd_recipient_restrictions 。 由于HELO来自SASLauthentication ,因此在smtpd_helo_restrictions不允许使用SASLauthentication。
一般来说,只使用smtpd_recipient_restrictions是smtpd_recipient_restrictions很好的做法,因为您可以在这里做所有事情,它可以节省您重复的工作,并且在helo之后终止的连接的networking开销并不大。
问题是在policyd(cluebringer)…从第一次看日志中没有看到,拒绝不是来自postfix的限制,而是来自policyd。
背景
我有在cluebringers组internal_domains只有我的主域(安装后),所有新的域名不存在…为了解决这个问题,我决定清空internal_domains,一切都按预期工作。
谢谢你的帮助!