Commit Graph

28168 Commits

Author SHA1 Message Date
Daniel Stenberg
215325e22d
cirlceci: also run a c-ares job on arm with debug enabled
Closes #8357
2022-01-31 12:33:37 +01:00
Daniel Stenberg
609ea92718
ci: move the OpenSSL + c-ares job from Zuul to Circle CI
Closes #8357
2022-01-31 12:33:30 +01:00
Daniel Stenberg
9a8888c94b
mailmap: Jan-Piet Mens 2022-01-31 09:39:48 +01:00
luminixinc on github
3c798b1db3
multi: remember connection_id before returning connection to pool
Fix a bug that does not require a new CVE as discussed on hackerone.com.
Previously `connection_id` was accessed after returning connection to
the shared pool.

Bug: https://hackerone.com/reports/1463013
Closes #8355
2022-01-31 08:55:22 +01:00
Jay Satiro
50e74ca18a write-out.d: Fix num_headers formatting 2022-01-31 01:04:19 -05:00
Jan-Piet Mens
09c807428e docs: capitalize the name 'Netscape'
Closes https://github.com/curl/curl/pull/8354
2022-01-30 14:20:32 -05:00
Daniel Stenberg
40a63419eb
RELEASE-NOTES: synced 2022-01-30 12:48:27 +01:00
Antoine Pietri
b341b7675b
docs: grammar proofread, typo fixes
(Partially automated) proofread of most of the documentation, leading to
various typo fixes.

Closes #8353
2022-01-30 12:06:05 +01:00
Daniel Stenberg
91e3996aa7
urldata: CONN_IS_PROXIED replaces bits.close when proxy can be disabled
To remove run-time checks for such builds.

Closes #8350
2022-01-30 12:01:25 +01:00
Daniel Stenberg
96629ba2c2
setopt: fix the TLSAUTH #ifdefs for proxy-disabled builds
Closes #8350
2022-01-30 12:01:16 +01:00
Daniel Stenberg
79cca04da8
conncache: make conncache_add_bundle return the pointer
Simplifies the logic a little and avoids a ternary operator.

Ref: #8346
Closes #8349
2022-01-30 11:59:43 +01:00
Daniel Stenberg
2c7d6b9cf0
mailmap: neutric on github 2022-01-30 11:55:49 +01:00
neutric
0d0ff37e35 docs/TheArtOfHttpScripting: fix example POST URL
Closes https://github.com/curl/curl/pull/8352
2022-01-30 01:52:51 -05:00
Daniel Stenberg
3267ac40da
nss: handshake callback during shutdown has no conn->bundle
The callback gets called because of the call to PR_Recv() done to
attempt to avoid RST on the TCP connection. The conn->bundle pointer is
already cleared at this point so avoid dereferencing it.

Reported-by: Eric Musser
Fixes #8341
Closes #8342
2022-01-28 16:02:38 +01:00
MAntoniak
df66c7c5ba
mbedtls: remove #include <mbedtls/certs.h>
mbedtls/certs.h file contains only certificates example (all definitions
is beginning by mbedtls_test_*). None of them is used so we can avoid
include the file.

Closes #8343
2022-01-28 16:01:28 +01:00
MAntoniak
16c01bc5a5
mbedtls: enable use of mbedtls without CRL support
Closes #8344
2022-01-28 16:00:23 +01:00
Bernhard Walle
ac55564530
configure: set CURL_LIBRARY_PATH for nghttp2
To execute the test program, we might need the library path so that the
lib is found at runtime.

Closes #8340
2022-01-28 15:55:12 +01:00
Jay Satiro
598b142f6d schannel: restore debug message in schannel_connect_step2
This is a follow-up to recent commit 2218c3a which removed the debug
message to avoid an unused variable warning. The message has been
reworked to avoid the warning.

Ref: https://github.com/curl/curl/pull/8320#issuecomment-1022957904

Closes https://github.com/curl/curl/pull/8336
2022-01-28 02:42:57 -05:00
Jay Satiro
9b8ed6bc3e test3021: disable all msys2 path transformation
- Disable all MSYS2 path transformation in test3021 and test3022.

Prior to this change path transformation in those tests was disabled
only for arguments that start with forward slashes. However arguments
that are in base64 contain forward slashes at any position and caused
unwanted translations.

== Info: Denied establishing ssh session: mismatch sha256 fingerprint.
Remote +/EYG2YDzDGm6yiwepEMSuExgRRMoTi8Di1UN3kixZw= is not equal to
+C:/msys64/EYG2YDzDGm6yiwepEMSuExgRRMoTi8Di1UN3kixZw

In the above example an argument containing a base64 sha256 fingerprint
was passed to curl after MSYS2 translated +/ into +C:/msys64/, and then
the fingerprint didn't match what was expected.

Ref: https://www.msys2.org/wiki/Porting/

Fixes https://github.com/curl/curl/issues/8084
Closes https://github.com/curl/curl/pull/8325
2022-01-28 02:40:16 -05:00
Daniel Stenberg
36e8703a20
CI: move scan-build job from Zuul to Azure Pipelines
Closes #8338
2022-01-27 16:13:38 +01:00
Marcel Raad
610bd89315
openssl: fix ctx_option_t for OpenSSL v3+
The options have been changed to `uint64_t` in
56bd17830f.

Closes https://github.com/curl/curl/pull/8331
2022-01-27 12:22:18 +01:00
Daniel Stenberg
54a3179ebc
CI: move 'distcheck' job from zuul to azure pipelines
Assisted-by: Kushal Das

Closes #8334
2022-01-27 09:33:49 +01:00
Daniel Stenberg
2218c3a57e
vtls: pass on the right SNI name
The TLS backends convert the host name to SNI name and need to use that.
This involves cutting off any trailing dot and lowercasing.

Co-authored-by: Jay Satiro
Closes #8320
2022-01-27 08:36:10 +01:00
Daniel Stenberg
b27ad8e1d3
url: revert the removal of trailing dot from host name
Reverts 5de8d84098 (May 2014, shipped in 7.37.0) and the
follow-up changes done afterward.

Keep the dot in names for everything except the SNI to make curl behave
more similar to current browsers. This means 'name' and 'name.' send the
same SNI for different 'Host:' headers.

Updated test 1322 accordingly

Fixes #8290
Reported-by: Charles Cazabon
Closes #8320
2022-01-27 08:35:18 +01:00
neutric on github
be683243b6
docs/TheArtOfHttpScripting: fix capitalization
Closes #8333
2022-01-26 23:35:03 +01:00
Daniel Stenberg
4bf593a0de
tests/memanalyze.pl: also count and show "total allocations"
This is the total number of bytes allocated, increasing for new
allocations and never reduced when freed. The existing "Maximum
allocated" is the high water mark.

Closes #8330
2022-01-26 14:34:40 +01:00
Daniel Stenberg
e35637f193 mailmap: spellfix githuh => github 2022-01-25 12:05:06 +01:00
Daniel Stenberg
6a2daeeecd
RELEASE-NOTES: synced 2022-01-25 09:27:24 +01:00
Daniel Stenberg
955cb99130
hostcheck: fixed to not touch used input strings
Avoids the need to clone the strings before check, thus avoiding
mallocs, which for cases where there are many SAN names in a cert could
end up numerous.

Closes #8321
2022-01-24 13:55:57 +01:00
Daniel Stenberg
f6dd94f640
ngtcp2: adapt to changed end of headers callback proto
Closes #8322
2022-01-24 13:22:54 +01:00
xkernel
a97eb81d94
openssl: check SSL_get_ex_data to prevent potential NULL dereference
Closes #8268
2022-01-23 10:41:24 +01:00
Jay Satiro
f0fb903cbc md5: check md5_init_func return value
Prior to this change the md5_init_func (my_md5_init) return value was
ignored.

Closes https://github.com/curl/curl/pull/8319
2022-01-23 01:56:59 -05:00
Jay Satiro
0e5c4f574b md5: refactor for standard compliance
- Wrap OpenSSL / wolfSSL MD5 functions instead of taking their function
  addresses during static initialization.

Depending on how curl was built the old way may have used a dllimport
function address during static initialization, which is not standard
compliant, resulting in Visual Studio warning C4232 (nonstandard
extension). Instead the function pointers now point to the wrappers
which call the MD5 functions.

This change only affects OpenSSL and wolfSSL because calls to other SSL
libraries' md5 functions were already wrapped. Also sha256.c already
does this for all SSL libraries.

Ref: https://github.com/curl/curl/pull/8298

Closes https://github.com/curl/curl/pull/8318
2022-01-23 01:45:46 -05:00
lucas
519b62ccd0
docs: update IETF links to use datatracker
The tools.ietf.org domain has been deprecated a while now, with the
links being redirected to datatracker.ietf.org.

Rather than make people eat that redirect time, this change switches the
URL to a more canonical source.

Closes #8317
2022-01-21 23:06:36 +01:00
Harry Sarson
6c82e3f42d
CI: test building wolfssl with --enable-opensslextra
Closes #8315
2022-01-21 23:04:15 +01:00
Harry Sarson
392fdb0438
misc: allow curl to build with wolfssl --enable-opensslextra
put all #include of openssl files behind wolfssl ifdefs so that we can
use the wolfssl/ prefixed include paths. Without these curl only builds
when wolfssl is built with enable-all.

Fixes #8292
Closes #8315
2022-01-21 23:04:02 +01:00
Lucas Pardue
8a3e67e732
quiche: change qlog file extension to .sqlog
quiche has just switched it's qlog serialization format to JSON-SEQ by
default . The spec says this SHOULD use `.sqlog` extension.

I believe ngtcp2 also supports JSON-SEQ by default as of
9baf06fc3f

Let's update curl so that tools know what format we are using!

Closes #8316
2022-01-21 22:34:57 +01:00
Jay Satiro
f74b6d8551 projects: Fix Visual Studio wolfSSL configurations
- Change build-wolfssl.bat to disable SSLv3, enable TLSv1.3, enable
  wolfSSL_DES_ecb_encrypt (needed by NTLM) and enable alt cert chains.

- Disable warning C4214 'bit field types other than int'.

- Add include directory wolfssl\wolfssl.

wolfSSL offers OpenSSL API compatibility that libcurl uses, and some
recent change in libcurl included an include file for wolfSSL like
openssl/foo.h, which has a path like wolfssl\wolfssl\openssl\foo.h.

The include directory issue was reported in #8292 but it's currently
unclear whether this type of change is needed for other build systems.

Bug: https://github.com/curl/curl/issues/8292
Reported-by: Harry Sarson

Closes https://github.com/curl/curl/pull/8298
2022-01-21 03:22:06 -05:00
Daniel Stenberg
d03cb7c14a
openssl: return error if TLS 1.3 is requested when not supported
Previously curl would just silently ignore it if the necessary defines
are not present at build-time.

Reported-by: Stefan Eissing
Fixes #8309
Closes #8310
2022-01-21 08:44:17 +01:00
Daniel Stenberg
e29665c775
TODO: Passing NOTIFY option to CURLOPT_MAIL_RCPT
Closes #8232
2022-01-20 11:29:43 +01:00
pheiduck on githuh
f558534e22
workflows/wolfssl: install impacket
needed Python Package for SMB tests

Closes #8307
2022-01-20 11:22:52 +01:00
Daniel Stenberg
e74a6b7b72
url: make Curl_disconnect return void
1. The function would only ever return CURLE_OK anyway
 2. Only one caller actually used the return code
 3. Most callers did (void)Curl_disconnect()

Closes #8303
2022-01-20 09:07:30 +01:00
Daniel Stenberg
cdb495f743
docs: document HTTP/2 not insisting on TLS 1.2
Both for --http2 and CURLOPT_HTTP_VERSION.

Reported-by: jhoyla on github
Fixes #8235
Closes #8300
2022-01-19 23:30:07 +01:00
Daniel Stenberg
fde0925214
cmdline-opts/gen.pl: fix option matching to improve references
Previously it could mistakenly match partial names when there are
options that start with the same prefix, leading to the wrong references
used.

Closes #8299
2022-01-19 13:29:28 +01:00
Daniel Stenberg
0c2694f22f
TODO: Less memory massaging with Schannel 2022-01-19 11:59:53 +01:00
Patrick Monnerat
52826d3b79
runtests.pl: disable debuginfod
Valgrind and gdb implement this feature: as this highly slows down tests,
disable it.

Closes #8291
2022-01-17 22:26:52 +01:00
Daniel Stenberg
39b24a1183
RELEASE-NOTES: synced 2022-01-17 16:49:00 +01:00
Daniel Stenberg
c24764ef59
CURLMOPT_TIMERFUNCTION/DATA.3: fix the examples
... to not call libcurl recursively back.

Closes #8286
2022-01-17 16:45:28 +01:00
Daniel Stenberg
340bb1905f
multi: set in_callback for multi interface callbacks
This makes most libcurl functions return error if called from within a
callback using the same multi handle. For example timer or socket
callbacks calling curl_multi_socket_action.

Reported-by: updatede on github
Fixes #8282
Closes #8286
2022-01-17 16:44:45 +01:00
Daniel Stenberg
a3d2eeab01
docs/HISTORY.md: mention alt-svc and HSTS 2022-01-17 15:56:41 +01:00