Re: [exim] exim4: headers check syntax?

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Michael Fischer v. Mollard
Ημερομηνία:  
Προς: Chris Lightfoot
Υ/ο: exim-users
Αντικείμενο: Re: [exim] exim4: headers check syntax?


-- On Tuesday, August 22, 2006 11:23:44 +0100 Chris Lightfoot wrote:

> On Tue, Aug 22, 2006 at 12:04:01PM +0200, Michael Fischer v. Mollard
> wrote:
>> that's a cool tip (I just forgot that I could use a regexp in the ACLs).
>> But it won't work in this case, as its not "Message-ID: Garbage" but
>> "GarbageMessage-ID: XXX". Even if matching '$hdr_<EF><BB><BF>Message-ID'
>> would work (not shure about that), this would only be a very specific
>> solution. Any other idea?
>
> Is $message_headers available in an ACL (I think it is)?
> If so test that for /^[\200-\377]+Message-ID/ or similar.


With
  # header field name with 8-bit char
  deny message  = Your message contains invalid headers
  log_message   = message header 8-bit
  condition =     ${if match{$message_headers}{(?im)^[^: 
]*[\x80-\xFF]+[^:]*:}{1}{0}}
it seems to work great. Thanks.


Michael


--
Michael Fischer v. Mollard, Netzwerkadministration
Heise Zeitschriften Verlag GmbH & Co KG
Helstorfer Straße 7
D-30625 Hannover
Tel: +49 511 5352 477; Email: Michael.Fischer.von.Mollard@???