Home > Software engineering >  Timeout while sending email on specific port with SSL enabled
Timeout while sending email on specific port with SSL enabled

Time:03-12

I get timeout error when I try to send an email using the port 465 and EnableSSL=True. If I change the port to 25 and EnableSSL=False I mail will be sent properly.

I use vb.net, domain email and password and I want to sent throught domain's SMTP.

Dim smtpServer As New SmtpClient()
        smtpServer.Host = "ip"
        smtpServer.Port = 465 ''SSL Port
        smtpServer.Credentials = New System.Net.NetworkCredential(FromMail,Password)
        smtpServer.EnableSsl = True
        smtpServer.Send(mail)

What I need to use in order to be able to send properly from Port 465 and with SSL=True?

CodePudding user response:

Use the TLS Port instead of SSL Port. This worked for me.

  • Related