How do you use regex flags in postfix?

Altimus Prime asked:

In Postfix we can apply some basic header, body, client checks using regex. I wanted to use flags.

I added the following to the header_checks file:

/some(\s|_|-)words(\s|_|-)here/gmi REJECT

and tested it by sending myself and email with those words in the title, but I get the error in my maillog stating unknown regexp option "g": skipping this rule

Is there a proper way to apply flags or does postfix regex simply not use or acknowlege certain flags?

My answer:

There is no supported flag g, neither in POSIX regexp tables or PCRE tables. Therefore it’s impossible to understand what you intended. Is that a typo? Just remove it.

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.