]> git.ipfire.org Git - thirdparty/curl.git/log
thirdparty/curl.git
17 months agomk-ca-bundle.md: cleanups and polish 12958/head
Daniel Stenberg [Mon, 19 Feb 2024 08:31:08 +0000 (09:31 +0100)] 
mk-ca-bundle.md: cleanups and polish

Closes #12958

17 months agospellcheck.yml: remove .1/.3 handling, clean all man page .md files
Daniel Stenberg [Mon, 19 Feb 2024 08:54:21 +0000 (09:54 +0100)] 
spellcheck.yml: remove .1/.3 handling, clean all man page .md files

Since we generate all .1 and .3 files from markdown now, we can limit
the spellcheck to the markdown versions only.

Closes #12960

17 months agolibcurl-docs: cleanups
Daniel Stenberg [Mon, 19 Feb 2024 09:56:14 +0000 (10:56 +0100)] 
libcurl-docs: cleanups

 CURLMOPT_SOCKETDATA.md: fix typo
 CURLMOPT_TIMERDATA.md: fix typo
 CURLOPT_COOKIELIST.m: quote strings
 CURLOPT_PREREQFUNCTION.md: quote variable names
 CURLOPT_TCP_NODELAY.md: rephrased to please spell checker
 CURLOPT_WILDCARDMATCH.md: rephrased
 libcurl-tutorial.md: use correct option name
 curl_global_init_mem.md: quote headers
 curl_easy_getinfo.md: use correct symbol names in headers
 curl_global_trace.md: quote some headers
 curl_ws_meta.md: quote struct field names
 libcurl-env.md: quote headers

17 months agocd2nroff: remove backticks from titles
Daniel Stenberg [Mon, 19 Feb 2024 09:56:38 +0000 (10:56 +0100)] 
cd2nroff: remove backticks from titles

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 19 Feb 2024 07:34:37 +0000 (08:34 +0100)] 
RELEASE-NOTES: synced

17 months agohttp_chunks: fix the accounting of consumed bytes
Stefan Eissing [Wed, 14 Feb 2024 15:27:23 +0000 (16:27 +0100)] 
http_chunks: fix the accounting of consumed bytes

Prior to this change chunks were handled correctly although in verbose
mode libcurl could incorrectly warn of "Leftovers after chunking" even
if there were none.

Reported-by: Michael Kaufmann
Fixes https://github.com/curl/curl/issues/12937
Closes https://github.com/curl/curl/pull/12939

17 months agofile: use xfer buf for file:// transfers
Stefan Eissing [Tue, 13 Feb 2024 10:39:06 +0000 (11:39 +0100)] 
file: use xfer buf for file:// transfers

- For file:// transfers use the multi handle's transfer buffer for
  up- and downloads.

Prior to this change a6c9a33 (precedes 8.6.0) changed the file://
transfers to use a smaller stack based buffer, and that caused a
significant performance decrease in Windows.

Bug: https://github.com/curl/curl/issues/12750#issuecomment-1920103086
Reported-by: edmcln@users.noreply.github.com
Closes https://github.com/curl/curl/pull/12932

17 months agoHTTP3.md: always run nghttp3 submodule init
Karthikdasari0423 [Mon, 12 Feb 2024 09:52:39 +0000 (15:22 +0530)] 
HTTP3.md: always run nghttp3 submodule init

- For consistency change all 'build nghttp3' commands to run submodule
  init after cloning, even if the branch does not have submodules.

Follow-up to 5a4b2f93 and 4f794558.

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

17 months agoCURLOPT_POSTQUOTE.md: fix typo
LeeRiva [Sun, 11 Feb 2024 21:52:12 +0000 (22:52 +0100)] 
CURLOPT_POSTQUOTE.md: fix typo

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

17 months agochecksrc.pl: fix handling .checksrc with CRLF
Evgeny Grin [Sun, 18 Feb 2024 06:36:27 +0000 (11:36 +0500)] 
checksrc.pl: fix handling .checksrc with CRLF

- When parsing .checksrc chomp the (CR)LF line ending.

Prior to this change on Windows checksrc.pl would not process the
symbols in .checksrc properly, since many git repos in Windows use auto
crlf to check out files with CRLF line endings.

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

17 months agocmake: fix install for older CMake versions
Richard Levitte [Sat, 10 Feb 2024 16:34:43 +0000 (17:34 +0100)] 
cmake: fix install for older CMake versions

- Generate the docs install list by using a foreach loop instead of
  LIST:TRANSFORM since older CMake can't handle the latter.

Reported-by: Dan Fandrich
Fixes https://github.com/curl/curl/issues/12920
Closes https://github.com/curl/curl/pull/12922

17 months agovtls: fix tls proxy peer verification
Stefan Eissing [Tue, 13 Feb 2024 10:05:21 +0000 (11:05 +0100)] 
vtls: fix tls proxy peer verification

- When verifying a proxy certificate for an ip address, use the correct
  ip family.

Prior to this change the "connection" ip family was used, which was not
necessarily the same.

Reported-by: HsiehYuho@users.noreply.github.com
Fixes https://github.com/curl/curl/issues/12831
Closes https://github.com/curl/curl/pull/12931

17 months agoCI: Bump the Circle CI base Ubuntu image to the latest 20.04
Dan Fandrich [Fri, 16 Feb 2024 00:04:40 +0000 (16:04 -0800)] 
CI: Bump the Circle CI base Ubuntu image to the latest 20.04

The previous ones are going to be removed soon, plus the new ones
include all the fixes since then.

17 months agotransfer: improve Windows SO_SNDBUF update limit
Jay Satiro [Fri, 9 Feb 2024 09:08:35 +0000 (04:08 -0500)] 
transfer: improve Windows SO_SNDBUF update limit

- Change the 1 second SO_SNDBUF update limit from per transfer to per
  connection.

Prior to this change many transfers over the same connection could cause
many SO_SNDBUF updates made to that connection per second, which was
unnecessary.

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

17 months agoschannel: fix hang on unexpected server close
Jay Satiro [Fri, 9 Feb 2024 08:41:30 +0000 (03:41 -0500)] 
schannel: fix hang on unexpected server close

- Treat TLS connection close (either due to a close_notify from the
  server or just closed due to receiving 0) as pending data.

This is because in some cases schannel_recv knows the connection is
closed but has to return actual pending data so it can't return 0 or an
error to indicate no more data. In this case schannel_recv must be
called again, which only happens if readwrite_data sees that there is
still pending data.

Prior to this change if the total size of the body that libcurl expected
to receive from the server was unknown then it was possible under some
network conditions that libcurl would hang waiting to receive more data,
when in fact a close_notify alert indicating no more data would be sent
was already processed.

Fixes https://github.com/curl/curl/issues/12894
Closes https://github.com/curl/curl/pull/12910

17 months agoKNOWN_BUGS: FTP upload fails if remebered dir is deleted
Daniel Stenberg [Sat, 10 Feb 2024 17:31:31 +0000 (18:31 +0100)] 
KNOWN_BUGS: FTP upload fails if remebered dir is deleted

Closes #12181
Closes #12923

17 months agombedtls: use mbedtls_ssl_conf_{min|max}_tls_version
MAntoniak [Thu, 8 Feb 2024 19:16:23 +0000 (20:16 +0100)] 
mbedtls: use mbedtls_ssl_conf_{min|max}_tls_version

... instead of the deprecated mbedtls_ssl_conf_{min|max}_version

Closes #12905

17 months agoCI: bump to actions/cache@v4 to avoid warning
Dan Fandrich [Sat, 10 Feb 2024 01:23:55 +0000 (17:23 -0800)] 
CI: bump to actions/cache@v4 to avoid warning

17 months agotest1165: improve pattern matching
Evgeny Grin [Thu, 8 Feb 2024 17:41:55 +0000 (18:41 +0100)] 
test1165: improve pattern matching

* Fix excluded digits at the end of the symbols ('CURL_DISABLE_POP3'
  was checked as 'CURL_DISABLE_POP')

Closes #12903

17 months agoscripts: Fix cijobs.pl for Azure and GHA
Dan Fandrich [Fri, 9 Feb 2024 22:38:58 +0000 (14:38 -0800)] 
scripts: Fix cijobs.pl for Azure and GHA

The spacing in the yaml files changed.

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Fri, 9 Feb 2024 22:47:10 +0000 (23:47 +0100)] 
RELEASE-NOTES: synced

17 months agoTODO: use pkg-config to find libpsl
Daniel Stenberg [Fri, 9 Feb 2024 15:37:43 +0000 (16:37 +0100)] 
TODO: use pkg-config to find libpsl

Closes #12919

17 months agoTODO: avoid nroff
Daniel Stenberg [Fri, 9 Feb 2024 15:30:28 +0000 (16:30 +0100)] 
TODO: avoid nroff

Instead of adjusting roffit, skip the nroff step.

Closes #12919

17 months agoRevert "CI: run Circle macOS builds on x86 for now"
Dan Fandrich [Thu, 4 Jan 2024 18:32:04 +0000 (10:32 -0800)] 
Revert "CI: run Circle macOS builds on x86 for now"

This reverts commit 2683de3078eadc86d9b182e7417f4ee75a247e2c.
ARM resources are now available in Circle CI, so run these builds on ARM
again. This platform needs explicit paths set to libpsl and its
dependency icu4c.

Follow-up to 2683de30

Closes #12635

17 months agocmake: add warning for using TLS libraries without 1.3 support
Viktor Szakats [Thu, 8 Feb 2024 21:45:55 +0000 (22:45 +0100)] 
cmake: add warning for using TLS libraries without 1.3 support

Closes #12900

17 months agoconfigure: add warning for using TLS libraries without 1.3 support
Daniel Stenberg [Thu, 8 Feb 2024 14:11:55 +0000 (15:11 +0100)] 
configure: add warning for using TLS libraries without 1.3 support

Closes #12900

17 months agombedtls: fix building when MBEDTLS_X509_REMOVE_INFO flag is defined
MAntoniak [Thu, 8 Feb 2024 18:54:45 +0000 (19:54 +0100)] 
mbedtls: fix building when MBEDTLS_X509_REMOVE_INFO flag is defined

Closes #12904

17 months agoftp: fix socket wait activity in ftp_domore_getsock
Stefan Eissing [Fri, 9 Feb 2024 12:10:08 +0000 (13:10 +0100)] 
ftp: fix socket wait activity in ftp_domore_getsock

- when waiting on the data connection, always add the control socket to
  the pollset on state STOP or let the pingpong add the socket according
  to its needs.

Reported-by: Fabian Vogt
Fixes #12901
Closes #12913

17 months agodist: make sure the http tests are in the tarball
Daniel Stenberg [Fri, 9 Feb 2024 13:15:25 +0000 (14:15 +0100)] 
dist: make sure the http tests are in the tarball

Fixes #12914
Reported-by: Fabian Vogt
Closes #12917

17 months agomulti: add xfer_buf to multi handle
Stefan Eissing [Fri, 26 Jan 2024 11:05:08 +0000 (12:05 +0100)] 
multi: add xfer_buf to multi handle

- can be borrowed by transfer during recv-write operation
- needs to be released before borrowing again
- adjustis size to `data->set.buffer_size`
- used in transfer.c readwrite_data()

Closes #12805

17 months agowrite-out.md: clarify error handling details
Daniel Stenberg [Thu, 8 Feb 2024 22:41:50 +0000 (23:41 +0100)] 
write-out.md: clarify error handling details

- it gets used even if the transfer fails

- it does not cause error to be returned even if it fails

Closes #12909

17 months agoftp: do lineend conversions in client writer
Stefan Eissing [Tue, 6 Feb 2024 10:56:35 +0000 (11:56 +0100)] 
ftp: do lineend conversions in client writer

- remove the ftp special handling from sendf.c
- let ftp_do() add a client writer that does
  the linened conversions
- change the lineend conversion to no longer
  modify the passed buffer, but write smaller
  chunks to the next cwriter instead. The
  inefficiency of this will be mitigated once
  we add output buffering for all client writes.

Closes #12878

17 months agoftp: tracing improvements
Stefan Eissing [Thu, 8 Feb 2024 16:52:29 +0000 (17:52 +0100)] 
ftp: tracing improvements

- trace socketindex for connection filters when not the first
- trace socket fd in tcp
- trace pollset adjusts in vtls

Closes #12902

17 months agoHTTP3.md: adjust the OpenSSL QUIC install instructions
Karthikdasari0423 [Thu, 8 Feb 2024 11:38:16 +0000 (17:08 +0530)] 
HTTP3.md: adjust the OpenSSL QUIC install instructions

tried installing with old steps but failed
tried with newly added setps and able to build
```
root@ubuntu:~/curl# ./src/curl -V
/root/curl/src/.libs/curl: /lib/x86_64-linux-gnu/libssl.so.3: version `OPENSSL_3.2.0' not found (required by /root/curl/lib/.libs/libcurl.so.4)
root@ubuntu:~/curl#
```
```
root@ubuntu:~/curl# ./src/curl -V
curl 8.6.1-DEV (x86_64-pc-linux-gnu) libcurl/8.6.1-DEV OpenSSL/3.2.0 zlib/1.2.11 brotli/1.0.9 libpsl/0.21.0 nghttp3/1.1.0 OpenLDAP/2.5.16
Release-Date: [unreleased]
Protocols: dict file ftp ftps gopher gophers http https imap imaps ipfs ipns ldap ldaps mqtt pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS brotli HSTS HTTP3 HTTPS-proxy IPv6 Largefile libz NTLM PSL SSL threadsafe TLS-SRP UnixSockets
root@ubuntu:~/curl#
```

Closes #12896

17 months agoTODO: align the TOC with the header
Daniel Stenberg [Thu, 8 Feb 2024 14:00:00 +0000 (15:00 +0100)] 
TODO: align the TOC with the header

17 months agodocs: make sure curl.1 is included in dist tarballs
Daniel Stenberg [Thu, 8 Feb 2024 06:58:09 +0000 (07:58 +0100)] 
docs: make sure curl.1 is included in dist tarballs

Ref: https://github.com/curl/curl/issues/12832#issuecomment-1933271873

Closes #12892

17 months agoHTTP3.md: remove quiche word in Openssl 3.2
Karthikdasari0423 [Thu, 8 Feb 2024 08:02:05 +0000 (13:32 +0530)] 
HTTP3.md: remove quiche word in Openssl 3.2

Closes #12893

17 months agocurl: when allocating variables, add the name into the struct
Daniel Stenberg [Wed, 7 Feb 2024 13:28:38 +0000 (14:28 +0100)] 
curl: when allocating variables, add the name into the struct

This saves the name from being an extra separate allocation.

Closes #12891

17 months agolib582: remove code causing warning that is never run
Daniel Stenberg [Wed, 7 Feb 2024 13:06:56 +0000 (14:06 +0100)] 
lib582: remove code causing warning that is never run

The previous realloc code in this code could trigger a compiler warning,
but since that code path cannot happen in normal circumstances it now
instead exits with an error message there.

Ref: #12887
Closes #12890

17 months agovtls: revert "receive max buffer" + add test case
Stefan Eissing [Thu, 1 Feb 2024 17:15:50 +0000 (18:15 +0100)] 
vtls: revert "receive max buffer" + add test case

- add test_05_04 for requests using http/1.0, http/1.1 and h2 against an
  Apache resource that does an unclean TLS shutdown.
- revert special workarund in openssl.c for suppressing shutdown errors
  on multiplexed connections
- vlts.c restore to its state before 9a90c9dd64d2f03601833a70786d485851bd1b53

Fixes #12885
Fixes #12844

Closes #12848

17 months agotests: support setting/using blank content env variables
Daniel Stenberg [Mon, 5 Feb 2024 16:04:28 +0000 (17:04 +0100)] 
tests: support setting/using blank content env variables

- test450: remove --config from the keywords
- test2080: change return code
- test428: add --config as a keyword
- test428: disable on Windows due to CI problems

17 months agocurl: exit on config file parser errors
Daniel Stenberg [Mon, 5 Feb 2024 14:04:31 +0000 (15:04 +0100)] 
curl: exit on config file parser errors

Like when trying to import an environment variable that does not exist.

Also fix a bug for reading env variables when there is a default value
set.

Bug: https://curl.se/mail/archive-2024-02/0008.html
Reported-by: Brett Buddin
Add test 462 to verify.

Closes #12862

17 months agoCURLOPT_WRITEFUNCTION.md: typo fix
Daniel Szmulewicz [Wed, 7 Feb 2024 12:13:14 +0000 (20:13 +0800)] 
CURLOPT_WRITEFUNCTION.md: typo fix

The maximum amount of body data that is <be> passed to the write
callback is defined in the curl.h header file

Closes #12889

17 months agolib: convert Curl_get_line to use dynbuf
Daniel Stenberg [Tue, 6 Feb 2024 09:15:52 +0000 (10:15 +0100)] 
lib: convert Curl_get_line to use dynbuf

Create the line in a dynbuf. Aborts the reading of the file on
errors. Avoids having to always allocate maximum amount from the
start. Avoids direct malloc.

Closes #12846

17 months agoKNOWN_BUGS: unicode on Windows
Daniel Stenberg [Tue, 6 Feb 2024 16:39:04 +0000 (17:39 +0100)] 
KNOWN_BUGS: unicode on Windows

Closes #11461
Closes #12231
Closes #12883

17 months agotool_operate: change precedence of server Retry-After time
Daniel Stenberg [Mon, 5 Feb 2024 23:09:11 +0000 (18:09 -0500)] 
tool_operate: change precedence of server Retry-After time

- When calculating the retry time, no longer allow a server's requested
  Retry-After time to take precedence over a longer retry time (either
  default algorithmic or user-specified).

Prior to this change the server's Retry-After time took precedence over
curl's retry time in all cases, but that's not always practical for
short Retry-After times depending on how busy the server is.

Bug: https://curl.se/mail/archive-2024-01/0022.html
Reported-by: Dirk Hünniger
Closes https://github.com/curl/curl/pull/12871

17 months agocmdline-docs: quote and angle bracket cleanup
Daniel Stenberg [Tue, 6 Feb 2024 17:07:07 +0000 (18:07 +0100)] 
cmdline-docs: quote and angle bracket cleanup

- make sure angle brackets are escaped
- remove a lot of superfluous double quotes
- replace several double quotes with backticks

To make nicer-looking markdown.

Closes #12884

17 months agobadwords: use hostname, not host name
Daniel Stenberg [Tue, 6 Feb 2024 22:43:41 +0000 (23:43 +0100)] 
badwords: use hostname, not host name

and username, filename - consistently. Fixed the patterns in
badwords.txt to catch these.

Closes #12888

17 months agocmake: fix function description in comment [ci skip]
Viktor Szakats [Tue, 6 Feb 2024 13:04:24 +0000 (13:04 +0000)] 
cmake: fix function description in comment [ci skip]

Closes #12879

17 months agoheader.md: remove backslash, make nicer markdown
Daniel Stenberg [Tue, 6 Feb 2024 10:20:30 +0000 (11:20 +0100)] 
header.md: remove backslash, make nicer markdown

- remove a leftover backslash before a dash
- use backticks for "code" strings

Closes #12877

17 months agodocs: add mk-ca-bundle.1 to dist
Daniel Stenberg [Tue, 6 Feb 2024 08:29:17 +0000 (09:29 +0100)] 
docs: add mk-ca-bundle.1 to dist

... which also makes it get built. But don't build this or curl-config.1
if build docs is disabled.

Closes #12875

17 months agohttps-proxy: use IP address and cert with ip in alt names
Stefan Eissing [Thu, 1 Feb 2024 09:51:45 +0000 (10:51 +0100)] 
https-proxy: use IP address and cert with ip in alt names

- improve info logging when peer verification fails to indicate
  if DNS name or ip address has been tried to match
- add test case for contacting https proxy with ip address
- add pytest env check on loaded credentials and re-issue
  when they are no longer valid
- disable proxy ip address test for bearssl, since not supported there

Ref: #12831
Closes #12838

17 months agodocs: add necessary setup for nghttp3
Jiawen Geng [Sun, 4 Feb 2024 09:19:46 +0000 (17:19 +0800)] 
docs: add necessary setup for nghttp3

Now nghttp3 has submodules
https://github.com/ngtcp2/nghttp3/blob/main/.gitmodules

Closes #12859

17 months agoversion: allow building with ancient libpsl
Peter Krefting [Fri, 2 Feb 2024 22:22:32 +0000 (23:22 +0100)] 
version: allow building with ancient libpsl

The psl_check_version_number() API was added in libpsl 0.11.0. CentOS 7
ships with version 0.7.0 which lacks this API. Revert to using the older
versioning API if we detect an old libpsl version.

Follow-up to 72bd88adde0e8cf6e63644a7d6df1da01a399db4
Bug: https://curl.se/mail/archive-2024-02/0004.html
Reported-by: Scott Mutter
Closes #12872

17 months agoTODO: Support latest rustls
Daniel Stenberg [Tue, 6 Feb 2024 07:58:52 +0000 (08:58 +0100)] 
TODO: Support latest rustls

Closes #12737
Closes #12874

17 months agodocs: make curldown do angle brackets like markdown
Daniel Stenberg [Mon, 5 Feb 2024 22:23:56 +0000 (23:23 +0100)] 
docs: make curldown do angle brackets like markdown

Make sure we use \< and \> in markdown all over so that it renders
correctly, on GitHub and elsewhere. cd2nroff now outputs a warning if it
finds an unescaled angle bracket.

Ref: #12854
Closes #12869

17 months agodocs: fix the --disable-docs for autotools
Daniel Stenberg [Mon, 5 Feb 2024 23:00:35 +0000 (00:00 +0100)] 
docs: fix the --disable-docs for autotools

Follow-up to 541321507e386

Closes #12870

17 months agoRELEASE-NOTES: synced
Daniel Stenberg [Mon, 5 Feb 2024 23:14:44 +0000 (00:14 +0100)] 
RELEASE-NOTES: synced

17 months agolibcurl-security.md: Active FTP passes on the local IP address
Daniel Stenberg [Mon, 5 Feb 2024 18:30:48 +0000 (19:30 +0100)] 
libcurl-security.md: Active FTP passes on the local IP address

Reported-by: Harry Sintonen
Closes #12867

17 months agoconfigure: do not link with nghttp3 unless necessary
Stefan Eissing [Mon, 5 Feb 2024 16:02:21 +0000 (17:02 +0100)] 
configure: do not link with nghttp3 unless necessary

Fixes #12833
Closes #12864
Reported-by: Ryan Carsten Schmidt
17 months agoTHANKS: add Dmitry Tretyakov
Daniel Stenberg [Mon, 5 Feb 2024 22:46:26 +0000 (23:46 +0100)] 
THANKS: add Dmitry Tretyakov

... since I missed to give credit to the report in the fix of #12861

17 months agoopenssl-quic: check on Windows that socket conv to int is possible
Stefan Eissing [Mon, 5 Feb 2024 16:29:24 +0000 (17:29 +0100)] 
openssl-quic: check on Windows that socket conv to int is possible

Fixes #12861
Closes #12865

17 months agotool_cb_hdr: only parse etag + content-disposition for 2xx
Daniel Stenberg [Mon, 5 Feb 2024 18:24:50 +0000 (19:24 +0100)] 
tool_cb_hdr: only parse etag + content-disposition for 2xx

... and ignore them for other response codes.

Reported-by: Harry Sintonen
Closes #12866

17 months agomd4: include strdup.h for the memdup proto
Daniel Stenberg [Mon, 5 Feb 2024 14:22:08 +0000 (15:22 +0100)] 
md4: include strdup.h for the memdup proto

Reported-by: Erik Schnetter
Fixes #12849
Closes #12863

17 months agodocs: add missing slashes to SChannel client certificate documentation
Joel Depooter [Sat, 3 Feb 2024 01:58:04 +0000 (17:58 -0800)] 
docs: add missing slashes to SChannel client certificate documentation

When setting the CURLOPT_SSLCERT option to a certificate thumprint, it
is required to have a backslash between the "store location", "store
name" and "thumbprint" tokens. These slashes were present in the
previous documentation, but were missed in the transition to markdown
documentation.

Closes #12854

17 months agoHTTP/2: write response directly
Stefan Eissing [Wed, 31 Jan 2024 15:30:54 +0000 (16:30 +0100)] 
HTTP/2: write response directly

- use the new `Curl_xfer_write_resp()` to write incoming responses
  directly to the client
- eliminates `stream->recvbuf`
- memory consumption on parallel transfers minimized

Closes #12828

17 months agocookie.md: provide an example sending a fixed cookie
Daniel Stenberg [Mon, 5 Feb 2024 18:42:58 +0000 (19:42 +0100)] 
cookie.md: provide an example sending a fixed cookie

Closes #12868

17 months agoALTSVC.md: correct a typo
Lars Kellogg-Stedman [Fri, 2 Feb 2024 17:51:19 +0000 (12:51 -0500)] 
ALTSVC.md: correct a typo

The ALPN documentation erroneously referred to a "host number" instead
of a "port number".

Closes #12852

17 months agoproxy1.0.md: fix example
Boris Verkhovskiy [Sat, 3 Feb 2024 09:05:16 +0000 (01:05 -0800)] 
proxy1.0.md: fix example

Closes #12856

17 months agoconfigure: add --disable-docs flag
Chris Webb [Sat, 3 Feb 2024 21:05:59 +0000 (21:05 +0000)] 
configure: add --disable-docs flag

Building man pages from curldown sources now requires perl. Add a
--disable-docs flag to configure to enable building and installing
without documentation where perl is not available or man pages are not
required. This is selected automatically (with a warning) when perl is
not found by configure.

Fixes #12832
Closes #12857

17 months agoconnect.c: fix typo
Faraz Fallahi [Sun, 4 Feb 2024 00:20:35 +0000 (16:20 -0800)] 
connect.c: fix typo

Closes #12858

18 months agosendf: ignore response body to HEAD
Daniel Stenberg [Thu, 1 Feb 2024 12:23:12 +0000 (13:23 +0100)] 
sendf: ignore response body to HEAD

and mark the stream for close, but return OK since the response this far
was ok - if headers were received. Partly because this is what curl has
done traditionally.

Test 499 verifies. Updates test 689.

Reported-by: Sergey Bronnikov
Bug: https://curl.se/mail/lib-2024-02/0000.html
Closes #12842

18 months agoftp: treat a 226 arriving before data as a signal to read data
Daniel Stenberg [Thu, 1 Feb 2024 10:28:22 +0000 (11:28 +0100)] 
ftp: treat a 226 arriving before data as a signal to read data

For active mode transfers.

Due to some interesting timing, curl can sometimes get the 226 (transfer
complete) over the control channel first, before the data connection
signals readability. If this happens, use that as a signal to check the
data connection.

Additionally, set the socket filter in listen mode *before* the
PORT/EPRT command is issued, to reduce the risk that the little time gap
could interfere.

This issue never reproduced for me on Debian and takes several hundred
rounds for me to trigger on my mac.

Reported-by: Stefan Eissing
Fixes #12823
Closes #12841

18 months agoOS400: avoid using awk in the build scripts
Patrick Monnerat [Wed, 31 Jan 2024 13:04:41 +0000 (14:04 +0100)] 
OS400: avoid using awk in the build scripts

Awk is a PASE program and its use may cause a failure depending on the
CCSID of the calling script (IBM bug?).

For this reason, revert to an sed-only solution to extract the exported
symbols from the header files.

Closes #12826

18 months agodocs: remove `mk-ca-bundle.1` from `man_MANS`
Jan Macku [Thu, 1 Feb 2024 13:18:12 +0000 (14:18 +0100)] 
docs: remove `mk-ca-bundle.1` from `man_MANS`

It was accidentally added in https://github.com/curl/curl/pull/12730

Co-authored-by: Lukáš Zaoral <lzaoral@redhat.com>
Signed-off-by: Jan Macku <jamacku@redhat.com>
Follow-up to eefcc1bda4bccd800f5a56a0fe17a2f44a96e88b
Closes #12843

18 months agoRELEASE-NOTES: synced
Daniel Stenberg [Thu, 1 Feb 2024 13:47:09 +0000 (14:47 +0100)] 
RELEASE-NOTES: synced

and bump to 8.6.1 for now

18 months agocmdline-docs/Makefile: avoid using a fixed temp file name
Daniel Stenberg [Thu, 1 Feb 2024 09:53:29 +0000 (10:53 +0100)] 
cmdline-docs/Makefile: avoid using a fixed temp file name

By appending the pid number two different runs at the same time will not
trample over the same file.

Reported-by: Jon Rumsey
Fixes #12829
Closes #12839

18 months agoasyn-thread: use wakeup_close to close the read descriptor
Daniel Stenberg [Thu, 1 Feb 2024 08:36:19 +0000 (09:36 +0100)] 
asyn-thread: use wakeup_close to close the read descriptor

Reported-by: Dan Fandrich
Ref: #12834
Closes #12836

18 months agontml_wb: fix buffer type typo
Stefan Eissing [Wed, 31 Jan 2024 11:14:34 +0000 (12:14 +0100)] 
ntml_wb: fix buffer type typo

Closes #12825

18 months agotool_operate: do not set CURLOPT_QUICK_EXIT in debug builds
Daniel Stenberg [Thu, 1 Feb 2024 08:34:41 +0000 (09:34 +0100)] 
tool_operate: do not set CURLOPT_QUICK_EXIT in debug builds

Since it allows (small) memory leaks that interfere with torture tests
and regular memory-leak checks.

Reported-by: Dan Fandrich
Fixes #12834
Closes #12835

18 months agoform-string.md: correct the example
Boris Verkhovskiy [Wed, 31 Jan 2024 09:34:19 +0000 (01:34 -0800)] 
form-string.md: correct the example

Closes #12822

18 months agoRELEASE-NOTES: synced curl-8_6_0
Daniel Stenberg [Wed, 31 Jan 2024 07:02:47 +0000 (08:02 +0100)] 
RELEASE-NOTES: synced

curl 8.6.0

18 months agoTHANKS: new contributors from 8.5.0
Daniel Stenberg [Wed, 31 Jan 2024 07:02:47 +0000 (08:02 +0100)] 
THANKS: new contributors from 8.5.0

18 months agocd2nroff: use perl 'strict' and 'warnings'
Jay Satiro [Mon, 29 Jan 2024 23:57:10 +0000 (18:57 -0500)] 
cd2nroff: use perl 'strict' and 'warnings'

- Use strict and warnings pragmas.

- If open() fails then show the reason.

- Set STDIN io layer :crlf so that input is properly read on Windows.

- When STDIN is used as input, the filename $f is now set to "STDIN".

Various error messages in single() use $f for the filename and this way
it is not undefined when STDIN.

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

18 months agocd2nroff: fix duplicate output issue
Daniel Stenberg [Mon, 29 Jan 2024 21:39:33 +0000 (22:39 +0100)] 
cd2nroff: fix duplicate output issue

Assisted-by: Jay Satiro
Fixes https://github.com/curl/curl-www/issues/321
Closes #12818

18 months agolib: error out on multissl + http3
Daniel Stenberg [Fri, 26 Jan 2024 15:59:33 +0000 (16:59 +0100)] 
lib: error out on multissl + http3

Since the QUIC/h3 code has no knowledge or handling of multissl it might
bring unintended consequences if we allow it.

configure, cmake and curl_setup.h all now reject this combination.

Assisted-by: Viktor Szakats
Assisted-by: Gisle Vanem
Ref: #12806
Closes #12807

18 months agoOS400: sync ILE/RPG binding
Patrick Monnerat [Mon, 29 Jan 2024 11:10:17 +0000 (12:10 +0100)] 
OS400: sync ILE/RPG binding

Also do not force git CRLF line endings on *.cmd files for OS400.

Closes #12815

18 months agobuild: delete/replace 3 more clang warning pragmas
Viktor Szakats [Sun, 28 Jan 2024 00:06:37 +0000 (00:06 +0000)] 
build: delete/replace 3 more clang warning pragmas

- tool_msgs: delete redundant `-Wformat-nonliteral` suppression pragma.

- whitespace formatting in `mprintf.h`, lib518, lib537.

- lib518: fix wrong variable in `sizeof()`.

- lib518: bump variables to `rlim_t`.
  Follow-up to e2b394106d543c4615a60795b7fdce04bd4e5090 #1469

- lib518: sync error message with lib537
  Follow-up to 365322b8bcf9efb6a361473d227b70f2032212ce

- lib518, lib537: replace `-Wformat-nonliteral` suppression pragmas
  by reworking test code.

Follow-up to 5b286c250829e06a135a6ba998e80beb7f43a734 #12812
Follow-up to aee4ebe59161d0a5281743f96e7738ad97fe1cd4 #12803
Follow-up to 09230127589eccc7e01c1a7217787ef8e64f3328 #12540
Follow-up to 3829759bd042c03225ae862062560f568ba1a231 #12489

Reviewed-by: Daniel Stenberg
Closes #12814

18 months agocmake: freshen up docs/INSTALL.cmake
Richard Levitte [Wed, 24 Jan 2024 12:07:00 +0000 (13:07 +0100)] 
cmake: freshen up docs/INSTALL.cmake

- Turn docs/INSTALL.cmake into a proper markdown file,
  docs/INSTALL-CMAKE.md
- Move things around to divide the description into configuration,
  building and installing sections
- Mention the more modern cmake options to configure, build and install,
  but also retain the older variants as fallbacks

Closes #12772

18 months agobuild: delete/replace clang warning pragmas
Viktor Szakats [Sat, 27 Jan 2024 17:40:38 +0000 (17:40 +0000)] 
build: delete/replace clang warning pragmas

- delete redundant warning suppressions for `-Wformat-nonliteral`.
  This now relies on `CURL_PRINTF()` and it's theoratically possible
  that this macro isn't active but the warning is. We're ignoring this
  as a corner-case here.

- replace two pragmas with code changes to avoid the warnings.

Follow-up to aee4ebe59161d0a5281743f96e7738ad97fe1cd4 #12803
Follow-up to 09230127589eccc7e01c1a7217787ef8e64f3328 #12540
Follow-up to 3829759bd042c03225ae862062560f568ba1a231 #12489

Reviewed-by: Daniel Stenberg
Closes #12812

18 months agoRELEASE-NOTES: synced
Daniel Stenberg [Sat, 27 Jan 2024 21:02:50 +0000 (22:02 +0100)] 
RELEASE-NOTES: synced

18 months agohttp: only act on 101 responses when they are HTTP/1.1
Daniel Stenberg [Sat, 27 Jan 2024 12:54:10 +0000 (13:54 +0100)] 
http: only act on 101 responses when they are HTTP/1.1

For 101 responses claiming to be any other protocol, bail out. This
would previously trigger an assert.

Add test 1704 to verify.

Bug: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=66184
Closes #12811

18 months ago_VARIABLES.md: add missing 'be' into the sentence
Scarlett McAllister [Sat, 27 Jan 2024 01:10:49 +0000 (21:10 -0400)] 
_VARIABLES.md: add missing 'be' into the sentence

Closes #12809

18 months agomqtt, remove remaining use of data->state.buffer
Stefan Eissing [Fri, 26 Jan 2024 08:21:37 +0000 (09:21 +0100)] 
mqtt, remove remaining use of data->state.buffer

Closes #12799

18 months agox509asn1: switch from malloc to dynbuf
Daniel Stenberg [Fri, 26 Jan 2024 14:02:19 +0000 (15:02 +0100)] 
x509asn1: switch from malloc to dynbuf

Closes #12808

18 months agox509asn1: make utf8asn1str() use dynbuf instead of malloc + memcpy
Daniel Stenberg [Fri, 26 Jan 2024 10:49:21 +0000 (11:49 +0100)] 
x509asn1: make utf8asn1str() use dynbuf instead of malloc + memcpy

Closes #12808

18 months agox509asn1: reduce malloc in Curl_extract_certinfo
Daniel Stenberg [Fri, 26 Jan 2024 10:30:25 +0000 (11:30 +0100)] 
x509asn1: reduce malloc in Curl_extract_certinfo

Using dynbuf

Closes #12808

18 months agoTHANKS: add Alexander Bartel and Brennan Kinney
Jay Satiro [Sat, 27 Jan 2024 07:07:05 +0000 (02:07 -0500)] 
THANKS: add Alexander Bartel and Brennan Kinney

They reported and investigated #10259 which was fixed by 7b2d98df.

Ref: https://github.com/curl/curl/issues/10259

18 months agokrb5: add prototype to silence clang warnings on mvsnprintf()
Daniel Stenberg [Fri, 26 Jan 2024 09:46:17 +0000 (10:46 +0100)] 
krb5: add prototype to silence clang warnings on mvsnprintf()

"error: format string is not a string literal"

Follow-up to 09230127589eccc7 which made the warning appear

Assisted-by: Viktor Szakats
Closes #12803

18 months agox509asn1: remove code for WANT_VERIFYHOST
Daniel Stenberg [Fri, 26 Jan 2024 10:00:21 +0000 (11:00 +0100)] 
x509asn1: remove code for WANT_VERIFYHOST

No code ever sets this anymore since we dropped gskit

Follow-up to 78d6232f1f326b9ab4d

Closes #12804