Szerző: Jelle Raaijmakers Dátum: Címzett: exim-users Tárgy: [exim] Sender address sometimes get truncated until I enable debug
log
Hi,
I've run into an issue with Exim 4.80 (Debian Stable amd64) where
sometimes the sender envelope address (the address given after the MAIL
FROM: command) is truncated to a random number of characters. It usually
happens with addresses containing equals signs (=), pluses (+) or
hyphens/dashes (-).
For example:
> s-vBH-bxWddjS2uVL2kEHv-cjlO30LT6UimlO8JySwYE5iSZ2VGI5Lw9@???
> s-vBH-bxWddjS2uVL2kEHv-cjlO30LT6UimlO8JyS
Or Facebook:
> notification+zrdpih6iocvf@???
> notification+zrdp
Exim registers these emails with their truncated sender address in the
mainlog:
> 2014-06-10 09:34:57 1WuGa7-0007ik-VS <= notification+zrdp
> H=outmail023.ash2.facebook.com (mx-out.facebook.com) [66.220.155.157]
> P=esmtps X=TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128 S=8683
> id=feceb7aea9abf11820c8158fefd3f416@???
However, our custom logging in acl_smtp_mail registers the entire
address when we log $sender_address. Somewhere in the process, the
address gets truncated.
Because our mail server is functionally a spam proxy, it sends all valid
emails to a smarthost. Exim then uses the sender address for the MAIL
FROM: command. Because the address is truncated, it tries to qualify it
with its own hostname causing invalid addresses like:
> s-vBH-bxWddjS2uVL2kEHv-cjlO30LT6UimlO8JyS@???
> notification+zrdp@???
This of course fails, because our server doesn't accept these invalid
addresses during verification phase of the smarthost. The icing on the
cake: if I enable debugging in acl_smtp_mail, the problem goes away!
> warn
> condition = ${if match
> {$sender_address}{\N(bounce|mailer|notification|alert)\N}}
> control = debug/tag=.$sender_host_address/opts=+all
This is the only difference in the entire ACL for these sender
addresses. It makes the problem virtually impossible for me to debug. My
guess would be a timing issue of sorts.