Re: [exim] rewriting headers (add and remove)

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: Michael Johnson
CC: exim-users, John Horne
Subject: Re: [exim] rewriting headers (add and remove)
On Tue, 21 Jun 2005, Michael Johnson wrote:

> Here's the complete entry in the router section (last items):
>
> # If both Reply-to and List-Post exist, copy original Reply-To
> # If List-Post exists, generate Reply-To from it
> headers_add     = ${if match {$header_list-post:} {\<mailto:(.*)\>} \
>                 {${if def:header_reply-to: \
>                 {X-Orig-reply-to: $header_reply-to:\nReply-To: <$1>} \
>                 {Reply-To: <$1>} }} \
>                 {} }

>
>
> # If both Reply-to and List-Post exist, remove original Reply-To
> headers_remove = ${if and { \
>                 {def:header_reply-to:} {def:header_list-post:}\
>                 } {reply-to} fail }


That doesn't look like a complete router to me...

> The headers aren't being added/removed.


We need debug output to see exactly what is happening.

> > Logging probably won't show you what you want to see. Run exim
> > standalone and add '-d+expand' (or '-d+all' for the whole lot) to the
> > command line. I usually run it on port 26 and capture all the output
> > into a file (something like 'exim ... -oX 26 >jhf 2>&1'). Then send a
> > test message to port 26. It just avoids messing up your usual mail
> > service on port 25 :-)
>
> Would this work?:
>
> exim -bd+all -q30m


No. A quick glance at the reference manual will show you that debugging
is set by the -d option; the -bd option starts a daemon.

> Or should I do this?:
>
> exim -bd -q30m -d+all


Yes, but as suggested above, adding something like '>/file 2>&1' is good
so that you capture the debugging output in a file.

Actually, I would not use '+all'; it includes voluminous memory
management information. '-d+expand' should show enough.


-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book