RE: [Exim] Rewrite Help

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Bernard Stern
Date:  
À: exim-users
Sujet: RE: [Exim] Rewrite Help
On Wed, 21 Jun 2000 00:56:40 -0400 (EDT) Padraic Renaghan wrote:

(snip)

> Here is what I have so far:


> ^.*@.*foo\.com$ "${if match{$sender_address}{.*-bounce}\
> fail${if def:header_from:{$h_from:} fail}}" Fs


Mmhhh... I'm not sure but beware for the possible white space.
When dealing with such string expansions, pretty everything is
"textual". This is a trap I have been falling into often enough...

> I've tried a number of sytaxes for this, sometimes getting "misplaced
> { or }", other times getting "yielded unqualified local address:
> fail".


> Also, is there a good way to test rewrite rules like this that depend
> on other headers short of sending test messages through exim?


Yes, try pcretest that is included in the exim distribution
(needs separate buil/install, though), or try the complete
pcre (perl compatible regular expression) package you can find
at

ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-xxx.tar.gz

Current version is pcre-3.2.

Regards,

Bernard Stern, SWITCH

____________S_W_I_T_CH___Swiss Academic_______________________________________
        mail: SWITCH Head Office       a          Tel: +41 1 268 1520
              Limmatquai 138           n          Fax: +41 1 268 1568
              CH-8001 Zurich           d        e-mail: stern@???
________________________________________Reseach Network_______________________