Skip to content

Java: Move sink-constraints into the configuration in NumericCastTainted.ql. #10084

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

Merged

Conversation

aschackmull
Copy link
Contributor

The exclusion of right-shifted variables on sinks is probably better as a sanitizer, so move it there. That should help performance a bit and possibly also remove some FPs.

Also, there was a somewhat arbitrary-looking restriction that the sink has to be a variable access. I'm not going to consider whether that restriction ought to lifted (it's probably fine to keep), but we might as well make it explicit and move it into the configuration to gain some performance.

@github-actions github-actions bot added the Java label Aug 17, 2022
@aschackmull
Copy link
Contributor Author

Dca looks very uneventful.

@aschackmull aschackmull added the no-change-note-required This PR does not need a change note label Aug 18, 2022
@aschackmull aschackmull marked this pull request as ready for review August 18, 2022 07:36
@aschackmull aschackmull requested a review from a team as a code owner August 18, 2022 07:36
Copy link
Contributor

@atorralba atorralba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I have the gut feeling that restricting the sinks to VarAccesses wasn't intentional, so removing it would probably be fine.

@aschackmull aschackmull merged commit 61a2c0d into github:main Aug 18, 2022
@aschackmull aschackmull deleted the java/numericcasttainted-barrier branch August 18, 2022 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Java no-change-note-required This PR does not need a change note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants