|
| 1 | +.. _codeql-cli-2.25.4: |
| 2 | + |
| 3 | +========================== |
| 4 | +CodeQL 2.25.4 (2026-05-05) |
| 5 | +========================== |
| 6 | + |
| 7 | +.. contents:: Contents |
| 8 | + :depth: 2 |
| 9 | + :local: |
| 10 | + :backlinks: none |
| 11 | + |
| 12 | +This is an overview of changes in the CodeQL CLI and relevant CodeQL query and library packs. For additional updates on changes to the CodeQL code scanning experience, check out the `code scanning section on the GitHub blog <https://github.blog/tag/code-scanning/>`__, `relevant GitHub Changelog updates <https://github.blog/changelog/label/application-security/>`__, `changes in the CodeQL extension for Visual Studio Code <https://marketplace.visualstudio.com/items/GitHub.vscode-codeql/changelog>`__, and the `CodeQL Action changelog <https://github.com/github/codeql-action/blob/main/CHANGELOG.md>`__. |
| 13 | + |
| 14 | +Security Coverage |
| 15 | +----------------- |
| 16 | + |
| 17 | +CodeQL 2.25.4 runs a total of 496 security queries when configured with the Default suite (covering 169 CWE). The Extended suite enables an additional 131 queries (covering 32 more CWE). |
| 18 | + |
| 19 | +CodeQL CLI |
| 20 | +---------- |
| 21 | + |
| 22 | +There are no user-facing CLI changes in this release. |
| 23 | + |
| 24 | +Language Libraries |
| 25 | +------------------ |
| 26 | + |
| 27 | +Breaking Changes |
| 28 | +~~~~~~~~~~~~~~~~ |
| 29 | + |
| 30 | +C# |
| 31 | +"" |
| 32 | + |
| 33 | +* The C# control flow graph (CFG) implementation has been completely rewritten. The CFG now includes additional nodes to more accurately represent certain constructs. This also means that any existing code that implicitly relies on very specific details about the CFG may need to be updated. |
| 34 | + The CFG no longer uses splitting, which means that AST nodes now have a unique CFG node representation. |
| 35 | + Additionally, the following breaking changes have been made: |
| 36 | + |
| 37 | + * :code:`ControlFlow::Node` has been renamed to :code:`ControlFlowNode`. |
| 38 | + * :code:`ControlFlow::Nodes` has been renamed to :code:`ControlFlowNodes`. |
| 39 | + * :code:`BasicBlock.getCallable` has been renamed to :code:`BasicBlock.getEnclosingCallable`. |
| 40 | + * :code:`BasicBlocks.qll` has been deleted. |
| 41 | + * :code:`ControlFlowNode.getAstNode` has changed its meaning. The AST-to-CFG mapping remains one-to-many, but now for a different reason. It used to be because of splitting, but now it's because of additional "helper" CFG nodes. To get the (now canonical) CFG node for a given AST node, use |
| 42 | + :code:`ControlFlowNode.asExpr()` or :code:`ControlFlowNode.asStmt()` or |
| 43 | + :code:`ControlFlowElement.getControlFlowNode()` instead. |
| 44 | + |
| 45 | +Major Analysis Improvements |
| 46 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 47 | + |
| 48 | +C# |
| 49 | +"" |
| 50 | + |
| 51 | +* When resolving dependencies in :code:`build-mode: none`, :code:`dotnet restore` now explicitly receives reachable NuGet feeds configured in :code:`nuget.config` when feed responsiveness checking is enabled (the default), and any private registries directly, improving reliability when default feeds are unavailable or restricted. |
| 52 | + |
| 53 | +Swift |
| 54 | +""""" |
| 55 | + |
| 56 | +* Upgraded to allow analysis of Swift 6.3.1. |
| 57 | + |
| 58 | +Minor Analysis Improvements |
| 59 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 60 | + |
| 61 | +C/C++ |
| 62 | +""""" |
| 63 | + |
| 64 | +* Added taint flow models for the :code:`Strsafe.h` header from the Windows SDK. |
| 65 | + |
| 66 | +C# |
| 67 | +"" |
| 68 | + |
| 69 | +* Expanded ASP and ASP.NET remote source modeling to cover additional sources, including fields of tainted parameters as well as properties and fields that become tainted transitively. |
| 70 | +* C# 14: Added support for user-defined compound assignment operators. |
| 71 | + |
| 72 | +Java/Kotlin |
| 73 | +""""""""""" |
| 74 | + |
| 75 | +* Added :code:`sql-injection` sink models for the Hibernate :code:`org.hibernate.query.QueryProducer` methods :code:`createNativeMutationQuery`, :code:`createMutationQuery`, and :code:`createSelectionQuery`. |
| 76 | +* The :code:`java/partial-path-traversal` and :code:`java/partial-path-traversal-from-remote` queries now correctly recognize file separator appends using :code:`+=`. |
| 77 | +* The :code:`java/path-injection` and :code:`java/zipslip` queries now recognize :code:`Path.toRealPath()` as a path normalization sanitizer, consistent with the existing treatment of :code:`Path.normalize()` and :code:`File.getCanonicalPath()`. This reduces false positives for code that uses the NIO.2 API for path canonicalization. |
| 78 | +* The :code:`java/sensitive-log` query now excludes additional common variable naming patterns that do not hold sensitive data, reducing false positives. This includes pagination/iteration tokens (:code:`nextToken`, :code:`pageToken`, :code:`continuationToken`), token metadata (:code:`tokenType`, :code:`tokenEndpoint`, :code:`tokenCount`), and secret metadata (:code:`secretName`, :code:`secretId`, :code:`secretVersion`). |
| 79 | +* The :code:`java/sensitive-log` query now treats method calls whose names contain "encrypt", "hash", or "digest" as sanitizers, consistent with the existing treatment in :code:`java/cleartext-storage-in-log`. This reduces false positives when sensitive data is hashed or encrypted before logging. |
| 80 | +* The :code:`java/trust-boundary-violation` query now recognizes regular expression checks (including :code:`String.matches()` guards and :code:`@javax.validation.constraints.Pattern` annotations) as sanitizers, consistent with the existing treatment of ESAPI validators. This reduces false positives when input is validated against a pattern before being stored in a session. |
| 81 | + |
| 82 | +Python |
| 83 | +"""""" |
| 84 | + |
| 85 | +* The Python extractor now supports unpacking in comprehensions, e.g. :code:`[*x for x in nested]` (as defined in `PEP-798 <https://peps.python.org/pep-0798/>`__) that will be part of Python 3.15. |
| 86 | + |
| 87 | +Deprecated APIs |
| 88 | +~~~~~~~~~~~~~~~ |
| 89 | + |
| 90 | +C# |
| 91 | +"" |
| 92 | + |
| 93 | +* The QL classes in the C# SSA library have been renamed to improve consistency between languages. Any custom QL code that makes use of SSA needs to be updated. The old classes have been deprecated and include more detailed migration instructions in their qldoc. |
| 94 | + |
| 95 | +New Features |
| 96 | +~~~~~~~~~~~~ |
| 97 | + |
| 98 | +C/C++ |
| 99 | +""""" |
| 100 | + |
| 101 | +* A new predicate :code:`getSwitchCase` was added to the :code:`SwitchStmt` class, which yields the :code:`n`\ th :code:`case` statement from a :code:`switch` statement. |
| 102 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for C and C++ <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-cpp/>`__. |
| 103 | + |
| 104 | +C# |
| 105 | +"" |
| 106 | + |
| 107 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for C# <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-csharp/>`__. |
| 108 | + |
| 109 | +Golang |
| 110 | +"""""" |
| 111 | + |
| 112 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for Go <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-go/>`__. |
| 113 | + |
| 114 | +Java/Kotlin |
| 115 | +""""""""""" |
| 116 | + |
| 117 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for Java and Kotlin <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-java-and-kotlin/>`__. |
| 118 | + |
| 119 | +JavaScript/TypeScript |
| 120 | +""""""""""""""""""""" |
| 121 | + |
| 122 | +* Added support for |link-code-vercel-node-1|_ Vercel serverless functions. Handlers are recognized via the :code:`VercelRequest`\ /\ :code:`VercelResponse` TypeScript parameter types, and standard security queries (:code:`js/reflected-xss`, :code:`js/request-forgery`, :code:`js/sql-injection`, :code:`js/command-line-injection`, etc.) now detect vulnerabilities in Vercel API route files. |
| 123 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for JavaScript <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-javascript/>`__. |
| 124 | + |
| 125 | +Python |
| 126 | +"""""" |
| 127 | + |
| 128 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for Python <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-python/>`__. |
| 129 | + |
| 130 | +Ruby |
| 131 | +"""" |
| 132 | + |
| 133 | +* Data flow barriers and barrier guards can now be added using data extensions. For more information see `Customizing library models for Ruby <https://codeql.github.com/docs/codeql-language-guides/customizing-library-models-for-ruby/>`__. |
| 134 | + |
| 135 | +Swift |
| 136 | +""""" |
| 137 | + |
| 138 | +* The :code:`BuiltinFixedArrayType` class now defines the predicates :code:`getSize` and :code:`getElementType`, which yield the size of the array and the type of elements stored in the array, respectively. |
| 139 | + |
| 140 | +Rust |
| 141 | +"""" |
| 142 | + |
| 143 | +* Data flow barriers and barrier guards can now be added using data extensions. |
| 144 | + |
| 145 | +.. |link-code-vercel-node-1| replace:: :code:`@vercel/node`\ |
| 146 | +.. _link-code-vercel-node-1: https://www.npmjs.com/package/@vercel/node |
| 147 | + |
0 commit comments