File tree Expand file tree Collapse file tree
python/ql/lib/semmle/python Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4848 " python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImpl2.qll" ,
4949 " python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImpl3.qll" ,
5050 " python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImpl4.qll" ,
51- " python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImplForRegExp.qll" ,
5251 " ruby/ql/lib/codeql/ruby/dataflow/internal/DataFlowImpl1.qll" ,
5352 " ruby/ql/lib/codeql/ruby/dataflow/internal/DataFlowImpl2.qll" ,
5453 " ruby/ql/lib/codeql/ruby/dataflow/internal/DataFlowImplForHttpClientLibraries.qll" ,
Original file line number Diff line number Diff line change 55private import semmle.python.RegexTreeView
66private import semmle.python.regex
77private import semmle.python.dataflow.new.DataFlow
8+ private import semmle.python.regexp.internal.RegExpTracking
89
910/**
1011 * Provides utility predicates related to regular expressions.
@@ -25,18 +26,18 @@ deprecated module RegExpPatterns {
2526 * as a part of a regular expression.
2627 */
2728class RegExpPatternSource extends DataFlow:: CfgNode {
28- private Regex astNode ;
29+ private DataFlow :: Node sink ;
2930
30- RegExpPatternSource ( ) { astNode = this . asExpr ( ) }
31+ RegExpPatternSource ( ) { this = regExpSource ( sink ) }
3132
3233 /**
3334 * Gets a node where the pattern of this node is parsed as a part of
3435 * a regular expression.
3536 */
36- DataFlow:: Node getAParse ( ) { result = this }
37+ DataFlow:: Node getAParse ( ) { result = sink }
3738
3839 /**
3940 * Gets the root term of the regular expression parsed from this pattern.
4041 */
41- RegExpTerm getRegExpTerm ( ) { result .getRegex ( ) = astNode }
42+ RegExpTerm getRegExpTerm ( ) { result .getRegex ( ) = this . asExpr ( ) }
4243}
You can’t perform that action at this time.
0 commit comments