-
Notifications
You must be signed in to change notification settings - Fork 23
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
Security: Doesn't encode urls with punycode #395
Comments
Thanks for bringing this concern. I think this is still better than React Native's implementation, but still not perfect. What would you suggest in order to address this issue while remaining lightweight? Should we try to encode them with a lightweight library? Should we throw on URLs with special characters? |
I'm not sure, but it looks like you are using |
Yes. I'm the author of |
Wow thats a lot, I appreciate the effort, maybe there is a lightweight punycode lib to handle this issue. |
Malicious actors could trick victims into click phishing links, because they look exactly like the valid original domain.
E.g. the original apple.com url could be converted using the cyrillic alphabet to аррlе.com which looks identical to the original url.
That's why the browser encodes urls with special characters using punycode to xn--l-7sbq6ba.com
You can check it, if you enter this in the browser console:
this should result in
However this react-native-url-polyfill library doesn't encode urls using punycode which results in a huge security risk for the end user.
The text was updated successfully, but these errors were encountered: