furl icon indicating copy to clipboard operation
furl copied to clipboard

Seems to be a bug when paring multiple '@'s ?

Open YuanchengJiang opened this issue 2 years ago • 0 comments

Hi,

I notice one difference by applying differential testing with urllib.parse.

Case 1:

URL = "https://@david:[email protected]"
f = furl(URL)

Error: ValueError: Invalid port '[email protected]'. However, it should access the host 'testing.xyz' with username '@david' and password 'passwd'.

Case 2:

URL = "https://aa@[email protected]"
f = furl(URL)

Error: ValueError: Invalid host '[email protected]'. However, it should access the host 'testing.xyz' with username 'aa@bb'.

When parsing multiple '@'s, I think the domain should be sliced by the last '@' rather than the first '@'.

Thanks, Yuancheng

YuanchengJiang avatar Sep 20 '22 05:09 YuanchengJiang