You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Tracy Snell (JIRA)" <ji...@apache.org> on 2010/10/05 17:58:40 UTC

[jira] Created: (CAMEL-3199) Allow : and , inside quoted names for addresses

Allow : and , inside quoted names for addresses
-----------------------------------------------

                 Key: CAMEL-3199
                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
             Project: Apache Camel
          Issue Type: Bug
          Components: camel-mail
            Reporter: Tracy Snell
            Assignee: Tracy Snell
            Priority: Minor


"Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hadrian Zbarcea updated CAMEL-3199:
-----------------------------------

    Affects Version/s: 2.4.0
        Fix Version/s: 2.5.0

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>    Affects Versions: 2.4.0
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>             Fix For: 2.5.0
>
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Work started: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Work on CAMEL-3199 started by Tracy Snell.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Karthz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62376#action_62376 ] 

Karthz edited comment on CAMEL-3199 at 10/6/10 2:18 PM:
--------------------------------------------------------

In MailBinding.java, in the method appendRecipientToMimeMessage(), 

{code} 
replace this line

        String[] lines = recipient.split("[,;]");

with 

        String[] lines = recipient.split("[,;](?=([^\"]*\"[^\"]*\")*[^\"]*$)");
{code} 


The regex just does a lookahead to see if every quote has its matching quote till the end.

      was (Author: karthz):
    In MailBinding.java, in the method appendRecipientToMimeMessage(), replace this line

        String[] lines = recipient.split("[,;]");

with 

        String[] lines = recipient.split("[,;](?=([^\"]*\"[^\"]*\")*[^\"]*$)");


The regex just does a lookahead to see if every quote has its matching quote till the end.
  
> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>    Affects Versions: 2.4.0
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>             Fix For: 2.5.0
>
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62377#action_62377 ] 

Tracy Snell edited comment on CAMEL-3199 at 10/5/10 9:08 PM:
-------------------------------------------------------------

Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

Actually this is the regex I used:

{code}
  String[] lines = recipient.split("[,;]++(?=(?:(?:[^\\\"]*+\\\"){2})*+[^\\\"]*+$)");
{code}

      was (Author: tjsnell):
    Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

Actually this is the regex I used:

  String[] lines = recipient.split("[,;]++(?=(?:(?:[^\\\"]*+\\\"){2})*+[^\\\"]*+$)");
  
> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tracy Snell updated CAMEL-3199:
-------------------------------

    Attachment: camel-mail-patch.txt

Here's the new regex and a modified test for coverage.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Karthz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62376#action_62376 ] 

Karthz commented on CAMEL-3199:
-------------------------------

In MailBinding.java, in the method appendRecipientToMimeMessage(), replace this line

        String[] lines = recipient.split("[,;]");

with 

        String[] lines = recipient.split("[,;](?=([^\"]*\"[^\"]*\")*[^\"]*$)");


The regex just does a lookahead to see if every quote has its matching quote till the end.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62377#action_62377 ] 

Tracy Snell edited comment on CAMEL-3199 at 10/5/10 9:07 PM:
-------------------------------------------------------------

Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

Actually this is the regex I used:

  String[] lines = recipient.split("[,;]++(?=(?:(?:[^\\\"]*+\\\"){2})*+[^\\\"]*+$)");

      was (Author: tjsnell):
    Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

Actually this is the regex I used:

  String[] lines = recipient.split("[,;]++(?=(?:(?:[^\\\"]*+\\\"){2})*+[^\\\"]*+)");
  
> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hadrian Zbarcea updated CAMEL-3199:
-----------------------------------

    Patch Info: [Patch Available]

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>    Affects Versions: 2.4.0
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>             Fix For: 2.5.0
>
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62377#action_62377 ] 

Tracy Snell commented on CAMEL-3199:
------------------------------------

Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hadrian Zbarcea resolved CAMEL-3199.
------------------------------------

    Resolution: Fixed

Patch applied with thanks to Tracy Snell. Nice contribution, keep them coming.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>    Affects Versions: 2.4.0
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>             Fix For: 2.5.0
>
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62380#action_62380 ] 

Hadrian Zbarcea commented on CAMEL-3199:
----------------------------------------

I assume the pom.xml change is unintentional.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62377#action_62377 ] 

Tracy Snell edited comment on CAMEL-3199 at 10/5/10 9:07 PM:
-------------------------------------------------------------

Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.

Actually this is the regex I used:

  String[] lines = recipient.split("[,;]++(?=(?:(?:[^\\\"]*+\\\"){2})*+[^\\\"]*+)");

      was (Author: tjsnell):
    Heh, that's exactly what I did. Added it to the test, now just testing with an example to do a final confirmation.
  
> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Tracy Snell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62381#action_62381 ] 

Tracy Snell commented on CAMEL-3199:
------------------------------------

Fat fingers in my IDE :) Blitz that change.

> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (CAMEL-3199) Allow : and , inside quoted names for addresses

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=62382#action_62382 ] 

Hadrian Zbarcea edited comment on CAMEL-3199 at 10/5/10 11:55 PM:
------------------------------------------------------------------

Patch applied (r1004889) with thanks to Tracy Snell. Nice contribution, keep them coming.


      was (Author: hadrian):
    Patch applied with thanks to Tracy Snell. Nice contribution, keep them coming.
  
> Allow : and , inside quoted names for addresses
> -----------------------------------------------
>
>                 Key: CAMEL-3199
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3199
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-mail
>    Affects Versions: 2.4.0
>            Reporter: Tracy Snell
>            Assignee: Tracy Snell
>            Priority: Minor
>             Fix For: 2.5.0
>
>         Attachments: camel-mail-patch.txt
>
>
> "Snell, Tracy" <tj...@juicelabs.com> breaks with the current address parsing.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.