[Dovecot] Bug in Deliver v1.2
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Hello,
if deliver is started with:
deliver -f sender -d user
(no -a option) and no Envelope-To header exists in the mail, two problems show up in this block in main():
if (destaddr == NULL) {
destaddr = deliver_get_address(mail, "Envelope-To");
if (destaddr == NULL) {
destaddr = strchr(user, '@') == NULL ? user :
t_strconcat(user, "@",
deliver_set->hostname, NULL);
}
}
deliver_get_address(mail, "Envelope-To") returns the argument of the -f option.
if no Envelope-To header is available, destaddr gets assigned user@hostname if user contains a domain already.
Attached patches propose fixes for the problems.
Bye,
Steffen Kaiser -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux)
iQEVAwUBSYbV5XWSIuGy1ktrAQJbKAgAut1Ix+lg2643lr6N6sSfRqkTPexloT7i MrUDE8R8wZUVxA/SpemebMOph4lIGEKlnSFA4R5a69oZIJT96ieyZ0Hsi4ueMO1c zNA3uBg3+0lo/9v7Ro7T7pPMvAsgybIrEWId0uq+YFAhNIQmqQp220cqNhzXwse/ G3UN7+BczhZS400uz88rgPzknewHr8Kl//bz7BBlPkQWhuVDRqk2sAezPQvUJqzI zzhccp2SHyFtBX3ija3Fc16uEbhTF+cmhNTvgIPDH1rmS7tcPhwFCM0HUGrBRwb2 zsn+JtHlSOl530pnO6ppyTdB7kac46RgbquFcLuLeHwBg1zdlh5ang== =xE9p -----END PGP SIGNATURE-----
On Mon, 2009-02-02 at 12:15 +0100, Steffen Kaiser wrote:
- deliver_get_address(mail, "Envelope-To") returns the argument of the -f option.
This was also buggy in the From logging case, so fixed differently: http://hg.dovecot.org/dovecot-1.2/rev/db9989630e89
- if no Envelope-To header is available, destaddr gets assigned user@hostname if user contains a domain already.
Committed your fix: http://hg.dovecot.org/dovecot-1.2/rev/8fb251e401e6
participants (2)
-
Steffen Kaiser
-
Timo Sirainen