File tree Expand file tree Collapse file tree 2 files changed +4
-14
lines changed
go/ql/test/library-tests/semmle/go Expand file tree Collapse file tree 2 files changed +4
-14
lines changed Original file line number Diff line number Diff line change 1
1
import go
2
+ import semmle.go.dataflow.internal.DataFlowPrivate
2
3
3
4
from DataFlow:: Node nd , DataFlow:: Node succ
4
5
where
5
6
TaintTracking:: localTaintStep ( nd , succ ) and
6
7
// exclude data-flow steps
7
8
not DataFlow:: localFlowStep ( nd , succ ) and
8
9
// Exclude results from libraries
9
- not exists ( string pkg , string name |
10
- nd .( DataFlow:: SummarizedParameterNode )
11
- .getCallable ( )
12
- .asSummarizedCallable ( )
13
- .asFunction ( )
14
- .hasQualifiedName ( pkg , name )
15
- )
10
+ not nd instanceof FlowSummaryNode
16
11
select nd , succ
Original file line number Diff line number Diff line change 1
1
// This test finds taint tracking steps which are not data flow steps
2
2
// to illustrate which steps are added specifically by taint tracking
3
3
import go
4
+ import semmle.go.dataflow.internal.DataFlowPrivate
4
5
5
6
from DataFlow:: Node pred , DataFlow:: Node succ
6
7
where
7
8
TaintTracking:: localTaintStep ( pred , succ ) and
8
9
not DataFlow:: localFlowStep ( pred , succ ) and
9
10
// Exclude results from libraries
10
- not exists ( string pkg , string name |
11
- pred .( DataFlow:: SummarizedParameterNode )
12
- .getCallable ( )
13
- .asSummarizedCallable ( )
14
- .asFunction ( )
15
- .hasQualifiedName ( pkg , name )
16
- )
11
+ not pred instanceof FlowSummaryNode
17
12
select pred , succ
You can’t perform that action at this time.
0 commit comments