|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
Making FILTER work in UCE header_checks
From: Crispin Olson (colson
rdemail.com)
Date: Tue Apr 01 2003 - 13:59:58 CST
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Folks,
I have a filter that works OK using the 'content_filter' method - I have
a c program that takes piped input, and reinjects into the system using
a different port, where the filtering has been disabled with a -o
content_filter= {blank} in the command in master.cf - and this daemon is
only bound to the loopback so only programs running locally (like my
filter) can get access.
The intent is to check, then redirect messages that contain a pattern in
the header, and it works fine
However, I would like to move to using the regular expression checks in
2.0, to avoid having to put mail that doesn't contain the pattern
through the filter. So I added
header_checks=regexp:/usr/postfix/header_checks
in main.cf. In header checks I put
/mypattern/ FILTER myfilter:
(had to add the : even though it says the nexthop bit after the
transport is optional)
In order to avoid a content filtering loop I modified my unfiltered
daemon in master.cf to read -o header_checks= {blank}
However it would seem that the system doesn't allow me to override, and
I end up with a content filtering loop anyway. I've also tried the other
way around
-o header_checks=regexp:/usr/postfix/header_checks
after the main SMTP daemon entry in master.cf, and removing the config
line from main.cf, but its clear that the header_checks aren't even made
then, suggesting header_checks can't be overridden with -o
In the last piece of FILTER_README that describes this under "Getting
Nasty" it says you have to be careful to reinject through a clean
unfiltered SMTP daemon, but it doesn't say how.
Anyone any idea?
Crispin Olson
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]