-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Python: Model outgoing HTTP client requests #2904
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
a976a07
to
d268cbc
Compare
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.
A few comments, otherwise LGTM.
call_origin.getObject().pointsTo(_, constructor_call_value, constructor_call) and | ||
cls = constructor_call_value.getClass() and | ||
constructor_call = cls.getACall() | ||
) |
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.
🤔 This looks quite complicated. It's not immediately clear to be why the last two lines are needed. Do you get spurious instances if you omit those lines?
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.
Yes. I should have left a comment in there explaining why I needed to do that.
Taus poitned out that the reuqest being send off, doesn't *need* to happen on a CallNode. Someone *could* use a __setattr__ or property :\
Move the stdlib tests from test/{2,3}/library-tests/ into /test/library-tests/, and deal with version by using sys.version_info (results should be the same for both versions). six tests were moved from /library-tests/web/client/stdlib => /library-tests/web/client/six
d517aca
to
4330d4e
Compare
I think this is a great starting point for modeling outgoing HTTP client requests. I wouldn't say it's perfect, but it should be good enough to get me going for the SSRF query I'm trying to get finished 😄