Hi Oleg,

Thank you for the fix!

In order to test the fix, is there a way I can get the mime4j binary, or do I 
need to recompile it from the source?

Thanks,
 
--
Nitsan Seniak
Co-founder | ccGenie
+33 6 07 01 32 94
ccGenie turns a mountain of emails into an organized project
www.ccgenie.com

Follow us on Facebook and Twitter

On 07 Mar 2014, at 17:06, Oleg Kalnichevski (JIRA) 
<[email protected]> wrote:

> 
>     [ 
> https://issues.apache.org/jira/browse/MIME4J-237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>  ]
> 
> Oleg Kalnichevski resolved MIME4J-237.
> --------------------------------------
> 
>    Resolution: Fixed
> 
> Fixed in SVN trunk and 0.7.x branch.
> 
> Please review / test.
> 
> Oleg
> 
>> The address list parser does not properly parse encoded display names that 
>> contain a comma.
>> -------------------------------------------------------------------------------------------
>> 
>>                Key: MIME4J-237
>>                URL: https://issues.apache.org/jira/browse/MIME4J-237
>>            Project: James Mime4j
>>         Issue Type: Bug
>>   Affects Versions: 0.7.2
>>           Reporter: Nitsan Seniak
>>            Fix For: 0.7.3
>> 
>> 
>> The address list parser doesn't correctly parse an address that contains an 
>> encoded display names that contain a comma, for example:
>> =?utf-8?Q?"Dupont,_Gr=C3=A9goire"?= <[email protected]>
>> Here's the code to reproduce the problem:
>> String str = "=?utf-8?Q?\"Dupont,_Gr=C3=A9goire\"?= 
>> <[email protected]>";
>> AddressList addressList = 
>> LenientAddressBuilder.DEFAULT.parseAddressList(str);
>> Mailbox mbox = (Mailbox) addressList.get(0);
>> System.out.println("Name: " + mbox.getName());
>> System.out.println("Address: " + mbox.getAddress());
>> The execution of this code yields:
>> Name: null                                  // Should be 
>> [email protected]
>> Address: =?utf-8?Q?"Dupont     // Should be Dupont, Grégoire
>> The problem seems to be in RawFieldParser#parseValue. Double quotes are not 
>> properly handled when the first double quote is the first character of the 
>> text to parse, which can happen with encoded addresses. In that case, if the 
>> name contains a comma and the passed delimiter bitset include the comma, 
>> then the comma in the name is mistakenly taken for a delimiter.
> 
> 
> 
> --
> This message was sent by Atlassian JIRA
> (v6.2#6252)

Reply via email to