Skip to content

Commit 3fa93e5

Browse files
committed
Rust: Add rust/summary/taint-sources query.
1 parent b6cdae2 commit 3fa93e5

1 file changed

Lines changed: 17 additions & 0 deletions

File tree

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
/**
2+
* @name Taint Sources
3+
* @description List all sources of untrusted input that have been idenfitied
4+
* in the database.
5+
* @kind problem
6+
* @problem.severity info
7+
* @id rust/summary/taint-sources
8+
* @tags summary
9+
*/
10+
11+
import rust
12+
import codeql.rust.Concepts
13+
14+
from ThreatModelSource s, string defaultString
15+
where
16+
if s instanceof ActiveThreatModelSource then defaultString = ", DEFAULT" else defaultString = ""
17+
select s, s.getSourceType() + " (" + s.getThreatModel() + defaultString + ")"

0 commit comments

Comments
 (0)