Why I can't send emails using smtp.gmail.com:587 on ipv6?

我与影子孤独终老i 提交于 2021-01-25 06:42:04

问题


I have tried to send emails from my server using smtp.gmail.com:587 on ipv6 but I get this error:

=== Connected to smtp.gmail.com.
<** 421 4.7.0 Try again later, closing connection.
 -> QUIT
*** Remote host closed connection unexpectedly.

On the server I use swaks to test this using the following command:

swaks -6 --server smtp.gmail.com:587 --from from@gmail.com --to to@gmail.com -tls -a LOGIN

But if I use the swaks on ipv4 I can send email with no problems:

swaks -4 --server smtp.gmail.com:587 --from from@gmail.com --to to@gmail.com -tls -a LOGIN

The response:

235 2.7.0 Accepted
 ~> MAIL FROM:<from@gmail.com>
<~  250 2.1.0 OK gsmtp
 ~> RCPT TO:<to@gmail.com>
<~  250 2.1.5 OK gsmtp
 ~> DATA
<~  354  Go ahead gsmtp
 ~> Date: Wed, 29 Jul 2020
 ~> To: to@gmail.com
 ~> From: from@gmail.com
 ~> Subject: test Wed, 29 Jul 2020
 ~> X-Mailer: swaks v20181104.0
 ~> This is a test mailing
 ~> .
<~  250 2.0.0 OK  1596049286 gsmtp
 ~> QUIT
<~  221 2.0.0 closing connection gsmtp

来源:https://stackoverflow.com/questions/63160968/why-i-cant-send-emails-using-smtp-gmail-com587-on-ipv6

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!