-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Shared: Add support for provenance pretty-printing as a qltest postpr…
…ocess step.
- Loading branch information
1 parent
a9bf17e
commit 884eff6
Showing
6 changed files
with
95 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/** | ||
* @kind test-postprocess | ||
*/ | ||
|
||
import codeql.dataflow.test.ProvenancePathGraph | ||
import semmle.code.java.dataflow.ExternalFlow | ||
|
||
external predicate queryResults(string relation, int row, int column, string data); | ||
|
||
external predicate queryRelations(string relation); | ||
|
||
query predicate resultRelations(string relation) { queryRelations(relation) } | ||
|
||
module Res = TranslateProvenanceResults<interpretModelForTest/2, queryResults/4>; | ||
|
||
from string relation, int row, int column, string data | ||
where Res::results(relation, row, column, data) | ||
select relation, row, column, data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
Security/CWE/CWE-078/ExecTainted.ql | ||
query: Security/CWE/CWE-078/ExecTainted.ql | ||
postprocess: TestUtilities/ProvenancePathGraph.ql |
14 changes: 0 additions & 14 deletions
14
java/ql/test/query-tests/security/CWE-311/CWE-319/HttpsUrls.ql
This file was deleted.
Oops, something went wrong.
2 changes: 2 additions & 0 deletions
2
java/ql/test/query-tests/security/CWE-311/CWE-319/HttpsUrls.qlref
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
query: Security/CWE/CWE-319/HttpsUrls.ql | ||
postprocess: TestUtilities/ProvenancePathGraph.ql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters