Warning
- DigiPortal Software
does not provide technical support on this topic and all requests
will be quietly ignored. The information in this document is provided
as-is and intended only as a starting point for advanced users familiar
with the concepts described below.
ChoiceMail One supports the use of regular expressions to specify match
conditions in permission rules. An explanation of regular expressions
is beyond the scope of this document but you can search for the phrase
using your
normal search engine to find more information on this topic. A particularly
interesting website is http://www.regexlib.com/ which
contains many examples of regular expressions. Microsoft also has an
excellent regular
expression tutorial on their website.
To use a regular expression instead of simple text, start the line
with the sequence
(regex)
Everything immediately following that sequence will be treated as the
regular expression.
Example:
(regex)(?i)v[i|1]agra
- (?i) A switch that means that
the match is not case-sensitive
- [i|1] matches either the letter
i or the number 1
So the expression above will match viagra, v1agra, ViAgRa, and so
forth.
Example:
(regex)(?i)</html>[\s]*(<.*>)*?[a-zA-Z0-9]+
Placed in the BODY section of a permission rule, this expression does
the following:
- (?i) A switch that means that the match is not case-sensitive
- </html> Looks for the
normal end tag of an HTML document ,followed immediately by
- [\s]* Any number of blank spaces, followed immediately by
- (<.*>)*? An arbitrary number of characters (including none),
followed by
- [a-zA-Z0-9]+ At least one alphanumeric
character. The uppercase range A-Z is not actually necessary due
to the (?i) switch but is good practice since the switch is not
always used.
Comment: a properly formed HTML document should never have characters after
the final </html> tag. Spammers often insert random characters
(different in every message) so that server-based filtering system will
not recognize the messages as spam (filter systems often presume that if
the identical message is received many times, then it's highly
likely to be spam).
See also
Transform rules
ChoiceMail
One User's Guide

Online Help Index