On Wednesday, July 01, 2009 at 07:02 CEST, Rob Brandt <bro...@csd-bes.net> wrote:
> Sahil Tandon wrote: > > > I prefer pcre:, but the following patterns should work with regexp: > > as well. No, {n} isn't supported by regexp. > > /^Subject:.*\*{3}SPAM\*{3}/ DISCARD ***SPAM*** > > > > /^X-Spam-Flag: YES$/ DISCARD Spam Flag > > Still doesn't seem to be working. Still using regexp, it seems I > don't have pcre installed as postfix throws errors when I try it. "postconf -m" indicates which map types are supported. > I'm focusing on the X-Spam-Flag one since they both should eliminate > the same emails anyway. I've tried it both with the colon and > without. Is here a log somewhere where I can see what's going on? You can use "postmap -q" to test input strings. The following patterns are regexp-compatible: /^Subject:.*\*\*\*SPAM\*\*\*/ DISCARD ***SPAM*** /^X-Spam-Flag: YES$/ DISCARD Spam Flag Test them with "postmap -q" first. If it doesn't work you need to provide an example email with these headers. Please do not top-post. -- Magnus Bäck mag...@dsek.lth.se