File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
java/ql/lib/semmle/code/java/security/regexp Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,24 @@ module PolynomialRedosConfig implements DataFlow::ConfigSig {
47
47
node instanceof SimpleTypeSanitizer or
48
48
node .asExpr ( ) .( MethodCall ) .getMethod ( ) instanceof LengthRestrictedMethod
49
49
}
50
+
51
+ predicate observeDiffInformedIncrementalMode ( ) { any ( ) }
52
+
53
+ Location getASelectedSinkLocation ( DataFlow:: Node sink ) {
54
+ exists ( SuperlinearBackTracking:: PolynomialBackTrackingTerm regexp |
55
+ regexp .getRootTerm ( ) = sink .( PolynomialRedosSink ) .getRegExp ( )
56
+ |
57
+ result = sink .getLocation ( )
58
+ )
59
+ }
60
+
61
+ Location getASelectedSinkLocationApprox ( DataFlow:: Node sink ) {
62
+ exists ( SuperlinearBackTracking:: PolynomialBackTrackingTerm regexp |
63
+ regexp .getRootTerm ( ) = sink .( PolynomialRedosSink ) .getRegExp ( )
64
+ |
65
+ result = regexp .getLocation ( )
66
+ )
67
+ }
50
68
}
51
69
52
70
module PolynomialRedosFlow = TaintTracking:: Global< PolynomialRedosConfig > ;
You can’t perform that action at this time.
0 commit comments