mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
[DIFF-INFORMED] Swift: CleartextStorageDatabase
https://github.com/d10c/codeql/blob/d10c/diff-informed-phase-3/swift/ql/src/queries/Security/CWE-311/CleartextStorageDatabase.ql#L33
This commit is contained in:
@@ -48,6 +48,17 @@ module CleartextStorageDatabaseConfig implements DataFlow::ConfigSig {
|
||||
node.asExpr().getType().getUnderlyingType() instanceof DictionaryType and
|
||||
c.getAReadContent().(DataFlow::Content::TupleContent).getIndex() = 1
|
||||
}
|
||||
|
||||
predicate observeDiffInformedIncrementalMode() { any() }
|
||||
|
||||
Location getASelectedSinkLocation(DataFlow::Node sink) {
|
||||
exists(DataFlow::Node cleanSink | result = cleanSink.getLocation() |
|
||||
cleanSink = sink.(DataFlow::PostUpdateNode).getPreUpdateNode()
|
||||
or
|
||||
not sink instanceof DataFlow::PostUpdateNode and
|
||||
cleanSink = sink
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user