commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gerard Bouchar (JIRA)" <j...@apache.org>
Subject [jira] [Created] (VALIDATOR-406) java.lang.IndexOutOfBoundsException in UrlValidator.isValid()
Date Mon, 19 Sep 2016 08:33:20 GMT
Gerard Bouchar created VALIDATOR-406:
----------------------------------------

             Summary: java.lang.IndexOutOfBoundsException in UrlValidator.isValid()
                 Key: VALIDATOR-406
                 URL: https://issues.apache.org/jira/browse/VALIDATOR-406
             Project: Commons Validator
          Issue Type: Bug
          Components: Routines
    Affects Versions: 1.5.1
            Reporter: Gerard Bouchar


String[] schemes = {"http","https"};
UrlValidator validator = new UrlValidator(schemes);
validator.isValid("http://aaaaa aaaaa aaaaa aaaaa aaa’aa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa
aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa
aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa aaaaa
aaaaa aaaaa");

causes : 


Exception in thread "main" java.lang.IndexOutOfBoundsException
	at sun.net.idn.Punycode.encode(Punycode.java:188)
	at java.net.IDN.toASCIIInternal(IDN.java:320)
	at java.net.IDN.toASCII(IDN.java:122)
	at java.net.IDN.toASCII(IDN.java:151)
	at org.apache.commons.validator.routines.DomainValidator.unicodeToASCII(DomainValidator.java:1764)
	at org.apache.commons.validator.routines.UrlValidator.isValidAuthority(UrlValidator.java:389)
	at org.apache.commons.validator.routines.UrlValidator.isValid(UrlValidator.java:323)
	at testBloom.TestBloom.main(TestBloom.java:153)





--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message