Files
codeql/java/ql/test/library-tests/dataflow/capture/test.ql
Anders Schack-Mulligen d8edae96df Java: Add test.
2020-03-24 15:24:17 +01:00

18 lines
400 B
Plaintext

import java
import semmle.code.java.dataflow.DataFlow
import DataFlow
StringLiteral src() { result.getCompilationUnit().fromSource() }
class Conf extends Configuration {
Conf() { this = "qq capture" }
override predicate isSource(Node n) { n.asExpr() = src() }
override predicate isSink(Node n) { any() }
}
from Node src, Node sink, Conf conf
where conf.hasFlow(src, sink)
select src, sink