]> git.ipfire.org Git - thirdparty/curl.git/log
thirdparty/curl.git
4 weeks agoshow-headers.md: mention bold headers and --no-styled-output
Daniel Stenberg [Mon, 4 May 2026 15:19:04 +0000 (17:19 +0200)] 
show-headers.md: mention bold headers and --no-styled-output

Mentioned-by: Sollace on github
Fixes #21495
Closes #21497

4 weeks agosocks_gssapi: tiny Curl_SOCKS5_gssapi_negotiate cleanups
Daniel Stenberg [Mon, 4 May 2026 10:47:12 +0000 (12:47 +0200)] 
socks_gssapi: tiny Curl_SOCKS5_gssapi_negotiate cleanups

- use 'result' instead of 'code' for CURLcode variable
- use aprintf() instead of malloc + snprintf

Closes #21493

4 weeks agolibcurl-easy.md: minor clarifications
Daniel Stenberg [Mon, 4 May 2026 09:13:19 +0000 (11:13 +0200)] 
libcurl-easy.md: minor clarifications

Closes #21491

4 weeks agomime: simplify Curl_mime_prepare_headers
Daniel Stenberg [Mon, 4 May 2026 08:50:50 +0000 (10:50 +0200)] 
mime: simplify Curl_mime_prepare_headers

Make add_content_disposition() a sub function for that single purpose.

Closes #21490

4 weeks agotool_formparse: cleanups
Daniel Stenberg [Mon, 4 May 2026 08:28:10 +0000 (10:28 +0200)] 
tool_formparse: cleanups

- explain the get_param_part() function
- make it parse only blanks like the rest of this code
- check for commas explicitly when scanning multiple files (to help code
  understanding)

Closes #21489

4 weeks agogtls: simplify Curl_gtls_verifyserver
Daniel Stenberg [Mon, 4 May 2026 07:55:26 +0000 (09:55 +0200)] 
gtls: simplify Curl_gtls_verifyserver

Move peer certificate verification logic into gtls_verify_cert()

Closes #21488

4 weeks agosetopt: changing the proxy port is also a proxy change
Daniel Stenberg [Sat, 2 May 2026 15:18:00 +0000 (17:18 +0200)] 
setopt: changing the proxy port is also a proxy change

Test 1589 verifies.

Closes #21485

5 weeks agoGHA: bump actions and pips
dependabot[bot] [Fri, 1 May 2026 17:50:42 +0000 (17:50 +0000)] 
GHA: bump actions and pips

- update action `actions/cache` from 5.0.4 to 5.0.5
- update action `actions/upload-artifact` from 7.0.0 to 7.0.1
- update action `github/codeql-action` from 4.32.4 to 4.35.2
- update action `msys2/setup-msys2` from 2.31.0 to 2.31.1

- update pip `filelock` from 3.25.2 to 3.29.0
- update pip `impacket` to 0.13.0
- update pip `ruff` from 0.15.10 to 0.15.12

Closes #21483
Closes #21482

5 weeks agotool_formparse.c: fix two minor comment typos
Daniel Stenberg [Fri, 1 May 2026 09:28:30 +0000 (11:28 +0200)] 
tool_formparse.c: fix two minor comment typos

Pointed out by Copilot

Closes #21480

5 weeks agourl: simplify parseurlandfillconn
Daniel Stenberg [Fri, 1 May 2026 09:13:27 +0000 (11:13 +0200)] 
url: simplify parseurlandfillconn

Introduce two helper functions:

- hsts_upgrade()
- setup_hostname()

Closes #21479

5 weeks agoRELEASE-NOTES: synced
Daniel Stenberg [Fri, 1 May 2026 09:34:15 +0000 (11:34 +0200)] 
RELEASE-NOTES: synced

Also bump the curlver to tenative 8.20.1

5 weeks agoasyn-thrdd: fix result processing without wakeup socketpair
Stefan Eissing [Thu, 30 Apr 2026 14:53:02 +0000 (16:53 +0200)] 
asyn-thrdd: fix result processing without wakeup socketpair

When building curl 8.20.0 with socketpair disabled, there is no
wakeup socket and the resolve results are not processed.

This fix performs result processing in the absence of a wakeup
socket before checking the resolve result.

Closes #21476

5 weeks agouser-agent.md: mention double quotes too
Daniel Stenberg [Thu, 30 Apr 2026 20:50:27 +0000 (22:50 +0200)] 
user-agent.md: mention double quotes too

Reported-by: Jeremy Nicoll
Bug: https://curl.se/mail/archive-2026-04/0029.html
Closes #21477

5 weeks agotool_formparse: simplify get_param_part
Daniel Stenberg [Thu, 30 Apr 2026 12:51:47 +0000 (14:51 +0200)] 
tool_formparse: simplify get_param_part

Introduce a few sub functions to reduce complexity

Closes #21478

5 weeks agotidy-up: miscellaneous
Viktor Szakats [Wed, 29 Apr 2026 13:27:37 +0000 (15:27 +0200)] 
tidy-up: miscellaneous

- sha256: fix backend priority in comment.
- URLs: link to IETF URLs to the HTML document, to match others.
- VERSIONS.md: use unified date format for recent entries too.
  Ref: https://github.com/curl/curl-www/commit/ce5d32032f8d3d8601f3ef022bbca485020d1bb9
- GHA/labeler.yml: alpha-sort file masks in a label block.
- tests/server/mqttd: fix call arg list in a disabled function.
- tests/server/mqttd: fix comment.

Closes #21473

5 weeks agoGHA/curl-for-win: switch riscv job to debian:stable (testing broke)
Viktor Szakats [Thu, 30 Apr 2026 14:06:35 +0000 (16:06 +0200)] 
GHA/curl-for-win: switch riscv job to debian:stable (testing broke)

```
The following packages have unmet dependencies:
[...]
E: Unable to satisfy dependencies. Reached two conflicting assignments:
   1. musl-dev:amd64=1.2.5-3+b1 is selected for install
   2. musl-dev:amd64 is not selected for install because:
      1. musl-dev:riscv64=1.2.5-3 is selected for install
      2. musl-dev:amd64 Breaks musl-dev:riscv64 (!= 1.2.5-3+b1)
```
Ref: https://github.com/curl/curl/actions/runs/25168601672/job/73785600341#step:3:154

Closes #21475

5 weeks agomqtt: validate PINGRESP and DISCONNECT have remaining_length == 0
Raymond Steen [Wed, 29 Apr 2026 07:27:39 +0000 (10:27 +0300)] 
mqtt: validate PINGRESP and DISCONNECT have remaining_length == 0

Per MQTT 3.1.1 sections 3.13.1 and 3.14.1, PINGRESP and DISCONNECT fixed
headers must have remaining_length set to zero. The previous code
dispatched to mqtt->nextstate based on the queued state alone without
validating remaining_length for these no-payload packet types, allowing
a malicious broker to send a PINGRESP with non-zero remaining_length
whose trailing bytes would be interpreted as the payload of whatever
message type was queued (CONNACK, SUBACK, etc.).

The exploitation path turned out to be narrow — curl sends data to the
server the user chose to talk to — but the spec violation and the
resulting protocol-state error are real. Reject the malformed packets
with CURLE_WEIRD_SERVER_REPLY before state dispatch.

Reported-by: Raymond Steen <raymond@vortiqxconsilium.com>
Found by VORTIQ-X VXF Framework
Bug: https://hackerone.com/reports/3702718

Signed-off-by: Raymond Steen <raymond@vortiqxconsilium.com>
Closes #21465

5 weeks agoGHA/linux: work around Linuxbrew install failure
Viktor Szakats [Wed, 29 Apr 2026 19:51:43 +0000 (21:51 +0200)] 
GHA/linux: work around Linuxbrew install failure

Root cause unknown, it appeared today without any local change:
```
==> Installing dependencies for libssh2: openssl@3 and zlib-ng-compat
==> Installing libssh2 dependency: openssl@3
==> Pouring openssl@3--3.6.2.x86_64_linux.bottle.tar.gz
Error: A `brew install openssl@4 libssh2 libngtcp2 libnghttp3 c-ares` process has already locked /home/linuxbrew/.linuxbrew/Cellar/openssl@4.
Please wait for it to finish or terminate it to continue.
Error: Process completed with exit code 1.
```
Ref: https://github.com/curl/curl/actions/runs/25129061781/job/73650161844?pr=21468#step:2:407

Last known good run: https://github.com/curl/curl/actions/runs/25038989485/job/73337289504

Ref: 1fbffe7f08f0d551038520b569b817f58084f77b #21379

Closes #21469

5 weeks agoRELEASE-NOTES: synced curl-8_20_0
Daniel Stenberg [Wed, 29 Apr 2026 05:45:21 +0000 (07:45 +0200)] 
RELEASE-NOTES: synced

curl 8.20.0 release

plus VERSIONS.md update

5 weeks agoTHANKS: names from the 8.20.0 release
Daniel Stenberg [Wed, 29 Apr 2026 05:45:21 +0000 (07:45 +0200)] 
THANKS: names from the 8.20.0 release

5 weeks agotidy-up: a cmake warning message and a variable name
Viktor Szakats [Mon, 27 Apr 2026 20:21:27 +0000 (22:21 +0200)] 
tidy-up: a cmake warning message and a variable name

Spotted by GitHub Code Quality

Closes #21462

5 weeks agobuild: stop building and installing `runtests.1` and `testcurl.1`
Viktor Szakats [Mon, 27 Apr 2026 15:51:16 +0000 (17:51 +0200)] 
build: stop building and installing `runtests.1` and `testcurl.1`

The corresponding tools are never installed, and both are dev tools.
Refer to their `.md` originals instead.

Also markdownify text in lines nearby.

Ref: https://github.com/curl/curl/pull/21460#issuecomment-4328258450

Closes #21461

5 weeks agocmake: do not install shell completions when `BUILD_CURL_EXE=OFF`
Viktor Szakats [Mon, 27 Apr 2026 15:12:42 +0000 (17:12 +0200)] 
cmake: do not install shell completions when `BUILD_CURL_EXE=OFF`

Follow-up to 74542c1f4bfea75f92562075370fd839891cc440 #21459

Closes #21460

5 weeks agocmake: do not install `wcurl` when `BUILD_CURL_EXE=OFF`
Viktor Szakats [Mon, 27 Apr 2026 15:00:41 +0000 (17:00 +0200)] 
cmake: do not install `wcurl` when `BUILD_CURL_EXE=OFF`

Skip installing `wcurl.1` also.

Reported-by: Daniel Schulte
Fixes #21458
Follow-up to 23bed347b38922779382599f8b72c4d762add7bd #17035

Closes #21459

5 weeks agoGHA/checksrc: switch to zizmor `--persona` option
Viktor Szakats [Mon, 27 Apr 2026 12:55:40 +0000 (14:55 +0200)] 
GHA/checksrc: switch to zizmor `--persona` option

Closes #21457

5 weeks agotidy-up: whitespace
Viktor Szakats [Wed, 15 Apr 2026 21:57:35 +0000 (23:57 +0200)] 
tidy-up: whitespace

Closes #21456

5 weeks agowrite-out.md: minor language fix
Daniel Stenberg [Mon, 27 Apr 2026 09:41:34 +0000 (11:41 +0200)] 
write-out.md: minor language fix

Pointed out by Copilot

Closes #21455

5 weeks agotool_dirhie: fix to create drive-relative directory
Viktor Szakats [Sun, 26 Apr 2026 11:38:47 +0000 (13:38 +0200)] 
tool_dirhie: fix to create drive-relative directory

Fix to create the top directory `foo` when specified as
`X:foo\bar\filename`, on Windows and MS-DOS. Add test to verify.

Caught by Codex Security

Follow-up to 787ee935acd5867bdac836b2043b6095eed2c29e #16566

Closes #21449

5 weeks agotunits: initialize global `tool_stderr`
Viktor Szakats [Mon, 27 Apr 2026 08:49:45 +0000 (10:49 +0200)] 
tunits: initialize global `tool_stderr`

To avoid difficult to track down crashes when a tested function ends up
outputing a message via `errorf()`, `warnf()` or siblings.

Cherry-picked from #21449

Closes #21454

5 weeks agoruntests: fix linefeeds in log messages
Viktor Szakats [Sun, 26 Apr 2026 23:25:37 +0000 (01:25 +0200)] 
runtests: fix linefeeds in log messages

Cherry-picked from #21449

Closes #21452

5 weeks agounits: tidy up dynbuf init
Viktor Szakats [Sun, 26 Apr 2026 20:06:59 +0000 (22:06 +0200)] 
units: tidy up dynbuf init

Init dynbuf after global init to bring closer to use, improve
readability and sync test sources.

Closes #21451

5 weeks agosetopt: clear proxy auth properties when switching
Daniel Stenberg [Mon, 27 Apr 2026 07:14:51 +0000 (09:14 +0200)] 
setopt: clear proxy auth properties when switching

Verify with test 1588

Closes #21453

5 weeks agodocs/cmdline-opts/write-out.md: minor language edit
Daniel Stenberg [Sun, 26 Apr 2026 14:42:31 +0000 (16:42 +0200)] 
docs/cmdline-opts/write-out.md: minor language edit

5 weeks agodocs/cmdline-opts/write-out.md: tls_earlydata was adeded in 8.13.0
Daniel Stenberg [Sun, 26 Apr 2026 14:35:33 +0000 (16:35 +0200)] 
docs/cmdline-opts/write-out.md: tls_earlydata was adeded in 8.13.0

5 weeks agowrite-out.md: fix minor language mistake
Daniel Stenberg [Sun, 26 Apr 2026 14:18:12 +0000 (16:18 +0200)] 
write-out.md: fix minor language mistake

Closes #21450

6 weeks agoKNOWN_BUGS.md: Windows stdin relay accepts unauthenticated local connections
Daniel Stenberg [Fri, 24 Apr 2026 06:49:03 +0000 (08:49 +0200)] 
KNOWN_BUGS.md: Windows stdin relay accepts unauthenticated local connections

A windows developer could have a look at this.

Closes #21433

6 weeks agosectrust: fail on missing OCSP stapling
Stefan Eissing [Sat, 25 Apr 2026 08:34:06 +0000 (10:34 +0200)] 
sectrust: fail on missing OCSP stapling

When using Apple SecTrust, requiring the server to send
an OCSP response and does not, fail correctly.

Reported-by: Carlos Carrillo
Closes #21444

6 weeks agotest_22_httpsrr: avoid class name clash with `test_21_resolve`
Viktor Szakats [Sat, 25 Apr 2026 12:08:12 +0000 (14:08 +0200)] 
test_22_httpsrr: avoid class name clash with `test_21_resolve`

Spotted by GitHub Code Quality

Closes #21448

6 weeks agotidy-up: git options, ECH, HTTP/3 documentation
Viktor Szakats [Sat, 25 Apr 2026 10:59:55 +0000 (12:59 +0200)] 
tidy-up: git options, ECH, HTTP/3 documentation

- prefer `--branch` over `-b`, where missing.
- add `--depth 1` where missing.
- sync option order between docs and GHA.
- bump quiche and rustls-ffi versions in documentation.
- ECH.md: update for OpenSSL 4.

Closes #21447

6 weeks agotest_22_httpsrr: drop duplicate skipif conditions
Viktor Szakats [Sat, 25 Apr 2026 10:42:56 +0000 (12:42 +0200)] 
test_22_httpsrr: drop duplicate skipif conditions

Already set at class-level.

Spotted by GitHub Code Quality

Closes #21446

6 weeks agopytest: drop unused imports
Viktor Szakats [Sat, 25 Apr 2026 10:05:32 +0000 (12:05 +0200)] 
pytest: drop unused imports

Spotted by GitHub Code Quality

Closes #21445

6 weeks agoRELEASE-NOTES: synced
Daniel Stenberg [Sat, 25 Apr 2026 09:37:19 +0000 (11:37 +0200)] 
RELEASE-NOTES: synced

6 weeks agoRELEASE-NOTES: add missing contributors
Daniel Stenberg [Sat, 25 Apr 2026 09:28:08 +0000 (11:28 +0200)] 
RELEASE-NOTES: add missing contributors

From security reports etc

6 weeks agosshserver.pl: tidy up around `AllowUsers` setup
Viktor Szakats [Fri, 24 Apr 2026 20:49:10 +0000 (22:49 +0200)] 
sshserver.pl: tidy up around `AllowUsers` setup

- drop redundant space-to-`?` replacement.
- add parentheses to silence code checker.
- tidy up comments.

Follow-up to e53523fef07894991c69d907a7c7794c7ada4ff4 #14859

Closes #21442

6 weeks agoGHA/windows: bump stunnel to 5.78
Viktor Szakats [Fri, 24 Apr 2026 22:18:54 +0000 (00:18 +0200)] 
GHA/windows: bump stunnel to 5.78

Closes #21443

6 weeks agoconnect: fix typo on error message [ci skip]
Viktor Szakats [Fri, 24 Apr 2026 20:25:07 +0000 (22:25 +0200)] 
connect: fix typo on error message [ci skip]

Pointed out by GitHub Code Quality

6 weeks agosetup connection filter: mark as setup
Stefan Eissing [Fri, 24 Apr 2026 09:34:13 +0000 (11:34 +0200)] 
setup connection filter: mark as setup

Add CF_TYPE_SETUP to the setup connection filter so that it is
removed and destroyed after the connection has been established.

Closes #21437

6 weeks agosocks filter: pass operation parameters
Stefan Eissing [Fri, 24 Apr 2026 08:38:22 +0000 (10:38 +0200)] 
socks filter: pass operation parameters

Pass all operations parameters to a SOCKS filter at creation
time, not relying on "global" connectdata values.

Eliminate modifications to `conn->ip_version` when local resolving
for SOCKS4.

Do not retrieve the socket for GSSAPI blocking calls from connectdata,
but from the filters "below" the SOCKS one.

Closes #21436

6 weeks agombedtls: remove failf() call with first argument as NULL
Daniel Stenberg [Fri, 24 Apr 2026 15:23:05 +0000 (17:23 +0200)] 
mbedtls: remove failf() call with first argument as NULL

failf() needs an easy handle to work. This change removes the call since
there is normnally nowhere to show the output if init fails.

Bonus: improve language in an infof() call

Spotted by Copilot

Closes #21441

6 weeks agosshserver.pl: add option to enable KEX algorithms in sshd
Viktor Szakats [Fri, 24 Apr 2026 11:31:53 +0000 (13:31 +0200)] 
sshserver.pl: add option to enable KEX algorithms in sshd

Necessary when the libssh2/libssh client library does not support KEX
algos offered by default by the OpenSSH server. E.g. libssh2 with WinCNG
combined with OpenSSH 10+.

Also: use this option in GHA/windows.

Follow-up to 3b8bb1a86afbaf967163bf6709b1825e11655bf5 #21219
Follow-up to c98d0a2e9aa7ec87d16af8b056e6e7c0d614feec #21220

Closes #21438

6 weeks agombedtls: cleanup more without care for 'initialized'
Daniel Stenberg [Fri, 24 Apr 2026 14:27:34 +0000 (16:27 +0200)] 
mbedtls: cleanup more without care for 'initialized'

Several mbedTLS resources (entropy/CTR-DRBG, CA/client certs, keys, CRL)
are initialized and may allocate memory before initialized is set, and
must still be cleaned up.

Follow-up to 1c4813c769ea65c128c067004

Caught by Codex Security
Closes #21440

6 weeks agoGHA/windows: disable ssh-ed25519 hostkey in libssh2-wincng jobs
Viktor Szakats [Fri, 24 Apr 2026 12:38:50 +0000 (14:38 +0200)] 
GHA/windows: disable ssh-ed25519 hostkey in libssh2-wincng jobs

libssh2 built with the WinCNG crypto backend does not support ed25519
hostkeys.

Ref: #21438
Follow-up to acda4eae5eeb24a7b0ab9ec7b1783d74eb43687c #21223

Closes #21439

6 weeks agoresolve: pass bool for proxy resolves
Stefan Eissing [Thu, 23 Apr 2026 14:26:13 +0000 (16:26 +0200)] 
resolve: pass bool for proxy resolves

So that CURLcode failure is correct and not figured out later via
`conn->bits.proxy`. Add the flag to the async struct.

`for_proxy` is figured out by the caller of Curl_resolv() when it
figures out which host/proxy name it wants the addresses for.

Remove CONN_IS_PROXIED macro as no longer needed.

Closes #21423

6 weeks agochecksrc: add missing semicolon, fix `IFDEFSINGLE` capture group
Viktor Szakats [Fri, 24 Apr 2026 08:07:40 +0000 (10:07 +0200)] 
checksrc: add missing semicolon, fix `IFDEFSINGLE` capture group

Pointed out by GitHub Code Quality

Closes #21435

6 weeks agotests: drop support for the hex="yes" option in getpart
Daniel Stenberg [Thu, 23 Apr 2026 20:54:01 +0000 (22:54 +0200)] 
tests: drop support for the hex="yes" option in getpart

The remaining datacheck sections using this for MQTT tests were not
actually used anyway!

Closes #21428

6 weeks agochecksrc: add missing items to warnings hash, alpha-sort
Viktor Szakats [Fri, 24 Apr 2026 07:53:21 +0000 (09:53 +0200)] 
checksrc: add missing items to warnings hash, alpha-sort

Closes #21434

6 weeks agochecksrc: fix code quality findings
Viktor Szakats [Thu, 23 Apr 2026 23:24:32 +0000 (01:24 +0200)] 
checksrc: fix code quality findings

- fix counting errors. Update test1185 results accordingly.
- fix an error message.
- tidy up regexp syntax.

Pointed out by GitHub Code Quality

Closes #21429

6 weeks agodoh: fix #ifdef name
Daniel Stenberg [Fri, 24 Apr 2026 05:57:14 +0000 (07:57 +0200)] 
doh: fix #ifdef name

Spotted by Copilot

Closes #21431

6 weeks agohostip: init the curl_jmpenv_lock appropriately
Daniel Stenberg [Fri, 24 Apr 2026 06:11:10 +0000 (08:11 +0200)] 
hostip: init the curl_jmpenv_lock appropriately

A zero-initialized static value is not guaranteed to be a valid mutex on
all POSIX implementations

Spotted by Codex Security

Closes #21432

6 weeks agourldata.h: fix typo and lingering backtick
Daniel Stenberg [Fri, 24 Apr 2026 05:55:00 +0000 (07:55 +0200)] 
urldata.h: fix typo and lingering backtick

Spotted by Copilot

Closes #21430

6 weeks agorustls: fix memory leak on repeated SSLKEYLOGFILE fails
Daniel Stenberg [Thu, 23 Apr 2026 19:49:50 +0000 (21:49 +0200)] 
rustls: fix memory leak on repeated SSLKEYLOGFILE fails

Before this fix, Curl_tls_keylog_open() assigned the environment
variable result to a global keylog_file_name without freeing any prior
allocation. If the file cannot be opened (e.g., permission error)
keylog_file_fp stays NULL, so subsequent calls to Curl_tls_keylog_open
will overwrite keylog_file_name and leak the previous allocation.

Spotted by Codex Security

Closes #21427

6 weeks agochecksrc.pl: delete stray commas
Viktor Szakats [Thu, 23 Apr 2026 18:57:44 +0000 (20:57 +0200)] 
checksrc.pl: delete stray commas

Closes #21426

6 weeks agoci: update RUSTLS_VERSION 0.15.2 -> 0.15.3
Daniel McCarney [Thu, 23 Apr 2026 15:20:42 +0000 (11:20 -0400)] 
ci: update RUSTLS_VERSION 0.15.2 -> 0.15.3

Closes #21424

6 weeks agodoh: remove conn->bits.doh
Stefan Eissing [Thu, 23 Apr 2026 12:43:11 +0000 (14:43 +0200)] 
doh: remove conn->bits.doh

Since we have a new struct instance for each async operation now and
async operation may happen in parallel, remove the connection bit
indicating doh is in progress.

Closes #21422

6 weeks agomulti: enhance pending handles fairness
Stefan Eissing [Wed, 22 Apr 2026 13:00:14 +0000 (15:00 +0200)] 
multi: enhance pending handles fairness

When trying to connect a pending transfer, remember the `mid` that was
last reactivated and start looking for future pending handles from the
last one forward through the pending bitset.

Background: when many pending handles exist, iterating the bitset always
from the start may become unfair to transfers that were assigned higher
`mid` values.

Fixes #21396
Reported-by: Juan Belón
Closes #21412

6 weeks agovtls: fix comment typos and tidy up a type
Viktor Szakats [Thu, 23 Apr 2026 09:55:59 +0000 (11:55 +0200)] 
vtls: fix comment typos and tidy up a type

Pointed out by GitHub Code Quality

Closes #21421

6 weeks agoCI: set `DO_NOT_TRACK=1`
Viktor Szakats [Thu, 23 Apr 2026 08:17:13 +0000 (10:17 +0200)] 
CI: set `DO_NOT_TRACK=1`

Closes #21420

6 weeks agoGHA/appveyor-status: disable `gh` tool telemetry
Viktor Szakats [Thu, 23 Apr 2026 08:11:16 +0000 (10:11 +0200)] 
GHA/appveyor-status: disable `gh` tool telemetry

Ref: https://cli.github.com/telemetry

Closes #21418

6 weeks agovtls: log when key logging is enabled.
Yedaya Katsman [Tue, 2 Dec 2025 16:15:47 +0000 (18:15 +0200)] 
vtls: log when key logging is enabled.

If built with LibreSSL, also warn that it only works for TLS <= 1.2

Inspired-by: Viktor Szakats
Closes #19814

6 weeks agourlapi: simplify urlget_url
Daniel Stenberg [Wed, 22 Apr 2026 21:37:57 +0000 (23:37 +0200)] 
urlapi: simplify urlget_url

- unify the query and fragment separator logic
- read the bitflags directly instead of via a temp variable
- narrow the scope of a few variables

Closes #21417

6 weeks agoGHA: deprioritize Azure Ubuntu mirror
Viktor Szakats [Wed, 22 Apr 2026 16:43:23 +0000 (18:43 +0200)] 
GHA: deprioritize Azure Ubuntu mirror

Due to year-long unreliability.

The default Ubuntu mirror works as fast as the Azure one when it's
working at its normal speed. And has HTTPS.

Also:
- replac the retry hack that turn out to not solve the problem.
- add timeouts to each download step to catch slowness early.

Follow-up to a5838847c4395cdf043d9a833f38d5ba0a704ca1 #21181
Follow-up to 5172ba5475cffc525c2338dfa63f818e11e80a42 #21107

Closes #21414

6 weeks agoasyn-thrdd: drop redundant `result` check
Viktor Szakats [Wed, 22 Apr 2026 15:34:57 +0000 (17:34 +0200)] 
asyn-thrdd: drop redundant `result` check

Pointed out by GitHub Code Quality

Closes #21415

6 weeks agoGHA: delete all apt sources except `ubuntu.sources`
Viktor Szakats [Wed, 22 Apr 2026 16:03:32 +0000 (18:03 +0200)] 
GHA: delete all apt sources except `ubuntu.sources`

GitHub runners are getting new 3rd-party sources frequntly now, last
week `docker.list`, this week: `google-chrome.sources`. To avoid
playing catch up, allowlist the only one we use: `ubuntu.sources`. If
this is renamed, CI would break. Let's hope this happens much less
often than new sources.

Bug: https://github.com/curl/curl/pull/21414#issuecomment-4297788640

Follow-up to 3e0e2cc1ab6f3f44c7d35e84256858edc2ef73f5 #21344

Closes #21416

6 weeks agoasyn-thrdd: minor without-IPv6 fixes
Daniel Stenberg [Wed, 22 Apr 2026 13:05:57 +0000 (15:05 +0200)] 
asyn-thrdd: minor without-IPv6 fixes

Pointed out by Copilot

Closes #21413

6 weeks agodocs: clarify retry-max-time timing
Dio Putra [Wed, 22 Apr 2026 10:36:36 +0000 (17:36 +0700)] 
docs: clarify retry-max-time timing

Closes #21411

6 weeks agoDockerfile: update debian:bookworm-slim Docker digest to f9c6a2f
renovate[bot] [Wed, 22 Apr 2026 02:54:52 +0000 (02:54 +0000)] 
Dockerfile: update debian:bookworm-slim Docker digest to f9c6a2f

Closes #21406

6 weeks agoappveyor: bump to OpenSSL 3.6
Viktor Szakats [Tue, 21 Apr 2026 22:24:55 +0000 (00:24 +0200)] 
appveyor: bump to OpenSSL 3.6

Closes #21405

6 weeks agoRELEASE-NOTES: synced
Daniel Stenberg [Wed, 22 Apr 2026 05:53:54 +0000 (07:53 +0200)] 
RELEASE-NOTES: synced

6 weeks agotool_operate: reset the upload glob counter for next URL
Daniel Stenberg [Tue, 21 Apr 2026 15:51:26 +0000 (17:51 +0200)] 
tool_operate: reset the upload glob counter for next URL

Fixes #21402

Adjust test 2012 and 2013 accordingly

Closes #21403

6 weeks agotool_operate: keep the filename for upload globbing
Daniel Stenberg [Tue, 21 Apr 2026 15:14:51 +0000 (17:14 +0200)] 
tool_operate: keep the filename for upload globbing

Follow-up to 19695e815c51f8830fc54255

Verify with test 2012 and 2013

Closes #21401

6 weeks agoruntests: allow %EMPTY in <stdout> to verify no output
Daniel Stenberg [Tue, 21 Apr 2026 15:15:05 +0000 (17:15 +0200)] 
runtests: allow %EMPTY in <stdout> to verify no output

6 weeks agoasync-ares: fix query counter handling
Stefan Eissing [Tue, 21 Apr 2026 13:06:46 +0000 (15:06 +0200)] 
async-ares: fix query counter handling

When starting an c-ares query, the provided callback may be invoked
right away, leading to a decrement of `queries_ongoing`. Increment
the counter *before* call c-ares. Otherwise, the `async->done` bit
is not properly set.

Closes #21399

6 weeks agolib557: add tests with flags AND conversion specifier
Daniel Stenberg [Tue, 21 Apr 2026 12:49:32 +0000 (14:49 +0200)] 
lib557: add tests with flags AND conversion specifier

Remove superfluous and never-built test code for systems with 16-bit and
64-bit ints and 16-bit longs, as we don't know any such.

6 weeks agomprintf: OR the flags
Daniel Stenberg [Tue, 21 Apr 2026 12:33:27 +0000 (14:33 +0200)] 
mprintf: OR the flags

As 'flags' may already have been set to something when
parse_conversion() is called, make sure to only OR the new flags.

Follow-up to 4e0bfd8cf73603697ddad5d25e94

Closes #21398

6 weeks agomisc: fix code quality findings
Viktor Szakats [Tue, 21 Apr 2026 08:14:16 +0000 (10:14 +0200)] 
misc: fix code quality findings

- httpsrr: drop redundant checks.
  Follow-up to 809dda3a37363160d4bf5ea2dafa0bcb8188a3f0 #21354
- httpsrr.h: drop obsolete comment.
  Follow-up to 2b3dfb4ad47ec05efad9af930c47968a49916999 #21175
- ws: drop redundant check in `curl_ws_start_frame()`.
  Follow-up to 37cecfc7b91118f116cf16af8f50a18b15d00d51 #17683
- ws: fix typo in comment.
- tool_operate: fix VMS build. (broken since 2019-07-20, v7.66.0)
  Follow-up to b88940850002a3f1c25bc6488b95ad30eb80d696 #3804

Pointed out by Copilot Code Quality

Closes #21393

6 weeks agoparsedate: refactor
Daniel Stenberg [Tue, 21 Apr 2026 07:19:53 +0000 (09:19 +0200)] 
parsedate: refactor

- introduce 'struct when' to hold the parser result
- initwhen() initializes a 'struct when'
- datestring() parses strings
- datenum() parses numbers
- datecheck() does some final checks
- tzadjust() adds the time zone offset
- convert math to 64 bit, squeeze into time_t only in the last step,
  mktimet() does the time_t storing

Closes #21394

6 weeks agowolfssl: fix `-Wmissing-prototypes`
Viktor Szakats [Tue, 21 Apr 2026 07:46:45 +0000 (09:46 +0200)] 
wolfssl: fix `-Wmissing-prototypes`

Seen with unity, H3, wolfssl with `HAVE_EX_DATA`.

Fixing:
```
lib/vtls/wolfssl.c:412:10: error: no previous prototype for function 'Curl_wssl_cache_session' [-Wmissing-prototypes]
  412 | CURLcode Curl_wssl_cache_session(struct Curl_cfilter *cf,
      |          ^
lib/vtls/wolfssl.c:412:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
  412 | CURLcode Curl_wssl_cache_session(struct Curl_cfilter *cf,
      | ^
      | static
1 error generated.
```

Follow-up to cc5c1553fbdb8c1391d0cf81134583ee32da64d4 #19852

Closes #21392

6 weeks agotool_operate: split create_single into smaller sub functions
Daniel Stenberg [Mon, 20 Apr 2026 14:55:38 +0000 (16:55 +0200)] 
tool_operate: split create_single into smaller sub functions

Reduces complexity from 58 => 32.

Closes #21389

6 weeks agomprintf: simplify parsefmt
Daniel Stenberg [Mon, 20 Apr 2026 22:08:39 +0000 (00:08 +0200)] 
mprintf: simplify parsefmt

- split out parse_flags() and parse_conversion() to reduce complexity
  from 57 to 30.

Closes #21391

6 weeks agolib: minor comment typos
Daniel Stenberg [Mon, 20 Apr 2026 20:30:31 +0000 (22:30 +0200)] 
lib: minor comment typos

Closes #21388

6 weeks agoHappy Eyeballs: add resolution time delay
Stefan Eissing [Fri, 17 Apr 2026 08:26:25 +0000 (10:26 +0200)] 
Happy Eyeballs: add resolution time delay

HEv3 describes conditions on when first connect attempts shall be
started.
https://www.ietf.org/archive/id/draft-ietf-happy-happyeyeballs-v3-01.html
Chapter 4.2

libcurl now waits 50ms for AAAA and HTTPS results (when requested) to
return before continuing with the connect.

Added HTTPS-RR to the "was resolved" information info message. Changed
logging of HTTPS-RR to a one-liner with RFC 9460 like formatting. This
way the user can see if/what was resolved and used in connecting.

Closes #21354

6 weeks agobuild: link `bcrypt.lib` via vcxproj files
Viktor Szakats [Mon, 20 Apr 2026 14:02:14 +0000 (16:02 +0200)] 
build: link `bcrypt.lib` via vcxproj files

And drop pragma from `rand.c`.

Closes #21386

6 weeks agolib: fix typos in comments
Daniel Stenberg [Mon, 20 Apr 2026 12:36:58 +0000 (14:36 +0200)] 
lib: fix typos in comments

Closes #21385

6 weeks agomime: only allow 40 levels of calls
Daniel Stenberg [Mon, 20 Apr 2026 08:28:28 +0000 (10:28 +0200)] 
mime: only allow 40 levels of calls

To avoid problems when doing insane things.

Closes #21384

6 weeks agovtls_scache: check reentrancy
Stefan Eissing [Mon, 20 Apr 2026 08:21:43 +0000 (10:21 +0200)] 
vtls_scache: check reentrancy

Track lock status of session cache, add DEBUGASSERT()s for proper
calling sequences. Add check of lock status.

Use lock status check to prevent reentry of import/export calls.
Deny such calls with CURLE_RECURSIVE_API_CALL.

Closes #21383

6 weeks agoGHA: bump test minimums (more)
Viktor Szakats [Mon, 20 Apr 2026 07:44:24 +0000 (09:44 +0200)] 
GHA: bump test minimums (more)

Follow-up to 701a8319ec96c0b73c39e16c5db68dd758419c2 #21353

Closes #21382

6 weeks agoGHA: use more OpenSSL 4, enable ECH in more jobs
Viktor Szakats [Sun, 19 Apr 2026 22:49:06 +0000 (00:49 +0200)] 
GHA: use more OpenSSL 4, enable ECH in more jobs

for Linux and macOS.

Closes #21379

6 weeks agoopenssl: fix unused variable warnings in !verbose builds
Viktor Szakats [Sun, 19 Apr 2026 23:12:34 +0000 (01:12 +0200)] 
openssl: fix unused variable warnings in !verbose builds

Also fix clang-tidy `readability-redundant-control-flow`.

```
lib/vtls/openssl.c:4055:46: error: unused parameter 'reason' [-Wunused-parameter]
 4055 |                                          int reason)
      |                                              ^
lib/vtls/openssl.c:4279:19: error: variable 'status' set but not used [-Wunused-but-set-variable]
 4279 |       const char *status = NULL;
      |                   ^
```
Ref: https://github.com/curl/curl/actions/runs/24641388439/job/72045859306?pr=21379

```
lib/vtls/openssl.c:4092:7: error: Value stored to 'rv' is never read [clang-analyzer-deadcode.DeadStores]
 4092 |       rv = SSL_ech_get1_status(ssl, &inner, &outer);
      |       ^    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/vtls/openssl.c:4092:7: note: Value stored to 'rv' is never read
 4092 |       rv = SSL_ech_get1_status(ssl, &inner, &outer);
      |       ^    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/vtls/openssl.c:4112:3: error: redundant return statement at the end of a function with a void return type [readability-redundant-control-flow]
 4111 | #endif
      | ~~~~~~
 4112 |   return;
      |   ^~~~~~~
 4113 | }
```
Ref: https://github.com/curl/curl/actions/runs/24642154148/job/72047919525?pr=21379#step:42:186

Cherry-picked from #21379

Closes #21380

6 weeks agotests: avoid infinite recursion for `make check`
Dag-Erling Smørgrav [Sun, 19 Apr 2026 16:14:44 +0000 (18:14 +0200)] 
tests: avoid infinite recursion for `make check`

The combination of a misspelled directory name and failing to check the
result of cd leads to infinite recursion as `make check` simply invokes
itself over and over.

Follow-up to 00887aee8ca0efe0b40fa41b2a36e2d853d49b57 #18079
Closes #21378

6 weeks agolib1960: fix test failure
Dag-Erling Smørgrav [Sun, 19 Apr 2026 16:09:29 +0000 (18:09 +0200)] 
lib1960: fix test failure

On platforms where struct sockaddr has a length field, the current code
leaves it uninitialized, resulting in a test failure when valgrind is
used.

Closes #21377