Merge topic 'curl-tls-verify'

4e62bc943c ctest: Verify TLS server certificate by default
8e92ee34f6 file(DOWNLOAD/UPLOAD): Verify TLS server certificate by default
dcaea54898 cmCTestCurl: Clarify names and logic using optional<bool>
03d37ae3ff cmFileCommand: Clarify names and logic using optional<bool>

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9843
This commit is contained in:
Brad King
2024-09-24 14:35:10 +00:00
committed by Kitware Robot
11 changed files with 124 additions and 54 deletions
+10 -5
View File
@@ -813,8 +813,15 @@ Transfer
``TLS_VERIFY <ON|OFF>``
Specify whether to verify the server certificate for ``https://`` URLs.
The default is to *not* verify. If this option is not specified, the
value of the :variable:`CMAKE_TLS_VERIFY` variable will be used instead.
If this option is not specified, the value of the
:variable:`CMAKE_TLS_VERIFY` variable or :envvar:`CMAKE_TLS_VERIFY`
environment variable will be used instead.
If neither is set, the default is *on*.
.. versionchanged:: 3.31
The default is on. Previously, the default was off.
Users may set the :envvar:`CMAKE_TLS_VERIFY` environment
variable to ``0`` to restore the old default.
.. versionadded:: 3.18
Added support to ``file(UPLOAD)``.
@@ -827,9 +834,7 @@ Transfer
.. versionadded:: 3.18
Added support to ``file(UPLOAD)``.
For ``https://`` URLs CMake must be built with OpenSSL support. ``TLS/SSL``
certificates are not checked by default. Set ``TLS_VERIFY`` to ``ON`` to
check certificates.
For ``https://`` URLs CMake must be built with SSL/TLS support.
Additional options to ``DOWNLOAD`` are:
+5
View File
@@ -1569,6 +1569,11 @@ Configuration settings include:
* `CTest Script`_ variable: :variable:`CTEST_TLS_VERIFY`
* :module:`CTest` module variable: ``CTEST_TLS_VERIFY``
.. versionchanged:: 3.31
The default is on. Previously, the default was off.
Users may set the :envvar:`CMAKE_TLS_VERIFY` environment
variable to ``0`` to restore the old default.
``TriggerSite``
Legacy option. Not used.
+14
View File
@@ -0,0 +1,14 @@
curl-tls-verify
---------------
* The :command:`file(DOWNLOAD)` and :command:`file(UPLOAD)` commands now
verify TLS server certificates for connections to ``https://`` URLs by
default. See the :variable:`CMAKE_TLS_VERIFY` variable for details.
This change was made without a policy so that users are protected
even when building projects that have not been updated.
Users may set the :envvar:`CMAKE_TLS_VERIFY` environment
variable to ``0`` to restore the old default.
* The :command:`ctest_submit` command and :option:`ctest -T Submit <ctest -T>`
step now verify TLS server certificates for connections to ``https://`` URLs
by default. See the :variable:`CTEST_TLS_VERIFY` variable for details.
+6 -1
View File
@@ -5,7 +5,12 @@ Specify the default value for the :command:`file(DOWNLOAD)` and
:command:`file(UPLOAD)` commands' ``TLS_VERIFY`` options.
If this variable is not set, the commands check the
:envvar:`CMAKE_TLS_VERIFY` environment variable.
If neither is set, the default is *off*.
If neither is set, the default is *on*.
.. versionchanged:: 3.31
The default is on. Previously, the default was off.
Users may set the :envvar:`CMAKE_TLS_VERIFY` environment
variable to ``0`` to restore the old default.
This variable is also used by the :module:`ExternalProject` and
:module:`FetchContent` modules for internal calls to :command:`file(DOWNLOAD)`.
+6
View File
@@ -11,3 +11,9 @@ to a dashboard via ``https://`` URLs.
If ``CTEST_TLS_VERIFY`` is not set, the :variable:`CMAKE_TLS_VERIFY` variable
or :envvar:`CMAKE_TLS_VERIFY` environment variable is used instead.
If neither is set, the default is *on*.
.. versionchanged:: 3.31
The default is on. Previously, the default was off.
Users may set the :envvar:`CMAKE_TLS_VERIFY` environment
variable to ``0`` to restore the old default.