]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
docs: mention indirect effects of --insecure
authorDaniel Stenberg <daniel@haxx.se>
Wed, 21 Dec 2022 22:36:57 +0000 (23:36 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Wed, 21 Dec 2022 22:36:58 +0000 (23:36 +0100)
Warn users that disabling certficate verification allows servers to
"pollute" curl with data it trusts.

Reported-by: Harry Sintonen
Closes #10126

docs/cmdline-opts/insecure.d
docs/libcurl/opts/CURLOPT_SSL_VERIFYHOST.3
docs/libcurl/opts/CURLOPT_SSL_VERIFYPEER.3

index c75817efcce2076c778df06beefcad15fd12e871..122f2fcb667abfd6bd850d2ee9a48281947b5242 100644 (file)
@@ -26,3 +26,8 @@ For SFTP and SCP, this option makes curl skip the *known_hosts* verification.
 ".ssh" subdirectory, which contains host names and their public keys.
 
 **WARNING**: using this option makes the transfer insecure.
+
+When curl uses secure protocols it trusts responses and allows for example
+HSTS and Alt-Svc information to be stored and used subsequently. Using
+--insecure can make curl trust and use such information from malicious
+servers.
index 024661b4363e31d95c79f66f46e98dbe8aeb40bd..5a00f51f304e7b6d1b57be9d8cac7cd24a8c83bc 100644 (file)
@@ -67,6 +67,17 @@ The default value for this option is 2.
 This option controls checking the server's certificate's claimed identity.
 The server could be lying.  To control lying, see
 \fICURLOPT_SSL_VERIFYPEER(3)\fP.
+
+WARNING: disabling verification of the certificate allows bad guys to
+man-in-the-middle the communication without you knowing it. Disabling
+verification makes the communication insecure. Just having encryption on a
+transfer is not enough as you cannot be sure that you are communicating with
+the correct end-point.
+
+When libcurl uses secure protocols it trusts responses and allows for example
+HSTS and Alt-Svc information to be stored and used subsequently. Disabling
+certificate verification can make libcurl trust and use such information from
+malicious servers.
 .SH LIMITATIONS
 Secure Transport: If \fIverify\fP value is 0, then SNI is also disabled. SNI is
 a TLS extension that sends the hostname to the server. The server may use that
index 7b643a2078efa908d0c33a7f9ade21ca059e400f..1f94e51a60cc0d52b806abe3188fbe4db464c637 100644 (file)
@@ -61,6 +61,11 @@ man-in-the-middle the communication without you knowing it. Disabling
 verification makes the communication insecure. Just having encryption on a
 transfer is not enough as you cannot be sure that you are communicating with
 the correct end-point.
+
+When libcurl uses secure protocols it trusts responses and allows for example
+HSTS and Alt-Svc information to be stored and used subsequently. Disabling
+certificate verification can make libcurl trust and use such information from
+malicious servers.
 .SH DEFAULT
 By default, curl assumes a value of 1.
 .SH PROTOCOLS