File tree Expand file tree Collapse file tree 15 files changed +58
-7
lines changed
go/ql/test/library-tests/semmle/go
frameworks/StdlibTaintFlow Expand file tree Collapse file tree 15 files changed +58
-7
lines changed Original file line number Diff line number Diff line change 11invalidModelRow
22testFailures
3+ | test.go:204:21:204:51 | comment | Missing result: hasTaintFlow="call to new" |
4+ | test.go:205:21:205:55 | comment | Missing result: hasTaintFlow="star expression" |
Original file line number Diff line number Diff line change 11module semmle.go.Packages
22
3- go 1.13
3+ go 1.26
44
55require github.com/nonexistent/test v0.0.0-20200203000000-0000000000000
Original file line number Diff line number Diff line change @@ -44,4 +44,6 @@ invalidModelRow
4444| test.go:199:23:199:26 | arg2 | qltest |
4545| test.go:199:29:199:32 | arg3 | qltest |
4646| test.go:202:22:202:25 | temp | qltest |
47- | test.go:206:10:206:12 | src | qltest |
47+ | test.go:204:10:204:17 | call to new | qltest |
48+ | test.go:205:10:205:18 | star expression | qltest |
49+ | test.go:209:10:209:12 | src | qltest |
Original file line number Diff line number Diff line change @@ -22,4 +22,4 @@ invalidModelRow
2222| test.go:187:24:187:31 | call to Src1 | qltest |
2323| test.go:191:24:191:31 | call to Src1 | qltest |
2424| test.go:201:10:201:28 | selection of SourceVariable | qltest |
25- | test.go:205 :15:205 :17 | definition of src | qltest |
25+ | test.go:208 :15:208 :17 | definition of src | qltest |
Original file line number Diff line number Diff line change @@ -200,6 +200,9 @@ func simpleflow() {
200200
201201 temp := test .SourceVariable
202202 test .SinkVariable = temp // $ hasTaintFlow="temp"
203+
204+ b .Sink1 (new (src )) // $ hasTaintFlow="call to new"
205+ b .Sink1 (* new (src )) // $ hasTaintFlow="star expression"
203206}
204207
205208func srcParam (src string , b test.B ) {
Original file line number Diff line number Diff line change 11invalidModelRow
22testFailures
3+ | test.go:213:21:213:55 | comment | Missing result: hasValueFlow="star expression" |
Original file line number Diff line number Diff line change 11module semmle.go.Packages
22
3- go 1.21
3+ go 1.26
44
55require github.com/nonexistent/test v0.0.0-20200203000000-0000000000000
Original file line number Diff line number Diff line change @@ -50,4 +50,6 @@ invalidModelRow
5050| test.go:206:10:206:26 | call to min | qltest |
5151| test.go:207:10:207:26 | call to min | qltest |
5252| test.go:210:22:210:25 | temp | qltest |
53- | test.go:214:10:214:12 | src | qltest |
53+ | test.go:212:10:212:17 | call to new | qltest |
54+ | test.go:213:10:213:18 | star expression | qltest |
55+ | test.go:217:10:217:12 | src | qltest |
Original file line number Diff line number Diff line change @@ -22,4 +22,4 @@ invalidModelRow
2222| test.go:187:24:187:31 | call to Src1 | qltest |
2323| test.go:191:24:191:31 | call to Src1 | qltest |
2424| test.go:209:10:209:28 | selection of SourceVariable | qltest |
25- | test.go:213 :15:213 :17 | definition of src | qltest |
25+ | test.go:216 :15:216 :17 | definition of src | qltest |
Original file line number Diff line number Diff line change @@ -208,6 +208,9 @@ func simpleflow() {
208208
209209 temp := test .SourceVariable
210210 test .SinkVariable = temp // $ hasValueFlow="temp"
211+
212+ b .Sink1 (new (src ))
213+ b .Sink1 (* new (src )) // $ hasValueFlow="star expression"
211214}
212215
213216func srcParam (src string , b test.B ) {
You can’t perform that action at this time.
0 commit comments