-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Python: Add taint for urlsplit #2875
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
Conversation
Following the setup I invented for library-tests/taint/unpacking. TestStep is still a bit annoying, since the output is not easy to eyeball; but for now I guess we can live with it :) I honestly didn't get the point of DistinctStringKinds.ql, other than showing we can handle multiple taint kinds
It isn't used by default, it has to *actively* be enabled.
I ended up writing a sanitizer for this. It's not a perfect solution, since I couldn't find a way to turn it on by default -- so right now the extra taint from urlsplit/urlparse is enabled by default, but the sanitizer isn't 😕 Anyway, do you feel happy about this @tausbn ? I realize now that I forgot to discuss this approach in person 😅 |
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.
In the short term, I think this solution is fine, especially as it'll unblock you on the larger query you're working. We definitely need a better way of handling this, though.
One comment to address, otherwise ready to merge.
I intended to rename before committing, but woops
This is actually a part of my effort for writing the SSRF query, but I think we can discuss this part without the rest.
I'm a bit skeptical about this change, since we don't handle the sanitation steps below. Would very much like your opinion @tausbn. How do we proceed from here?
Could I write a query that finds such places? Yes, yes I could... https://lgtm.com/query/1626963161462581314/