mirror of
https://github.com/github/codeql.git
synced 2026-05-03 12:45:27 +02:00
Use flowFrom.
This commit is contained in:
@@ -81,5 +81,5 @@ module Config implements DataFlow::ConfigSig {
|
||||
module Flow = DataFlow::Global<Config>;
|
||||
|
||||
from DataFlow::Node source, string msg
|
||||
where Flow::flow(source, _) and Config::isSourceString(source, msg)
|
||||
where Flow::flowFrom(source) and Config::isSourceString(source, msg)
|
||||
select source, msg
|
||||
|
||||
@@ -154,7 +154,7 @@ module FlowToPrintFlow = DataFlow::Global<FlowToPrintConfig>;
|
||||
|
||||
/** Holds if the provided `CallNode`'s result flows to an argument of a printer call. */
|
||||
predicate resultFlowsToPrinter(DataFlow::CallNode authCodeUrlCall) {
|
||||
FlowToPrintFlow::flow(authCodeUrlCall.getResult(), _)
|
||||
FlowToPrintFlow::flowFrom(authCodeUrlCall.getResult())
|
||||
}
|
||||
|
||||
/** Get a data-flow node that reads the value of `os.Stdin`. */
|
||||
|
||||
@@ -70,5 +70,6 @@ module PamStartToAuthenticateFlow = TaintTracking::Global<PamStartToAuthenticate
|
||||
from DataFlow::Node source, DataFlow::Node sink
|
||||
where
|
||||
not isInTestFile(source.asExpr()) and
|
||||
(PamStartToAuthenticateFlow::flow(source, sink) and not PamStartToAcctMgmtFlow::flow(source, _))
|
||||
PamStartToAuthenticateFlow::flow(source, sink) and
|
||||
not PamStartToAcctMgmtFlow::flowFrom(source)
|
||||
select source, "This Pam transaction may not be secure."
|
||||
|
||||
@@ -24,7 +24,7 @@ module JwtParseWithConstantKeyConfig implements DataFlow::ConfigSig {
|
||||
or
|
||||
n = fd.(FuncDecl).getFunction().getARead()
|
||||
|
|
||||
GolangJwtKeyFunc::flow(n, _) and
|
||||
GolangJwtKeyFunc::flowFrom(n) and
|
||||
sink = rn and
|
||||
rn.getRoot() = fd and
|
||||
rn.getIndex() = 0
|
||||
|
||||
Reference in New Issue
Block a user