Mandrill SMTP失败 [英] Mandrill smtp failures

查看:138
本文介绍了Mandrill SMTP失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

要使山d SMTP可靠发送,我遇到了很大的困难.或更准确地说,每次都进行身份验证.完成身份验证后,电子邮件可以正常工作

I'm having enormous difficulty getting mandrill SMTP to send reliably. Or more accurately, authenticate every time. When it does authenticate the email works fine

我可以很好地运行发送脚本,然后依次连续运行2到3次.然后它不进行身份验证.但是有时它不能立即进行身份验证.

I can run the send script fine, then 2 or 3 times in succession one after the other. Then it doesn't authenticate. But on occasions it doesn't authenticate straight away.

我认为也许只是因为它认为我在滥用它并在短时间内阻止了我.

I thought perhaps it's just because it thinks I'm abusing it and blocked me for a short period.

但是我可以看到,由于我开始对网站使用mandrill SMTP,因此其身份验证失败率是正常的.

But I can see that since I started using mandrill SMTP for my website, its failure rate to authenticate is regular.

尝试在域中归因于SPF和dmik文本.这没有帮助

Tried SPF and dmik text attributed on the domain. This didn't help

环顾四周,我看不到其他人遇到此问题,但是以这种速度,我当然不能将mandrill用于SMTP.

Looking around I can't see other people having this issue, but at this rate I certainly can't use mandrill for SMTP.

任何人都可以建议为什么会发生这种情况吗?我的凭据是100%准确的,而且我认为我根本不会发送很多电子邮件.

Can anyone suggest reasons why this could be happening? My credentials are 100% accurate, and I don't think I'm sending many emails at all.

在使用其他山man帐户的另一台服务器上遇到相同的问题.

Having the same problem on another server using another mandrill account.

注意:我正在使用phpmailer

Note: I'm using phpmailer

示例调试错误:

2014-12-06 08:52:59 Connection: opening to smtp.mandrillapp.com:587, t=300, opt=array (
)
2014-12-06 08:52:59 Connection: opened
2014-12-06 08:52:59 SERVER -> CLIENT: 220 smtp.mandrillapp.com ESMTP
2014-12-06 08:52:59 CLIENT -> SERVER: EHLO fakemail.com
2014-12-06 08:52:59 SERVER -> CLIENT: 250-ip-10-243-6-11
250-PIPELINING
250-SIZE 26214400
250-STARTTLS
250-AUTH PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250 8BITMIME
2014-12-06 08:52:59 CLIENT -> SERVER: AUTH LOGIN
2014-12-06 08:52:59 SERVER -> CLIENT: 334 VXNlcm5hbWU6
2014-12-06 08:52:59 CLIENT -> SERVER: bWVAZG91Z25vcmZvbGsuY29tLmF1
2014-12-06 08:52:59 SERVER -> CLIENT: 334 UGFzc3dvcmQ6
2014-12-06 08:52:59 CLIENT -> SERVER: REDACTED
2014-12-06 08:53:01 SERVER -> CLIENT: 435 4.7.8 Error: authentication failed: UGFzc3dvcmQ6
2014-12-06 08:53:01 SMTP ERROR: Password command failed: 435 4.7.8 Error: authentication failed: UGFzc3dvcmQ6
2014-12-06 08:53:01 CLIENT -> SERVER: QUIT
2014-12-06 08:53:01 SERVER -> CLIENT: 221 2.0.0 Bye
2014-12-06 08:53:01 Connection: closed
2014-12-06 08:53:01 SMTP connect() failed.
Mailer Error: SMTP connect() failed.

正确发送示例:

2014-12-06 08:52:33 Connection: opening to smtp.mandrillapp.com:587, t=300, opt=array (
)
2014-12-06 08:52:33 Connection: opened
2014-12-06 08:52:33 SERVER -> CLIENT: 220 smtp.mandrillapp.com ESMTP
2014-12-06 08:52:33 CLIENT -> SERVER: EHLO fakemail.com
2014-12-06 08:52:33 SERVER -> CLIENT: 250-ip-10-250-28-124
250-PIPELINING
250-SIZE 26214400
250-STARTTLS
250-AUTH PLAIN LOGIN
250-ENHANCEDSTATUSCODES
250 8BITMIME
2014-12-06 08:52:33 CLIENT -> SERVER: AUTH LOGIN
2014-12-06 08:52:33 SERVER -> CLIENT: 334 VXNlcm5hbWU6
2014-12-06 08:52:33 CLIENT -> SERVER: bWVAZG91Z25vcmZvbGsuY29tLmF1
2014-12-06 08:52:33 SERVER -> CLIENT: 334 UGFzc3dvcmQ6
2014-12-06 08:52:33 CLIENT -> SERVER: REDACTED
2014-12-06 08:52:33 SERVER -> CLIENT: 235 2.7.0 Authentication successful
2014-12-06 08:52:33 CLIENT -> SERVER: MAIL FROM:<me@fakemail.com>
2014-12-06 08:52:33 SERVER -> CLIENT: 250 2.1.0 Ok
2014-12-06 08:52:33 CLIENT -> SERVER: RCPT TO:<me@fakemail.com>
2014-12-06 08:52:33 SERVER -> CLIENT: 250 2.1.5 Ok
2014-12-06 08:52:33 CLIENT -> SERVER: DATA
2014-12-06 08:52:33 SERVER -> CLIENT: 354 End data with <CR><LF>.<CR><LF>
2014-12-06 08:52:33 CLIENT -> SERVER: Date: Sat, 6 Dec 2014 19:52:33 +1100
2014-12-06 08:52:33 CLIENT -> SERVER: To: Test <me@fakemail.com>
2014-12-06 08:52:33 CLIENT -> SERVER: From: Test <me@fakemail.com>
2014-12-06 08:52:33 CLIENT -> SERVER: Subject: Here is the subject
2014-12-06 08:52:33 CLIENT -> SERVER: Message-ID: <0a8f3c40575be98668d8ea6fb03f4bfc@fakemail.com>
2014-12-06 08:52:33 CLIENT -> SERVER: X-Priority: 3
2014-12-06 08:52:33 CLIENT -> SERVER: X-Mailer: PHPMailer 5.2.9 (https://github.com/PHPMailer/PHPMailer/)
2014-12-06 08:52:33 CLIENT -> SERVER: MIME-Version: 1.0
2014-12-06 08:52:33 CLIENT -> SERVER: Content-Type: multipart/alternative;
2014-12-06 08:52:33 CLIENT -> SERVER:   boundary="b1_0a8f3c40575be98668d8ea6fb03f4bfc"
2014-12-06 08:52:33 CLIENT -> SERVER: Content-Transfer-Encoding: 8bit
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: --b1_0a8f3c40575be98668d8ea6fb03f4bfc
2014-12-06 08:52:33 CLIENT -> SERVER: Content-Type: text/plain; charset=us-ascii
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: This is the body in plain text for non-HTML mail clients
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: --b1_0a8f3c40575be98668d8ea6fb03f4bfc
2014-12-06 08:52:33 CLIENT -> SERVER: Content-Type: text/html; charset=us-ascii
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: This is the HTML message body <strong>in bold!</strong>
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: --b1_0a8f3c40575be98668d8ea6fb03f4bfc--
2014-12-06 08:52:33 CLIENT -> SERVER:
2014-12-06 08:52:33 CLIENT -> SERVER: .
2014-12-06 08:52:33 SERVER -> CLIENT: 250 2.0.0 Ok: queued as 109BC180070
2014-12-06 08:52:33 CLIENT -> SERVER: QUIT
2014-12-06 08:52:33 SERVER -> CLIENT: 221 2.0.0 Bye
2014-12-06 08:52:33 Connection: closed
Message sent!

我尝试每5秒触发一次电子邮件. 10次​​中有3次未发送.

I tried firing the email every 5 seconds. 3 out of 10 times it didn't send.

1分钟后,我每10秒尝试一次. 10人中有8人未发送.

1 minute later, i tried every 10 seconds. 8 out of 10 didn't send.

推荐答案

由于它是断断续续的,因此在其末尾肯定看起来像是一个问题.设置SMTPDebug = 3可以查看整个SMTP会话.

Since it's intermittent, it certainly looks like a problem at their end. Set SMTPDebug = 3 to see the whole SMTP conversation.

从您所提供的单方面来看,您似乎并没有使用TLS,并且通常在启动TLS之前不允许进行身份验证,尽管我可以看到服务器在说它将执行此操作它.我认为允许不带TLS的身份验证是一个安全漏洞,当然这不是您需要允许的.

From the one-sided view you've given, it doesn't look like you're using TLS, and it's common not to allow authentication prior to starting TLS, though I can see that the server is saying it will do it. I'd regard allowing auth without TLS as a security flaw, certainly not something you need to allow.

还要确保您使用的是最新的PHPMailer(5.2.9 +).

Also make sure you're using latest PHPMailer (5.2.9+).

这篇关于Mandrill SMTP失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆