OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Subject: Re: header_checks question
From: Alain Thivillon (Alain.Thivillonhsc.fr)
Date: Fri Sep 29 2000 - 00:21:05 CDT


Liviu Daia <Liviu.Daiaimar.ro> écrivait (wrote) :

 
> No. For various reasons, the RHS in header_checks can only be
> REJECT or IGNORE, not OK. Actually, I had the same problem a few days

        Mhhhh. I generally try before answering a question in a list, so
maybe problem is more subtil than i/you/we thought:

10 [7:13] titiyoko:~> postconf mail_version
mail_version = Snapshot-20000531
11 [7:14] titiyoko:~> postconf header_checks
header_checks = regexp:/etc/postfix/headreject
12 [7:14] titiyoko:~> cat /etc/postfix/headreject
/^From: meabruti\.com/ OK
/^From: .*abruti\.com/ REJECT

220 yoko.hsc.fr ESMTP Server (Microsoft Exchange Internet Mail Service 5.5.2524.0) ready
EHLO a
250-yoko.hsc.fr
250-PIPELINING
250-SIZE 8000000
250-ETRN
250-STARTTLS
250 8BITMIME
MAIL FROM: <athsc.fr>
250 Ok
RCPT TO: <athsc.fr>
250 Ok
DATA
354 End data with <CR><LF>.<CR><LF>
From: totoabruti.com

a
.
552 Error: content rejected
RSET
250 Ok
MAIL FROM: <athsc.fr>
250 Ok
RCPT TO: <athsc.fr>
250 Ok
DATA
354 End data with <CR><LF>.<CR><LF>
From: meabruti.com

a
.
250 Ok: queued as BCBF49B387
QUIT
221 Bye
Connection closed by foreign host.

Postfix documentations about header_checks:

    At present, specifying a header pattern with OK serves no useful
purpose. A rule ending in OK affects only the header being matched. The
next header may still result in a REJECT match, causing the mail still
to be rejected.