mirror of
https://github.com/github/codeql.git
synced 2026-05-03 04:39:29 +02:00
C++: Stop taint from flowing to arithmetic types
These are not likely to give the user much control over what can be accessed.
This commit is contained in:
@@ -75,6 +75,10 @@ class TaintedPathConfiguration extends TaintTracking::Configuration {
|
||||
}
|
||||
|
||||
override predicate isSanitizerIn(DataFlow::Node node) { this.isSource(node) }
|
||||
|
||||
override predicate isSanitizer(DataFlow::Node node) {
|
||||
node.asExpr().(Call).getTarget().getUnspecifiedType() instanceof ArithmeticType
|
||||
}
|
||||
}
|
||||
|
||||
from
|
||||
|
||||
Reference in New Issue
Block a user