Skip to content

Commit f08f175

Browse files
author
Dave Bartolomeo
authored
Merge pull request github#17139 from github/dbartol/provenance/qltest
Update test expectations after extension numbering fix
2 parents 59572e5 + 7e82986 commit f08f175

10 files changed

+139
-159
lines changed

go/ql/test/library-tests/semmle/go/dataflow/ThreatModels/threat-models-flowtest2.expected

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
models
2-
| 1 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
3-
| 1 | Summary: archive/tar; ; false; NewReader; ; ; Argument[0]; ReturnValue; taint; manual |
4-
| 2 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
5-
| 3 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
6-
| 4 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
2+
| 1 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
3+
| 2 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
4+
| 3 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
5+
| 4 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
76
edges
8-
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:1 |
9-
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:2 MaD:3 |
10-
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:4 |
7+
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:4 |
8+
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:1 MaD:2 |
9+
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:3 |
1110
| test.go:32:11:32:36 | call to Get | test.go:34:7:34:30 | ...+... | provenance | |
1211
nodes
1312
| test.go:27:11:27:63 | call to ExecuteQuery | semmle.label | call to ExecuteQuery |

go/ql/test/library-tests/semmle/go/dataflow/ThreatModels/threat-models-flowtest3.expected

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,16 @@
11
models
2-
| 1 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
3-
| 1 | Summary: archive/tar; ; false; NewReader; ; ; Argument[0]; ReturnValue; taint; manual |
4-
| 2 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
5-
| 2 | Summary: archive/tar; Header; true; FileInfo; ; ; Argument[receiver]; ReturnValue; taint; manual |
6-
| 3 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
7-
| 3 | Summary: archive/tar; Writer; true; WriteHeader; ; ; Argument[0]; Argument[receiver]; taint; manual |
8-
| 4 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
9-
| 5 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
10-
| 6 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
2+
| 1 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
3+
| 2 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
4+
| 3 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
5+
| 4 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
6+
| 5 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
7+
| 6 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
118
edges
12-
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:2 |
13-
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:3 |
14-
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:1 |
15-
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:4 MaD:5 |
16-
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:6 |
9+
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:5 |
10+
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:6 |
11+
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:4 |
12+
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:1 MaD:2 |
13+
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:3 |
1714
| test.go:32:11:32:36 | call to Get | test.go:34:7:34:30 | ...+... | provenance | |
1815
nodes
1916
| test.go:9:10:9:40 | call to ReadEnvironment | semmle.label | call to ReadEnvironment |

go/ql/test/library-tests/semmle/go/dataflow/ThreatModels/threat-models-flowtest4.expected

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,18 @@
11
models
2-
| 1 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
3-
| 1 | Summary: archive/tar; ; false; NewReader; ; ; Argument[0]; ReturnValue; taint; manual |
4-
| 2 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
5-
| 2 | Summary: archive/tar; Header; true; FileInfo; ; ; Argument[receiver]; ReturnValue; taint; manual |
6-
| 3 | Source: github.com/nonexistent/sources; ; false; GetCustom; ; ; ReturnValue; custom; manual |
7-
| 3 | Summary: archive/tar; Reader; true; Next; ; ; Argument[receiver]; ReturnValue[0]; taint; manual |
8-
| 4 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
9-
| 4 | Summary: archive/tar; Writer; true; WriteHeader; ; ; Argument[0]; Argument[receiver]; taint; manual |
10-
| 5 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
11-
| 6 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
12-
| 7 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
2+
| 1 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
3+
| 2 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
4+
| 3 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
5+
| 4 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
6+
| 5 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
7+
| 6 | Source: github.com/nonexistent/sources; ; false; GetCustom; ; ; ReturnValue; custom; manual |
8+
| 7 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
139
edges
14-
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:2 |
15-
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:4 |
16-
| test.go:21:11:21:36 | call to GetCustom | test.go:23:7:23:30 | ...+... | provenance | Src:MaD:3 |
17-
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:1 |
18-
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:5 MaD:6 |
19-
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:7 |
10+
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:5 |
11+
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:7 |
12+
| test.go:21:11:21:36 | call to GetCustom | test.go:23:7:23:30 | ...+... | provenance | Src:MaD:6 |
13+
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:4 |
14+
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:1 MaD:2 |
15+
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:3 |
2016
| test.go:32:11:32:36 | call to Get | test.go:34:7:34:30 | ...+... | provenance | |
2117
nodes
2218
| test.go:9:10:9:40 | call to ReadEnvironment | semmle.label | call to ReadEnvironment |

go/ql/test/library-tests/semmle/go/dataflow/ThreatModels/threat-models-flowtest5.expected

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
models
2-
| 1 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
3-
| 1 | Summary: archive/tar; Reader; true; Next; ; ; Argument[receiver]; ReturnValue[0]; taint; manual |
4-
| 2 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
5-
| 2 | Summary: archive/zip; ; false; FileInfoHeader; ; ; Argument[0]; ReturnValue[0]; taint; manual |
6-
| 3 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
7-
| 4 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
8-
| 5 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
2+
| 1 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
3+
| 2 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
4+
| 3 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
5+
| 4 | Source: github.com/nonexistent/sources; ; false; ReadEnvironment; ; ; ReturnValue; environment; manual |
6+
| 5 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
97
edges
10-
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:1 |
11-
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:2 |
12-
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:3 MaD:4 |
13-
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:5 |
8+
| test.go:9:10:9:40 | call to ReadEnvironment | test.go:11:7:11:29 | ...+... | provenance | Src:MaD:4 |
9+
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:5 |
10+
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:1 MaD:2 |
11+
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:3 |
1412
| test.go:32:11:32:36 | call to Get | test.go:34:7:34:30 | ...+... | provenance | |
1513
nodes
1614
| test.go:9:10:9:40 | call to ReadEnvironment | semmle.label | call to ReadEnvironment |

go/ql/test/library-tests/semmle/go/dataflow/ThreatModels/threat-models-flowtest6.expected

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
models
2-
| 1 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
3-
| 1 | Summary: archive/tar; Header; true; FileInfo; ; ; Argument[receiver]; ReturnValue; taint; manual |
4-
| 2 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
5-
| 2 | Summary: archive/zip; ; false; FileInfoHeader; ; ; Argument[0]; ReturnValue[0]; taint; manual |
6-
| 3 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
7-
| 4 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
8-
| 5 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
2+
| 1 | Source: net/http; Request; true; URL; ; ; ; remote; manual |
3+
| 2 | Summary: net/url; URL; true; Query; ; ; Argument[receiver]; ReturnValue; taint; manual |
4+
| 3 | Summary: net/url; Values; true; Get; ; ; Argument[receiver]; ReturnValue; taint; manual |
5+
| 4 | Source: github.com/nonexistent/sources; ; false; ExecuteQuery; ; ; ReturnValue; database; manual |
6+
| 5 | Source: github.com/nonexistent/sources; ; false; GetCliArg; ; ; ReturnValue; commandargs; manual |
97
edges
10-
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:2 |
11-
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:1 |
12-
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:3 MaD:4 |
13-
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:5 |
8+
| test.go:15:9:15:32 | call to GetCliArg | test.go:17:7:17:28 | ...+... | provenance | Src:MaD:5 |
9+
| test.go:27:11:27:63 | call to ExecuteQuery | test.go:28:7:28:11 | query | provenance | Src:MaD:4 |
10+
| test.go:32:11:32:15 | selection of URL | test.go:32:11:32:23 | call to Query | provenance | Src:MaD:1 MaD:2 |
11+
| test.go:32:11:32:23 | call to Query | test.go:32:11:32:36 | call to Get | provenance | MaD:3 |
1412
| test.go:32:11:32:36 | call to Get | test.go:34:7:34:30 | ...+... | provenance | |
1513
nodes
1614
| test.go:15:9:15:32 | call to GetCliArg | semmle.label | call to GetCliArg |

java/ql/test/library-tests/dataflow/threat-models/threat-models-flowtest2.expected

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,23 @@
11
models
2-
| 1 | Sink: android.app; Activity; true; bindServiceAsUser; ; ; Argument[0]; intent-redirection; manual |
3-
| 1 | Source: testlib; TestSources; false; executeQuery; (String); ; ReturnValue; database; manual |
4-
| 2 | Summary: java.io; InputStream; true; read; (byte[]); ; Argument[this]; Argument[0]; taint; manual |
5-
| 3 | Summary: java.lang; String; false; String; ; ; Argument[0]; Argument[this]; taint; manual |
6-
| 4 | Source: java.net; Socket; false; getInputStream; (); ; ReturnValue; remote; manual |
7-
| 5 | Sink: java.sql; Statement; true; executeUpdate; ; ; Argument[0]; sql-injection; manual |
8-
| 6 | Sink: java.util.logging; Logger; true; severe; ; ; Argument[0]; log-injection; manual |
2+
| 1 | Summary: java.io; InputStream; true; read; (byte[]); ; Argument[this]; Argument[0]; taint; manual |
3+
| 2 | Summary: java.lang; String; false; String; ; ; Argument[0]; Argument[this]; taint; manual |
4+
| 3 | Source: java.net; Socket; false; getInputStream; (); ; ReturnValue; remote; manual |
5+
| 4 | Sink: java.sql; Statement; true; executeUpdate; ; ; Argument[0]; sql-injection; manual |
6+
| 5 | Sink: java.util.logging; Logger; true; severe; ; ; Argument[0]; log-injection; manual |
7+
| 6 | Source: testlib; TestSources; false; executeQuery; (String); ; ReturnValue; database; manual |
98
edges
109
| Test.java:10:31:10:41 | data : byte[] | Test.java:11:23:11:26 | data : byte[] | provenance | |
11-
| Test.java:11:23:11:26 | data : byte[] | Test.java:11:12:11:51 | new String(...) : String | provenance | MaD:3 |
12-
| Test.java:19:5:19:25 | getInputStream(...) : InputStream | Test.java:19:32:19:35 | data [post update] : byte[] | provenance | Src:MaD:4 MaD:2 |
10+
| Test.java:11:23:11:26 | data : byte[] | Test.java:11:12:11:51 | new String(...) : String | provenance | MaD:2 |
11+
| Test.java:19:5:19:25 | getInputStream(...) : InputStream | Test.java:19:32:19:35 | data [post update] : byte[] | provenance | Src:MaD:3 MaD:1 |
1312
| Test.java:19:32:19:35 | data [post update] : byte[] | Test.java:22:49:22:52 | data : byte[] | provenance | |
1413
| Test.java:19:32:19:35 | data [post update] : byte[] | Test.java:25:69:25:72 | data : byte[] | provenance | |
1514
| Test.java:22:49:22:52 | data : byte[] | Test.java:10:31:10:41 | data : byte[] | provenance | |
16-
| Test.java:22:49:22:52 | data : byte[] | Test.java:22:36:22:53 | byteToString(...) | provenance | MaD:3 Sink:MaD:6 |
17-
| Test.java:25:56:25:73 | byteToString(...) : String | Test.java:25:26:25:80 | ... + ... | provenance | Sink:MaD:5 |
15+
| Test.java:22:49:22:52 | data : byte[] | Test.java:22:36:22:53 | byteToString(...) | provenance | MaD:2 Sink:MaD:5 |
16+
| Test.java:25:56:25:73 | byteToString(...) : String | Test.java:25:26:25:80 | ... + ... | provenance | Sink:MaD:4 |
1817
| Test.java:25:69:25:72 | data : byte[] | Test.java:10:31:10:41 | data : byte[] | provenance | |
19-
| Test.java:25:69:25:72 | data : byte[] | Test.java:25:56:25:73 | byteToString(...) : String | provenance | MaD:3 |
20-
| Test.java:30:21:30:61 | executeQuery(...) : String | Test.java:33:26:33:68 | ... + ... | provenance | Src:MaD:1 Sink:MaD:5 |
21-
| Test.java:30:21:30:61 | executeQuery(...) : String | Test.java:36:36:36:41 | result | provenance | Src:MaD:1 Sink:MaD:6 |
18+
| Test.java:25:69:25:72 | data : byte[] | Test.java:25:56:25:73 | byteToString(...) : String | provenance | MaD:2 |
19+
| Test.java:30:21:30:61 | executeQuery(...) : String | Test.java:33:26:33:68 | ... + ... | provenance | Src:MaD:6 Sink:MaD:4 |
20+
| Test.java:30:21:30:61 | executeQuery(...) : String | Test.java:36:36:36:41 | result | provenance | Src:MaD:6 Sink:MaD:5 |
2221
nodes
2322
| Test.java:10:31:10:41 | data : byte[] | semmle.label | data : byte[] |
2423
| Test.java:11:12:11:51 | new String(...) : String | semmle.label | new String(...) : String |

0 commit comments

Comments
 (0)