mirror of
https://github.com/github/codeql.git
synced 2025-12-17 17:23:36 +01:00
19 lines
445 B
Plaintext
19 lines
445 B
Plaintext
import csharp
|
|
|
|
class Config extends DataFlow::Configuration {
|
|
Config() { this = "Config" }
|
|
|
|
override predicate isSource(DataFlow::Node source) {
|
|
source.asExpr().(StringLiteral).getValue() = "taint source"
|
|
or
|
|
source.asParameter().hasName("tainted")
|
|
}
|
|
|
|
override predicate isSink(DataFlow::Node sink) {
|
|
exists(MethodCall mc |
|
|
mc.getTarget().getName() = "Check" and
|
|
mc.getAnArgument() = sink.asExpr()
|
|
)
|
|
}
|
|
}
|