Swift: Add numeric barrier for command injection query.

This commit is contained in:
Geoffrey White
2023-09-19 14:09:22 +01:00
parent 903b0f5bab
commit f98de85e36

View File

@@ -69,3 +69,13 @@ private class CommandInjectionSinks extends SinkModelCsv {
]
}
}
/**
* A barrier for command injection vulnerabilities.
*/
private class CommandInjectionDefaultBarrier extends CommandInjectionBarrier {
CommandInjectionDefaultBarrier() {
// any numeric type
this.asExpr().getType().getUnderlyingType().getABaseType*().getName() = "Numeric"
}
}