Skip to content

Commit 303a2bb

Browse files
committed
C#: Update expected test output
1 parent ea7d9c9 commit 303a2bb

File tree

62 files changed

+2913
-1394
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+2913
-1394
lines changed

csharp/ql/test/experimental/Security Features/CWE-759/HashWithoutSalt.expected

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
edges
2-
| HashWithoutSalt.cs:18:28:18:105 | call to method ConvertStringToBinary : IBuffer | HashWithoutSalt.cs:20:49:20:56 | access to local variable passBuff | provenance | |
2+
| HashWithoutSalt.cs:18:17:18:24 | access to local variable passBuff : IBuffer | HashWithoutSalt.cs:20:49:20:56 | access to local variable passBuff | provenance | |
3+
| HashWithoutSalt.cs:18:28:18:105 | call to method ConvertStringToBinary : IBuffer | HashWithoutSalt.cs:18:17:18:24 | access to local variable passBuff : IBuffer | provenance | |
34
| HashWithoutSalt.cs:18:70:18:77 | access to parameter password : String | HashWithoutSalt.cs:18:28:18:105 | call to method ConvertStringToBinary : IBuffer | provenance | |
4-
| HashWithoutSalt.cs:38:28:38:72 | call to method GetBytes : Byte[] | HashWithoutSalt.cs:39:51:39:59 | access to local variable passBytes | provenance | |
5+
| HashWithoutSalt.cs:38:16:38:24 | access to local variable passBytes : Byte[] | HashWithoutSalt.cs:39:51:39:59 | access to local variable passBytes | provenance | |
6+
| HashWithoutSalt.cs:38:28:38:72 | call to method GetBytes : Byte[] | HashWithoutSalt.cs:38:16:38:24 | access to local variable passBytes : Byte[] | provenance | |
57
| HashWithoutSalt.cs:38:64:38:71 | access to parameter password : String | HashWithoutSalt.cs:38:28:38:72 | call to method GetBytes : Byte[] | provenance | |
6-
| HashWithoutSalt.cs:70:28:70:72 | call to method GetBytes : Byte[] | HashWithoutSalt.cs:71:48:71:56 | access to local variable passBytes | provenance | |
8+
| HashWithoutSalt.cs:70:16:70:24 | access to local variable passBytes : Byte[] | HashWithoutSalt.cs:71:48:71:56 | access to local variable passBytes | provenance | |
9+
| HashWithoutSalt.cs:70:28:70:72 | call to method GetBytes : Byte[] | HashWithoutSalt.cs:70:16:70:24 | access to local variable passBytes : Byte[] | provenance | |
710
| HashWithoutSalt.cs:70:64:70:71 | access to parameter password : String | HashWithoutSalt.cs:70:28:70:72 | call to method GetBytes : Byte[] | provenance | |
811
nodes
12+
| HashWithoutSalt.cs:18:17:18:24 | access to local variable passBuff : IBuffer | semmle.label | access to local variable passBuff : IBuffer |
913
| HashWithoutSalt.cs:18:28:18:105 | call to method ConvertStringToBinary : IBuffer | semmle.label | call to method ConvertStringToBinary : IBuffer |
1014
| HashWithoutSalt.cs:18:70:18:77 | access to parameter password : String | semmle.label | access to parameter password : String |
1115
| HashWithoutSalt.cs:20:49:20:56 | access to local variable passBuff | semmle.label | access to local variable passBuff |
16+
| HashWithoutSalt.cs:38:16:38:24 | access to local variable passBytes : Byte[] | semmle.label | access to local variable passBytes : Byte[] |
1217
| HashWithoutSalt.cs:38:28:38:72 | call to method GetBytes : Byte[] | semmle.label | call to method GetBytes : Byte[] |
1318
| HashWithoutSalt.cs:38:64:38:71 | access to parameter password : String | semmle.label | access to parameter password : String |
1419
| HashWithoutSalt.cs:39:51:39:59 | access to local variable passBytes | semmle.label | access to local variable passBytes |
20+
| HashWithoutSalt.cs:70:16:70:24 | access to local variable passBytes : Byte[] | semmle.label | access to local variable passBytes : Byte[] |
1521
| HashWithoutSalt.cs:70:28:70:72 | call to method GetBytes : Byte[] | semmle.label | call to method GetBytes : Byte[] |
1622
| HashWithoutSalt.cs:70:64:70:71 | access to parameter password : String | semmle.label | access to parameter password : String |
1723
| HashWithoutSalt.cs:71:48:71:56 | access to local variable passBytes | semmle.label | access to local variable passBytes |

csharp/ql/test/experimental/Security Features/backdoor/PotentialTimeBomb.expected

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
nodes
2+
| test.cs:69:18:69:30 | access to local variable lastWriteTime : DateTime | semmle.label | access to local variable lastWriteTime : DateTime |
23
| test.cs:69:34:69:76 | call to method GetLastWriteTime : DateTime | semmle.label | call to method GetLastWriteTime : DateTime |
34
| test.cs:71:13:71:71 | call to method CompareTo | semmle.label | call to method CompareTo |
45
| test.cs:71:13:71:71 | call to method CompareTo : Int32 | semmle.label | call to method CompareTo : Int32 |
@@ -7,7 +8,8 @@ nodes
78
| test.cs:71:36:71:70 | call to method AddHours | semmle.label | call to method AddHours |
89
subpaths
910
edges
10-
| test.cs:69:34:69:76 | call to method GetLastWriteTime : DateTime | test.cs:71:36:71:48 | access to local variable lastWriteTime | provenance | |
11+
| test.cs:69:18:69:30 | access to local variable lastWriteTime : DateTime | test.cs:71:36:71:48 | access to local variable lastWriteTime | provenance | |
12+
| test.cs:69:34:69:76 | call to method GetLastWriteTime : DateTime | test.cs:69:18:69:30 | access to local variable lastWriteTime : DateTime | provenance | |
1113
| test.cs:71:13:71:71 | call to method CompareTo : Int32 | test.cs:71:13:71:76 | ... >= ... | provenance | |
1214
| test.cs:71:36:71:48 | access to local variable lastWriteTime | test.cs:71:13:71:71 | call to method CompareTo | provenance | |
1315
| test.cs:71:36:71:48 | access to local variable lastWriteTime | test.cs:71:13:71:71 | call to method CompareTo : Int32 | provenance | |

csharp/ql/test/library-tests/cil/dataflow/DataFlow.expected

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,10 @@ edges
4545
| dataflow.cs:100:30:100:33 | null : null | dataflow.cs:72:39:72:52 | call to method IndirectNull : null | provenance | |
4646
| dataflow.cs:100:30:100:33 | null : null | dataflow.cs:106:20:106:33 | call to method IndirectNull | provenance | |
4747
| dataflow.cs:100:30:100:33 | null : null | dataflow.cs:106:20:106:33 | call to method IndirectNull : null | provenance | |
48-
| dataflow.cs:106:20:106:33 | call to method IndirectNull : null | dataflow.cs:108:16:108:16 | access to local variable x : null | provenance | |
49-
| dataflow.cs:107:23:107:26 | null : null | dataflow.cs:108:16:108:16 | access to local variable x : null | provenance | |
48+
| dataflow.cs:106:16:106:16 | access to local variable x : null | dataflow.cs:108:16:108:16 | access to local variable x : null | provenance | |
49+
| dataflow.cs:106:20:106:33 | call to method IndirectNull : null | dataflow.cs:106:16:106:16 | access to local variable x : null | provenance | |
50+
| dataflow.cs:107:19:107:19 | access to local variable x : null | dataflow.cs:108:16:108:16 | access to local variable x : null | provenance | |
51+
| dataflow.cs:107:23:107:26 | null : null | dataflow.cs:107:19:107:19 | access to local variable x : null | provenance | |
5052
| dataflow.cs:108:16:108:16 | access to local variable x : null | dataflow.cs:72:21:72:34 | call to method NullFunction : null | provenance | |
5153
| dataflow.cs:108:16:108:16 | access to local variable x : null | dataflow.cs:87:31:87:44 | call to method NullFunction : null | provenance | |
5254
nodes
@@ -104,8 +106,10 @@ nodes
104106
| dataflow.cs:87:24:87:51 | ... ? ... : ... | semmle.label | ... ? ... : ... |
105107
| dataflow.cs:87:31:87:44 | call to method NullFunction : null | semmle.label | call to method NullFunction : null |
106108
| dataflow.cs:100:30:100:33 | null : null | semmle.label | null : null |
109+
| dataflow.cs:106:16:106:16 | access to local variable x : null | semmle.label | access to local variable x : null |
107110
| dataflow.cs:106:20:106:33 | call to method IndirectNull | semmle.label | call to method IndirectNull |
108111
| dataflow.cs:106:20:106:33 | call to method IndirectNull : null | semmle.label | call to method IndirectNull : null |
112+
| dataflow.cs:107:19:107:19 | access to local variable x : null | semmle.label | access to local variable x : null |
109113
| dataflow.cs:107:23:107:26 | null : null | semmle.label | null : null |
110114
| dataflow.cs:108:16:108:16 | access to local variable x : null | semmle.label | access to local variable x : null |
111115
subpaths

csharp/ql/test/library-tests/csharp7/GlobalFlow.expected

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,50 @@
11
edges
2-
| CSharp7.cs:39:9:39:21 | SSA def(x) : String | CSharp7.cs:49:22:49:23 | SSA def(t1) : String | provenance | |
3-
| CSharp7.cs:39:13:39:21 | "tainted" : String | CSharp7.cs:39:9:39:21 | SSA def(x) : String | provenance | |
4-
| CSharp7.cs:42:19:42:19 | x : String | CSharp7.cs:44:9:44:13 | SSA def(y) : String | provenance | |
5-
| CSharp7.cs:49:22:49:23 | SSA def(t1) : String | CSharp7.cs:51:18:51:19 | access to local variable t1 | provenance | |
2+
| CSharp7.cs:39:9:39:9 | access to parameter x : String | CSharp7.cs:49:22:49:23 | String t1 : String | provenance | |
3+
| CSharp7.cs:39:13:39:21 | "tainted" : String | CSharp7.cs:39:9:39:9 | access to parameter x : String | provenance | |
4+
| CSharp7.cs:42:19:42:19 | x : String | CSharp7.cs:44:9:44:9 | access to parameter y : String | provenance | |
5+
| CSharp7.cs:49:22:49:23 | String t1 : String | CSharp7.cs:51:18:51:19 | access to local variable t1 | provenance | |
66
| CSharp7.cs:55:11:55:19 | "tainted" : String | CSharp7.cs:42:19:42:19 | x : String | provenance | |
7-
| CSharp7.cs:55:11:55:19 | "tainted" : String | CSharp7.cs:55:30:55:31 | SSA def(t4) : String | provenance | |
8-
| CSharp7.cs:55:30:55:31 | SSA def(t4) : String | CSharp7.cs:56:18:56:19 | access to local variable t4 | provenance | |
7+
| CSharp7.cs:55:11:55:19 | "tainted" : String | CSharp7.cs:55:30:55:31 | String t4 : String | provenance | |
8+
| CSharp7.cs:55:30:55:31 | String t4 : String | CSharp7.cs:56:18:56:19 | access to local variable t4 | provenance | |
99
| CSharp7.cs:80:21:80:21 | x : String | CSharp7.cs:82:20:82:20 | access to parameter x : String | provenance | |
1010
| CSharp7.cs:82:16:82:24 | (..., ...) : ValueTuple<String,Int32> [field Item1] : String | CSharp7.cs:82:16:82:26 | access to field Item1 : String | provenance | |
1111
| CSharp7.cs:82:20:82:20 | access to parameter x : String | CSharp7.cs:82:16:82:24 | (..., ...) : ValueTuple<String,Int32> [field Item1] : String | provenance | |
12-
| CSharp7.cs:87:18:87:34 | (..., ...) : ValueTuple<String,String> [field Item1] : String | CSharp7.cs:90:20:90:21 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | provenance | |
12+
| CSharp7.cs:87:13:87:14 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | CSharp7.cs:90:20:90:21 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | provenance | |
13+
| CSharp7.cs:87:18:87:34 | (..., ...) : ValueTuple<String,String> [field Item1] : String | CSharp7.cs:87:13:87:14 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | provenance | |
1314
| CSharp7.cs:87:19:87:27 | "tainted" : String | CSharp7.cs:87:18:87:34 | (..., ...) : ValueTuple<String,String> [field Item1] : String | provenance | |
1415
| CSharp7.cs:90:20:90:21 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | CSharp7.cs:90:20:90:27 | access to field Item1 : String | provenance | |
1516
| CSharp7.cs:90:20:90:27 | access to field Item1 : String | CSharp7.cs:80:21:80:21 | x : String | provenance | |
1617
| CSharp7.cs:90:20:90:27 | access to field Item1 : String | CSharp7.cs:90:18:90:28 | call to method I | provenance | |
17-
| CSharp7.cs:175:22:175:30 | "tainted" : String | CSharp7.cs:181:23:181:25 | access to local variable src : String | provenance | |
18-
| CSharp7.cs:175:22:175:30 | "tainted" : String | CSharp7.cs:182:23:182:25 | access to local variable src : String | provenance | |
18+
| CSharp7.cs:175:16:175:18 | access to local variable src : String | CSharp7.cs:181:23:181:25 | access to local variable src : String | provenance | |
19+
| CSharp7.cs:175:16:175:18 | access to local variable src : String | CSharp7.cs:182:23:182:25 | access to local variable src : String | provenance | |
20+
| CSharp7.cs:175:22:175:30 | "tainted" : String | CSharp7.cs:175:16:175:18 | access to local variable src : String | provenance | |
1921
| CSharp7.cs:177:25:177:25 | s : String | CSharp7.cs:177:31:177:31 | access to parameter s : String | provenance | |
2022
| CSharp7.cs:178:25:178:25 | s : String | CSharp7.cs:178:37:178:37 | access to parameter s : String | provenance | |
2123
| CSharp7.cs:181:23:181:25 | access to local variable src : String | CSharp7.cs:177:25:177:25 | s : String | provenance | |
2224
| CSharp7.cs:181:23:181:25 | access to local variable src : String | CSharp7.cs:181:21:181:26 | call to local function g | provenance | |
2325
| CSharp7.cs:182:23:182:25 | access to local variable src : String | CSharp7.cs:178:25:178:25 | s : String | provenance | |
2426
| CSharp7.cs:182:23:182:25 | access to local variable src : String | CSharp7.cs:182:21:182:26 | call to local function h | provenance | |
2527
nodes
26-
| CSharp7.cs:39:9:39:21 | SSA def(x) : String | semmle.label | SSA def(x) : String |
28+
| CSharp7.cs:39:9:39:9 | access to parameter x : String | semmle.label | access to parameter x : String |
2729
| CSharp7.cs:39:13:39:21 | "tainted" : String | semmle.label | "tainted" : String |
2830
| CSharp7.cs:42:19:42:19 | x : String | semmle.label | x : String |
29-
| CSharp7.cs:44:9:44:13 | SSA def(y) : String | semmle.label | SSA def(y) : String |
30-
| CSharp7.cs:49:22:49:23 | SSA def(t1) : String | semmle.label | SSA def(t1) : String |
31+
| CSharp7.cs:44:9:44:9 | access to parameter y : String | semmle.label | access to parameter y : String |
32+
| CSharp7.cs:49:22:49:23 | String t1 : String | semmle.label | String t1 : String |
3133
| CSharp7.cs:51:18:51:19 | access to local variable t1 | semmle.label | access to local variable t1 |
3234
| CSharp7.cs:55:11:55:19 | "tainted" : String | semmle.label | "tainted" : String |
33-
| CSharp7.cs:55:30:55:31 | SSA def(t4) : String | semmle.label | SSA def(t4) : String |
35+
| CSharp7.cs:55:30:55:31 | String t4 : String | semmle.label | String t4 : String |
3436
| CSharp7.cs:56:18:56:19 | access to local variable t4 | semmle.label | access to local variable t4 |
3537
| CSharp7.cs:80:21:80:21 | x : String | semmle.label | x : String |
3638
| CSharp7.cs:82:16:82:24 | (..., ...) : ValueTuple<String,Int32> [field Item1] : String | semmle.label | (..., ...) : ValueTuple<String,Int32> [field Item1] : String |
3739
| CSharp7.cs:82:16:82:26 | access to field Item1 : String | semmle.label | access to field Item1 : String |
3840
| CSharp7.cs:82:20:82:20 | access to parameter x : String | semmle.label | access to parameter x : String |
41+
| CSharp7.cs:87:13:87:14 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | semmle.label | access to local variable t1 : ValueTuple<String,String> [field Item1] : String |
3942
| CSharp7.cs:87:18:87:34 | (..., ...) : ValueTuple<String,String> [field Item1] : String | semmle.label | (..., ...) : ValueTuple<String,String> [field Item1] : String |
4043
| CSharp7.cs:87:19:87:27 | "tainted" : String | semmle.label | "tainted" : String |
4144
| CSharp7.cs:90:18:90:28 | call to method I | semmle.label | call to method I |
4245
| CSharp7.cs:90:20:90:21 | access to local variable t1 : ValueTuple<String,String> [field Item1] : String | semmle.label | access to local variable t1 : ValueTuple<String,String> [field Item1] : String |
4346
| CSharp7.cs:90:20:90:27 | access to field Item1 : String | semmle.label | access to field Item1 : String |
47+
| CSharp7.cs:175:16:175:18 | access to local variable src : String | semmle.label | access to local variable src : String |
4448
| CSharp7.cs:175:22:175:30 | "tainted" | semmle.label | "tainted" |
4549
| CSharp7.cs:175:22:175:30 | "tainted" : String | semmle.label | "tainted" : String |
4650
| CSharp7.cs:177:25:177:25 | s : String | semmle.label | s : String |
@@ -52,7 +56,7 @@ nodes
5256
| CSharp7.cs:182:21:182:26 | call to local function h | semmle.label | call to local function h |
5357
| CSharp7.cs:182:23:182:25 | access to local variable src : String | semmle.label | access to local variable src : String |
5458
subpaths
55-
| CSharp7.cs:55:11:55:19 | "tainted" : String | CSharp7.cs:42:19:42:19 | x : String | CSharp7.cs:44:9:44:13 | SSA def(y) : String | CSharp7.cs:55:30:55:31 | SSA def(t4) : String |
59+
| CSharp7.cs:55:11:55:19 | "tainted" : String | CSharp7.cs:42:19:42:19 | x : String | CSharp7.cs:44:9:44:9 | access to parameter y : String | CSharp7.cs:55:30:55:31 | String t4 : String |
5660
| CSharp7.cs:90:20:90:27 | access to field Item1 : String | CSharp7.cs:80:21:80:21 | x : String | CSharp7.cs:82:16:82:26 | access to field Item1 : String | CSharp7.cs:90:18:90:28 | call to method I |
5761
| CSharp7.cs:181:23:181:25 | access to local variable src : String | CSharp7.cs:177:25:177:25 | s : String | CSharp7.cs:177:31:177:31 | access to parameter s : String | CSharp7.cs:181:21:181:26 | call to local function g |
5862
| CSharp7.cs:182:23:182:25 | access to local variable src : String | CSharp7.cs:178:25:178:25 | s : String | CSharp7.cs:178:37:178:37 | access to parameter s : String | CSharp7.cs:182:21:182:26 | call to local function h |

0 commit comments

Comments
 (0)