[lug] Procmail Recipe to Match High-ASCII Characters?
bthoen at gisnet.com
Thu Feb 8 14:26:20 MST 2007
Never mind... I solved it:
* 4^1 $MATCH ?? [^0-9 A-Za-z]
* -1^1 $MATCH ?? .
Bill Thoen wrote:
> Is there a regex that can match a range of high-ascii characters? I'm
> trying to write a procmail recipe that can tell if a mail message's
> Subject: line contains 25% or more non-english characters and tag it
> as potential spam.
> Or should I reverse the logic and tag the message as spam if 25% of
> the characters are not in the desired range (e.g. [^0-9 A-Za-z]).
> Then, of course, I need to be able to count the total number of
> characters in the line and the total number of characters that
> match/don't match the filter. Can I do this with Procmail, or is there
> an easier way catch non-english mail?
> - Bill Thoen
> Web Page: http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
More information about the LUG