Re: X-Mailer: domain
On Wed, 1 Jul 2009, Karsten Bräckelmann wrote:
> header FROM_EQ_XM ALL =~
> /^From: [^\@]+\@(?:[^.]+\.)?([^.]+\.[^.]+)>?\$.{0,400}^X-Mailer: \1\$/msi
Firstly, my thanks. This syntax provides the functionality I was asking
for in another thread where I wanted to capture things like the appearance
of the recipients e-mail address on the subject line, or cases where the
from and to headers are identical.
I haven't tried a rule continaing '\$', but I'm suprised that your usage
seems to contradict the standard rule of escaping special characters to
have them appear literally in an RE. I would guess that this is to keep
Perl from treating the '$' as the indicator of a variable substitution.
Does Perl permit this syntax because of the /m modifier? What if I want a
literal $ in my RE? :)
Anyways, thanks again for this neat tool. Now all I need is a way to
detect the 'To' address being used at the top of the message body (as in,
"dear blah@wherever").....
- C