Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
275 commits
Select commit Hold shift + click to select a range
4b6135c
[DIFF-INFORMED] Ruby: MissingFullAnchor
d10c Jul 16, 2025
793f921
[DIFF-INFORMED] C#: ConditionalBypass
d10c Jul 16, 2025
7f085e6
[DIFF-INFORMED] C#: UnsafeDeserializationQuery
d10c Jul 16, 2025
b2fd58e
[DIFF-INFORMED] C#: ThreadUnsafeCryptoTransformLambda
d10c Jul 16, 2025
218fcbb
[DIFF-INFORMED] C#: HardcodedConnectionString
d10c Jul 16, 2025
9da94fb
Fix #19294, Ruby NetHttpRequest improvements
mschwager Jul 21, 2025
5192f31
Update expected test output
mschwager Jul 21, 2025
d8b9d4d
Add change-note
mschwager Jul 23, 2025
67c170f
Merge branch 'main' into sqlx
geoffw0 Jul 24, 2025
e3021f4
Java: Untangle code a bit to improve join order.
aschackmull Jul 25, 2025
5ca35af
Java: Improve joinorder in getErasedRepr.
aschackmull Jul 25, 2025
6c82752
Java: Improve ObjFlow performance.
aschackmull Jul 25, 2025
9972aaf
Rust: Add tests cases for cleartext storage.
geoffw0 Jun 13, 2025
897822d
Rust: The Cargo.lock file has changed as well.
geoffw0 Jul 28, 2025
5c64d4e
Rust: Query framework.
geoffw0 Jun 26, 2025
a3110a9
Rust: Implement query.
geoffw0 Jun 26, 2025
e585e67
Rust: Add qhelp and examples.
geoffw0 Jul 28, 2025
215fe7d
Rust: Clean up the alert message.
geoffw0 Jul 29, 2025
b6e60e4
Rust: Address small bugs in the test.
geoffw0 Jul 30, 2025
42ced8a
Rust: Add examples to tests.
geoffw0 Jul 30, 2025
5f53820
Exlucde environmental variables from default detection in regexp inje…
Napalys Jul 31, 2025
8583257
Created new folder for test with threat models disabled
Napalys Jul 31, 2025
d28a6e6
Added new test cases for regexp injection with enviromental variable …
Napalys Jul 31, 2025
3f9061a
Added change note
Napalys Jul 31, 2025
58680c9
Rust: Repair BadCtorInitialization.ql's StdCall using getCanonicalPath.
geoffw0 Jul 31, 2025
1828970
C++: Add an example of double negation to the IR tests.
MathiasVP Jul 31, 2025
01d24c4
Merge branch 'main' into sqlx
geoffw0 Jul 31, 2025
e8eb9be
Add command injection tests for CLI argument parsing libraries
Napalys Aug 1, 2025
e980798
Added step through yargs/yargs constructor and chained methods.
Napalys Aug 1, 2025
6b4e34d
Added a step from parse to opts for commander js
Napalys Aug 1, 2025
39170f3
Added couple more test cases for commander js
Napalys Aug 1, 2025
d6508f3
Add taint flow for Commander.js direct property access and action cal…
Napalys Aug 1, 2025
ae4077d
add taint flow for arg/command-line-args with custom argv option
Napalys Aug 1, 2025
881ea76
Added change note
Napalys Aug 1, 2025
7561190
C++: Fix type errors in C code.
MathiasVP Jul 31, 2025
14345a8
C++: Accept test changes.
MathiasVP Jul 31, 2025
1aa8adb
C++: Add test.
MathiasVP Aug 2, 2025
34c1ec7
C++: Add tests with missing flow through globals.
MathiasVP Jul 22, 2025
73e4bfd
C++: Fix missing flow by also generating final global uses for functi…
MathiasVP Jul 22, 2025
fca49dd
C++: Accept test changes.
MathiasVP Jul 22, 2025
0d9e298
C++: Specifier-only converting instructions preserve GVNs.
MathiasVP Aug 3, 2025
c726285
C++: Sync identical files.
MathiasVP Aug 3, 2025
b807ee4
C++: Accept test changes.
MathiasVP Aug 2, 2025
851c498
C++: Accept test changes. This is a FP that's been present since we p…
MathiasVP Aug 2, 2025
65b1b7f
C++: Add change note.
MathiasVP Aug 2, 2025
361ef0f
C#: Include constructors in `ValueOrRefType.hasCallable`
hvitved Aug 4, 2025
c3349bb
Rust: Add type inference example with cycle blowup
paldepind Aug 2, 2025
3ba285c
Rust: Implement certain type information for annotation and simple calls
paldepind Aug 2, 2025
f1cb1a3
Rust: Add computed security-severity tag.
geoffw0 Aug 4, 2025
0a27a8c
Java: Assume normal termination in post-dominance.
aschackmull Aug 4, 2025
989b48d
Rust: Add tests for rusqlite.
geoffw0 Aug 4, 2025
e368ee4
Rust: Accept that sql-injection sinks are sinks for this query, and t…
geoffw0 Aug 4, 2025
a86479e
Rust: Accept consistency check failures.
geoffw0 Aug 4, 2025
651e162
Rust: Fix bad join
hvitved Aug 4, 2025
836f797
Rust: Accept suite changes.
geoffw0 Aug 4, 2025
b60faad
Rust: Change note.
geoffw0 Aug 4, 2025
def655f
Rust: Accept changes to the CWE-089 test (there are some duplicate re…
geoffw0 Aug 4, 2025
fb4b0aa
Post-release preparation for codeql-cli-2.22.3
invalid-email-address Aug 4, 2025
eab7481
Rust: Accept CWE-312 consistency check failures.
geoffw0 Aug 4, 2025
6c024a5
Rust: Remove unnecessary pattern matching in cleartext logging query …
geoffw0 Aug 4, 2025
e2b8d7b
Merge pull request #20166 from github/post-release-prep/codeql-cli-2.…
cklin Aug 4, 2025
0a49b65
Rust: Make the rust/cleartext-transmission alert message more consist…
geoffw0 Aug 4, 2025
dcda6db
Rust: Lets not try to maintain this list.
geoffw0 Aug 4, 2025
b426d84
Merge pull request #20164 from hvitved/rust/fix-bad-join
hvitved Aug 5, 2025
273429d
Java: Accept qltest output
aschackmull Aug 5, 2025
6e90823
Merge pull request #20158 from hvitved/csharp/has-callable-constructor
hvitved Aug 5, 2025
c8e9ed3
Merge branch 'main' into cleartextstorage
geoffw0 Aug 5, 2025
23aac0a
Java: document nullness false negative as qltest
aschackmull Aug 5, 2025
c59d20a
Merge pull request #20163 from aschackmull/java/postdom-normal
aschackmull Aug 5, 2025
9427428
Merge pull request #20127 from aschackmull/java/joinorder3
aschackmull Aug 5, 2025
1823355
Merge pull request #20171 from aschackmull/java/nullness-fn
aschackmull Aug 5, 2025
11dcd90
Shared: Use `final` aliases in `ConcentsShared.qll`
hvitved Aug 5, 2025
a396f93
Rust: Remove restriction in `PathTypeMention`
hvitved Aug 5, 2025
0d4f876
Merge pull request #20167 from geoffw0/mdlcleanup
geoffw0 Aug 5, 2025
83ec1d0
Rust: Add the new query sinks to the Stats.qll import, so that they'r…
geoffw0 Aug 5, 2025
eb3c054
JS: Generate legacy flow steps for all flow summaries
hvitved Aug 5, 2025
1f15fc8
Merge pull request #20173 from hvitved/rust/type-mention-remove-restr…
hvitved Aug 6, 2025
d201ce1
Merge pull request #20155 from paldepind/rust/type-inference-certain
hvitved Aug 6, 2025
7660832
Rust: Add tests with `where` clause
paldepind Jul 30, 2025
b302f3f
Rust: Improve handling of where clauses in type inference and path re…
paldepind Jul 30, 2025
0cfb22f
Rust: Add example with multiple where clause items for the same type …
paldepind Aug 4, 2025
b50a766
Rust: Handle multiple type bounds for the same type parameter in `get…
paldepind Aug 4, 2025
d215ea1
Merge pull request #19802 from geoffw0/sqlx
geoffw0 Aug 6, 2025
ed3a33f
Merge pull request #20177 from hvitved/rust/type-inference-where
hvitved Aug 6, 2025
e991aa3
Merge branch 'main' into cleartextstorage
geoffw0 Aug 6, 2025
dfe4401
Merge pull request #20169 from hvitved/javascript/legacy-summary-steps
hvitved Aug 6, 2025
1be542e
Rust: Generalize certain type inference logic
hvitved Aug 6, 2025
e172e74
Rust: Remove comment from type inference test
hvitved Aug 6, 2025
3aaf48d
Guards: Remove CustomGuard nesting in Guards instantiation.
aschackmull Jul 22, 2025
1bdaa24
Java: Simplify Guards instantiation a bit.
aschackmull Jul 22, 2025
6e52df1
Guards: Rename module.
aschackmull Jul 22, 2025
0c31a80
Guards: Generalise wrapper guards.
aschackmull Jul 23, 2025
b156bd5
Guards: Rename predicate.
aschackmull Jul 23, 2025
f90b6ab
Guards: Add support for wrappers that may throw exceptions.
aschackmull Jul 23, 2025
ec513ea
Guards: Add support for extending BarrierGuards with wrapped invocati…
aschackmull Jul 24, 2025
a40ae3a
Guards: Slight join-order improvement.
aschackmull Jul 24, 2025
d9cfe14
Java: Accept qltest change.
aschackmull Jul 24, 2025
b51c0e7
Java: Add change note.
aschackmull Jul 28, 2025
2909def
Guards: Rename predicate.
aschackmull Aug 7, 2025
3674966
Merge pull request #20121 from aschackmull/guards/wrapperguard
aschackmull Aug 7, 2025
a04ff18
Java: Enable validation wrappers in BarrierGuards.
aschackmull Jul 29, 2025
9957cbe
Java/Guards: Improve BarrierGuards to include `validate(x = ...)` che…
aschackmull Jul 29, 2025
b19f15b
Java: Simplify ArithmeticCommon using BarrierGuards.
aschackmull Jul 29, 2025
3b3f4bc
Java/Guards: Remove unused.
aschackmull Jul 29, 2025
c5f83c4
Rust: Add rust/diagnostics/type-inference-consistency-counts.
geoffw0 Aug 7, 2025
38f4f8d
Rust: Update suite lists.
geoffw0 Aug 7, 2025
72563ec
Merge pull request #20080 from d10c/d10c/diff-informed-phase-3-ruby
cklin Aug 7, 2025
1965fdb
Rust: Update consistency .expected.
geoffw0 Aug 7, 2025
72843b5
Java: use java 17 in `no-wrapper` tests
redsun82 Aug 8, 2025
e94f018
Kotlin: Support kotlin Throws annotations.
aschackmull Aug 8, 2025
492a5ca
Java: Add some more exception edges to the CFG to facilitate guard wr…
aschackmull Aug 8, 2025
c043e30
Rust: Remove source/library deduplication in path resolution
hvitved Aug 8, 2025
26be983
C++: Add FP.
MathiasVP Aug 8, 2025
d76ce4f
C++: Also handle reference types when computing 'trueSize'.
MathiasVP Aug 8, 2025
0c9d14f
C++: Accept test changes.
MathiasVP Aug 8, 2025
b00107f
C++: Add change note.
MathiasVP Aug 8, 2025
e02a2d8
Merge pull request #20189 from github/redsun82/java-17-in-gradle-no-w…
redsun82 Aug 8, 2025
874f951
Merge pull request #20172 from hvitved/shared/concepts-final-aliases
hvitved Aug 11, 2025
56aacb1
Merge pull request #20145 from MathiasVP/fix-type-error-in-ir
MathiasVP Aug 11, 2025
ccfcd90
Merge pull request #20156 from MathiasVP/value-numbering-for-noop-casts
MathiasVP Aug 11, 2025
04014d9
Merge pull request #20150 from geoffw0/ctorinit
geoffw0 Aug 11, 2025
a1bc865
Merge pull request #20185 from geoffw0/typeconsistencycounts
geoffw0 Aug 11, 2025
851cb04
Merge pull request #20193 from MathiasVP/fix-fp-in-overflow-buffer
MathiasVP Aug 11, 2025
c8eb1cf
C++: Add change note.
MathiasVP Aug 11, 2025
f9f99a0
Merge pull request #20126 from MathiasVP/fix-missing-global-flow
jketema Aug 11, 2025
98d312f
Actions: clarify doc for untrusted checkout
p- Aug 11, 2025
3382d06
Rust: Remove newline.
geoffw0 Aug 11, 2025
5fc8db8
Merge pull request #20137 from geoffw0/cleartextstorage
geoffw0 Aug 11, 2025
9905cd6
Merge pull request #20192 from hvitved/rust/path-resolution-remove-so…
hvitved Aug 11, 2025
357964e
Remove duplicate lines and format query
mschwager Aug 11, 2025
6e38087
Merge pull request #20204 from p-/p--actions-untrusted-checkout-doc
Napalys Aug 11, 2025
45c0c46
Cargo: align rust toolchain version with internal repository
redsun82 Aug 11, 2025
911d6f0
Shared tree-sitter extractor: run clippy
redsun82 Aug 11, 2025
31353e7
Rust: Test more variants of postgres usage.
geoffw0 Aug 11, 2025
b311864
Rust: Test more variants of rusqlite usage.
geoffw0 Aug 11, 2025
17741af
Rust: Fill out a few gaps in the models.
geoffw0 Aug 4, 2025
5056ebf
Rust: Fix typo in one of the models.
geoffw0 Aug 4, 2025
35681d0
Rust: Add SQLx sources.
geoffw0 Aug 4, 2025
4bbffc5
Rust: Expand tokio-postgres sources.
geoffw0 Aug 4, 2025
0544ea8
Rust: Add postgres sources.
geoffw0 Aug 4, 2025
398d2ac
Rust: Fix a couple more gaps.
geoffw0 Aug 11, 2025
993f00b
Rust: Change note.
geoffw0 Aug 11, 2025
af20d33
Rust: Accept consistency test changes.
geoffw0 Aug 11, 2025
cb541b5
Fix indentation in the "Supported languages and frameworks" page
aeisenberg Aug 8, 2025
f5fbef9
Merge pull request #20196 from github/aeisenberg/indentation-fix
aeisenberg Aug 11, 2025
565d607
Merge branch 'main' into redsun82/rust-toolchain
redsun82 Aug 12, 2025
0dfacf4
Rust: add test `rust-toolchain.toml` after fixing `.gitignore`
redsun82 Aug 12, 2025
8436f00
Merge pull request #20179 from hvitved/rust/type-inference-certain-fo…
hvitved Aug 12, 2025
b2343f9
Rust: Add another type inference test
hvitved Aug 7, 2025
454ab4d
Rust: Unify type inference for tuple indexing expressions
hvitved Aug 7, 2025
2b92b83
Merge pull request #20207 from github/redsun82/rust-toolchain
redsun82 Aug 12, 2025
0a67902
Merge pull request #20101 from mschwager/main
hvitved Aug 12, 2025
b20521b
Shared: Overhaul the AlertFiltering QLDoc
cklin Aug 12, 2025
34d546c
Merge branch 'main' into cklin/alert-filtering-qldoc
cklin Aug 12, 2025
caa935d
C++: Update the tests for guard conditions so that the tests print mo…
MathiasVP Jul 29, 2025
17b4682
Merge pull request #20208 from geoffw0/sqlmodels
geoffw0 Aug 13, 2025
c997b29
Rust: regenerate bazel files
redsun82 Aug 13, 2025
fcbd333
Merge pull request #20215 from github/redsun82/rust-fix-bazel
jketema Aug 13, 2025
a271354
C++: Add tests.
MathiasVP Aug 13, 2025
91eb4da
Rust: Add a type inference test case resembling PathBuf.canonicalize.
geoffw0 Aug 13, 2025
ea320c2
Bazel: regenerate cargo vendored files
redsun82 Aug 13, 2025
dc6e76a
Merge pull request #20182 from hvitved/rust/type-inference-tuple-type…
hvitved Aug 13, 2025
653a997
Merge pull request #20216 from github/redsun82/rust-fix-bazel
jketema Aug 13, 2025
d5f8289
Go: Update Go version in tests to 1.25.0
jketema Aug 12, 2025
4baf115
Go: Use Go 1.25.0 to build the Go extractor
jketema Aug 12, 2025
976ef99
Go: Request go1.25.0 toolchain
jketema Aug 12, 2025
5e2a560
Update `go_rules` to the latest version
jketema Aug 13, 2025
4b215d5
Go: Update `maxGoVersion` in the autobuilder
jketema Aug 13, 2025
4c263c0
Merge pull request #20047 from github/cklin/alert-filtering-qldoc
cklin Aug 13, 2025
ff288d7
Merge pull request #20210 from github/jketema/go-1.25
jketema Aug 13, 2025
e67b6d6
C++: Add another inference step.
MathiasVP Aug 13, 2025
e6cd27a
C++: Skip non-Boolean instructions in the new inference step.
MathiasVP Aug 13, 2025
bf4a84b
C++: Drive-by: Add forgotten disjuncts involving '__builtin_expect'.
MathiasVP Aug 13, 2025
9ee313f
C++: Remove code that is now subsumed.
MathiasVP Aug 12, 2025
9c3bb87
C++: Add change note.
MathiasVP Aug 13, 2025
39f5e33
C++: Accept more test changes.
MathiasVP Aug 13, 2025
cc302c0
Sitedocs for 2.22.3
jonjanego Aug 13, 2025
603f0f2
Merge pull request #20219 from github/changedocs-2.22.3
jonjanego Aug 13, 2025
72c89ec
Merge pull request #20218 from MathiasVP/fix-guard-conditions-for-likely
jketema Aug 14, 2025
fd1d940
Rust: Add tests for chained `let` expressions
hvitved Aug 11, 2025
f63e55c
Rust: Handle chained `let` expressions
hvitved Aug 12, 2025
1c186e2
Merge remote-tracking branch 'upstream/main' into pathbuf
geoffw0 Aug 14, 2025
28f2157
Go: Mention Go 1.25 as supported
jketema Aug 14, 2025
51fb215
Rust: Remove references to `getResolvedPath` and `getExtendedCanonica…
hvitved Aug 14, 2025
ecf0e08
Rust: Add some more path injection test case variants.
geoffw0 Jul 9, 2025
6941e7f
Rust: Add tags to intermediate steps in the test.
geoffw0 Aug 14, 2025
02b9229
Rust: Update StartswithCall.
geoffw0 Aug 14, 2025
6951f58
Merge pull request #20226 from geoffw0/stdlib
geoffw0 Aug 14, 2025
d09645b
Add change note
hvitved Aug 14, 2025
5c0300c
Merge pull request #20224 from hvitved/rust/remove-extractor-resoluti…
hvitved Aug 14, 2025
b67394a
Merge pull request #20183 from aschackmull/java/barrierguard-wrappers
aschackmull Aug 14, 2025
f1bff93
Merge pull request #20203 from hvitved/rust/if-let-chain-test
hvitved Aug 14, 2025
a8889ff
add extensions for remote sources
5idg5 Aug 14, 2025
e1ffb32
C#: Replace input interpolation with environment variable
mbg Aug 15, 2025
ec605b2
Merge pull request #20229 from github/mbg/ci/fix/csharp-create-extrac…
mbg Aug 15, 2025
7501e62
Shared: Skip non-CFG children in `StandardTree`
hvitved Aug 15, 2025
896819f
[DIFF-INFORMED] Actions: ArgumentInjection
d10c Jul 15, 2025
bbda290
[DIFF-INFORMED] Actions: ArtifactPoisoning
d10c Jul 15, 2025
418e4b4
[DIFF-INFORMED] Actions: CodeInjection
d10c Jul 15, 2025
f1b995a
[DIFF-INFORMED] Actions: CommandInjection
d10c Jul 15, 2025
f1445eb
[DIFF-INFORMED] Actions: EnvPathInjection
d10c Jul 15, 2025
126d24a
[DIFF-INFORMED] Actions: EnvVarInjection
d10c Jul 15, 2025
43e99d0
[TEST] C++: CleartextSqliteDatabase: add new test
d10c Jul 15, 2025
448a1ea
[DIFF-INFORMED] C++: OverflowDestination
d10c Jul 15, 2025
fabdf99
[DIFF-INFORMED] C++: ConstantSizeArrayOffByOne
d10c Jul 15, 2025
e382cb5
[DIFF-INFORMED] C++: DecompressionBombs
d10c Jul 15, 2025
2f56baa
[DIFF-INFORMED] C++: NonConstantFormat
d10c Jul 15, 2025
91b9c3e
[DIFF-INFORMED] C++: LeapYear
d10c Jul 16, 2025
a77cab6
[DIFF-INFORMED] C++: TaintedPath
d10c Jul 16, 2025
80da00b
[DIFF-INFORMED] C++: ExecTainted
d10c Jul 16, 2025
36d43a4
[DIFF-INFORMED] C++: CgiXss
d10c Jul 16, 2025
7df09f3
[DIFF-INFORMED] C++: SqlTainted
d10c Jul 16, 2025
f3098e7
[DIFF-INFORMED] C++: UnboundedWrite
d10c Jul 16, 2025
62fa730
[DIFF-INFORMED] C++: ImproperNullTerminationTainted
d10c Jul 16, 2025
861a768
[DIFF-INFORMED] C++: CWE-190/ArithmeticTainted,etc.
d10c Jul 16, 2025
87016f3
[DIFF-INFORMED] C++: AuthenticationBypass
d10c Jul 16, 2025
2191403
[DIFF-INFORMED] C++: SSLResultConflation (has secondary config but pa…
d10c Jul 16, 2025
05df2f2
[DIFF-INFORMED] C++: CWE-311/Cleartext…
d10c Jul 16, 2025
8560868
[DIFF-INFORMED] C++: CleartextSqliteDatabase
d10c Jul 16, 2025
c0c96ea
[DIFF-INFORMED] C++: UseOfHttp
d10c Jul 16, 2025
ec85e55
[DIFF-INFORMED] C++: InsufficientKeySize
d10c Jul 16, 2025
39b430a
[DIFF-INFORMED] C++: IteratorToExpiredContainer
d10c Jul 16, 2025
194d9a9
[DIFF-INFORMED] C++: UnsafeCreateProcessCall
d10c Jul 16, 2025
0c636dd
[DIFF-INFORMED] C++: UnsafeDaclSecurityDescriptor
d10c Jul 16, 2025
5b9e37c
[DIFF-INFORMED] C++: TaintedCondition
d10c Jul 16, 2025
8978820
[DIFF-INFORMED] C++: TypeConfusion
d10c Jul 16, 2025
8000e7c
Merge pull request #20074 from d10c/d10c/diff-informed-phase-3-csharp
d10c Aug 15, 2025
0b68c1c
C++: Add some more tests for SloppyGlobal
igfoo Aug 15, 2025
4b78606
C++: SloppyGlobal: Don't alert on template instantiations, only the t…
igfoo Aug 15, 2025
0512940
Merge pull request #20075 from d10c/d10c/diff-informed-phase-3-go
d10c Aug 15, 2025
bfd4c41
C++: SloppyGlobal: Accept test changes
igfoo Aug 15, 2025
1af6ddd
Rust: Remove TC from `ImplTraitTypeRepr.isInReturnPos`
hvitved Aug 15, 2025
3157fcd
C++: Add some BAD annotations to SloppyGlobal test
igfoo Aug 15, 2025
0870cc3
C++: Add a changenote for the change to cpp/short-global-name
igfoo Aug 15, 2025
84119ba
Merge pull request #20223 from jketema/go-1.25-doc
jketema Aug 15, 2025
bb9daa0
Merge pull request #20072 from d10c/d10c/diff-informed-phase-3-actions
d10c Aug 15, 2025
e697e89
Merge branch 'main' of https://github.com/5idg5/codeql into java/data…
5idg5 Aug 15, 2025
d84e531
changenote
5idg5 Aug 15, 2025
b234618
Merge pull request #20148 from Napalys/js/reg-exp-env-variable-threat…
Napalys Aug 18, 2025
b19d1e0
Merge pull request #20151 from Napalys/js/command-line-libs
Napalys Aug 18, 2025
4199859
Merge pull request #20079 from d10c/d10c/diff-informed-phase-3-python
d10c Aug 18, 2025
f1b5564
Merge pull request #20073 from d10c/d10c/diff-informed-phase-3-cpp
d10c Aug 18, 2025
877d397
Merge pull request #20228 from 5idg5/java/data-extensions-change
aschackmull Aug 18, 2025
4eea443
Merge pull request #20222 from geoffw0/pathbuf
geoffw0 Aug 18, 2025
299ccb6
Merge pull request #20230 from hvitved/cfg/standard-tree-skip-non-tre…
hvitved Aug 18, 2025
fd020b5
Merge pull request #20232 from igfoo/igfoo/SloppyGlobal
igfoo Aug 18, 2025
f1ca0ec
Merge pull request #20233 from hvitved/rust/remove-tc
hvitved Aug 18, 2025
90d2999
Release preparation for version 2.22.4
invalid-email-address Aug 18, 2025
57378ec
Merge pull request #20240 from github/release-prep/2.22.4
smowton Aug 18, 2025
05dbec6
Merge tag 'codeql-cli/latest' into auto/sync-main-pr
Aug 21, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 7 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,13 @@ common --registry=https://bcr.bazel.build

common --@rules_dotnet//dotnet/settings:strict_deps=false

# we only configure a nightly toolchain
common --@rules_rust//rust/toolchain/channel=nightly

# rust does not like the gold linker, while bazel does by default, so let's avoid using it
common:linux --linkopt=-fuse-ld=lld
common:macos --linkopt=-fuse-ld=lld

# Reduce this eventually to empty, once we've fixed all our usages of java, and https://github.com/bazel-contrib/rules_go/issues/4193 is fixed
common --incompatible_autoload_externally="+@rules_java,+@rules_shell"

Expand Down
51 changes: 27 additions & 24 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ local_path_override(
# see https://registry.bazel.build/ for a list of available packages

bazel_dep(name = "platforms", version = "0.0.11")
bazel_dep(name = "rules_go", version = "0.50.1")
bazel_dep(name = "rules_go", version = "0.56.1")
bazel_dep(name = "rules_pkg", version = "1.0.1")
bazel_dep(name = "rules_nodejs", version = "6.2.0-codeql.1")
bazel_dep(name = "rules_python", version = "0.40.0")
Expand All @@ -28,7 +28,7 @@ bazel_dep(name = "rules_kotlin", version = "2.1.3-codeql.1")
bazel_dep(name = "gazelle", version = "0.40.0")
bazel_dep(name = "rules_dotnet", version = "0.17.4")
bazel_dep(name = "googletest", version = "1.14.0.bcr.1")
bazel_dep(name = "rules_rust", version = "0.58.0")
bazel_dep(name = "rules_rust", version = "0.63.0")
bazel_dep(name = "zstd", version = "1.5.5.bcr.1")

bazel_dep(name = "buildifier_prebuilt", version = "6.4.0", dev_dependency = True)
Expand All @@ -38,7 +38,10 @@ bazel_dep(name = "buildifier_prebuilt", version = "6.4.0", dev_dependency = True
RUST_EDITION = "2024"

# run buildutils-internal/scripts/fill-rust-sha256s.py when updating (internal repo)
RUST_VERSION = "1.86.0"
# a nightly toolchain is required to enable experimental_use_cc_common_link, which we require internally
# we prefer to run the same version as internally, even if experimental_use_cc_common_link is not really
# required in this repo
RUST_VERSION = "nightly/2025-08-01"

rust = use_extension("@rules_rust//rust:extensions.bzl", "rust")
rust.toolchain(
Expand All @@ -50,26 +53,26 @@ rust.toolchain(
],
# generated by buildutils-internal/scripts/fill-rust-sha256s.py (internal repo)
sha256s = {
"rustc-1.86.0-x86_64-unknown-linux-gnu.tar.xz": "4438b809ce4a083af31ed17aeeedcc8fc60ccffc0625bef1926620751b6989d7",
"rustc-1.86.0-x86_64-apple-darwin.tar.xz": "42b76253626febb7912541a30d3379f463dec89581aad4cb72c6c04fb5a71dc5",
"rustc-1.86.0-aarch64-apple-darwin.tar.xz": "23b8f52102249a47ab5bc859d54c9a3cb588a3259ba3f00f557d50edeca4fde9",
"rustc-1.86.0-x86_64-pc-windows-msvc.tar.xz": "fdde839fea274529a31e51eb85c6df1782cc8479c9d1bc24e2914d66a0de41ab",
"clippy-1.86.0-x86_64-unknown-linux-gnu.tar.xz": "02aaff2c1407d2da8dba19aa4970dd873e311902b120a66cbcdbe51eb8836edf",
"clippy-1.86.0-x86_64-apple-darwin.tar.xz": "bb85efda7bbffaf124867f5ca36d50932b1e8f533c62ee923438afb32ff8fe9a",
"clippy-1.86.0-aarch64-apple-darwin.tar.xz": "239fa3a604b124f0312f2af08537874a1227dba63385484b468cca62e7c4f2f2",
"clippy-1.86.0-x86_64-pc-windows-msvc.tar.xz": "d00498f47d49219f032e2c5eeebdfc3d32317c0dc3d3fd7125327445bc482cb4",
"cargo-1.86.0-x86_64-unknown-linux-gnu.tar.xz": "c5c1590f7e9246ad9f4f97cfe26ffa92707b52a769726596a9ef81565ebd908b",
"cargo-1.86.0-x86_64-apple-darwin.tar.xz": "af163eb02d1a178044d1b4f2375960efd47130f795f6e33d09e345454bb26f4e",
"cargo-1.86.0-aarch64-apple-darwin.tar.xz": "3cb13873d48c3e1e4cc684d42c245226a11fba52af6b047c3346ed654e7a05c0",
"cargo-1.86.0-x86_64-pc-windows-msvc.tar.xz": "e57a9d89619b5604899bac443e68927bdd371e40f2e03e18950b6ceb3eb67966",
"llvm-tools-1.86.0-x86_64-unknown-linux-gnu.tar.xz": "282145ab7a63c98b625856f44b905b4dc726b497246b824632a5790debe95a78",
"llvm-tools-1.86.0-x86_64-apple-darwin.tar.xz": "b55706e92f7da989207c50c13c7add483a9fedd233bc431b106eca2a8f151ec9",
"llvm-tools-1.86.0-aarch64-apple-darwin.tar.xz": "04d3618c686845853585f036e3211eb9e18f2d290f4610a7a78bdc1fcce1ebd9",
"llvm-tools-1.86.0-x86_64-pc-windows-msvc.tar.xz": "721a17cc8dc219177e4277a3592253934ef08daa1e1b12eda669a67d15fad8dd",
"rust-std-1.86.0-x86_64-unknown-linux-gnu.tar.xz": "67be7184ea388d8ce0feaf7fdea46f1775cfc2970930264343b3089898501d37",
"rust-std-1.86.0-x86_64-apple-darwin.tar.xz": "3b1140d54870a080080e84700143f4a342fbd02a410a319b05d9c02e7dcf44cc",
"rust-std-1.86.0-aarch64-apple-darwin.tar.xz": "0fb121fb3b8fa9027d79ff598500a7e5cd086ddbc3557482ed3fdda00832c61b",
"rust-std-1.86.0-x86_64-pc-windows-msvc.tar.xz": "3d5354b7b9cb950b58bff3fce18a652aa374bb30c8f70caebd3bd0b43cb41a33",
"2025-08-01/rustc-nightly-x86_64-unknown-linux-gnu.tar.xz": "9bbeaf5d3fc7247d31463a9083aa251c995cc50662c8219e7a2254d76a72a9a4",
"2025-08-01/rustc-nightly-x86_64-apple-darwin.tar.xz": "c9ea539a8eff0d5d162701f99f9e1aabe14dd0dfb420d62362817a5d09219de7",
"2025-08-01/rustc-nightly-aarch64-apple-darwin.tar.xz": "ae83feebbc39cfd982e4ecc8297731fe79c185173aee138467b334c5404b3773",
"2025-08-01/rustc-nightly-x86_64-pc-windows-msvc.tar.xz": "9f170c30d802a349be60cf52ec46260802093cb1013ad667fc0d528b7b10152f",
"2025-08-01/clippy-nightly-x86_64-unknown-linux-gnu.tar.xz": "9ae5f3cd8f557c4f6df522597c69d14398cf604cfaed2b83e767c4b77a7eaaf6",
"2025-08-01/clippy-nightly-x86_64-apple-darwin.tar.xz": "983cb9ee0b6b968188e04ab2d33743d54764b2681ce565e1b3f2b9135c696a3e",
"2025-08-01/clippy-nightly-aarch64-apple-darwin.tar.xz": "ed2219dbc49d088225e1b7c5c4390fa295066e071fddaa2714018f6bb39ddbf0",
"2025-08-01/clippy-nightly-x86_64-pc-windows-msvc.tar.xz": "911f40ab5cbdd686f40e00965271fe47c4805513a308ed01f30eafb25b448a50",
"2025-08-01/cargo-nightly-x86_64-unknown-linux-gnu.tar.xz": "106463c284e48e4904c717471eeec2be5cc83a9d2cae8d6e948b52438cad2e69",
"2025-08-01/cargo-nightly-x86_64-apple-darwin.tar.xz": "6ad35c40efc41a8c531ea43235058347b6902d98a9693bf0aed7fc16d5590cef",
"2025-08-01/cargo-nightly-aarch64-apple-darwin.tar.xz": "dd28c365e9d298abc3154c797720ad36a0058f131265c9978b4c8e4e37012c8a",
"2025-08-01/cargo-nightly-x86_64-pc-windows-msvc.tar.xz": "7b431286e12d6b3834b038f078389a00cac73f351e8c3152b2504a3c06420b3b",
"2025-08-01/llvm-tools-nightly-x86_64-unknown-linux-gnu.tar.xz": "e342e305d7927cc288d386983b2bc253cfad3776b113386e903d0b302648ef47",
"2025-08-01/llvm-tools-nightly-x86_64-apple-darwin.tar.xz": "e44dd3506524d85c37b3a54bcc91d01378fd2c590b2db5c5974d12f05c1b84d1",
"2025-08-01/llvm-tools-nightly-aarch64-apple-darwin.tar.xz": "0c1b5f46dd81be4a9227b10283a0fcaa39c14fea7e81aea6fd6d9887ff6cdc41",
"2025-08-01/llvm-tools-nightly-x86_64-pc-windows-msvc.tar.xz": "423e5fd11406adccbc31b8456ceb7375ce055cdf45e90d2c3babeb2d7f58383f",
"2025-08-01/rust-std-nightly-x86_64-unknown-linux-gnu.tar.xz": "3c0ceb46a252647a1d4c7116d9ccae684fa5e42aaf3296419febd2c962c3b41d",
"2025-08-01/rust-std-nightly-x86_64-apple-darwin.tar.xz": "3be416003cab10f767390a753d1d16ae4d26c7421c03c98992cf1943e5b0efe8",
"2025-08-01/rust-std-nightly-aarch64-apple-darwin.tar.xz": "4046ac0ef951cb056b5028a399124f60999fa37792eab69d008d8d7965f389b4",
"2025-08-01/rust-std-nightly-x86_64-pc-windows-msvc.tar.xz": "191ed9d8603c3a4fe5a7bbbc2feb72049078dae2df3d3b7d5dedf3abbf823e6e",
},
versions = [RUST_VERSION],
)
Expand Down Expand Up @@ -260,7 +263,7 @@ use_repo(
)

go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk")
go_sdk.download(version = "1.24.0")
go_sdk.download(version = "1.25.0")

go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps")
go_deps.from_file(go_mod = "//go/extractor:go.mod")
Expand Down
4 changes: 4 additions & 0 deletions actions/ql/lib/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.4.15

No user-facing changes.

## 0.4.14

No user-facing changes.
Expand Down
3 changes: 3 additions & 0 deletions actions/ql/lib/change-notes/released/0.4.15.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## 0.4.15

No user-facing changes.
2 changes: 1 addition & 1 deletion actions/ql/lib/codeql-pack.release.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
lastReleaseVersion: 0.4.14
lastReleaseVersion: 0.4.15
21 changes: 21 additions & 0 deletions actions/ql/lib/codeql/actions/security/ArgumentInjectionQuery.qll
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
private import actions
private import codeql.actions.TaintTracking
private import codeql.actions.dataflow.ExternalFlow
private import codeql.actions.security.ControlChecks
import codeql.actions.dataflow.FlowSources
import codeql.actions.DataFlow

Expand Down Expand Up @@ -65,6 +66,16 @@ class ArgumentInjectionFromMaDSink extends ArgumentInjectionSink {
override string getCommand() { result = "unknown" }
}

/**
* Gets the event that is relevant for the given node in the context of argument injection.
*
* This is used to highlight the event in the query results when an alert is raised.
*/
Event getRelevantEventInPrivilegedContext(DataFlow::Node node) {
inPrivilegedContext(node.asExpr(), result) and
not exists(ControlCheck check | check.protects(node.asExpr(), result, "argument-injection"))
}

/**
* A taint-tracking configuration for unsafe user input
* that is used to construct and evaluate a code script.
Expand All @@ -88,6 +99,16 @@ private module ArgumentInjectionConfig implements DataFlow::ConfigSig {
run.getScript().getAnEnvReachingArgumentInjectionSink(var, _, _)
)
}

predicate observeDiffInformedIncrementalMode() { any() }

Location getASelectedSourceLocation(DataFlow::Node source) { none() }

Location getASelectedSinkLocation(DataFlow::Node sink) {
result = sink.getLocation()
or
result = getRelevantEventInPrivilegedContext(sink).getLocation()
}
}

/** Tracks flow of unsafe user input that is used to construct and evaluate a code script. */
Expand Down
21 changes: 21 additions & 0 deletions actions/ql/lib/codeql/actions/security/ArtifactPoisoningQuery.qll
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import codeql.actions.DataFlow
import codeql.actions.dataflow.FlowSources
import codeql.actions.security.PoisonableSteps
import codeql.actions.security.UntrustedCheckoutQuery
import codeql.actions.security.ControlChecks

string unzipRegexp() { result = "(unzip|tar)\\s+.*" }

Expand Down Expand Up @@ -292,6 +293,16 @@ class ArtifactPoisoningSink extends DataFlow::Node {
string getPath() { result = download.getPath() }
}

/**
* Gets the event that is relevant for the given node in the context of artifact poisoning.
*
* This is used to highlight the event in the query results when an alert is raised.
*/
Event getRelevantEventInPrivilegedContext(DataFlow::Node node) {
inPrivilegedContext(node.asExpr(), result) and
not exists(ControlCheck check | check.protects(node.asExpr(), result, "artifact-poisoning"))
}

/**
* A taint-tracking configuration for unsafe artifacts
* that is used may lead to artifact poisoning
Expand All @@ -318,6 +329,16 @@ private module ArtifactPoisoningConfig implements DataFlow::ConfigSig {
exists(run.getScript().getAFileReadCommand())
)
}

predicate observeDiffInformedIncrementalMode() { any() }

Location getASelectedSourceLocation(DataFlow::Node source) { none() }

Location getASelectedSinkLocation(DataFlow::Node sink) {
result = sink.getLocation()
or
result = getRelevantEventInPrivilegedContext(sink).getLocation()
}
}

/** Tracks flow of unsafe artifacts that is used in an insecure way. */
Expand Down
54 changes: 54 additions & 0 deletions actions/ql/lib/codeql/actions/security/CodeInjectionQuery.qll
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ private import codeql.actions.TaintTracking
private import codeql.actions.dataflow.ExternalFlow
import codeql.actions.dataflow.FlowSources
import codeql.actions.DataFlow
import codeql.actions.security.ControlChecks
import codeql.actions.security.CachePoisoningQuery

class CodeInjectionSink extends DataFlow::Node {
CodeInjectionSink() {
Expand All @@ -11,6 +13,46 @@ class CodeInjectionSink extends DataFlow::Node {
}
}

/**
* Get the relevant event for the sink in CodeInjectionCritical.ql.
*/
Event getRelevantCriticalEventForSink(DataFlow::Node sink) {
inPrivilegedContext(sink.asExpr(), result) and
not exists(ControlCheck check | check.protects(sink.asExpr(), result, "code-injection")) and
// exclude cases where the sink is a JS script and the expression uses toJson
not exists(UsesStep script |
script.getCallee() = "actions/github-script" and
script.getArgumentExpr("script") = sink.asExpr() and
exists(getAToJsonReferenceExpression(sink.asExpr().(Expression).getExpression(), _))
)
}

/**
* Get the relevant event for the sink in CachePoisoningViaCodeInjection.ql.
*/
Event getRelevantCachePoisoningEventForSink(DataFlow::Node sink) {
exists(LocalJob job |
job = sink.asExpr().getEnclosingJob() and
job.getATriggerEvent() = result and
// job can be triggered by an external user
result.isExternallyTriggerable() and
// excluding privileged workflows since they can be exploited in easier circumstances
// which is covered by `actions/code-injection/critical`
not job.isPrivilegedExternallyTriggerable(result) and
(
// the workflow runs in the context of the default branch
runsOnDefaultBranch(result)
or
// the workflow caller runs in the context of the default branch
result.getName() = "workflow_call" and
exists(ExternalJob caller |
caller.getCallee() = job.getLocation().getFile().getRelativePath() and
runsOnDefaultBranch(caller.getATriggerEvent())
)
)
)
}

/**
* A taint-tracking configuration for unsafe user input
* that is used to construct and evaluate a code script.
Expand All @@ -35,6 +77,18 @@ private module CodeInjectionConfig implements DataFlow::ConfigSig {
exists(run.getScript().getAFileReadCommand())
)
}

predicate observeDiffInformedIncrementalMode() { any() }

Location getASelectedSourceLocation(DataFlow::Node source) { none() }

Location getASelectedSinkLocation(DataFlow::Node sink) {
result = sink.getLocation()
or
result = getRelevantCriticalEventForSink(sink).getLocation()
or
result = getRelevantCachePoisoningEventForSink(sink).getLocation()
}
}

/** Tracks flow of unsafe user input that is used to construct and evaluate a code script. */
Expand Down
19 changes: 19 additions & 0 deletions actions/ql/lib/codeql/actions/security/CommandInjectionQuery.qll
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,20 @@ private import codeql.actions.TaintTracking
private import codeql.actions.dataflow.ExternalFlow
import codeql.actions.dataflow.FlowSources
import codeql.actions.DataFlow
import codeql.actions.security.ControlChecks

private class CommandInjectionSink extends DataFlow::Node {
CommandInjectionSink() { madSink(this, "command-injection") }
}

/** Get the relevant event for the sink in CommandInjectionCritical.ql. */
Event getRelevantEventInPrivilegedContext(DataFlow::Node sink) {
inPrivilegedContext(sink.asExpr(), result) and
not exists(ControlCheck check |
check.protects(sink.asExpr(), result, ["command-injection", "code-injection"])
)
}

/**
* A taint-tracking configuration for unsafe user input
* that is used to construct and evaluate a system command.
Expand All @@ -16,6 +25,16 @@ private module CommandInjectionConfig implements DataFlow::ConfigSig {
predicate isSource(DataFlow::Node source) { source instanceof RemoteFlowSource }

predicate isSink(DataFlow::Node sink) { sink instanceof CommandInjectionSink }

predicate observeDiffInformedIncrementalMode() { any() }

Location getASelectedSourceLocation(DataFlow::Node source) { none() }

Location getASelectedSinkLocation(DataFlow::Node sink) {
result = sink.getLocation()
or
result = getRelevantEventInPrivilegedContext(sink).getLocation()
}
}

/** Tracks flow of unsafe user input that is used to construct and evaluate a system command. */
Expand Down
31 changes: 31 additions & 0 deletions actions/ql/lib/codeql/actions/security/EnvPathInjectionQuery.qll
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,25 @@ class EnvPathInjectionFromMaDSink extends EnvPathInjectionSink {
EnvPathInjectionFromMaDSink() { madSink(this, "envpath-injection") }
}

/**
* Get the relevant event for a sink in EnvPathInjectionCritical.ql where the source type is "artifact".
*/
Event getRelevantArtifactEventInPrivilegedContext(DataFlow::Node sink) {
inPrivilegedContext(sink.asExpr(), result) and
not exists(ControlCheck check |
check.protects(sink.asExpr(), result, ["untrusted-checkout", "artifact-poisoning"])
) and
sink instanceof EnvPathInjectionFromFileReadSink
}

/**
* Get the relevant event for a sink in EnvPathInjectionCritical.ql where the source type is not "artifact".
*/
Event getRelevantNonArtifactEventInPrivilegedContext(DataFlow::Node sink) {
inPrivilegedContext(sink.asExpr(), result) and
not exists(ControlCheck check | check.protects(sink.asExpr(), result, "code-injection"))
}

/**
* A taint-tracking configuration for unsafe user input
* that is used to construct and evaluate an environment variable.
Expand Down Expand Up @@ -108,6 +127,18 @@ private module EnvPathInjectionConfig implements DataFlow::ConfigSig {
exists(run.getScript().getAFileReadCommand())
)
}

predicate observeDiffInformedIncrementalMode() { any() }

Location getASelectedSourceLocation(DataFlow::Node source) { none() }

Location getASelectedSinkLocation(DataFlow::Node sink) {
result = sink.getLocation()
or
result = getRelevantArtifactEventInPrivilegedContext(sink).getLocation()
or
result = getRelevantNonArtifactEventInPrivilegedContext(sink).getLocation()
}
}

/** Tracks flow of unsafe user input that is used to construct and evaluate the PATH environment variable. */
Expand Down
Loading
Loading