如何使用Asp.net WEB API中的Power MTA发送电子邮件 [英] How to send Email using Power MTA in Asp.net WEB API
问题描述
我正在尝试使用gmail帐户通过smtp服务器发送大量电子邮件,但我面临的问题是:SMTP服务器需要一个安全连接或客户端未经过身份验证。服务器响应为:5.7.0必须首先发出STARTTLS命令.ry1sm18393619pab.30 - gsmtp。
我不明白为什么会出现这个问题。我已经给出了正确的凭据,例如:Gmail的Emailid和密码,我已经更改了端口号25,587。如果有人有些懒散,那将非常有用。
Hi,
I am trying to send bulk of emails through smtp server using gmail account, but i am facing issue like this: "The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.0 Must issue a STARTTLS command first. ry1sm18393619pab.30 - gsmtp".
I don't understand why this issue is coming. I have given correct credentials like: Emailid and password for gmail, i have changed port number also 25,587. If anyone has some sloution then it would be very helpful.
推荐答案
查看我过去的答案 - 从asp.net发送电子邮件到gmail [ ^ ]。
只要您输入正确的用户名和密码,此代码就可以完美地将 Gmail 用作SMTP
i> inNetworkCredentials
。
此问题主要与EnableSsl $相关c $ c> property。
See my past answer - sending email to gmail from asp.net[^].
This code works perfectly uing Gmail asSMTP
provided you write correct username and password inNetworkCredentials
.
This issue is mostly related toEnableSsl
property.
Thanx tadit用于回复。我更改了EnableSsl = false,但后来我也遇到了同样的问题。这是防火墙阻塞问题,还是必须更改某些gmail设置?
Thanx tadit for replying. I changed EnableSsl = false, but then also i am getting the same issue. Is that a firewall blocking issue, or some gmail settings has to be changed?
这篇关于如何使用Asp.net WEB API中的Power MTA发送电子邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!