]> git.ipfire.org Git - thirdparty/curl.git/log
thirdparty/curl.git
16 months agocmake: show protocols, then features
Viktor Szakats [Mon, 1 Jul 2024 22:11:29 +0000 (00:11 +0200)] 
cmake: show protocols, then features

To match the order used by `curl -V` and `./configure`.

Closes #14082

16 months agocmdline-docs: fix `--proxy-ca-native` example + tidy-ups
Viktor Szakats [Mon, 1 Jul 2024 19:25:33 +0000 (21:25 +0200)] 
cmdline-docs: fix `--proxy-ca-native` example + tidy-ups

Also:
- fix an indentation.
- fix capitalized option in comment.

Closes #14078

16 months agocmake: sync protocol/feature list with `curl -V` output
Viktor Szakats [Sun, 30 Jun 2024 22:39:03 +0000 (00:39 +0200)] 
cmake: sync protocol/feature list with `curl -V` output

- sort features case-insensitively.
  Requires CMake v3.13.0.
  Follow-up to 0f26abeef1dd1d1a02f8e12dbc3d51e73e9d2e9c #14063

- convert protocol list to lowercase.
  But leave it uppercase in `curl-config`.

Closes #14066

16 months agoGHA/badwords.yml: fixup indent for yamllint [ci skip]
Viktor Szakats [Mon, 1 Jul 2024 21:23:46 +0000 (23:23 +0200)] 
GHA/badwords.yml: fixup indent for yamllint [ci skip]

16 months agoGHA: update dependency awslabs/aws-lc to v1.31.0
renovate[bot] [Mon, 1 Jul 2024 20:50:58 +0000 (20:50 +0000)] 
GHA: update dependency awslabs/aws-lc to v1.31.0

Closes #14080

16 months agoGHA/badwords.yml: check source code wording
Daniel Stenberg [Mon, 1 Jul 2024 13:53:54 +0000 (15:53 +0200)] 
GHA/badwords.yml: check source code wording

Closes #14073

16 months agocode: language cleanup in comments
Daniel Stenberg [Mon, 1 Jul 2024 14:47:21 +0000 (16:47 +0200)] 
code: language cleanup in comments

Based on the standards and guidelines we use for our documentation.

 - expand contractions (they're => they are etc)
 - host name = > hostname
 - file name => filename
 - user name = username
 - man page => manpage
 - run-time => runtime
 - set-up => setup
 - back-end => backend
 - a HTTP => an HTTP
 - Two spaces after a period => one space after period

Closes #14073

16 months agodocs: add RELEASE-TOOLS.md.dist to .gitignore
Yedaya Katsman [Mon, 1 Jul 2024 20:18:42 +0000 (23:18 +0300)] 
docs: add RELEASE-TOOLS.md.dist to .gitignore

Closes #14079

16 months agolibcurl.pc: add more `Requires.private`/`Requires` dependencies
Viktor Szakats [Mon, 1 Jul 2024 09:38:25 +0000 (11:38 +0200)] 
libcurl.pc: add more `Requires.private`/`Requires` dependencies

- add `libmsh3` reference from cmake and autotools.

- add `mit-krb5-gssapi` reference from cmake.

It leaves GSS not set from autotools. The handling of heimdal in cmake
is fuzzy, that's probably missing too.

Follow-up to f057de5a1a950a90d1920021db152a4b695f1a8a #13911
Closes #14072

16 months agocmake: improve wolfSSL detection
Viktor Szakats [Sun, 30 Jun 2024 09:37:06 +0000 (11:37 +0200)] 
cmake: improve wolfSSL detection

- support detecting wolfSSL via pkg-config (like autotools.)

- detect wolfSSL version.

- detect `HAVE_WOLFSSL_DES_ECB_ENCRYPT`.
  (needs e.g. `--enable-curl` when building wolfSSL)

- detect `HAVE_WOLFSSL_FULL_BIO` and enable HTTPS-proxy feature.
  (needs e.g. `--enable-opensslall` when building wolfSSL)

- fix to show `HTTPS-proxy` in cmake feature list.
  Ref: 55807e6c056f27846d70cec70ee6ac3f0e5b3bbe #9962

- fix to show `NTLM` in cmake feature list.

- fix to show `smb` and `smbs` in cmake protocol list.

- add wolfSSL CMake job to GHA (for macOS).

- fix mqtt and wolfSSL symbol clash.
  ```
  ./curl/lib/mqtt.c: In function 'mqtt_doing':
  ./curl/lib/mqtt.c:746:17: error: declaration of 'byte' shadows a global declaration [-Werror=shadow]
    746 |   unsigned char byte;
        |                 ^~~~
  /opt/homebrew/Cellar/wolfssl/5.7.0_1/include/wolfssl/wolfcrypt/types.h:85:36: note: shadowed declaration is here
     85 |             typedef unsigned char  byte;
        |                                    ^~~~
  ```

- format `FindWolfSSL.cmake` closer to neighbours.

Closes #14064

16 months agocurl_url_set: elaborate on scheme guessing
Daniel Stenberg [Mon, 1 Jul 2024 09:03:08 +0000 (11:03 +0200)] 
curl_url_set: elaborate on scheme guessing

Explain a little more and refer to the CURLU_NO_GUESS_SCHEME flag
for getting scheme or URL.

Closes #14071

16 months agodocs: misc language polish
Daniel Stenberg [Mon, 1 Jul 2024 08:37:43 +0000 (10:37 +0200)] 
docs: misc language polish

- CURLINFO_FILETIME*: improve language
- add '32bit' and '64bit' as bad words, use 32-bit and 64-bit
- mksymbolsmanpage.pl: avoid "will"

Closes #14070

16 months agocurl_easy_escape: elaborate a little on encoding a URL
Daniel Stenberg [Mon, 1 Jul 2024 08:11:39 +0000 (10:11 +0200)] 
curl_easy_escape: elaborate a little on encoding a URL

Closes #14069

16 months agocmake: fix feature and protocol lists for SecureTransport
Viktor Szakats [Sun, 30 Jun 2024 21:56:55 +0000 (23:56 +0200)] 
cmake: fix feature and protocol lists for SecureTransport

NTLM was missing from the features list, and SMB/SMBS from
the protocols list in SecureTransport builds.

Follow-up to 76a9c3c4be10b3d4d379d5b23ca76806bbae536a #3619

Reported-by: Tal Regev
Bug: https://github.com/curl/curl/pull/13963#issuecomment-2178791390
Closes #14065

16 months agocurl_str[n]equal.md: tidy up text to make them stand-alone
Daniel Stenberg [Mon, 1 Jul 2024 07:05:19 +0000 (09:05 +0200)] 
curl_str[n]equal.md: tidy up text to make them stand-alone

Previously this was one single manpage for two functions but as they are
two separate ones since a while back, they should each clearly document
their single specific functions.

Follow-up to eefcc1bda4bc

Closes #14068

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Sun, 30 Jun 2024 21:16:54 +0000 (23:16 +0200)] 
RELEASE-NOTES: synced

17 months agoGHA: use vcpkg to install packages for MSVC jobs
Tal Regev [Fri, 21 Jun 2024 13:12:07 +0000 (16:12 +0300)] 
GHA: use vcpkg to install packages for MSVC jobs

- enable new dependencies for existing jobs.

- add cache for vcpkg packages.

- tidy-up CMake options and environment for vcpkg.

Closes #13979

17 months agocurl_mprintf.md: add missing comma
Daniel Stenberg [Sun, 30 Jun 2024 14:11:52 +0000 (16:11 +0200)] 
curl_mprintf.md: add missing comma

17 months agoCURLOPT_TLSAUTH_PASSWORD/USERNAME.md: language fixups
Daniel Stenberg [Sat, 29 Jun 2024 21:43:36 +0000 (23:43 +0200)] 
CURLOPT_TLSAUTH_PASSWORD/USERNAME.md: language fixups

- relies *on* TLS SRP
- *for* the specific TLS backends

Closes #14061

17 months agodocs/libcurl: polish the single-line descriptions
Daniel Stenberg [Sat, 29 Jun 2024 22:08:06 +0000 (00:08 +0200)] 
docs/libcurl: polish the single-line descriptions

- use imperative form
- use lowercase
- no period
- unify some phrases
- fix curl_multi_socket and curl_multi_socket_all to keep their own
  descriptions

Closes #14062

17 months agocmake: alpha-sort feature list
Viktor Szakats [Sat, 29 Jun 2024 22:26:49 +0000 (00:26 +0200)] 
cmake: alpha-sort feature list

Like autotools does.

Closes #14063

17 months agoGHA: update github/codeql-action digest to b611370
renovate[bot] [Sat, 29 Jun 2024 20:46:34 +0000 (20:46 +0000)] 
GHA: update github/codeql-action digest to b611370

Closes #14058

17 months agovquic: fix UDP_GRO struct cmsghdr data type
Tatsuhiro Tsujikawa [Sat, 29 Jun 2024 00:55:55 +0000 (09:55 +0900)] 
vquic: fix UDP_GRO struct cmsghdr data type

The data type for UDP_GRO in struct cmsghdr is int. Limit the usage of
UDP_GRO to linux only because it is not portable.

Closes #14056

17 months agomk-ca-bundle.pl: delay 'curl -V' execution until it is needed
Sertonix [Sat, 29 Jun 2024 19:36:25 +0000 (19:36 +0000)] 
mk-ca-bundle.pl: delay 'curl -V' execution until it is needed

Avoid an `Can't exec "curl"` message when curl is not actually needed.

Closes #14060

17 months agosrc/Makefile.am: remove SUBDIRS assignment
Daniel Stenberg [Fri, 28 Jun 2024 21:34:45 +0000 (23:34 +0200)] 
src/Makefile.am: remove SUBDIRS assignment

It was once used to continue into ../docs but is just leftovers now.

Closes #14054

17 months agox509asn1: remove superfluous free()
z2_ [Fri, 28 Jun 2024 12:45:47 +0000 (14:45 +0200)] 
x509asn1: remove superfluous free()

17 months agongtcp2+quictls: fix cert-status use
Stefan Eissing [Fri, 28 Jun 2024 10:10:42 +0000 (12:10 +0200)] 
ngtcp2+quictls: fix cert-status use

- add test for --cert-status on all http versions

Reported-by: Dexter Gerig
Fixes #14049
Closes #14050

17 months agoRELEASE-PROCEDURE.md: update release date
Daniel Stenberg [Fri, 28 Jun 2024 12:30:04 +0000 (14:30 +0200)] 
RELEASE-PROCEDURE.md: update release date

17 months agomanagen: insert final .fi for files ending with a quote
Daniel Stenberg [Fri, 28 Jun 2024 07:01:08 +0000 (09:01 +0200)] 
managen: insert final .fi for files ending with a quote

When an individual file ended with a quote (typically an example), the
render function would return without ending the quote correctly with a
".fi" (fill in) in the manpage output.

This made the additional text provided below to render wrongly.

Closes #14048

17 months agoquic: update to quiche 0.22.0
Junho Choi [Fri, 28 Jun 2024 03:51:25 +0000 (12:51 +0900)] 
quic: update to quiche 0.22.0

quiche 0.22.0 will set SONAME in libquiche.so (libquiche.so.0) for
linux/BSDs. Install a symlink with SONAME.

Closes #14030
Closes #14046

17 months agomanagen: introduce "Multi: per-URL"
Daniel Stenberg [Thu, 27 Jun 2024 20:54:28 +0000 (22:54 +0200)] 
managen: introduce "Multi: per-URL"

For -O, -o and -T that are used once per specified URL.

Closes #14045

17 months agoquiche: fix operand of ‘?:’ changes signedness
Daniel Stenberg [Thu, 27 Jun 2024 11:05:07 +0000 (13:05 +0200)] 
quiche: fix operand of ‘?:’ changes signedness

... from ‘int’ to ‘curl_uint64_t’

Closes #14041

17 months agoGHA: add --enable-werror to the quiche job
Daniel Stenberg [Thu, 27 Jun 2024 10:57:02 +0000 (12:57 +0200)] 
GHA: add --enable-werror to the quiche job

Closes #14041

17 months agoKNOWN_BUGS: three new bugs
Daniel Stenberg [Thu, 27 Jun 2024 14:37:25 +0000 (16:37 +0200)] 
KNOWN_BUGS: three new bugs

These have lingered in the issue tracker for a long time without action.
We don't expect any fixes in the near term either. Move them to the
KNOWN_BUGS document.

Closes #12177
Closes #12171
Closes #13350

Closes #14042

17 months agoCI: add whitespace checker
Viktor Szakats [Thu, 27 Jun 2024 00:38:38 +0000 (02:38 +0200)] 
CI: add whitespace checker

Fix issues detected.

Also:

- One of the `.vc` files used LF EOLs, while the other didn't.
  Make that one also use LF EOLs, as this is apparently supported by
  `nmake`.

- Drop `.dsw` and `.btn` types from `.gitattributes`.
  The repository doesn't use them.

- Sync section order with the rest of files in
  `tests/certs/EdelCurlRoot-ca.prm`.

- Indent/align `.prm` and `.pem` files.

- Delete dummy `[something]` section from `.prm` and `.pem` files.

Mental note:
MSVC `.sln` files seem to accept spaces for indentation and also support
LF line-endings. I cannot test this and I don't know what's more
convenient when updating them, so left them as-is, with specific
exclusions.

Closes #14031

17 months agoCI: fix typo in job name
Viktor Szakats [Thu, 27 Jun 2024 10:38:21 +0000 (12:38 +0200)] 
CI: fix typo in job name

Closes #14040

17 months agotests/httpd: adjust ReadBufferSize for better performance
Stefan Eissing [Thu, 27 Jun 2024 10:03:52 +0000 (12:03 +0200)] 
tests/httpd: adjust ReadBufferSize for better performance

- list httpd and caddy versions in scorecard run

Closes #14039

17 months agoruntests: fix %VERNUM
Daniel Stenberg [Thu, 27 Jun 2024 08:16:59 +0000 (10:16 +0200)] 
runtests: fix %VERNUM

It needs to be set to the leading digits and dots only, so that the
`-[date]` suffix strings are not included, as those used in the daily
snapshots.

Fixes #14035
Reported-by: Marcel Raad
Closes #14036

17 months agoCI/synopsis.yml: run on `.md` files
Philip H [Thu, 27 Jun 2024 08:39:14 +0000 (10:39 +0200)] 
CI/synopsis.yml: run on `.md` files

Reported-by: Viktor Szakats
Fixes #14032
Closes #14037

17 months agoverify-synopsis.pl: work with .md files
Daniel Stenberg [Thu, 27 Jun 2024 09:23:13 +0000 (11:23 +0200)] 
verify-synopsis.pl: work with .md files

Ref: #14037
Closes #14038

17 months agoconncache: done always evaluates to false
Daniel Stenberg [Thu, 27 Jun 2024 06:48:18 +0000 (08:48 +0200)] 
conncache: done always evaluates to false

Follow-up to c9b95c0bb30f88bf00e1ac

Spotted by CodeSonar

Reviewed-by: Stefan Eissing
Closes #14034

17 months agolib: add a few DEBUGASSERT(data) to aid code analyzers
Daniel Stenberg [Thu, 27 Jun 2024 06:45:06 +0000 (08:45 +0200)] 
lib: add a few DEBUGASSERT(data) to aid code analyzers

... where 'data' is assumed to always work.

Closes #14033

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Thu, 27 Jun 2024 07:23:38 +0000 (09:23 +0200)] 
RELEASE-NOTES: synced

17 months agotidy-up: use `/usr/bin/env perl` shebang
Viktor Szakats [Wed, 26 Jun 2024 17:59:39 +0000 (19:59 +0200)] 
tidy-up: use `/usr/bin/env perl` shebang

Most Perl scripts already used it. Sync up the few outliers.

Closes #14029

17 months agoquic: openssl quic, cmake and doc version update to 3.3.0
Stefan Eissing [Wed, 26 Jun 2024 13:45:33 +0000 (15:45 +0200)] 
quic: openssl quic, cmake and doc version update to 3.3.0

Closes #14028

17 months agohttp/3: add shutdown support
Stefan Eissing [Wed, 26 Jun 2024 11:45:22 +0000 (13:45 +0200)] 
http/3: add shutdown support

- openssl-quic shutdown handling
- ngtcp2 shutdown handling
- quiche shutdown handling
- add test_19_06 for verfication

Reported-by: Dexter Gerig
Closes #14027
Fixes #14022

17 months agotests: verify managen
Daniel Stenberg [Wed, 26 Jun 2024 08:43:22 +0000 (10:43 +0200)] 
tests: verify managen

1705: verifies the manpage output

1706: verifies the ascii output

Closes #14025

17 months agoruntests: support %DATE for YYYY-MM-DD of right now
Daniel Stenberg [Wed, 26 Jun 2024 09:20:01 +0000 (11:20 +0200)] 
runtests: support %DATE for YYYY-MM-DD of right now

17 months agoruntests: support %VERNUM
Daniel Stenberg [Wed, 26 Jun 2024 09:13:54 +0000 (11:13 +0200)] 
runtests: support %VERNUM

For the plain version number of the built curl without -DEV etc. Only
digits and dots.

17 months agomanagen: only output .RE for manpage output
Daniel Stenberg [Wed, 26 Jun 2024 08:47:16 +0000 (10:47 +0200)] 
managen: only output .RE for manpage output

For ascii they are just rubbish.

Closes #14025

17 months agoquic: enable UDP GRO
Tatsuhiro Tsujikawa [Tue, 25 Jun 2024 09:51:03 +0000 (18:51 +0900)] 
quic: enable UDP GRO

Closes #14012

17 months agoquic: require at least OpenSSL 3.3 for QUIC
Stefan Eissing [Wed, 26 Jun 2024 09:19:26 +0000 (11:19 +0200)] 
quic: require at least OpenSSL 3.3 for QUIC

- when checking for QUIC support in OpenSSL, also check
  for it being at least 3.3.0
- remove workarounds for features buggy or missing in 3.2

Closes #14026

17 months agoFILEFORMAT.md: mentioned <file[num]> for "client"
Daniel Stenberg [Wed, 26 Jun 2024 08:13:16 +0000 (10:13 +0200)] 
FILEFORMAT.md: mentioned <file[num]> for "client"

They can be used to create more files.

Closes #14024

17 months agosystem_win32: add missing curl.h include
Marcel Raad [Tue, 25 Jun 2024 13:07:12 +0000 (15:07 +0200)] 
system_win32: add missing curl.h include

It's required for `CURLcode`.

Closes https://github.com/curl/curl/pull/14019

17 months agoTODO: specify which response codes that make -f/--fail return error
Daniel Stenberg [Tue, 25 Jun 2024 21:27:43 +0000 (23:27 +0200)] 
TODO: specify which response codes that make -f/--fail return error

Suggestion from the user survey 2024

Closes #14020

17 months agolib: graceful connection shutdown
Stefan Eissing [Wed, 19 Jun 2024 10:40:06 +0000 (12:40 +0200)] 
lib: graceful connection shutdown

When libcurl discards a connection there are two phases this may go
through: "shutdown" and "closing". If a connection is aborted, the
shutdown phase is skipped and it is closed right away.

The connection filters attached to the connection implement the phases
in their `do_shutdown()` and `do_close()` callbacks. Filters carry now a
`shutdown` flags next to `connected` to keep track of the shutdown
operation.

Filters are shut down from top to bottom. If a filter is not connected,
its shutdown is skipped. Notable filters that *do* something during
shutdown are HTTP/2 and TLS. HTTP/2 sends the GOAWAY frame. TLS sends
its close notify and expects to receive a close notify from the server.

As sends and receives may EAGAIN on the network, a shutdown is often not
successful right away and needs to poll the connection's socket(s). To
facilitate this, such connections are placed on a new shutdown list
inside the connection cache.

Since managing this list requires the cooperation of a multi handle,
only the connection cache belonging to a multi handle is used. If a
connection was in another cache when being discarded, it is removed
there and added to the multi's cache. If no multi handle is available at
that time, the connection is shutdown and closed in a one-time,
best-effort attempt.

When a multi handle is destroyed, all connection still on the shutdown
list are discarded with a final shutdown attempt and close. In curl
debug builds, the environment variable `CURL_GRACEFUL_SHUTDOWN` can be
set to make this graceful with a timeout in milliseconds given by the
variable.

The shutdown list is limited to the max number of connections configured
for a multi cache. Set via CURLMOPT_MAX_TOTAL_CONNECTIONS. When the
limit is reached, the oldest connection on the shutdown list is
discarded.

- In multi_wait() and multi_waitfds(), collect all connection caches
  involved (each transfer might carry its own) into a temporary list.
  Let each connection cache on the list contribute sockets and
  POLLIN/OUT events it's connections are waiting for.

- in multi_perform() collect the connection caches the same way and let
  them peform their maintenance. This will make another non-blocking
  attempt to shutdown all connections on its shutdown list.

- for event based multis (multi->socket_cb set), add the sockets and
  their poll events via the callback. When `multi_socket()` is invoked
  for a socket not known by an active transfer, forward this to the
  multi's cache for processing. On closing a connection, remove its
  socket(s) via the callback.

TLS connection filters MUST NOT send close nofity messages in their
`do_close()` implementation. The reason is that a TLS close notify
signals a success. When a connection is aborted and skips its shutdown
phase, the server needs to see a missing close notify to detect
something has gone wrong.

A graceful shutdown of FTP's data connection is performed implicitly
before regarding the upload/download as complete and continuing on the
control connection. For FTP without TLS, there is just the socket close
happening. But with TLS, the sent/received close notify signals that the
transfer is complete and healthy. Servers like `vsftpd` verify that and
reject uploads without a TLS close notify.

- added test_19_* for shutdown related tests
- test_19_01 and test_19_02 test for TCP RST packets
  which happen without a graceful shutdown and should
  no longer appear otherwise.
- add test_19_03 for handling shutdowns by the server
- add test_19_04 for handling shutdowns by curl
- add test_19_05 for event based shutdowny by server
- add test_30_06/07 and test_31_06/07 for shutdown checks
  on FTP up- and downloads.

Closes #13976

17 months agomanagen: fix blank line detection
Daniel Stenberg [Tue, 25 Jun 2024 14:28:33 +0000 (16:28 +0200)] 
managen: fix blank line detection

Follow-up to d14a53eea7b87 which ruined the output somewhat.

Closes #14017

17 months agomanagen: output tabs for each 8 leading spaces
Daniel Stenberg [Tue, 25 Jun 2024 11:37:51 +0000 (13:37 +0200)] 
managen: output tabs for each 8 leading spaces

This replacing of eight leading spaces into tabs was already done for
the embedded uncompressed version in tool_hugehelp.c so it does not save
anything there. But the gzip compressed version ends up almost 2K
smaller.

The output in a terminal should be identical.

Before using TABs:

curl.txt 282492 bytes
curl.txt.gz 73261 bytes

With this change applied:

curl.txt 249382 bytes
curl.txt.gz 71470 bytes

Closes #14016

17 months agomanagen: error on trailing blank lines in input files
Daniel Stenberg [Tue, 25 Jun 2024 11:23:37 +0000 (13:23 +0200)] 
managen: error on trailing blank lines in input files

Ref: #14014
Closes #14015

17 months agotidy-up: more whitespace
Viktor Szakats [Tue, 25 Jun 2024 11:12:30 +0000 (13:12 +0200)] 
tidy-up: more whitespace

Closes #14014

17 months agomulti: multi_getsock(), check correct socket
Stefan Eissing [Tue, 25 Jun 2024 09:35:48 +0000 (11:35 +0200)] 
multi: multi_getsock(), check correct socket

 - in phase CONNECTING/TUNNELING/PROTOCONNECT, retrieve
   the socket from the connection filters and do not rely
   on `conn->sockfd` being already set by the transfer.
 - this applies to the default behaviour, a protocol handler
   may override this via its callbacks.
 - add a warning message in multi_getsock() when the transfer
   is expected to have something in its pollset, but instead
   it is empty.

Reported-by: saurabhsingh-dev on github
Fixes #13998
Closes #14011

17 months agomanagen: fix each options footer to end with newline
Daniel Stenberg [Tue, 25 Jun 2024 09:35:48 +0000 (11:35 +0200)] 
managen: fix each options footer to end with newline

A previous change sometimes made a command line option's description not
end with a newline immediately before the next command line.

Also widened the lines to wrap on column 79 instead of 78.

Closes #14010

17 months agowolfssl: assume key_file equal to clientcert in the absence of key_file
Alex Snast [Mon, 24 Jun 2024 21:28:23 +0000 (14:28 -0700)] 
wolfssl: assume key_file equal to clientcert in the absence of key_file

When user sets CURLOPT_SSLCERT but leaves CURLOPT_SSLKEY unset assume
the path passed in CURLOPT_SSLCERT holds the ssl key which is what we do
in openssl implementation.

Fixes #14007
Closes #14008

17 months agoautotools: fix pkg-config names (zstd, ngtcp2*)
Viktor Szakats [Mon, 24 Jun 2024 18:29:02 +0000 (20:29 +0200)] 
autotools: fix pkg-config names (zstd, ngtcp2*)

Also verified that all names now match up with CMake.

Follow-up to f057de5a1a950a90d1920021db152a4b695f1a8a #13911
Follow-up to eeab0ea7aa19af61af881e8a0bf9ff1f2e28ef79 #13994
Reported-by: 李四
Fixes #14005
Closes #14006

17 months agotidy-up: whitespace [ci skip]
Viktor Szakats [Mon, 24 Jun 2024 18:26:34 +0000 (20:26 +0200)] 
tidy-up: whitespace [ci skip]

17 months agocmdline-docs: "added in" cleanups
Daniel Stenberg [Mon, 24 Jun 2024 14:25:40 +0000 (16:25 +0200)] 
cmdline-docs: "added in" cleanups

- markup fixes
- remove some mentions of < 7.60.0 changes

Closes #14003

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 24 Jun 2024 14:34:14 +0000 (16:34 +0200)] 
RELEASE-NOTES: synced

17 months agomanagen: "added in" fixes
Daniel Stenberg [Mon, 24 Jun 2024 11:57:02 +0000 (13:57 +0200)] 
managen: "added in" fixes

 - up the limit: remove all mentions of 7.60 or earlier from manpage
   7.60 is 6 years old now.
 - warn on "broken" added in lines, as they avoid detection
 - fixup added in markup in a few curldown files

Closes #14002

17 months agoconfigure: fix pkg-config library name 'libnghttp3'
Matt Jolly [Mon, 24 Jun 2024 06:49:10 +0000 (16:49 +1000)] 
configure: fix pkg-config library name 'libnghttp3'

Closes #13994

17 months agomanagen: cleanups to generate nicer-looking output
Daniel Stenberg [Mon, 24 Jun 2024 08:53:29 +0000 (10:53 +0200)] 
managen: cleanups to generate nicer-looking output

- output "see also" last
- when there are multiple mutex items, use commas between all of them
  except the last.
- call them mututally exclusive WITH not TO other options.
- remove trailing space from added in, add newline prefix
- smoother language for requires

Closes #14001

17 months agoconfigure: require a QUIC library if nghttp3 is used
Daniel Stenberg [Mon, 24 Jun 2024 08:27:08 +0000 (10:27 +0200)] 
configure: require a QUIC library if nghttp3 is used

Instead of just silently disabling HTTP/3.

Reported-by: Matt Jolly
Fixes #13995
Closes #13999

17 months agodocs/cmdline-opts: remove two superfluous "Added in" mentions
Daniel Stenberg [Mon, 24 Jun 2024 09:08:19 +0000 (11:08 +0200)] 
docs/cmdline-opts: remove two superfluous "Added in" mentions

The key "added in" phrase for the option itself is added automatically.

Closes #14000

17 months agocookie-jar.md: see also --junk-session-cookies
Daniel Stenberg [Mon, 24 Jun 2024 07:36:39 +0000 (09:36 +0200)] 
cookie-jar.md: see also --junk-session-cookies

Closes #13996

17 months agoruntests: support crlf="yes" for the <stderr> section
Daniel Stenberg [Sun, 23 Jun 2024 14:22:40 +0000 (16:22 +0200)] 
runtests: support crlf="yes" for the <stderr> section

17 months agoTODO: -h option
Daniel Stenberg [Sun, 23 Jun 2024 14:05:44 +0000 (16:05 +0200)] 
TODO: -h option

Support "curl -h --insecure" etc to output the manpage section for the
--insecure command line option in the terminal. Should be possible to
work with either long or short versions of command line options.

Closes #13990

17 months agotrace-ascii.md: mention "%" for stderr
Daniel Stenberg [Sun, 23 Jun 2024 14:12:50 +0000 (16:12 +0200)] 
trace-ascii.md: mention "%" for stderr

Closes #13991

17 months agoconnect-to.md: expand with examples
Daniel Stenberg [Sun, 23 Jun 2024 12:12:33 +0000 (14:12 +0200)] 
connect-to.md: expand with examples

- add referer from the resolve section to connect-to if user wants
  wildcard for the port number

Closes #13989

17 months agoTODO: connect to multiple IPs in parallel
Daniel Stenberg [Sun, 23 Jun 2024 09:31:16 +0000 (11:31 +0200)] 
TODO: connect to multiple IPs in parallel

Closes #13986

17 months agodump-header.md: mention minus for stdout
Daniel Stenberg [Sun, 23 Jun 2024 09:33:47 +0000 (11:33 +0200)] 
dump-header.md: mention minus for stdout

Closes #13985

17 months agoCURLOPT_RESOLVE.md: mention hostname can be wildcard ('*')
Daniel Stenberg [Sat, 22 Jun 2024 20:50:15 +0000 (22:50 +0200)] 
CURLOPT_RESOLVE.md: mention hostname can be wildcard ('*')

Closes #13983

17 months agocf-socket: optimize curlx_nonblock() and check its return error
Andy Pan [Thu, 13 Jun 2024 13:28:01 +0000 (21:28 +0800)] 
cf-socket: optimize curlx_nonblock() and check its return error

Reviewed-by: Stefan Eissing
Closes #13942

17 months agox509asn1: prevent NULL dereference
z2_ [Thu, 20 Jun 2024 19:57:07 +0000 (21:57 +0200)] 
x509asn1: prevent NULL dereference

Closes #13978

17 months agounit2604: use 'unitfail' instead of 'error' variable
Daniel Stenberg [Wed, 19 Jun 2024 07:34:43 +0000 (09:34 +0200)] 
unit2604: use 'unitfail' instead of 'error' variable

Since the framework is already returning that variable by default.
Avoids a warning for unreachable code.

Reported-by: Tal Regev
Fixes #13967
Closes #13973

17 months agoKNOWN_BUGS: TFTP tests fail on OpenBSD
Daniel Stenberg [Wed, 19 Jun 2024 10:02:40 +0000 (12:02 +0200)] 
KNOWN_BUGS: TFTP tests fail on OpenBSD

Closes #13623
Closes #13975

17 months agoVULN-DISCLOSURE-POLICY: NULL dereferences and crashes
Daniel Stenberg [Wed, 19 Jun 2024 09:47:26 +0000 (11:47 +0200)] 
VULN-DISCLOSURE-POLICY: NULL dereferences and crashes

If a malicious server can trigger a NULL dereference in curl or
otherwise cause curl to crash (and nothing worse), chances are big that
we do not consider that a security problem.

Closes #13974

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Wed, 19 Jun 2024 09:36:39 +0000 (11:36 +0200)] 
RELEASE-NOTES: synced

17 months agombedtls: support CURLOPT_CERTINFO
Sergey Markelov [Wed, 13 Mar 2024 00:21:06 +0000 (17:21 -0700)] 
mbedtls: support CURLOPT_CERTINFO

Closes #13113

17 months agox509asn1: ASN1tostr() should fail when 'constructed' is set
Daniel Stenberg [Wed, 19 Jun 2024 07:16:56 +0000 (09:16 +0200)] 
x509asn1: ASN1tostr() should fail when 'constructed' is set

This is a regression from my refactor in 623c3a8fa0bdb (#12808)

Follow-up to 623c3a8fa0bdb2751f14b37417

Closes #13972

17 months agox509asn1: remove two static variables
Daniel Stenberg [Wed, 19 Jun 2024 06:59:39 +0000 (08:59 +0200)] 
x509asn1: remove two static variables

cnOID and sanOID were not used outside of the OID table anyway

Closes #13971

17 months agoTODO: TLS channel binding
brian m. carlson [Tue, 18 Jun 2024 08:29:43 +0000 (10:29 +0200)] 
TODO: TLS channel binding

Closes #13483

17 months agocmake: add CURL_USE_GSASL option with detection + CI test
Tal Regev [Fri, 14 Jun 2024 05:09:55 +0000 (08:09 +0300)] 
cmake: add CURL_USE_GSASL option with detection + CI test

Reviewed-by: Viktor Szakats
Closes #13948

17 months agox509asn1: make Curl_extract_certinfo store error message
Daniel Stenberg [Sun, 16 Jun 2024 09:07:40 +0000 (11:07 +0200)] 
x509asn1: make Curl_extract_certinfo store error message

To help us all better understand where the error actually comes from.

Ref: #13958
Closes #13959

17 months agoappveyor: dump build logs on failure in VS2008 jobs
Viktor Szakats [Fri, 14 Jun 2024 15:50:21 +0000 (17:50 +0200)] 
appveyor: dump build logs on failure in VS2008 jobs

This seems to be the only way to see what actual toolchain commands were
run, and with what arguments.

Without `dos2unix`, `cat` output comes out empty.

Closes #13957

17 months agocmake: fix quotes when appending multiple options (SecureTransport)
Viktor Szakats [Fri, 14 Jun 2024 11:10:10 +0000 (13:10 +0200)] 
cmake: fix quotes when appending multiple options (SecureTransport)

Copied from a vcpkg distro patch:
https://github.com/microsoft/vcpkg/blob/02745e0f4749d1f51d2025824209408f5a6c3614/ports/curl/dependencies.patch#L43C38-L44

Ref: https://github.com/microsoft/vcpkg/pull/38847
Ref: https://github.com/microsoft/vcpkg/commit/795f2f137e6cf6d985fcc927bffcaf9c0a96e4ac
Ref: https://github.com/microsoft/vcpkg/pull/38847/commits/36f0c917de5319e95361451fc0aef0698b264874#diff-ab5c23e5dc5df412539cc93e24b37abbc588e1918236f8abc019d676b270c85fR39 (sub-commit)

Authored-by: Kai Pastor
Closes #13953

17 months agoCURLOPT_NETRC.md: clarify what it does on Windows
Daniel Stenberg [Sat, 15 Jun 2024 09:49:40 +0000 (11:49 +0200)] 
CURLOPT_NETRC.md: clarify what it does on Windows

Closes #13956

17 months agoKNOWN_BUGS: "HTTP/2 + TLS spends a lot of time in recv"
Daniel Stenberg [Fri, 14 Jun 2024 21:56:37 +0000 (23:56 +0200)] 
KNOWN_BUGS: "HTTP/2 + TLS spends a lot of time in recv"

Closes #13416
Closes #13955

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Fri, 14 Jun 2024 11:30:06 +0000 (13:30 +0200)] 
RELEASE-NOTES: synced

17 months agoexamples: add missing binaries to .gitignore
Yedaya Katsman [Fri, 14 Jun 2024 10:34:53 +0000 (13:34 +0300)] 
examples: add missing binaries to .gitignore

They were showing as changed when built. Add them sorted alphabetically,
while also moving a few more entries to sorted order.

Closes #13952

17 months agodocs: reference non deprecated libcurl options
Yedaya Katsman [Fri, 14 Jun 2024 08:19:32 +0000 (11:19 +0300)] 
docs: reference non deprecated libcurl options

There are a places where man pages reference deprecated CURLOPT options,
where it doesn't make sense, replace them with the reccomended
replacement option.

also remove reference to the removed mesalink TLS backend

Closes #13951

17 months agognutls: pass in SNI name, not hostname when checking cert
Daniel Stenberg [Fri, 14 Jun 2024 06:46:50 +0000 (08:46 +0200)] 
gnutls: pass in SNI name, not hostname when checking cert

The function we use is called 'gnutls_x509_crt_check_hostname()' but if
we pass in the hostname with a trailing dot, the check fails. If we pass
in the SNI name, which cannot have a trailing dot, it succeeds for
https://pyropus.ca./

I consider this as a flaw in GnuTLS and have submitted this issue
upstream:

  https://gitlab.com/gnutls/gnutls/-/issues/1548

In order to work with old and existing GnuTLS versions, we still need
this change no matter how they view the issue or might change it in the
future.

Fixes #13428
Reported-by: Ryan Carsten Schmidt
Closes #13949