Describe the bug
The Mime Header Decoding (RFC 2047) does not correctly resolve in case the display name contains an encoded comma.
The entire mailbox-list is decoded before separated into different mailboxes.
To Reproduce
The mail with header
From: =?ISO-8859-1?Q?Moore=2C_Keith?= <moore@cs.utk.edu>
is parsed to
mail._from == [('', 'Moore'), ('Keith', 'moore@cs.utk.edu')]
It appears that the header is first decoded to Moore, Keith <moore@cs.utk.edu> before getting the individual addresses.
Expected behavior
Correct would be
mail._from == [('Moore, Keith', 'moore@cs.utk.edu')]
Raw mail
Delivered-To: bruce@untroubled.org
Received: (fqmail 26559 invoked from network); 21 Aug 2016 10:49:40 -0000
Reply-To: =?ISO-8859-1?Q?Moore=2C_Keith?= <moore@cs.utk.edu>
From: =?ISO-8859-1?Q?Moore=2C_Keith?= <moore@cs.utk.edu>
Subject: PI
Date: Fri, 19 Aug 2016 15:33:29 +0100
MIME-Version: 1.0
Describe the bug The Mime Header Decoding (RFC 2047) does not correctly resolve in case the display name contains an encoded comma. The entire mailbox-list is decoded before separated into different mailboxes.
To Reproduce The mail with header
From: =?ISO-8859-1?Q?Moore=2C_Keith?= <moore@cs.utk.edu>
is parsed tomail._from == [('', 'Moore'), ('Keith', 'moore@cs.utk.edu')]
It appears that the header is first decoded toMoore, Keith <moore@cs.utk.edu>
before getting the individual addresses.Expected behavior Correct would be
mail._from == [('Moore, Keith', 'moore@cs.utk.edu')]
Raw mail
Environment: