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

ASF GitHub Bot commented on VALIDATOR-387:
------------------------------------------

GitHub user flexfrank opened a pull request:

    https://github.com/apache/commons-validator/pull/5

    VALIDATOR-387 Userinfo without colon should be valid in UrlValidator

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/flexfrank/commons-validator 
userinfo-without-colon-is-valid

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/commons-validator/pull/5.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #5
    
----
commit 91e01f882c91269560556202d5a0259db5b042bf
Author: Shumpei Akai <[email protected]>
Date:   2016-01-28T06:43:25Z

    VALIDATOR-387 Userinfo without colon should be valid in UrlValidator

----


> Userinfo without colon should be valid in UrlValidator
> ------------------------------------------------------
>
>                 Key: VALIDATOR-387
>                 URL: https://issues.apache.org/jira/browse/VALIDATOR-387
>             Project: Commons Validator
>          Issue Type: Bug
>    Affects Versions: 1.5.0
>            Reporter: Shumpei Akai
>
> UrlValidator does not accept userinfo without ":".
> The following code returns false.
> {code}
> UrlValidator validator = new UrlValidator();
> validator.isValid("http://[email protected]:80/path";)
> {code}
> But it should be accepted.
> RFC of URI allows userinfo without colon.
> https://tools.ietf.org/html/rfc3986#section-3.2.1
> {quote}
> userinfo    = *( unreserved / pct-encoded / sub-delims / ":" )
> {quote}
> RFC of URL also allows it.
> https://tools.ietf.org/html/rfc1738#section-3.1
> {quote}
>  //<user>:<password>@<host>:<port>/<url-path>
>    Some or all of the parts "<user>:<password>@", ":<password>",
>    ":<port>", and "/<url-path>" may be excluded. 
> {quote}



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

Reply via email to