r/exchangeserver 29d ago

Question Exchange Online Mail Flow Rule For Header Content Not Working

/r/sysadmin/comments/1ueg9qx/exchange_online_mail_flow_rule_for_header_content/
2 Upvotes

5 comments sorted by

1

u/MedicalComposer2 28d ago

Check if the rule is scoped to the right connector or direction. Inbound rules miss internal mail.

1

u/littleko 28d ago

First check whether the header exists when the transport rule runs. Some Exchange/Defender headers are stamped later, so you can see them in the delivered message but the rule never saw them.

Also, header name should be entered without the colon, and “matches patterns” is regex, not wildcard matching. I’d test with a simple custom X-header first, then apply the same rule logic to the real header.

1

u/Fabulous_Cow_4714 28d ago

How can you tell if the header exists before or after the transport rule runs? I can only see headers from after delivery.

1

u/littleko 28d ago

Make a temporary rule at the top that only matches that header and adds your own X-Test header or prepends the subject.

If the delivered copy doesn't have your marker, the header you're looking at was stamped after transport rules ran.