Forum Discussion
Robert Bollinger
Sep 08, 2022Brass Contributor
Transport Rules, RegEx (Ish).
Hey Team,
We have a need to block any emails that come from;
- domain.com
- sub.domain.com
- dom.domain.com
I have created a transport rule and it works as expected, I chose Sender Address Matches Pattern:
domain.com$
That all works as expected. However in reading the documentation I understand I am supposed to escape the ($) character. That is the part I am having an issue with. Do i really need to escape the dollar sign? it comes at the end of the expression.
Regular Expressions in Transport Rules: Exchange 2010 Help | Microsoft Docs
Thanks,
Robert
Yes, $ is working, you can refer below URL on some sharing as well, it embedded a link for regex test as well:
- Robert BollingerBrass ContributorSorry i don't think i understand your reply. I want to block:
domain.com
sub.domain.com
dom.domain.com
(all subdomains + the parent domain)
That is working. I just want to understand why or if I need the "\" character in addition to what i already have.
Thanks,
Robert