Rust: Add sinks as barriers to prevent duplicate results.

This commit is contained in:
Geoffrey White
2025-11-28 17:09:08 +00:00
parent bb50e9fb40
commit faf69b821b

View File

@@ -39,6 +39,11 @@ module HardcodedCryptographicValueConfig implements DataFlow::ConfigSig {
// case like `[0, 0, 0, 0]`)
isSource(node)
}
predicate isBarrierOut(DataFlow::Node node) {
// make sinks barriers so that we only report the closest instance
isSink(node)
}
}
module HardcodedCryptographicValueFlow = TaintTracking::Global<HardcodedCryptographicValueConfig>;