Re: [exim] Limit of "to" or "cc" by a sender

Top Page
Delete this message
Reply to this message
Author: Ian Eiloart
Date:  
To: Matthew Newton
CC: exim-users
Subject: Re: [exim] Limit of "to" or "cc" by a sender


--On 9 February 2007 12:29:31 +0000 Matthew Newton <mcn4@???>
wrote:

> Hi,
>
> On Fri, Feb 09, 2007 at 11:42:20AM +0000, Ian Eiloart wrote:
>> What I'm trying to do, if I can get the syntax right, is replace long
>> headers To: and Cc: headers (say, more than 1024 chars) with a comment
>> like "long list hidden by postmaster:;". I don't see a way of actually
>> counting the number of addresses, which I'd slightly prefer.
>
> Completely untested, but how about:
>
> headers_remove = "To"
> headers_add = To: \
>               ${if >{${strlen:${sg{$header_to:}{[^,]}{}}}}{50}\
>                 {Long list hidden by postmaster:;}{$header_to:}\
>               }


Ah, that's neat. I'll try something like that - of course the
headers_remove has to be conditional, too.

The syntax I have is more complex, because I do address rewriting in the
headers (to support canonical names). For some reason it works in my test
suite, but prevents delivery when I deploy it. I think I may need to
upgrade from 4.63

> (Basically, count the number of commas in the header.)
>
> Matthew




--
Ian Eiloart
IT Services, University of Sussex