recognize more exported functions in js/shell-command-constructed-from-input

This commit is contained in:
Erik Krogh Kristensen
2020-12-21 13:50:22 +01:00
parent 0a0137bb5e
commit 4ef569fbbe

View File

@@ -53,7 +53,7 @@ module UnsafeShellCommandConstruction {
ExternalInputSource() {
this =
Exports::getAValueExportedBy(Exports::getTopmostPackageJSON())
.(DataFlow::FunctionNode)
.getAFunctionValue()
.getAParameter() and
not this.getName() = ["cmd", "command"] // looks to be on purpose.
}