You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bval.apache.org by "Matt Benson (JIRA)" <ji...@apache.org> on 2016/10/20 22:47:58 UTC
[jira] [Resolved] (BVAL-117) EMailValidationUtils matches not at
circumflex
[ https://issues.apache.org/jira/browse/BVAL-117?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matt Benson resolved BVAL-117.
------------------------------
Resolution: Fixed
Committed revision 1765901.
> EMailValidationUtils matches not at circumflex
> ----------------------------------------------
>
> Key: BVAL-117
> URL: https://issues.apache.org/jira/browse/BVAL-117
> Project: BVal
> Issue Type: Bug
> Components: jsr303
> Affects Versions: 0.5
> Reporter: Ariel Küchler
> Priority: Minor
>
> The class _EMailValidationUtils_ contains the Regex:
> {code:java}
> private static String ATOM = "[^\\x00-\\x1F^\\(^\\)^\\<^\\>^\\@^\\,^\\;^\\:^\\\\^\\\"^\\.^\\[^\\]^\\s]";
> {code}
> It looks as if each part of the character class is negate with the circumflex.
> The Javadoc of the [Pattern|http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html] class describe that one circumflex ist enough at the beginning.
> Every character in the character class is negate incl. the circumflex. So a email address with circumflex is validated to false.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)