-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uri::getBaseUrl() should escape @ in password #2201
Comments
I'm not sure that the URL Standard is an actual RFC. However, I can see the argument that we should percent-encode at least the This URL Standard suggests percent-encoding all these characters:
If we did this, will we break BC? |
Note that the W3C HTML validator also complains about this if such an URL is used in a |
@akrabat in theory a password could contain any of those values. I would still think this would be fine as it is a bug-fix... |
This should be fixed, yes @RyanNerd |
Actually, see #2207 - this is needed for Slim 3 too. |
I don't know if the output of the
|
Hello,
Some user decided to use my app behind an Apache basic auth and some of the libraries I use started throwing errors about URLs. Turns out it was because they had a
@
in their password.And inded this code:
returns
https://foo:b@[email protected]
.But according the URL standard, the user and password should be percent-encoded:
https://foo:b%[email protected]
.The text was updated successfully, but these errors were encountered: