Hello SmarterTools team,
Following my previous feature request regarding Routing Rules and gateway selection, I performed additional testing and discovered what appears to be an inconsistency in how routing rules are applied when multiple recipients are present in the same message.
I would like to understand whether this behavior is expected by design or if it may be a bug.
Test Scenario
Configured gateways:
Routing Rule:
Test Results
Case 1 – Single Recipient
To: user@gmail.com
Result:
Expected:
To: user@outlook.com
Result:
Expected:
Case 2 – Multiple Recipients in TO
To: user@gmail.com; user@outlook.com
Result:
Observation:
While this may not be ideal, it is at least predictable.
Case 3 – Gmail in TO, Outlook in CC
To: user@gmail.com
CC: user@outlook.com
Result:
Again, the routing rule appears to be applied to the entire message.
Case 4 – Outlook in TO, Gmail in CC
To: user@outlook.com
CC: user@gmail.com
Result:
In this scenario, the Gmail recipient in CC is completely ignored by the routing rule, even though it matches the configured condition.
This behavior seems inconsistent with the previous cases.
Why This Matters
I operate in Brazil and use international outbound filtering gateways located in the US and Europe.
Unfortunately, some Brazilian organizations block SMTP connections originating from foreign countries and only accept connections from Brazilian IP addresses (or a small list of approved countries).
To work around this, I developed an automated process that detects delivery failures and automatically adds affected recipient domains to a routing rule that sends mail through a dedicated Brazilian outbound gateway.
This works correctly when those recipients are included in the TO field.
However, if a user sends a message to another recipient and places one of these domains in CC, SmarterMail appears to ignore the routing rule and uses the default international gateway instead, causing delivery failures that the routing rule was specifically created to avoid.
Is this behavior expected?
From my perspective, each recipient should be evaluated independently against the configured routing rules. If different recipients require different gateways, SmarterMail could split the delivery into separate outbound transactions, ensuring that all routing policies are respected.
I would appreciate clarification from the development team regarding whether this is intended behavior and whether improvements in this area are being considered.
Thank you.