Email relay with Office 365
|Knowledge Article Number||000220018|
|Description||Salesforce sends and relays e-mail using your corporate email address as the senders email address. Office 365 will accept mail on Port 587 in this scenario but it needs SMTP authentication which is not available with the Salesforce server to server relay functionality. Currently setting up a " Partner Connector" using Port 25 with TLS and Salesforce IPs should allow relay of mail from Salesforce to Office 365 and thus on to the Internet if desired. For Salesforce MTA IPs see the "The addresses used for email relay include:" section of What are the Salesforce IP Addresses & Domains to whitelist?
If more flexibility around email relay is needed it may be useful to set up an IIS or other relay server in your domain space to accept mail from Salesforce before passing this to your 365 implementation for either internal delivery and also relay to the internet.
Consult with Office 365 support for more information about this scenario.
See also: https://technet.microsoft.com/en-us/library/dn554323%28v=exchg.150%29.aspx