Skip to content

Commit 52f2a9a

Browse files
committed
Add Actix framework modeling and import to Frameworks.qll
1 parent 5c1581d commit 52f2a9a

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

rust/ql/lib/codeql/rust/Frameworks.qll

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
* This file imports all models of frameworks and libraries.
33
*/
44

5+
private import codeql.rust.frameworks.Actix
56
private import codeql.rust.frameworks.rustcrypto.RustCrypto
67
private import codeql.rust.frameworks.Poem
78
private import codeql.rust.frameworks.Sqlx
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/**
2+
* Provides modeling for the `Actix` library.
3+
*/
4+
5+
private import rust
6+
private import codeql.rust.Concepts
7+
private import codeql.rust.dataflow.DataFlow
8+
9+
/**
10+
* Parameters of a handler function
11+
*/
12+
private class ActixHandlerParam extends RemoteSource::Range {
13+
ActixHandlerParam() {
14+
exists(TupleStructPat param |
15+
param.getResolvedPath() = ["crate::types::query::Query"]
16+
|
17+
this.asPat().getPat() = param.getAField()
18+
)
19+
}
20+
}

0 commit comments

Comments
 (0)