C#: add AdditionalTaintStep extension point for taint-tracking - #22360
Merged
hvitved merged 3 commits intoAug 19, 2026
Conversation
Mirrors Java's AdditionalTaintStep (java/ql/lib/semmle/code/java/dataflow/FlowSteps.qll) and Ruby/Swift's existing ports of the same pattern: a `Unit`-based class that lets library code contribute additional taint steps applied to every taint-tracking configuration, with zero opt-in required. Wired into defaultAdditionalTaintStep in TaintTrackingPrivate.qll, tagged with model = "AdditionalTaintStep" for provenance. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
hvitved
requested changes
Aug 19, 2026
hvitved
left a comment
Contributor
There was a problem hiding this comment.
LGTM, just one minor thing. Also, merge conflict needs to be resolved.
Addresses review comment: the test-only AdditionalTaintStep subclass only has a single consumer, so fold it directly into the query file instead of keeping it in a separate .qll. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…/csharp-additional-taint-step # Conflicts: # csharp/ql/lib/semmle/code/csharp/dataflow/internal/TaintTrackingPrivate.qll
Author
|
Perfect, should be better now |
hvitved
approved these changes
Aug 19, 2026
hvitved
left a comment
Contributor
There was a problem hiding this comment.
Thanks for the contribution ❤️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mirrors Java's AdditionalTaintStep (java/ql/lib/semmle/code/java/dataflow/FlowSteps.qll) and Ruby/Swift's existing ports of the same pattern: a
Unit-based class that lets library code contribute additional taint steps applied to every taint-tracking configuration, with zero opt-in required. Wired into defaultAdditionalTaintStep in TaintTrackingPrivate.qll, tagged with model = "AdditionalTaintStep" for provenance.