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