-
Notifications
You must be signed in to change notification settings - Fork 1.7k
PY: change alert messages of path queries to use the same template #10252
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
73cdf9f
to
953cc1a
Compare
953cc1a
to
089ce5a
Compare
Hello from this week's docs first responder 👋 Thanks for the ping! I've added this PR to our review board for another writer to look at. They'll be able to advise on any additional considerations for this change. |
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.
One comment/suggestion, otherwise these all look good to me. 👍
select sink.getNode(), source, sink, "This value modification depends on a $@.", source.getNode(), | ||
"default value" |
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 one sounds a bit strange to me ("'value modification'? What's that?"), but I couldn't come up with a better phrasing.
Also, "depends on a default value" seems too weak of a statement to me. It not only depends on a default value, it actively mutates said default value.
Edit: Perhaps "This expression mutates a default value.
" would be better?
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.
Actually, s/mutates/modifies/
might be even better.
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.
Also, "depends on a default value" seems too weak of a statement to me. It not only depends on a default value, it actively mutates said default value.
You're right, it's a DataFlow::Configuration
and not a TaintTracking::Configuration
, so depends is too weak a statement.
"This expression mutates a default value" sounds good to me 👍
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.
As I mentioned in a comment, I'm rather rusty on select statements.
Assuming that I'm reading these correctly, these changes look clearer to me ✨
select sink.getNode(), source, sink, "This path depends on $@.", source.getNode(), | ||
"a user-provided value" |
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.
I'm rather rusty on how these select statements look in results. Am I right to think that this is shown as:
This path depends on a user-provided value.
If so, this looks good to me 👍🏻
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.
Yep, that's right!
This partly reverts the changes from github#10252 Although consistency is nice, the new messages didn't sound as natural. New alert message would read > Insecure hashing algorithm (md5) depends on sensitive data (password). (...) I'm not sure what it means that a hashing algorithm depends on data. So for me, the original text below is much easier to understand. > Sensitive data (password) is used in a hashing algorithm (md5) that is insecure (...) Same goes for the other sensitive data queries.
I tried to rewrite alert messages for the taint tracking queries.
This path depends on a user-provided value.
User-provided value flows to this location and is used in a path.
I also generally tried to use "this location" instead of "here".
I tried to formulate messages to use "depends on" and use the term "a user-provided value".
The previous change-note for changing the alert messages still cover this PR.