CodeQL library for Java
codeql/java-all 0.6.2 ( changelog , source )

Predicate regexMatchedAgainst

Holds if the string literal regex is a regular expression that is matched against the expression str.

As an optimisation, only regexes containing an infinite repitition quatifier (+, *, or {x,}) and therefore may be relevant for ReDoS queries are considered.

Import path

predicate regexMatchedAgainst ( StringLiteral regex , Expr str )