I have Google apps setup on a client site and I'm trying to send mail using Google's smtp server. The website is written in ASP.NET.
Below is the web.config excerpt:
I use this same approach on a couple of other VPS hosted websites with the exception of adding the port attribute to the network line. Seeing as the websites here don't run in full trust mode, the port attributes causes permission problems here.
Anyway, the error I'm receiving now is "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. 30sm8162202wfc.15". Any ideas?
Below is the web.config excerpt:
Code:
<system.net >
<mailSettings >
<smtp>
<network host="smtp.googlemail.com" userName="[email protected]"
password="topsecret" defaultCredentials="false"/>
</smtp>
</mailSettings>
</system.net>
I use this same approach on a couple of other VPS hosted websites with the exception of adding the port attribute to the network line. Seeing as the websites here don't run in full trust mode, the port attributes causes permission problems here.
Anyway, the error I'm receiving now is "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. 30sm8162202wfc.15". Any ideas?