[ 
https://issues.apache.org/jira/browse/VALIDATOR-406?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Benedikt Ritter updated VALIDATOR-406:
--------------------------------------
    Fix Version/s: 1.5.2

> 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
>             Fix For: 1.5.2
>
>
> 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)

Reply via email to