mirror of
https://github.com/github/codeql.git
synced 2026-04-30 03:05:15 +02:00
add taint step through the cli-color library
This commit is contained in:
@@ -266,3 +266,15 @@ class CliHighlightStep extends TaintTracking::SharedTaintStep {
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* A step through the [`cli-color`](https://npmjs.org/package/cli-color) library.
|
||||
*/
|
||||
class CliColorStep extends TaintTracking::SharedTaintStep {
|
||||
override predicate stringManipulationStep(DataFlow::Node pred, DataFlow::Node succ) {
|
||||
exists(API::CallNode call | call = API::moduleImport("cli-color").getAMember*().getACall() |
|
||||
pred = call.getArgument(0) and
|
||||
succ = call
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user