Ricardo Kleemann wrote:

I've ensured that /etc/courier/enablefiltering is run for both esmtp and
local (since I'm running tests on localhost).

Be sure that's what you want. There's *probably* no reason to filter "local" mail, which is why that's off by default. If only "esmtp" is specified, SMTP mail from the localhost is still filtered.

I believe I've setup perlfilter correctly and the processes are running.

# cat /etc/courier/enablefiltering
local esmtp

Looks right.

# ls /etc/courier/filters/active/
perlfilter

Use "ls -l", so we can see whether or not the symlink is "right". Mine looks like:

# ls -l /etc/courier/filters/active/
total 4
lrwxrwxrwx 1 root root 45 Mar 21 12:49 pythonfilter -> /usr/lib/courier/libexec/filters/pythonfilter

# cat /etc/courier/filters/perlfilter
/usr/lib/courier/share/perlfilter.pl

What's it doing *there*? The man page for filterctl indicates that filters belong in "/usr/lib/courier/libexec/filters". You *did* activate perlfilter.pl using filterctl, didn't you? I'm guessing that you didn't, since the symlink name isn't the same as the application's name, and the application isn't in the right spot.

# ls /var/spool/courier/filters/
perlfilter

Again, "ls -l" is more informative.

And, just as a test I've altered perlfilter.pl such that it will reject all
messages in the filterdata sub, by returning "500 Invalid Date header"
regardless of the content.

For debugging the filter, you can write to STDERR. Anything written to the filter's stderr will show up in your mail logs.




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
courier-users mailing list
[email protected]
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users

Reply via email to