简体   繁体   中英

Exchange 2013 Mail flow rule using RegEx

We're trying to implement a rule on certain mailboxes that it shouldn't accept an email without a subject.

I found documentation from Microsoft on exchange 2010 to Configure a Transport Rule for Messages That Have a Blank Subject , but I tried using the ^$ RegEx with Exchange 2013 and it doesn't seem to work.

I also looked at the Transport Rule Predicates for Exchange 2013 and it clearly says that SubjectMatchesPatterns matches messages where text patterns in the Subject field match a specified regular expression .

My workaround was to reject all messages to those specific mailboxes except if subject pattern matches . but if I want to add now conditions ie. to reject emails with a subject "Sent from my snipping tool" I can't do it.

I found Here that Exchange 2013 now supports extended RegEx but I didn't find that the syntax for ^$ should be any different in extended RegEx.

\\s+匹配空格,也许尝试一下。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM