Knowledge Base

How to manually add or remove connectors and transport rules using the Classic Exchange admin center

Problem:

You want to use the Classic Exchange admin center to manually configure the Exchange Online connectors and add the transport rule that are needed for CodeTwo Email Signatures for Office 365 to work correctly in server-side and combo mode or remove them manually. 

Solution:

Use the links below to learn how to perform the following tasks in the Classic Exchange admin center:

Manual configuration of Exchange Online connectors

You can also configure Exchange Online connectors manually in the Exchange admin center of your Microsoft 365. Manual setup might be useful if you have any problems with the connectors' configuration wizard, need non-standard (not available in the wizard) settings, or if you simply prefer to create connectors yourself.

Warning

CodeTwo strongly recommends that you use the configuration wizard instead of manually setting up connectors, to avoid mistakes and unsupported customizations.

To configure the connectors manually, follow the steps below.

  1. Access the mail flow configuration pages in Exchange admin center.
  2. Configure the inbound connector for CodeTwo Email Signatures for Office 365.
  3. Configure the outbound connector for the program.
  4. Configure the transport rule for the outbound connector.

Opening mail flow configuration in Exchange admin center

To manually add your connectors, start with logging in to your Office 365 tenant as administrator. On the Home screen, select Admin (Fig. 1.) to enter your Microsoft 365 admin center.

Accessing Microsoft 365 admin center.
Fig. 1. Accessing Microsoft 365 admin center.

Enter your Microsoft 365 Exchange admin center via the navigation menu on the left side (Fig. 2.).

Opening Exchange admin center.
Fig. 2. Opening Exchange admin center.

Select mail flow from the menu (Fig. 3.).

Accessing mail flow configuration pages from Exchange admin center.
Fig. 3. Accessing mail flow configuration pages in Exchange admin center.

Now you have to configure the mail flow configuration pages. The whole procedure is described in detail in the sections below. In a nutshell, you will need to add two connectors (Fig. 3.) and a transport rule:

ESIG for O365 Connectors Exchange admin center
Fig. 4. CodeTwo connectors in Exchange admin center.

Configuration of the inbound connector

First, create an inbound connector on the connectors tab (see Fig. 4.). Click the plus (+) button to create a new connector. On the pop-up page (Fig. 5.), select From: Your organization's email server, To: Office 365.

Inbound connector configuration.
Fig. 5. Inbound connector configuration.

On the next page (Fig. 6.), enter the following name: CodeTwo Inbound Connector 2.0 and make sure that the Turn it on and Retain internal Exchange email headers (recommended) checkboxes are both enabled (selected).

ESIG for O365 Inbound Connector 2.0
Fig. 6. Inbound connector configuration.

On the last page (Fig. 7.), select the first radio button and provide the domain name as follows:

[your unique subdomain name].smtp.codetwo.online

Info

In order to get your unique subdomain name:

  1. In the Classic Exchange admin center go to mail flow and open the accepted domains tab.
  2. Find the domain name ending with *.smtp.codetwo.online.

Inbound connector configuration.
Fig. 7. Inbound connector configuration.

Click Next and then Save to finish the configuration.

Configuration of the outbound connector

Next, create an outbound connector via the plus (+) button (see Fig. 4.). On the pop-up page (Fig. 8.), select From: Office 365, To: Your organization's email server.

Outbound connector configuration.
Fig. 8. Outbound connector configuration.

On the next page, enter the following name: CodeTwo Outbound Connector and make sure that the Turn it on and Retain internal Exchange email headers (recommended) checkboxes are both enabled (selected), as shown in Fig. 9.

Outbound connector configuration.
Fig. 9. Outbound connector configuration.

In the next step (Fig. 10.), choose the first option (Only when I have a transport rule set up...).

Outbound connector configuration.
Fig. 10. Outbound connector configuration.

On the next page (Fig. 11.), add the following CodeTwo smart host address:

[your unique subdomain name].smtp.codetwo.online

Info

In order to get your unique subdomain name:

  1. In the Classic Exchange admin center go to mail flow and open the accepted domains tab.
  2. Find the domain name ending with *.smtp.codetwo.online.

ESIG for O365 manual outbound connector 4
Fig. 11. Outbound connector configuration.

In the next step, configure the options as shown in Fig. 12. and make sure that you provide the address:

*.codetwo.com

as the domain name on the certificate. Proceed to the connector validation step by clicking Next.

Outbound connector configuration.
Fig. 12. Outbound connector configuration.

Finally, you have to validate the outbound connector (Fig. 13.) by typing any external (not hosted in Microsoft 365) email address. Click Validate and - after successful validation - click Save to finish the configuration of the outbound connector.

ESIG for O365 outbound connector validation.
Fig. 13. Validation of the outbound connector.

Warning

If you are not able to validate your connectors and you get the following (or similar) error:

401 4.5.4 Invalid arguments - possible version mismatch [VE1EUR01FT009.eop-EUR01.prod.protection.outlook.com]

then you might be experiencing a recent Microsoft 365 health issue. This problem is not related to our software.

Manual configuration of the CodeTwo Exchange transport rule

Once you're done with connectors, you need to create a new transport rule that will specify senders whose emails will be processed by the CodeTwo Email Azure Service.

Important

Every sender selected in this step will use one license from your license pool, no matter if the sender is defined in any signature rule. That is why you should pay special attention to properly define the scope of senders in the transport rule.

This configuration corresponds to the Senders scope step during the automatic configuration of connectors (learn more earlier in this article). You can specify the following scopes of senders:

Configuration of the transport rule for all AD users

To add and configure a new transport rule for all AD users (including emails sent internally in your organization), switch to the rules tab. Use the plus (+) button to create a new rule (Fig. 14.).

ESIG 365 add new transport rule in Exchange Online
Fig. 14. Adding a new transport rule for the program's outbound connector.

Configure the rule in the following way:

  • Type the following name: CodeTwo Exchange transport rule
  • Click the More options... link at the bottom to show all configuration settings.
  • In the Apply this rule if... section, add the following condition: The sender... > is external/internal. Select Inside the organization
  • In the Do the following... section, add the following action: Redirect the message to... > the following connector > CodeTwo Outbound Connector
  • In the Except if... section, add the following three exceptions:
    • The sender... > address matches any of these text patterns... > specify the following phrase: <>
    • The message properties... > include the message type > select the following message type: Calendaring
    • A message header... > matches these text patterns > specify the following header name:
      X-CodeTwoProcessed and enter the following text pattern: true

Leave the other options with their default settings, except for these fields:

  • Defer the message if rule processing doesn't complete - must be enabled (selected)
  • Match sender address in message - change to Header or envelope

Review your settings - compare them with Fig. 15. and make sure your rule looks exactly the same.


Fig. 15. The correct configuration of the CodeTwo Exchange transport rule for all users.

Important

In the above configuration, emails of all of your users will be routed through the CodeTwo Email Azure Service to receive signatures. This might lead to excessive usage of licenses (learn more).

The created transport rule is applied to both outgoing and internal messages. If you do not want to add signatures to emails sent between the users inside your tenant, you need to specify an additional condition, as described in this section.

Configuration of the transport rule for selected users or groups

If you want to add a transport rule that limits your users to a particular group in your Microsoft 365, start with configuring a transport rule for all users, as described earlier in this article. If all the settings are exactly as in Fig. 15., add another condition in the Apply this rule if... field: you can select individual senders (The sender... > is this person) or groups (The sender... > is a member of this group) from the menu. An example of changing the scope of senders to a distribution group (Engineering) is shown in Fig. 16.


Fig. 16. Limiting the scope of senders.

The transport rule will be applied to both outgoing and internal messages sent by the users and/or members of the group(s) you specified. Note that if the group you selected has other groups nested inside, emails sent by members of the nested groups will also travel through the CodeTwo service.

Tip

If you need guidelines on how to add multiple groups or if some of your groups are not displayed in the group picker, see our Knowledge Base article.

If you do not want to add signatures to emails sent between the users inside your tenant, you need to add and configure another condition, as described in the next section.

Configuration of the transport rule to exclude internal emails

If you would like to stop adding signatures to your internal correspondence, you need to modify your transport rule by adding an extra condition in the Apply this rule if... field. Click add condition, select The recipient... is external/internal and choose Outside the organization. The condition should appear as shown in Fig. 17.

Additional condition to exclude internal correspondence.
Fig. 17. Additional condition to exclude internal correspondence.

Important

If you use smart host (mail relay) services in your organization, additional configuration might be required. See this article for details.

How to manually remove connectors and transport rule in Microsoft 365 (Office 365)

Warning

This option should be used only as a last resort if, for some reason, the connectors removal wizard cannot be completed.

Warning

The following instructions on how to remove connectors do not apply if your program is working in client-side mode.

If you are working in combo mode, removing the connectors will stop emails from being routed to CodeTwo Email Azure Service and the signatures will not be added there. However, signatures may still be added for users with installed CodeTwo Signatures Add-in for Outlook unless the add-in has been disabled or your client-side signature rules have been turned off.

Log in to your Microsoft 365 tenant. Go to Admin (Fig. 18.), find Exchange in the left-hand side menu and click on it. Exchange admin center opens. Go to mail flow (Fig. 19.). On the rules tab, find the CodeTwo rule and delete it (Fig. 20.). Now go to the connectors tab, find two CodeTwo connectors (one is inbound and the other - outbound) and delete them both (Fig. 21.).

Accessing Microsoft 365 admin center.
Fig. 18. Accessing Microsoft 365 admin center.

Mail flow configuration in Exchange On-line dashboard.
Fig. 19. Mail flow configuration in Exchange On-line dashboard.

CodeTwo transport rule that should be removed.
Fig. 20. CodeTwo transport rule that should be removed.

CodeTwo connectors that should be removed.
Fig. 21. CodeTwo connectors that should be removed.