Stefan Parvu wrote:
> This is a spam REJECT
> makemap -t\tab hash spamsubjects < spamsubjects
> Kspamsubdb hash /etc/mail/spamsubjects
> HSubject: $>ScreenSubject
> SScreenSubject
> R $* $: $(spamsubdb $&{currHeader} $: OK $) $1
> R REJECT $* $#error $: "553 Subject:" $1 ": Not allowed"
> But it does not work. Nothing gets blocked. Any ideas what I am doing wrong?
"It's complicated"
op.txt: {currHeader} ... ``Header value as quoted string''
which means
'a b c'
is represented as
'" a b c "'
BUT for the map lookup the quotes are removed leaving us with:
' a b c'
"interesting", isn't it?
So this should work:
This is a spam REJECT
(space.........tab)
In general it is better to use a regex map to match the values
of "unstructured" headers (non-address fields).
--
Note: please read the netiquette before posting. I will almost never
reply to top-postings which include a full copy of the previous
article(s) at the end because it's annoying, shows that the poster
is too lazy to trim his article, and it's wasting the time of all readers.