Sending emails with SMTP Relay on Office 365 via Azure VM

Solution 1:

Outbound SMTP traffic on port 25 is blocked as documented here. You should be using authenticated SMTP on port 587 or 443.