C# 发邮件 服务器响应为: 5.7.0 Must issue a STARTTLS command first

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. d21sm2344514and.26

SMTP 服务器要求安全连接或客户端未通过身份验证。 服务器响应为: 5.7.0 Must issue a STARTTLS command first. i6sm4954143tid.5

今天用Gmail的发送邮件,返回这错误.查了下是因为Gmail要求把ssl加密打开.

加上这代码:client.EnableSsl = true;

上一篇:HDU 1166 敌兵布阵(线段树单点更新,区间查询)


下一篇:js实现element中可清空的输入框(2)