OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: pipe mailer and dspam

From: Wietse Venema (wietseporcupine.org)
Date: Tue Aug 03 2004 - 14:31:14 CDT


Alex Stade:
> I am very new to Postfix, although I have managed sendmail for many years,
> so please forgive me if I appear less than knowledgeble.
>
> I am trying to set up a pipe mailer for use as a content_filter, but I am
> unsure what the canonical equivalent of the following is;
>
> dspam unix - n n - 10 pipe
> flags=DORhqu user=dspam argv=/opt/bin/dspam --mode=tum
> --deliver=innocent --feature=ch,no,wh -i -f ${sender} -- %u --user
> ${user}
>
> I understand what 'flags' do, as well as 'user' and most of 'argv'.
> ${sender} ought to be the sender's e-mail address and ${user} would be
> 'foo' out of 'foobar.com'. But AFAIK, the '--' ought to terminate any
> options input to the preceding command, and %u I have no idea what it
> means. I have written this rule out like this based on advice from people
> who have gotten the pipe mailer to work properly. By way of not finding
> anything in the DSPAM documentation about the '--' and '%u' I imagine that
> they could be some sort of Postfix magic.

See: man 8 pipe (the master.cf hints at the existence of manual
pages for individual Postfix daemon programs).

> Also, the '-i -f ${sender}' are intended as LDA arguments, where the LDA
> is /opt/sbin/sendmail (Postfix's sendmail binary), and I think that
> portion works.

Indeed. Be sure to use `-f ${sender}' not `-f$senfer' as that
produces unexpected results with the null sender address.

        Wietse