commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nick Burch (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (VALIDATOR-275) EmailValidator.isValid(String) follows RFC822 but violates RFC1034
Date Fri, 27 May 2011 17:18:47 GMT

    [ https://issues.apache.org/jira/browse/VALIDATOR-275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13040338#comment-13040338
] 

Nick Burch commented on VALIDATOR-275:
--------------------------------------

I've added a unit test for this in r1128401. Using the newer routines EmailValidator, an email
like "exam+ple@example.com" is valid, but "example@example+3.com" isn't, so we now follow
RFC1034

> EmailValidator.isValid(String) follows RFC822 but violates RFC1034
> ------------------------------------------------------------------
>
>                 Key: VALIDATOR-275
>                 URL: https://issues.apache.org/jira/browse/VALIDATOR-275
>             Project: Commons Validator
>          Issue Type: Improvement
>          Components: Framework, JavaScript
>         Environment: All
>            Reporter: Adam Gordon
>             Fix For: 1.4
>
>   Original Estimate: 2h
>  Remaining Estimate: 2h
>
> Per RFC822, the domain portion of an email address may contain any ASCII character other
than chars 0-31 (control characters), 32 (space character) and any of the following: "(",
")", "<", ">", "@", ",", ";", ":", "\", <", ".", "[", "]".
> However, RFC1034, the DNS Domain Name spec specifies that domain names can only contain
alpha numerical characters and the hyphen/dot characters.
> The RFC's contradict each other and while technically the EmailValidator class is doing
what it says (in that it does not guarantee to catch all errors) when one passes in an email
address of the form foo@bar+3.com it yields a potentially bad email address which the user
won't find out about until they actually try and send the email message.  I've not yet found
a mail server that accepts an email address of this format, however it is possible there are
legacy systems out there that do support it.
> I realize that this is not a bug, per se, but it seems like EmailValidator should probably
do something or provide some mechanism to ensure that the email address specified is as valid
as possible than waiting until the message is actually sent before failing.
> I am, however, open to discussion.
> This bug was also filed against the JavaMail API's InternetAddress class here:  https://kenai.com/bugzilla/show_bug.cgi?id=202

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message