Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Duplicate
-
None
-
None
-
None
-
None
-
Operating System: other
Platform: Other
-
36560
Description
In the package: org.apache.commons.validator
In the class: EmailValidator
In the method: isValidSymbolicDomain
There is a restriction in the top domain lengths
int len = i;
if (domainSegment[len - 1].length() < 2
domainSegment[len - 1].length() > 4)
{
return false;
} Unfortunately this will limit the size between 2 and 4 characters. But in the list of top domains http://data.iana.org/TLD/tlds-alpha-by-domain.txt, there are two domains that are larger than 4 characters: travel and museum, thus these will fail. Fix, change the range from 2-4 to 2-6: int len = i; if (domainSegment[len - 1].length() < 2 || domainSegment[len - 1].length() > 6) { return false; } |
---|