Configuring Microsoft365 with ExchangeDefender | ExchangeDefender                [ Skip to content ](#main)  [ ![ExchangeDefender](/assets/images/xd_logo_blue.png) ](/)   Email Security     ![Platform Overview](/assets/images/m-xd-pro.png)### ExchangeDefender PRO

Enterprise-grade email security made simple for every business.

 [Sign Up](/sign-up) [Live Demo](/demo) 

 [Email Security

Stops spam, malware &amp; phishing in real time.

 ](/email-security) [Encryption

Secure your emails, attachments &amp; sensitive data.

 ](/corporate-email-encryption) [Web File Sharing

Easy, safe cloud file sharing with access control.

 ](/web-file-server) [Live Archive

Locked-in email backup &amp; continuity during outages.

 ](/livearchive-backup) [Emergency Inbox

Keep email flowing without interruption if your provider fails.

 ](/inbox) [Spearphish

Train your team with phishing simulations &amp; risk tracking.

 ](/spearphishing) 

  Managed Email    ### Enterprise-Grade Managed Email

Reliable, secure, and fully managed email operations for modern organizations.

 ![ExchangeDefender](/assets/images/managed_email_menu.png) 

 [Microsoft365/Google Email Management

Expert management and security for Microsoft 365 and Google Workspace email.

 ](/managed-email-operations) [AI Advisory

Secure, practical AI consulting &amp; implementation for SMBs.

 ](/management-ai) 

  Company    ### ExchangeDefender: 29+ Years of Trust

We are a cybersecurity company focused on business email protection, with 29+ years of experience keeping organizations secure, connected, and resilient.

 ![ExchangeDefender](/assets/images/careers_1.png) 

 [ About Us

Learn our purpose, values, and the mission behind every decision.

 ](/about-us) [ Blog

News, product updates and email security insights.

 ](/blog) [ Capabilities

Discover the tech and expertise that keep your email secure around the clock

 ](/capabilities) [ Careers

Be part of a team using modern tech to solve real threats and ship great work.

 ](/careers) 

 [Partners](/partners) [Docs](/docs) [Contact Us](/contact)  Talk to a Human 

  Open menu     

 Menu
----

   Email Security     [Email Security](/email-security) [Encryption](/corporate-email-encryption) [Web File Sharing](/web-file-server) [Live Archive](/livearchive-backup) [Inbox](/inbox) [Spearphish](/spearphishing) 

    Managed Email     [Microsoft365/Google Email Management](/managed-email-operations) [AI Advisory](/management-ai) 

    Company     [About Us](/about-us) [Blog](/blog) [Capabilities](/capabilities) [Careers](/careers) 

  [Partners](/partners) [Docs](/docs) [Contact Us](/contact) Talk to a Human 

    Search documentation       On this page     On this page
------------

- [ExchangeDefender Inbound Connector](#exchangedefender-inbound-connector)
- [ExchangeDefender Outbound Connector](#exchangeDefender-outbound-connector)
- [M365 Tenant Anti-phishing and Anti-spam Settings](#/m65-tenant-anti-phising-anti-spam-settings)
- [Microsoft365 and ExchangeDefender Outbound Limitation](#/microsoft-365-xd-outbound-limitation)

  [    Documentation ](https://www-preview.exchangedefender.com/docs) 

    [Documentation](https://www-preview.exchangedefender.com/docs)Configuring Microsoft365 with ExchangeDefender
==============================================

Configuring Microsoft365 with ExchangeDefender.

   ExchangeDefender Inbound Connector [¶](#exchangedefender-inbound-connector) 
-----------------------------------------------------------------------------

1. To lock down your M365 tenant to only allow secure email that has been scanned by ExchangeDefender, you need to create a **Connector** at https://admin.exchange.microsoft.com. Click on **Mail Flow -&gt; Connectors** and click on **+ Add a connector** to get started.

![](/images-documentation/office365-step1.png)

2. You will be presented with a modal for New Connector. Click on **Partner organization** and then click on **Next**. (edited)

![](/images-documentation/office365-step2.png)

3. Name and describe the ExchangeDefender SMTP connector so you can recognize it when managing your instance. If you are not using ExchangeDefender to the fullest you will likely have to create other connectors for other partner organizations, contact forms, IoT devices, printers, scanners, etc.

![](/images-documentation/office365-step3.png)

4. Next we will program IP restrictions so your M365 tenant only accepts messages from ExchangeDefender's delivery range. Click on **By verifying the IP address...** and type in the IP range **65.99.255.0/24** in the input box. Finally click on the **"+"** and then click on **Next**. IMPORTANT bubble highlight div: "Make sure you click on the + button which will empty out the input box and place "65.99.255.0/24" directly underneath it with a Delete icon. If you do not click on the **+** button the IP range will not be added and this is the **most common mistake** admins make in this process.

![](/images-documentation/office365-step4.png)

5. ExchangeDefender relies on secure connections and encryption to keep your messages private so accept the defaults on this screen by clicking **Next**

![](/images-documentation/office365-step5.png)

6. Your review connector screen should look like this. Make sure you see 65.99.255.0/24 under the *"How to identify your partner organization"* section. If everything looks correct, click on **Create connector** and then click on Done

![](/images-documentation/office365-step6.png)

7. You will be taken back to the list of your connectors and this portion of the setup is complete.

![](/images-documentation/office365-step7.png)

You can also create the ExchangeDefender SMTP connector using M365 PowerShell. Here is the command:

 New-InboundConnector -Name "ExchangeDefender" -ConnectorType OnPremises -SenderIPAddresses 65.99.255.0/24 -RequireTls $true -CloudServicesMailEnabled $false -Enabled $true -RestrictDomainsToIPAddresses $true -Comment "ExchangeDefender Inbound connector for 65.99.255.0/24"

   **Tips** 
This SMTP connector will restrict access to incoming mail in your organization and only messages that get scanned by ExchangeDefender and relayed from our secure endpoints will be accepted. If you have other services requiring direct access to your M365 tentant (web site contact forms, printers, scanners, IoT devices, firewall notification scripts, etc) you will need to create a connector for each service. ExchangeDefender makes this simple using our [IoT Connector](https://www.exchangedefender.com/iot-security) SMTP Relay service.

   ExchangeDefender Outbound Connector [¶](#exchangeDefender-outbound-connector) 
-------------------------------------------------------------------------------

 If your Organization hasn't updated their SPF for Office 365:

 Your organization should have a SPF record for the domain(s) registered with Office 365. When implementing ExchangeDefender with Office 365, this record must be updated in the DNS zone for the relevant domain to include the following:

 **Remove**: v=spf1 include:spf.protection.outlook.com –all
 **Replace with**: v=spf1 include:proxy.exchangedefender.com -all

###  CONFIGURING OUTBOUND SMARTHOST CONNECTOR: 

 LOG IN to the Office 365 Administration Console.

 Select the Admin | Exchange menu item. The Exchange Admin Center is displayed. Once displayed, in the menu on the left-hand side, navigate to Mail flow and then **Connectors**.

 Click the  ‘+’ button and you’ll be greeted with the following context menu. Once you've selected  'Office 365' and  'Partner Organization' click the  'Next' button.

![](/images-documentation/office-365-step3.png)

  ENTER the name of the connector (We suggest using ExchangeDefender).

 CLICK check box for “Turn it On”. Click NEXT -

 Select the option for  'Only when email messages are sent to these domains' and click the '+' button to add the domains

![](/images-documentation/office-365-step4.png)

 Put  \* in the domain name field and hit the  'Ok' button.

![](/images-documentation/office-365-step5.png)

  SELECT 'Route email through these smart hosts'  and then hit the  '+' button.

![](/images-documentation/office-365-step6.png)

  Add a smart host. Add 'outbound.exchangedefender.com' as you see it below.

![](/images-documentation/office-365-step6-2.png)

 Once you've entered the smart host hit the 'Save' button. From there you'll be taken to the TLS screen. Keep all options default as shown in the screenshot below.

![](/images-documentation/office-365-step7.png)

  Validate your configuration by letting O365 send a test email. Enter in any email address of a recipient outside of your organization. Click the **+** then click VALIDATE.

   M365 Tenant Anti-phishing and Anti-spam Settings [¶](#/m65-tenant-anti-phising-anti-spam-settings) 
----------------------------------------------------------------------------------------------------

ExchangeDefender protects you from SPAM and Phishing threats. To avoid M365 falsely identifying messages as fraud, follow these steps to add ExchangeDefender to tenant allow policies:

### **Manage Anti-Phishing Rules**

1. Login to Microsoft 365 Defender Security Center at [https://security.microsoft.com](https://security.microsoft.com)
2. Navigate to **Email &amp; Collaboration &gt; Policies &amp; Rules &gt; Threat Policies**

![](/images-documentation/m365_admin_antiphishing_step_2.png)

3. Under Microsoft Defender Policies we will be making changes to Anti-Phishing policies and Tenant Allow/Block Lists under Rules.

![](/images-documentation/m365_admin_antiphishing_step_3.png)

**Policies &amp; rules**

Select Anti-Phishing under Policies. You will be presented with a list of policies, select **"Office365 AntiPhish Default (Default)"** or your default security policy. Expand **Protection Settings**. Confirm that "**\[ \] Enable spoof intelligence (Recommended)**" setting is clear (unchecked) and click on Save.

![](/images-documentation/m365_admin_antiphishing_2.png)

![](/images-documentation/m365_admin_antiphishing_3.png)

![](/images-documentation/m365_admin_antiphishing_4.png)

**Tenant Allow/Block Lists**

Select Tenant Allow/Block Lists under Rules (Under Email &amp; Collaboration &gt; Policies &amp; rules &gt; Rules section of Microsoft Defender). Click on **Spoofing** and **+Add**

![](/images-documentation/m365_admin_antiphishing_7.png)

Below is the content to paste into the domain pair list

 **\*, 65.99.255.0/24**
 **\*, 206.125.40.0/24** 

Select Spoof type: External and Action: Allow. Paste the content below into the domain pairs text box and click on Add. Confirm that the new tenant Spoofing allow list matches the display below.

![](/images-documentation/m365_admin_antiphishing_5.png)

**Disable M365 False Phishing Alerts**

#### **"Subject: Informational-severity alert: Phish delivered due to an IP allow policy"** 

---

Go to [security.microsoft.com](http://security.microsoft.com) and select Policies &amp; Rules on the left. Select Alert Policy and make sure the following alert policies are deactivated (not blue) as in the screenshot below: **"Phish delivered due to an ETR override"** and **"Phish delivered due to an IP allow policy"**

![](/images-documentation/disable-M365-false-phishing-alerts.png)

   Microsoft365 and ExchangeDefender Outbound Limitation [¶](#/microsoft-365-xd-outbound-limitation) 
---------------------------------------------------------------------------------------------------

**Error: "500 5.7.1 . . . Command rejected."**

ExchangeDefender outbound network (outbound.exchangedefender.com) only relays email on behalf of our clients domains. Security and general Internet protocols prohibit us from sending email on behalf of other networks. As a security company it's our responsibility to prohibit spoofed or forged messages, for example someone using your organization to send emails as gmail.com or to launch an attack as a null sender.

#####  **Send legitimate M365 Out of Office (OOF) Responses** 

If you need to make sure Out of Office responses are sent out no matter what, here is the general process to follow at https://admin.exchange.microsoft.com

##### **Step 1: Create new Exchange Connector**

---

This step will create a Microsoft M365 connector that will route all messages from your M365 tenant directly to the senders MX record (bypassing ExchangeDefender and assuring the OOF attempt is made)

Exchange &gt; Mail flow &gt; Connectors

\+ Add a connector

\+ Connection from: Office365

\+ Connection to: Partner organization

\+ Name:

\+ What do you want to do after connector is saved? \[CHECK\] Turn it on

\+ Use of connector: Only when I have a transport rule set up that redirects messages to this connector Next&gt;

\+ Routing: Use the MX record associated with the partner's domain

\+ Security restrictions (accept defaults)

\+ Validation Email / Review Connector Next/Save.

##### **Step 2: Create a new Mail flow Rule**

---

This step will create a rule that forwards OOF messages to the Connector we made in step 1.

Exchange &gt; Mail flow &gt; Rules

\+ Add a rule

\+ Name: "Send Automatic Replies to connector Automatic Replies"

\+ Apply this rule if: "The message properties"

\+ The message type is Select one: "Automatic Reply"

\+ Do the following: Redirect the message to: "the following connector"

\+ Select "Automatic Replies (Out of Office) Only"

\+ Click Next&gt;

Accept defaults (Enforce)

##### **Step 3: Publish new DMARC**

---

Make sure you configure DKIM signing to include Microsoft's signature, the [instructions are here](https://learn.microsoft.com/en-us/defender-office-365/email-authentication-dkim-configure).

Next update the SPF record to include M365 connector, it should look like this: **"v=spf1 include:proxy.exchangedefender.com include:spf.protection.outlook.com -all"**

##### **Step 4: Make sure everything works**

---

Validate your connectors, rules, SPF records, DKIM records, and confirm everything is enabled and enforced. One area our clients often overlook is enabling the Mail Flow &gt; Rules: Confirm that the "Send Automatic Replies to connector Automatic Replies" - confirm that the rule is enabled.

##### **Sending messages from external domains**

To relay messages from external domains please see our [ExchangeDefender IoT Connector feature](https://exchangedefender.com/docs/setting-up-account-iot-connector).

   [ Next Outlook / Exchange → ](https://www-preview.exchangedefender.com/docs/exchange-setup)   

  Solutions
---------

- [Stop Spam &amp; Malware](/email-security)
- [Hands-Free Email Backup](/livearchive-backup)
- [Instant Email Recovery](/inbox)
- [Send Private Emails](/corporate-email-encryption)
- [Train Against Email Threats](/spearphishing)
- [Share Files Safely](/web-file-server)

Company
-------

- [About ExchangeDefender](/about-us)
- [Compliance &amp; Legal](/our-compliance)
- [Become a Partner](/partners)
- [Support Portal Login](https://support.exchangedefender.com/)
- [Microsoft 365 Email Management](/managed-email-operations)
- [AI Advisory Service](/management-ai)

 ![ExchangeDefender](/assets/images/dark-xd-logo.png)USA: +1 (407) 465-6800

United Kingdom: 0800 8620149

Australia: +61 0390010641

Fax: +1 (954) 839-8737

 [    ](https://www.facebook.com/ExchangeDefender) [    ](https://www.twitter.com/XD_Defender) [    ](https://www.linkedin.com/company/exchangdefender) [    ](/blog) 

© 2026 Own Web Now Corp - All rights reserved

 &lt;/&gt; with ❤️ in Orlando

 [SLA](/sla) [TOS](/tos) [PRIVACY](/privacy-end-users) [AUP](/aup) 

 We're Here to Help 👋
--------------------

Tired of AI 🤖 and hold music? Request a call or text (sms/telco charges may apply) and someone with a brain and a pulse will get in touch with you promptly.

  Close modal     

      Website   

  Name      Email Address      Company      Phone     

  Preferred Contact Method   Text me    Call me  

   Call Date    Call Time    Time Zone  Eastern Central Mountain Pacific London Paris Madrid Berlin Tokyo Dubai Sydney   

  Request Human Contact Submitting...  

  Close 

 Start Your Free Year
--------------------

Enter your details and we will set up your free year of email protection.

  Close modal     

       Website   

  Full Name      Email     

  Continue Submitting...  

  Close 

 Try ExchangeDefender for Free 💰
-------------------------------

We look forward to helping you secure your email. We offer a free 30-day no-risk trial, just fill out the form below and one of our onboarding techs will get you started. If you'd just like to take a look at the demo, click here for a [live demo site](/demo).

  Close modal     

      Website   

  Name      Email Address      Company      Phone     

  Preferred Contact Method   Text me    Call me  

   Call Date    Call Time    Time Zone  Eastern Central Mountain Pacific London Paris Madrid Berlin Tokyo Dubai Sydney   

  💰 Get your free month Submitting...   🏃 Explore a Live Demo Submitting...  

  Close 

 Train Your Team Before the Hackers Do 👋
---------------------------------------

ExchangeDefender Spearphish is our new phishing simulation and training tool, designed to help your team spot scams before they click. Want to be first in line? Request early access or get a personal demo — just drop your name and email below.

  Close modal     

       Website   

  Name      Email Address      Company      Phone     

  Preferred Contact Method   Text me    Call me  

   Call Date    Call Time    Time Zone  Eastern Central Mountain Pacific London Paris Madrid Berlin Tokyo Dubai Sydney   

  Request Early Access Submitting...  

  Close
