File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
python/ql/src/Security/CWE-798 Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ import semmle.python.dataflow.new.TaintTracking
18
18
import semmle.python.filters.Tests
19
19
private import semmle.python.dataflow.new.internal.DataFlowDispatch as DataFlowDispatch
20
20
private import semmle.python.dataflow.new.internal.Builtins:: Builtins as Builtins
21
+ private import semmle.python.frameworks.data.ModelsAsData
21
22
22
23
bindingset [ char, fraction]
23
24
predicate fewer_characters_than ( StringLiteral str , string char , float fraction ) {
@@ -80,6 +81,8 @@ class HardcodedValueSource extends DataFlow::Node {
80
81
81
82
class CredentialSink extends DataFlow:: Node {
82
83
CredentialSink ( ) {
84
+ this = ModelOutput:: getASinkNode ( "credentials-hardcoded" ) .asSink ( )
85
+ or
83
86
exists ( string name |
84
87
name .regexpMatch ( getACredentialRegex ( ) ) and
85
88
not name .matches ( "%file" )
You can’t perform that action at this time.
0 commit comments