|
| 1 | +.. _codeql-cli-2.10.0: |
| 2 | + |
| 3 | +========================== |
| 4 | +CodeQL 2.10.0 (2022-06-27) |
| 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/code-scanning/>`__, `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.10.0 runs a total of 339 security queries when configured with the Default suite (covering 142 CWE). The Extended suite enables an additional 104 queries (covering 30 more CWE). 4 security queries have been added with this release. |
| 18 | + |
| 19 | +CodeQL CLI |
| 20 | +---------- |
| 21 | + |
| 22 | +Breaking Changes |
| 23 | +~~~~~~~~~~~~~~~~ |
| 24 | + |
| 25 | +* The :code:`--format=stats` option of :code:`codeql generate log-summary` has been renamed to :code:`--format=overall`. It now produces a richer JSON object that, in addition to the previous statistics about the run (which can be found in the :code:`stats` property) also records the most expensive predicates in the evaluation run. |
| 26 | + |
| 27 | +Potentially Breaking Changes |
| 28 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 29 | + |
| 30 | +* The :code:`codeql resolve ml-model` command now requires one or more query specifications as command line arguments in order to determine the set of starting packs from which to initiate the resolution process. The command will locate all ML models in any qlpack that is a transitive dependency of any of the starting packs. Also, the output of the command has been expanded to include for each model the containing package's name, version, and path. |
| 31 | + |
| 32 | +* The :code:`buildMetadata` inside of compiled CodeQL packs no longer contains a :code:`creationTime` property. This was removed in order to ensure that the content of a CodeQL pack is identical when it is re-compiled. |
| 33 | + |
| 34 | +* The :code:`codeql pack download` command, when used with the :code:`--dir` option, |
| 35 | + now downloads requested packs in directories corresponding to their version numbers. Previously, |
| 36 | + :code:` codeql pack download --dir ./somewhere codeql/[email protected]` would download the pack into the :code:` ./somewhere/codeql/java-queries` directory. Now, it will download the pack into the |
| 37 | + :code:`./somewhere/codeql/java-queries/0.1.2` directory. This allows you to download multiple versions of the same pack using a single command. |
| 38 | + |
| 39 | +Bug Fixes |
| 40 | +~~~~~~~~~ |
| 41 | + |
| 42 | +* Fixed a bug where :code:`codeql pack download`, when used with the :code:`--dir` option, would not download a pack that is in the global package cache. |
| 43 | + |
| 44 | +* Fixed a bug where some versions of a CodeQL package could not be downloaded if there are more than 100 versions of this package in the package registry. |
| 45 | + |
| 46 | +* Fixed a bug where the :code:`--also-match` option for :code:`codeql resolve files` and :code:`codeql database index-files` does not work with relative paths. |
| 47 | + |
| 48 | +* Fixed a bug that caused :code:`codeql query decompile` to ignore the |
| 49 | + :code:`--output` option when producing bytecode output (:code:`--kind=bytecode`), |
| 50 | + writing only to :code:`stdout`. |
| 51 | + |
| 52 | +New Features |
| 53 | +~~~~~~~~~~~~ |
| 54 | + |
| 55 | +* You can now include diagnostic messages in the summary produced by the :code:`--print-diagnostics-summary` option of the |
| 56 | + :code:`codeql database interpret-results` and :code:`codeql database analyze` commands by running these commands at high verbosity levels. |
| 57 | + |
| 58 | +Query Packs |
| 59 | +----------- |
| 60 | + |
| 61 | +Major Analysis Improvements |
| 62 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 63 | + |
| 64 | +Python |
| 65 | +"""""" |
| 66 | + |
| 67 | +* Improved library modeling for the query "Request without certificate validation" (:code:`py/request-without-cert-validation`), so it now also covers :code:`httpx`, :code:`aiohttp.client`, and :code:`urllib3`. |
| 68 | + |
| 69 | +Minor Analysis Improvements |
| 70 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 71 | + |
| 72 | +C# |
| 73 | +"" |
| 74 | + |
| 75 | +* The syntax of the (source|sink|summary)model CSV format has been changed slightly for Java and C#. A new column called :code:`provenance` has been introduced, where the allowed values are :code:`manual` and :code:`generated`. The value used to indicate whether a model as been written by hand (:code:`manual`) or create by the CSV model generator (:code:`generated`). |
| 76 | +* All auto implemented public properties with public getters and setters on ASP.NET Core remote flow sources are now also considered to be tainted. |
| 77 | + |
| 78 | +Java |
| 79 | +"""" |
| 80 | + |
| 81 | +* The query :code:`java/log-injection` now reports problems at the source (user-controlled data) instead of at the ultimate logging call. This was changed because user functions that wrap the ultimate logging call could result in most alerts being reported in an uninformative location. |
| 82 | + |
| 83 | +JavaScript/TypeScript |
| 84 | +""""""""""""""""""""" |
| 85 | + |
| 86 | +* The :code:`js/resource-exhaustion` query no longer treats the 3-argument version of :code:`Buffer.from` as a sink, |
| 87 | + since it does not allocate a new buffer. |
| 88 | + |
| 89 | +Python |
| 90 | +"""""" |
| 91 | + |
| 92 | +* The query "Use of a broken or weak cryptographic algorithm" (:code:`py/weak-cryptographic-algorithm`) now reports if a cryptographic operation is potentially insecure due to use of a weak block mode. |
| 93 | + |
| 94 | +Ruby |
| 95 | +"""" |
| 96 | + |
| 97 | +* The query "Use of a broken or weak cryptographic algorithm" (:code:`rb/weak-cryptographic-algorithm`) now reports if a cryptographic operation is potentially insecure due to use of a weak block mode. |
| 98 | + |
| 99 | +New Queries |
| 100 | +~~~~~~~~~~~ |
| 101 | + |
| 102 | +Ruby |
| 103 | +"""" |
| 104 | + |
| 105 | +* Added a new query, :code:`rb/improper-memoization`. The query finds cases where the parameter of a memoization method is not used in the memoization key. |
| 106 | + |
| 107 | +Query Metadata Changes |
| 108 | +~~~~~~~~~~~~~~~~~~~~~~ |
| 109 | + |
| 110 | +C# |
| 111 | +"" |
| 112 | + |
| 113 | +* The :code:`kind` query metadata was changed to :code:`diagnostic` on :code:`cs/compilation-error`, :code:`cs/compilation-message`, :code:`cs/extraction-error`, and :code:`cs/extraction-message`. |
| 114 | + |
| 115 | +Language Libraries |
| 116 | +------------------ |
| 117 | + |
| 118 | +Bug Fixes |
| 119 | +~~~~~~~~~ |
| 120 | + |
| 121 | +C/C++ |
| 122 | +""""" |
| 123 | + |
| 124 | +* :code:`UserType.getADeclarationEntry()` now yields all forward declarations when the user type is a :code:`class`, :code:`struct`, or :code:`union`. |
| 125 | + |
| 126 | +Major Analysis Improvements |
| 127 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 128 | + |
| 129 | +JavaScript/TypeScript |
| 130 | +""""""""""""""""""""" |
| 131 | + |
| 132 | +* Added support for TypeScript 4.7. |
| 133 | + |
| 134 | +Minor Analysis Improvements |
| 135 | +~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 136 | + |
| 137 | +Java |
| 138 | +"""" |
| 139 | + |
| 140 | +* Added a flow step for :code:`String.valueOf` calls on tainted :code:`android.text.Editable` objects. |
| 141 | + |
| 142 | +JavaScript/TypeScript |
| 143 | +""""""""""""""""""""" |
| 144 | + |
| 145 | +* All new ECMAScript 2022 features are now supported. |
| 146 | + |
| 147 | +Deprecated APIs |
| 148 | +~~~~~~~~~~~~~~~ |
| 149 | + |
| 150 | +C/C++ |
| 151 | +""""" |
| 152 | + |
| 153 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
| 154 | + |
| 155 | +C# |
| 156 | +"" |
| 157 | + |
| 158 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
| 159 | + |
| 160 | +Golang |
| 161 | +"""""" |
| 162 | + |
| 163 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
| 164 | + |
| 165 | +Java |
| 166 | +"""" |
| 167 | + |
| 168 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
| 169 | + |
| 170 | +Python |
| 171 | +"""""" |
| 172 | + |
| 173 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
| 174 | + |
| 175 | +Ruby |
| 176 | +"""" |
| 177 | + |
| 178 | +* The :code:`BarrierGuard` class has been deprecated. Such barriers and sanitizers can now instead be created using the new :code:`BarrierGuard` parameterized module. |
0 commit comments