Ruby: mass enable diff-informed data flow

This commit is contained in:
Asger F
2024-12-20 10:10:29 +01:00
parent 498bfd2160
commit 4dc632f742
52 changed files with 159 additions and 0 deletions

View File

@@ -57,6 +57,8 @@ module BombsConfig implements DataFlow::ConfigSig {
nodeTo = cn
)
}
predicate observeDiffInformedIncrementalMode() { any() }
}
module Bombs = TaintTracking::Global<BombsConfig>;

View File

@@ -39,6 +39,8 @@ private module DecompressionApiConfig implements DataFlow::ConfigSig {
// our Decompression APIs defined above will be the sinks we use for this query
predicate isSink(DataFlow::Node sink) { sink instanceof DecompressionApiUse }
predicate observeDiffInformedIncrementalMode() { any() }
}
private module DecompressionApiFlow = TaintTracking::Global<DecompressionApiConfig>;

View File

@@ -86,6 +86,8 @@ private module HttpVerbConfig implements DataFlow::ConfigSig {
exists(ExprNodes::ConditionalExprCfgNode c | c.getCondition() = sink.asExpr()) or
exists(ExprNodes::CaseExprCfgNode c | c.getValue() = sink.asExpr())
}
predicate observeDiffInformedIncrementalMode() { any() }
}
private module HttpVerbFlow = TaintTracking::Global<HttpVerbConfig>;

View File

@@ -46,6 +46,8 @@ private module WeakParamsConfig implements DataFlow::ConfigSig {
// the sink is an instance of a Model class that receives a method call
predicate isSink(DataFlow::Node node) { node = any(PersistentWriteAccess a).getValue() }
predicate observeDiffInformedIncrementalMode() { any() }
}
private module WeakParamsFlow = TaintTracking::Global<WeakParamsConfig>;

View File

@@ -19,6 +19,8 @@ private module BasicTaintConfig implements DataFlow::ConfigSig {
// To reduce noise from synthetic nodes, only count nodes that have an associated expression.
exists(node.asExpr().getExpr())
}
predicate observeDiffInformedIncrementalMode() { any() }
}
private module BasicTaintFlow = TaintTracking::Global<BasicTaintConfig>;

View File

@@ -31,6 +31,8 @@ private module XxeConfig implements DataFlow::ConfigSig {
predicate isSource(DataFlow::Node src) { src instanceof RemoteFlowSource }
predicate isSink(DataFlow::Node sink) { sink instanceof UnsafeXxeSink }
predicate observeDiffInformedIncrementalMode() { any() }
}
private module XxeFlow = TaintTracking::Global<XxeConfig>;

View File

@@ -54,6 +54,8 @@ private module PermissivePermissionsConfig implements DataFlow::ConfigSig {
predicate isSink(DataFlow::Node sink) {
exists(FileSystemPermissionModification mod | mod.getAPermissionNode() = sink)
}
predicate observeDiffInformedIncrementalMode() { any() }
}
private module PermissivePermissionsFlow = DataFlow::Global<PermissivePermissionsConfig>;

View File

@@ -147,6 +147,8 @@ private module HardcodedCredentialsConfig implements DataFlow::ConfigSig {
binop.getExpr() instanceof AddExpr
)
}
predicate observeDiffInformedIncrementalMode() { any() }
}
private module HardcodedCredentialsFlow = DataFlow::Global<HardcodedCredentialsConfig>;