Menu

#1731 Basic authentication credentials in the URL could get lost

Latest SVN
closed
RBRi
None
1
2015-12-03
2015-12-03
No

HtmlUnit supports passing the credentials for basic authentication right in the URL:

http://john.smith:secret@localhost/foo.html

However, in some edge cases the credentials could get lost before the request is actually made. This happens if the passed URL needs to be modified because of

  • an empty path,
  • a path with dots, or
  • an internationalized domain name.

In all these cases a new URL will be created, but without the credentials from the original URL.

Attached are two patches, one that adds some new test cases and another one with a potential fix for this issue.

2 Attachments

Discussion

  • RBRi

    RBRi - 2015-12-03
    • status: open --> accepted
    • assigned_to: RBRi
     
  • RBRi

    RBRi - 2015-12-03

    As always, thanks for the patch.
    Changes are in SVN; will update the snapshot if the build is fine.

     
  • RBRi

    RBRi - 2015-12-03
    • status: accepted --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB