GMail SMTP via C# .Net errors on all ports

前端 未结 7 1519
鱼传尺愫
鱼传尺愫 2020-11-27 17:35

I\'ve been trying for a whlie on this, and have so far been failing miserably. My most recent attempt was lifted from this stack code here: Sending email through Gmail SMT

相关标签:
7条回答
  • 2020-11-27 18:02

    I had the same problem, but was not at liberty to alter my company's firewall restrictions. Based on the one of the notes on this Google doc, along with erdenetsogt's answer above, I tried using port 25 and it worked. (At first I was concerned that using port 25 might imply that message might not be encrypted; so I set EnableSSL to false, which caused gmail to reject it because the StartTLS was never called. This leads me to believe that gmail is enforcing the Explicit SSL, even over port 25).

    0 讨论(0)
提交回复
热议问题