[Fwd: Re: Mails in incoming cause of "invalid from"]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
sorry, i just replyed this to mads... so again to the list :)
Regards,
Sven
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQFFCycQQoCguWUBzBwRAomTAKCprf70oerL90IIIY5s3i1S/4tYNQCfasgt 9Dq+cVbGmy17KTuQv/FcMpw=
=SIZo
-----END PGP SIGNATURE-----
Quoted 1 line · Mads Martin Joergensen
Can you put the mail from the discarded directory somewhere and show me?
They stay in incoming btw.
tar'ed:
http://www.c3f2m.de/broken-mails.tar
Regards,
Sven
Quoted 4 lines · Sven 'Darkman' Michels
They stay in incoming btw.
Just tried to reproduce, and cannot. Can you reproduce with 1.2.12-RC2?
Signature · 4 lines
Mads Martin Joergensen, http://mmj.dk
"Why make things difficult, when it is possible to make them cryptic
and totally illogical, with just a little bit more effort?"
-- A. P. J.Quoted 20 lines · Sven 'Darkman' Michels
Quoted 1 line · Mads Martin Joergensen
Just tried to reproduce, and cannot. Can you reproduce with 1.2.12-RC2?
Yep. I updated to rc2 and did:
cat incoming/5dc2658876e70a91 |/usr/bin/mlmmj-recieve-L/var/spool/mlmmj/test/With 1.2.11 i saw output on the shell, now i don't. But: i see logs from
mlmmj-process.cwhich told me that the mail was discarded, and with RC2 the mail now is put into the discard dir, not left in incoming anymore.
Log:Sep 16 19:55:58 pamphlet /usr/bin/mlmmj-process[7818]: mlmmj-process.c:641: Discarding /var/spool/mlmmj/test//incoming/2d1420e3163f055e due to invalid From:: Bad file descriptor Sep 16 19:55:58 pamphlet /usr/bin/mlmmj-process[7818]: mlmmj-process.c:644: fromemails.emaillist[0] = [email protected] : Bad file descriptor Sep 16 19:55:58 pamphlet /usr/bin/mlmmj-process[7818]:
Quoted 2 lines
mlmmj-process.c:644: fromemails.emaillist[1] = Adnan Vatandas [mailto:[email protected]] : Bad file descriptor
What I meant by reproducing is creating a mail in an editor doing this? I cannot do that. So there must be something seriously fishy with this one. Haven't had a chance to examine it yet.
And please keep the list involved, since I'm no longer maintainer of mlmmj :-)
Signature · 4 lines
Mads Martin Joergensen, http://mmj.dk
"Why make things difficult, when it is possible to make them cryptic
and totally illogical, with just a little bit more effort?"
-- A. P. J.-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
Quoted 3 lines · Mads Martin Joergensen
What I meant by reproducing is creating a mail in an editor doing this? I cannot do that. So there must be something seriously fishy with this one. Haven't had a chance to examine it yet.
it has become even more serious now: with 1.2.12-RC2 the same user even can't subscribe to a new list... seems to be the same problem:
Sep 16 22:19:18 pamphlet /usr/bin/mlmmj-process[8010]:
listcontrol.c:180: Ignoring mail with invalid From: which was not a
bounce: Success
this was the reply to the confsub message... and the message has:
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Saturday, September 16, 2006 9:40 PM
To: [email protected]
Subject: [test] Confirm subscription to [email protected]
in it (notice the missing spaces for from etc!). Mailer is Outlook 11. Is it possible that something "removes" leading spaces?
*help?* ;)
Sven
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFDF0dQoCguWUBzBwRAiyIAJ9uz46VyhBxUI/BHYI51m36H6IZLgCgo24S B8BSByI+JkgOGKemb8dyg3s=r6re
-----END PGP SIGNATURE-----
Quoted 17 lines · Sven 'Darkman' Michels
Quoted 3 lines
What I meant by reproducing is creating a mail in an editor doing this? I cannot do that. So there must be something seriously fishy with this one. Haven't had a chance to examine it yet.
it has become even more serious now: with 1.2.12-RC2 the same user even can't subscribe to a new list... seems to be the same problem:
Sep 16 22:19:18 pamphlet /usr/bin/mlmmj-process[8010]:listcontrol.c:180: Ignoring mail with invalid From: which was not a
bounce: Successthis was the reply to the confsub message... and the message has:
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Saturday, September 16, 2006 9:40 PM
To: [email protected]
Subject: [test] Confirm subscription to [email protected]
Quoted 4 lines
in it (notice the missing spaces for from etc!). Mailer is Outlook 11. Is it possible that something "removes" leading spaces?
*help?* ;)
Can you try it without this patch?
chomp.c +1 -1
@@ -38,7 +38,7 @@ i =strlen (str) -1 ; -while (str[i] ='\n' ) { +while (str[i] ='\n' || str[i] ='\r' ) { str[i] =0 ; i--; }
Signature · 4 lines
Mads Martin Joergensen, http://mmj.dk
"Why make things difficult, when it is possible to make them cryptic
and totally illogical, with just a little bit more effort?"
-- A. P. J.-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Quoted 1 line · Mads Martin Joergensen
Can you try it without this patch?
doesn't work. It looks like the problem existed before because i run 1.2.11 since beginning of the year and haven't changed anything. The user with the problem did subscribe before moving to mlmmj, so we maybe never triggered that one. We played around with it now. It looks like the "From: " in the body is the normal behavior of outlook when replying to a mail. Now we add a "space" in front of the "From:" in the body and voila, it worked. So it seems the headerparser or whatever is broken. It doesn't stop parsing the mailheader after the "^$" line. May this from the new email address parsing?
I also tested this with thunderbird: when i add some "fake headers", it works with the following "code":
bla fasel
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Saturday, September 16, 2006 9:40 PM
To: [email protected]
Subject: Confirm unsubscribe from [email protected]
(maybe you need to change the listname to match yours, didn't test that)
can't check all versions back now because i'm a little bit limited in time ;)
Regards,
Sven
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQFFDZViQoCguWUBzBwRAqcOAKCdIXAbVcjghGzOZMCpCMy1ABvXmwCfcSgg mdRvH8MsVecnsYf0BGC5tZs=qfcc
-----END PGP SIGNATURE-----
Quoted 6 lines · Sven 'Darkman' Michels
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1Quoted 1 line · Mads Martin Joergensen
Can you try it without this patch?
Quoted 12 lines
doesn't work. It looks like the problem existed before because i run 1.2.11 since beginning of the year and haven't changed anything. The user with the problem did subscribe before moving to mlmmj, so we maybe never triggered that one. We played around with it now. It looks like the "From: " in the body is the normal behavior of outlook when replying to a mail. Now we add a "space" in front of the "From:" in the body and voila, it worked. So it seems the headerparser or whatever is broken. It doesn't stop parsing the mailheader after the "^$" line. May this from the new email address parsing?
mlmmj should stop parsing headers when two newlines are met like the spec claims.
That's why when I add a From: on the beginning of a line after a newline, that From: isn't picked up.
Could you look in a hex editor or such, to see if there's something making mlmmj believe there's more headers? Space or tab is enough to make it continue.
Quoted 3 lines
I also tested this with thunderbird: when i add some "fake headers", it works with the following "code":
bla fasel
Well, can you trigger it with Thunderbird, by writing From: somewhere after a newline?
Signature · 4 lines
Mads Martin Joergensen, http://mmj.dk
"Why make things difficult, when it is possible to make them cryptic
and totally illogical, with just a little bit more effort?"
-- A. P. J.Hi Sven,
Quoted 6 lines · Sven 'Darkman' Michels
Quoted 1 line · Mads Martin Joergensen
Can you try it without this patch?
doesn't work. It looks like the problem existed before because i run 1.2.11 since beginning of the year and haven't changed anything.
Yes, it is an old (but unknown) issue. We have just never seen any problems with it.
The problem is this; If a header is followed by a line beginning with whitespace, that next line is to be "folded" back into the first one (RFC 2822 section 2.2.3). We did that. However, we did not follow RFC 2822 section 3.2.3, which states:
However, where CFWS occurs in this standard, it MUST NOT be inserted in such a way that any line of a folded header field is made up entirely of WSP characters and nothing else.
So "Header: value1\n value2\n" was unfolded, but so was "\n body." So if a mail's body begin with a whitespace character, that first body line is folded onto the end-of-headers marker, and header parsing continues down through the mail body.
I have fixed the issue, and you can get the patch from
http://mlmmj.mmj.dk/~mortenp/patch-mlmmj-1.2.12_RC2-gethdrline.diff
Morten
Signature · 2 lines
Morten K. Poulsen <[email protected]> http://www.afdelingp.dk/