SMTP Issue

Hello,

I cannot get the email notification to work correctly using Office 365.

Server : smtp://smtp.office365.com
Username : ****@domain.com
Password : *****

I tried smtp://smtp.office365.com:587 but still no luck. Credentials and settings are correct as I use the same SMTP server to send email from another application on the same machine. Message is either Timeout was reached or cannot send to peer. I know Office 365 SMTP requires SSL or TLS. Maybe it's related ?

I also have another SMTP with IP relay filter which I could use but it doesn't support authentication and Acrosync notification SMTP authentication seems required (greyed test button if not filled)

Thank you for your help

Gilles

Comments

  • Have you tried smtps:// instead of smtp://?
  • Thanks for your answer. I made a test and I get a "Timeout reached" using smtps://smtp.office365.com
  • I think you need to add the port number:

    smtps://smtp.office365.com:587
  • Thank you for your message. I made a test using "smtps://smtp.office365.com:587", now I get a "SSL connect error" message
  • For gmail it is either 'smtps://smtp.gmail.com' or 'smtp://smtp.gmail.com:587'.  I don't have an office356 account so I can't try it myself.

    I uploaded a new version (build 555) that print out log messages when sending email, if the verbose logging option is enabled.  Hopefully this will give out enough information on why the connection fails. 
  • Hi,

    I tried the new version. Log is following :

    2016/10/26 08:56:27    Acrosync for windows 1.5 build 555 initialized
    2016/10/26 08:56:37    CURL: Rebuilt URL to: smtps://smtp.office365.com:587/
    2016/10/26 08:56:37    CURL:   Trying 40.96.24.146...
    2016/10/26 08:56:37    CURL: Connected to smtp.office365.com (40.96.24.146) port 587 (#0)
    2016/10/26 08:56:38    CURL: TLSv1.2, TLS handshake, Client hello (1):
    2016/10/26 08:56:38    CURL: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol
    2016/10/26 08:56:38    CURL: Closing connection 0

    I have sent you a PM message with an office365 account so you can perform some tests if required.

    Thank you for your help

  • Thank you for providing the test account, which really made debugging much easier...

    First, the correct server address to use is 'smtp://smtp.office365.com'.  The 'smtps' prefix caused the 'unknown protocol' error.

    Second, the reason you were getting timeout errors was because Microsoft seems to deliberately add some delay after successful authentication.  Once I increased the connection max timeout to 30 seconds it started to work every time.

    The new version (build 556) can be downloaded from acrosync.com.  You can delete the test account if the fix works for you.
  • Hi,

    Thank you for the new version and the debugging.

    I changed the address to 'smtp://smtp.office365.com' but I still get an error "Failed sending data to the peer". Please find log details below :

    2016/10/27 10:25:06    CURL: Rebuilt URL to: smtp://smtp.office365.com/
    2016/10/27 10:25:06    CURL:   Trying 132.245.48.34...
    2016/10/27 10:25:06    CURL: Connected to smtp.office365.com (132.245.48.34) port 25 (#0)
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Client hello (1):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Server hello (2):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, CERT (11):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Server key exchange (12):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Request CERT (13):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Server finished (14):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, CERT (11):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Client key exchange (16):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS change cipher, Client hello (1):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Finished (20):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS change cipher, Client hello (1):
    2016/10/27 10:25:06    CURL: TLSv1.2, TLS handshake, Finished (20):
    2016/10/27 10:25:06    CURL: SSL connection using TLSv1.2 / ECDHE-RSA-AES256-SHA384
    2016/10/27 10:25:06    CURL: Server certificate:
    2016/10/27 10:25:06    CURL: subject: C=US; ST=WA; L=Redmond; O=Microsoft Corporation; OU=Microsoft Corporation; CN=outlook.com
    2016/10/27 10:25:06    CURL: start date: 2015-10-13 22:20:04 GMT
    2016/10/27 10:25:06    CURL: expire date: 2017-10-12 22:20:04 GMT
    2016/10/27 10:25:06    CURL: issuer: C=US; ST=Washington; L=Redmond; O=Microsoft Corporation; OU=Microsoft IT; CN=Microsoft IT SSL SHA2
    2016/10/27 10:25:06    CURL: SSL certificate verify result: unable to get local issuer certificate (20), continuing anyway.
    2016/10/27 10:25:13    CURL: MAIL failed: 501
    2016/10/27 10:25:13    CURL: Closing connection 0
    2016/10/27 10:25:13    CURL: TLSv1.2, TLS alert, Client hello (1):

  • It looks like you're still running the old version (build 555).  Please make sure it says build 556 in the first log message.
  • You are right, I forgot to launch the installer as Administrator and I am running the service version. Now it works perfectly.

    Kind regards

    Gilles
Sign In or Register to comment.