-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
fix: do not allow invalid hazardous keys in query #880
Conversation
As a more rigorous and reliable alternative: return the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I think this makes sense as it could avoid weird forced bugs when sharing a URL with intentionally wrong query params
Co-authored-by: Eduardo San Martin Morote <posva@users.noreply.github.com>
Co-authored-by: Eduardo San Martin Morote <posva@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I think I will revert this change as it forbids keys like Do you have any real scenario cases where this is a problem? Otherwise I will proceed to revert this change in the next patch @cawa-93 |
No. I have no real scenarios. I see this as a safeguard against mistakes may by developer that lead to security risks |
so what security risks were you thinking about? That's a scenario |
I thinking about Prototype pollution, but I don't have any real example. I only assume that there may be some scenarios that may have some scenarios may exist when the developer makes some non-standard behavior when it can lead to problems. I only guess that there may be some scenarios (maybe when the developer makes some non-standard behavior) when it can lead to problems. |
Thanks for the input! |
I drew attention to that when parsing the search query, it is possible to some extent manipulate the prototype of the returned object. I added a few checks so that at least partially prevent it.