-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Java: Add query for leaking sensitive data through a ResultReceiver #11713
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
Java: Add query for leaking sensitive data through a ResultReceiver #11713
Conversation
5ec4f52
to
1dc9fa2
Compare
QHelp previews: java/ql/src/Security/CWE/CWE-927/SensitiveResultReceiver.qhelpLeaking sensitive information through a ResultReceiverIf a RecommendationDo not send sensitive data to an untrusted ExampleIn the following (bad) example, sensitive data is sent to an untrusted // BAD: Sensitive data is sent to an untrusted result receiver
void bad(String password) {
Intent intent = getIntent();
ResultReceiver rec = intent.getParcelableExtra("Receiver");
Bundle b = new Bundle();
b.putCharSequence("pass", password);
rec.send(0, b);
} References
|
1caa60d
to
e12febf
Compare
I think this is ready for docs review 👍 |
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.
@joefarebrother, hi from Docs 👋🏼 I've just suggested a couple small changes below, then this is looking good 👍🏼 thanks for your work on the documentation!
Co-authored-by: Sam Browning <106113886+sabrowning1@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 for making those changes @joefarebrother! Once @atorralba's updated the wording in that .ql file, this is good to go for docs 🚀
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.
🎉
Part of CWE-927.
Covers cases in which a ResultReceiver is obtained from some untrusted source, and then sensitive data is sent through it.