Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Email-Address CPAN distribution.

Report information
The Basics
Id: 44920
Status: open
Priority: 0/
Queue: Email-Address

People
Owner: Nobody in particular
Requestors: dev040_osa [...] mail.ua
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: www [...] rjbs.manxome.org
Subject: Bug with 2 dots in Email::Address
Date: Fri, 10 Apr 2009 16:10:35 +0300
To: bug-Email-Address [...] rt.cpan.org
From: Oleg Savchuk <dev040_osa [...] mail.ua>
Distribution name and version: Email-Address-1.889 Perl version: 5.8.8.817 Operating System: all platforms (Linux and Windows) Problem description: If I try to parse email with 2 dots I got partial email. Example: qqq www <yana..kor@mail.ua> => kor@mail.ua yana.(test).kor@mail.ua => kor@mail.ua I've compared parsing results with Mail::Address and got the following: Email::Address $VAR1 = [ bless( [ undef, 'kor@mail.ua', '', 'kor@mail.ua', [ \'qqq www <yana..kor@mail.ua>, yana.(test).kor@mail.ua', '0' ] ], 'Email::Address' ), bless( [ undef, 'kor@mail.ua', '', 'kor@mail.ua', [ $VAR1->[0][4][0], '1' ] ], 'Email::Address' ) ]; Mail::Address $VAR1 = [ bless( [ 'qqq www', 'yana..kor@mail.ua', '' ], 'Mail::Address' ), bless( [ '', 'yana..kor@mail.ua', '(test)' ], 'Mail::Address' ) ]; Could you please fix this in Email::Address module? Thanks, Oleg Savchuk www.osa.mail.ua
CC: undisclosed-recipients: ;
Subject: Re: [rt.cpan.org #44920] Bug with 2 dots in Email::Address
Date: Fri, 10 Apr 2009 09:28:18 -0400
To: Oleg Savchuk via RT <bug-Email-Address [...] rt.cpan.org>
From: Ricardo SIGNES <rjbs [...] cpan.org>
* Oleg Savchuk via RT <bug-Email-Address@rt.cpan.org> [2009-04-10T09:11:38] Show quoted text
> qqq www <yana..kor@mail.ua> => kor@mail.ua > yana.(test).kor@mail.ua => kor@mail.ua
I'll look into this. Please keep in mind that the fix still might not be what you want. Two dots may not appear in a row in an unquoted section of the local-part. yana..kor@mail.ua ...is not a valid email address. -- rjbs
Subject: Re: [rt.cpan.org #44920] Bug with 2 dots in Email::Address
Date: Fri, 10 Apr 2009 16:41:22 +0300
To: bug-Email-Address [...] rt.cpan.org
From: Oleg Savchuk <dev040_osa [...] mail.ua>
Show quoted text
----- Original Message ----- Від: "Ricardo SIGNES via RT" <bug-Email-Address@rt.cpan.org> Кому: dev040_osa@mail.ua Надіслано: 10.04.2009 16:29:03 Тема: Re: [rt.cpan.org #44920] Bug with 2 dots in Email::Address
> <URL: http://rt.cpan.org/Ticket/Display.html?id=44920 > > > * Oleg Savchuk via RT <bug-Email-Address@rt.cpan.org> > [2009-04-10T09:11:38]
> > qqq www <yana..kor@mail.ua> => kor@mail.ua > > yana.(test).kor@mail.ua => kor@mail.ua
> > I'll look into this. > > Please keep in mind that the fix still might not be what > you want. Two dots > may not appear in a row in an unquoted section of the > local-part. > > yana..kor@mail.ua > > ...is not a valid email address. > > -- > rjbs > >
thank you for quick response. Ok, if "yana..kor@mail.ua" is really not valid, maybe it would be better that Email::Address->parse would not return it at all (as with other invalid addresses)? At least this will not lead to incorrect partial address as result. Thank you, Oleg
CC: undisclosed-recipients: ;
Subject: Re: [rt.cpan.org #44920] Bug with 2 dots in Email::Address
Date: Fri, 10 Apr 2009 09:54:50 -0400
To: Oleg Savchuk via RT <bug-Email-Address [...] rt.cpan.org>
From: Ricardo SIGNES <rjbs [...] cpan.org>
* Oleg Savchuk via RT <bug-Email-Address@rt.cpan.org> [2009-04-10T09:41:58] Show quoted text
> Ok, if "yana..kor@mail.ua" is really not valid, maybe it would be better that > Email::Address->parse would not return it at all (as with other invalid > addresses)?
Agreed, that's what I'm going to try to look into. I can't promise a quick fix. The code is fairly complex (because it's a maze of regular expressions), and I'm pretty busy this month. I'll at least try to commit a TODO test, today. (Please feel free to fork on github.com/rjbs/email-address if you want to have a go yourself!) -- rjbs