]> git.ipfire.org Git - thirdparty/curl.git/log
thirdparty/curl.git
11 hours agoruntests: improve XML prolog check, enable `-w` permanently, fix two tests master
Viktor Szakats [Sun, 14 Dec 2025 08:42:59 +0000 (09:42 +0100)] 
runtests: improve XML prolog check, enable `-w` permanently, fix two tests

To really verify the presence of the XML prolog, also in CI.

- move the prolog check from `loadtest` to `checktest`.
  (load did a soft error, silently skipping the test instead of failing)
- runtests: enable `-w` functionality permanently for all test targets,
  drop the option. It has no measurable performance impact.
- test 798, 1665: add XML prolog.
  Follow-up to f0d277cb0e3712ae4edf8f51822ffa99e9b3ec54

Follow-up to b5ea0736bbeeae717925d8eccbdb15057d8e88e9 #19946
Follow-up to 904e7ecb66519951681377758fe6b07dde28ce36 #19347

Closes #19970

11 hours agosynctime: tidy up, make it work on all platforms
Viktor Szakats [Sun, 14 Dec 2025 07:12:01 +0000 (08:12 +0100)] 
synctime: tidy up, make it work on all platforms

The `--synctime` option remains non-UWP-Windows-specific.

Also:
- replace default URL with `ntp.org`.
- delete unused example URL.

Closes #19965

14 hours agoGHA: update actions
renovate[bot] [Sat, 13 Dec 2025 19:51:34 +0000 (19:51 +0000)] 
GHA: update actions

- update actions/checkout action to v6.0.1
- update github/codeql-action action to v4.31.8
- update msys2/setup-msys2 action to v2.30.0

Closes #19962
Closes #19967
Closes #19968

14 hours agorenovate: try to disable GitHub Actions updates differently
Viktor Szakats [Sun, 14 Dec 2025 08:10:58 +0000 (09:10 +0100)] 
renovate: try to disable GitHub Actions updates differently

Follow-up to a9b1be555a26aeca623721b0826ea66d6b8c0929 #19954

Closes #19969

15 hours agoexamples: delete unresponsive example URL
Viktor Szakats [Sat, 13 Dec 2025 11:45:09 +0000 (12:45 +0100)] 
examples: delete unresponsive example URL

Also:
- sync header layout with rest of examples.
- replace rest of arbitrary website links with example ones.

Closes #19959

15 hours agorenovate: leave bumping GitHub Actions to Dependabot
Viktor Szakats [Fri, 12 Dec 2025 22:30:45 +0000 (23:30 +0100)] 
renovate: leave bumping GitHub Actions to Dependabot

To avoid update noise. Renovate bumps everything instantly, meaning
a major version a couple hours after release, then all minor bugfix
releases throughout the next 1-2 days. Also putting major versions in
a different group than the bugfix release, and there is no support for
a cooldown period.

After this patch GitHub's Dependabot remains the single tool responsible
to bump GitHub Actions, once a month, grouped, with a cooldown period.
In sync with most other curl repos.

Both Renovate and Dependabot keep bumping pinned pips for now. Also
Renovate keeps updating C dependencies and Dockerfile.

Closes #19954

23 hours agoschannel: cap the maximum allowed size for loading cert
Daniel Stenberg [Sat, 13 Dec 2025 23:13:27 +0000 (00:13 +0100)] 
schannel: cap the maximum allowed size for loading cert

To avoid problems with mistakes or abuse, cap the largest allowed
certificate size to load to CURL_MAX_INPUT_LENGTH bytes (8MB).

Closes #19964

25 hours agotests: verify new header undfolder
Daniel Stenberg [Thu, 11 Dec 2025 22:28:51 +0000 (23:28 +0100)] 
tests: verify new header undfolder

test 798 - incoming cookie header in a folded line

test 1665 - verify HTTP headers without final CRLF. Make sure all complete
headers are delivered even if the reponse is partial

25 hours agohttp: unfold response headers earlier
Daniel Stenberg [Fri, 12 Dec 2025 15:36:08 +0000 (16:36 +0100)] 
http: unfold response headers earlier

Make the low-level HTTP header "builder" unfold headers so that
everything else can keep pretending folding does not exist.

This code no longer tries to reduce repeated leading whitespace (in the
continued folded header) to a single one. To avoid having to have a
special state for that.

Adjusted two test cases accordingly

Closes #19949

27 hours agoGHA/checksrc: fix `-z` position, also use `--output` with `xmllint`
Viktor Szakats [Sat, 13 Dec 2025 11:35:36 +0000 (12:35 +0100)] 
GHA/checksrc: fix `-z` position, also use `--output` with `xmllint`

Fixing:
```
fatal: option '-z' must come before non-option arguments
```
Ref: https://github.com/curl/curl/actions/runs/20183280533/job/57948203944#step:4:5

Follow-up to b5ea0736bbeeae717925d8eccbdb15057d8e88e9 #19946
Closes #19958

33 hours agotool_urlglob: support globs as long as config line lengths
Daniel Stenberg [Sat, 13 Dec 2025 12:48:59 +0000 (13:48 +0100)] 
tool_urlglob: support globs as long as config line lengths

libcurl supports up to 8MB string inputs, the config file accepts up to
10MB line lengths. It did not make sense to limit the globs to a maximum
of one megabyte.

Closes #19960

47 hours agotests: fix perl scalar warning
Dan Fandrich [Fri, 12 Dec 2025 23:36:40 +0000 (15:36 -0800)] 
tests: fix perl scalar warning

Fixes the warning "Scalar value @xml[0] better written as $xml[0]"

Follow-up to b5ea0736bbeeae717925d8eccbdb15057d8e88e9

Ref: #19946

2 days agoGHA: update actions
renovate[bot] [Fri, 12 Dec 2025 22:02:09 +0000 (22:02 +0000)] 
GHA: update actions

- actions/cache action to v5.0.1
- actions/download-artifact to v7.0.0
- actions/upload-artifact to v6.0.0

Closes #19952
Closes #19953

2 days agoGHA: enable libssh and libssh2 in 10 more Linux jobs
Viktor Szakats [Fri, 12 Dec 2025 02:59:21 +0000 (03:59 +0100)] 
GHA: enable libssh and libssh2 in 10 more Linux jobs

To run more pytest sshd tests, and for more static analysis.

Also:
- drop redundant option from `openssl libssh2 ...` config.
- GHA/linux: enable pytest in the LTO job (to test libssh2).
- avoid both with local builds of OpenSSL-forks, due to crypto lib
  mixups causing a mixture of build error, crashes, test failures.

Follow-up to eb39fee40be6a8e68be2551e36b6fcb94170aaed #19934

Closes #19943

2 days agotests/data: delete stray comments
Viktor Szakats [Fri, 12 Dec 2025 16:16:56 +0000 (17:16 +0100)] 
tests/data: delete stray comments

Closes #19950

2 days agotests/data: add XML prolog to test files
Viktor Szakats [Fri, 12 Dec 2025 12:43:55 +0000 (13:43 +0100)] 
tests/data: add XML prolog to test files

To formalize they are now XML-compliant (with some asterisks.)

Also to help syntax highlighters work on them to make their content more
readable.

Also:
- Delete empty comment decorations.
- GHA/checksrc: simplify XML check.
- runtests: fail to load test data with XML prolog missing.

Follow-up to bfe6eb1c06f295a45c4d2c9c7aa8f09895706313 #19927
Follow-up to 87ba80a6df1dfd7ceaaa52352c9f23afff0ed513

Closes #19946

2 days agotest567: add a header separating CRLF
Daniel Stenberg [Fri, 12 Dec 2025 15:37:27 +0000 (16:37 +0100)] 
test567: add a header separating CRLF

To make it a valid response.

Closes #19948

2 days agoGHA/windows: move dl-mingw tests from 9.5.0 to 15.1.0
Viktor Szakats [Fri, 12 Dec 2025 13:04:37 +0000 (14:04 +0100)] 
GHA/windows: move dl-mingw tests from 9.5.0 to 15.1.0

To see if it's less flaky. Also to finish 1m faster due to faster builds.

Closes #19947

2 days agotest568: fix codespell, catch it next time early in CI
Viktor Szakats [Fri, 12 Dec 2025 11:30:51 +0000 (12:30 +0100)] 
test568: fix codespell, catch it next time early in CI

Also:
- GHA/checksrc: do not exclude `tests/data/*` changes.

Follow-up to 407d2f3d574f68bfe986b621282a61016ca45c63 #19944

Closes #19945

2 days agocmake: update a comment
Viktor Szakats [Fri, 12 Dec 2025 12:09:37 +0000 (13:09 +0100)] 
cmake: update a comment

2 days agobuild: disable typecheck for analyzers and Fil-C
Viktor Szakats [Fri, 12 Dec 2025 00:05:21 +0000 (01:05 +0100)] 
build: disable typecheck for analyzers and Fil-C

- cmake: automatically disable typecheck when running clang-tidy,
  to avoid possible interference, and to improve performance.

- INSTALL-CMAKE: document both this, and unity=off for clang-tidy.

- GHA/linux: disable for some static analyzers CI jobs to avoid possible
  interference.

- GHA/linux: disable in Fil-C job to improve build performance.

Follow-up to 9e6f1c5efb7a70e1f33e467a738f3e3f652f3174 #19637
Follow-up to fd2ca2399e79e0b821af34c7c164c830c9c6574d #17955

Closes #19941

2 days agoruntests: add options to set minimum number of tests, use them
Viktor Szakats [Fri, 12 Dec 2025 00:55:30 +0000 (01:55 +0100)] 
runtests: add options to set minimum number of tests, use them

To detect mistakes made in the runtests framework that reduce
the number of test runs. Before this patch it could go undetected with
a green CI.

The minimum thresholds will need light maintenance going forward (either
bumping them periodically, or adjust if some may fell below minimums for
justified reasons). We may also make minimums tighter or looser, or more
job-specific.

Latest number of test runs for each job can be seen at Test Clutch:
https://testclutch.curl.se/static/reports/feature-matrix.html

Also:
- GHA: set minimums.

Assisted-by: Dan Fandrich
Follow-up to f2a75a14dd95e06cf9121c7d3bd5dc559748f350
Follow-up to bb1391f94394e635c1a5c58253e7a3d3b36bde57 #19510

Closes #19942

2 days agopytest: add tests using sshd
Stefan Eissing [Thu, 11 Dec 2025 15:02:41 +0000 (16:02 +0100)] 
pytest: add tests using sshd

With either /usr/sbin/sshd found or configured via --with-test-sshd=path
add tests for SCP down- and uploads, insecure, with known hosts or not,
with authorized user key or unauthorized one.

Working now with libssh and libssh2, using a hashed known_hosts file.

Closes #19934

2 days agotest568: remove what looks like an email and a URL
Daniel Stenberg [Fri, 12 Dec 2025 10:04:23 +0000 (11:04 +0100)] 
test568: remove what looks like an email and a URL

Closes #19944

2 days agotidy-up: miscellaneous
Viktor Szakats [Sun, 7 Dec 2025 15:49:55 +0000 (16:49 +0100)] 
tidy-up: miscellaneous

- drop stray duplicate empty lines in docs, scripts, test data, include,
  examples, tests.
- drop duplicate PP parenthesis.
- curl-functions.m4: move literals to the right side in if expressions,
  to match rest of the source code.
- FAQ.md: delete language designator from an URL.
- packages: apply clang-format (OS400, VMS).
- scripts/schemetable.c: apply clang-format.
- data320: delete duplicate empty line that doesn't change the outcome.
- spacecheck: extend to check for duplicate empty lines
  (with exceptions.)
- fix whitespace nits

Closes #19936

2 days agoGHA: update actions/cache action to v5
renovate[bot] [Thu, 11 Dec 2025 22:24:51 +0000 (22:24 +0000)] 
GHA: update actions/cache action to v5

Closes #19940

3 days agomdlinkcheck: only look for markdown links in markdown files
Daniel Stenberg [Thu, 11 Dec 2025 16:16:37 +0000 (17:16 +0100)] 
mdlinkcheck: only look for markdown links in markdown files

It finds debug outputs in source code otherwise.

Output the whitelist "warnings" to stderr to better allow us to count
URLs with `./mdlinkcheck --dry-run | wc -l`.

Closes #19938

3 days agoRELEASE-NOTES: synced
Daniel Stenberg [Thu, 11 Dec 2025 14:38:00 +0000 (15:38 +0100)] 
RELEASE-NOTES: synced

3 days agotransfer: remove @param for err for xfer_recv_resp function.
Christian Schmitz [Thu, 11 Dec 2025 13:37:13 +0000 (14:37 +0100)] 
transfer: remove @param for err for xfer_recv_resp function.

The err parameter in xfer_recv_resp doesn't exist anymore. Removed in
cb2bcb681fc9044d2a7adaaa621.

Closes #19937

3 days agoGHA/checkdocs: re-enable proselint, update setup, fix issues found
Viktor Szakats [Thu, 11 Dec 2025 01:46:24 +0000 (02:46 +0100)] 
GHA/checkdocs: re-enable proselint, update setup, fix issues found

- update configuration and invocation.
- install via pip.
- drop a file exception.
- alpha sort proselint settings.
- FILEFORMAT: update text about XML compliance.
- CI job takes 22 seconds total.

Ref: https://github.com/amperser/proselint/releases/tag/v0.16.0

Follow-up to 38bfe1c2aa2a6c8af29d525eb231ad66861199b1 #15314

Closes #19931

3 days agodocs: fold long lines
Viktor Szakats [Thu, 11 Dec 2025 01:13:46 +0000 (02:13 +0100)] 
docs: fold long lines

Also:
- replace a 'will' found by badwords.
- drop duplicate empty lines.

Closes #19930

3 days agotest1165: drop reference to deleted `CURL_DISABLE_TESTS`
Viktor Szakats [Thu, 11 Dec 2025 00:52:58 +0000 (01:52 +0100)] 
test1165: drop reference to deleted `CURL_DISABLE_TESTS`

Follow-up to bf823397bad09791277e983e44e8f0edc3c089b2 #16134

Closes #19929

3 days agoautotools: drop reference to deleted `CURL_CHECK_CURLDEBUG`
Viktor Szakats [Thu, 11 Dec 2025 00:43:21 +0000 (01:43 +0100)] 
autotools: drop reference to deleted `CURL_CHECK_CURLDEBUG`

The referred function has been deleted earlier.

Also:
- drop commented reference to deleted `CURL_CHECK_OPTION_THREADS`.
  0d4fdbf15d8eec908b3e63b606f112b18a63015e #16054

Follow-up to 96a1a05f662677af64b16d862c4126ed52ea4b30 #14096

Closes #19928

3 days agotests: verify setting bearer and doing redirects
Daniel Stenberg [Wed, 10 Dec 2025 09:49:54 +0000 (10:49 +0100)] 
tests: verify setting bearer and doing redirects

Test 778, 779 and 795

3 days agocurl_sasl: if redirected, require permission to use bearer
Daniel Stenberg [Wed, 10 Dec 2025 10:40:47 +0000 (11:40 +0100)] 
curl_sasl: if redirected, require permission to use bearer

Closes #19933

3 days agotest3214: allow a larger struct Curl_easy
Daniel Stenberg [Thu, 11 Dec 2025 08:11:45 +0000 (09:11 +0100)] 
test3214: allow a larger struct Curl_easy

In my local build it is now 5840 bytes. Add a 10 byte margin.

Closes #19932

3 days agoruntests: drop `notxml` keyword, verify all test data files as XML
Viktor Szakats [Wed, 10 Dec 2025 22:44:43 +0000 (23:44 +0100)] 
runtests: drop `notxml` keyword, verify all test data files as XML

Follow-up to 7f3731ce142c1d74023abad183cc8ce0fd527fab #19595

Closes #19927

4 days agoruntests: add support for single-quoted attributes, use it
Viktor Szakats [Wed, 10 Dec 2025 22:21:10 +0000 (23:21 +0100)] 
runtests: add support for single-quoted attributes, use it

With this, all test data files are XML-compliant.

Also:
- test1158, test1186: use single quotes for the test filename attribute
  containing a double quote. For XML-compliance.
- drop support for unquoted attributes. For XML-compliance.

Closes #19926

4 days agotests/data: replace `<`, `>` with `%LT`, `%GT`
Viktor Szakats [Wed, 10 Dec 2025 22:07:50 +0000 (23:07 +0100)] 
tests/data: replace `<`, `>` with `%LT`, `%GT`

For XML-compliance.

Closes #19925

4 days agotests/data: replace `<` with `%LT`
Viktor Szakats [Wed, 10 Dec 2025 21:57:58 +0000 (22:57 +0100)] 
tests/data: replace `<` with `%LT`

For XML-compliance.

Closes #19924

4 days agotests/data: replace `&` with `%AMP`
Viktor Szakats [Wed, 10 Dec 2025 21:42:35 +0000 (22:42 +0100)] 
tests/data: replace `&` with `%AMP`

For XML-compliance.

Closes #19923

4 days agoautotools: tidy-up `if` expressions
Viktor Szakats [Tue, 5 Aug 2025 14:07:21 +0000 (16:07 +0200)] 
autotools: tidy-up `if` expressions

- drop x-hacks for curl internal variables and certain autotools ones
  that do not hold custom values.
- make x-hacks consistently use `"x$var" = "xval"` style.
- add a few x-hacks for input/external variables that may hold custom
  values.
- prefer `-z` and `-n` to test empty/non-empty.
  This also makes some x-hacks unnecessary.
- optimized negated test `-z` and `-n` options.
- prefer `&&` and `||` over `-a` and `-o`.
  For better POSIX compatibility:
  https://pubs.opengroup.org/onlinepubs/9699919799/utilities/test.html
- quote variables passed to `test`, where missing.
- quote string literals in comparisons.
- fix some indentation, whitespace.

Note that a few `case` statements also use the x-hack, which looks
unnecessary. This patch does not change them.

Verified by comparing feature detection results with a reference CI run
from before this patch (PR #19922).

Refs:
https://www.shellcheck.net/wiki/SC2268
https://pubs.opengroup.org/onlinepubs/9699919799/utilities/test.html
https://www.vidarholen.net/contents/blog/?p=1035
https://mywiki.wooledge.org/BashPitfalls#A.5B_.24foo_.3D_.22bar.22_.5D

Closes #18189

4 days agoautotools: fix LargeFile feature display on Windows (after prev patch)
Viktor Szakats [Wed, 10 Dec 2025 17:45:06 +0000 (18:45 +0100)] 
autotools: fix LargeFile feature display on Windows (after prev patch)

Always show it on Windows, regardless of the `--disable-largefile`
build option.

Follow-up to 163705db756557e6c07ac9386663f0576ebfd64e #19888
Closes #19922

4 days agoquiche: fix version for skip due to flakiness
Stefan Eissing [Wed, 10 Dec 2025 15:07:59 +0000 (16:07 +0100)] 
quiche: fix version for skip due to flakiness

0.24.6 is the quiche version without the fix for proper handling fo
RESET streams. Require a verion higher than that to run test_05_02.

Follow-up to 14478429e71ef0eee6d12b73113e9ff8e3ae9e75 #19916

Closes #19921

4 days agoconfig-win32.h: drop unused/obsolete `CURL_HAS_OPENLDAP_LDAPSDK`
Viktor Szakats [Wed, 10 Dec 2025 14:48:31 +0000 (15:48 +0100)] 
config-win32.h: drop unused/obsolete `CURL_HAS_OPENLDAP_LDAPSDK`

Meant for use from `Makefile.mk`. The suggested replacement is CMake or
autotools.

Follow-up to ba8752e5566076acc8bdec7ae4ec78901f7050f4 #12224

Closes #19920

4 days agoldap: drop PP logic for old, unsupported, Windows SDKs
Viktor Szakats [Wed, 10 Dec 2025 14:37:44 +0000 (15:37 +0100)] 
ldap: drop PP logic for old, unsupported, Windows SDKs

`LDAP_VENDOR_NAME` and `winber.h` are available in all supported
MS SDK and mingw-w64 versions. Stop checking for them.

Also drop redundant parenthesis in PP expression.

Closes #19918

4 days agopytest: quiche flakiness
Stefan Eissing [Wed, 10 Dec 2025 10:17:49 +0000 (11:17 +0100)] 
pytest: quiche flakiness

Let nghttpx only use http/1.1 to backend. This reproduces the bug in
quiche with higher frequency. Allow test_14_05 to now return a 400 in
addition to the 431 we get from a h2 backend to nghttpx.

Skip test_05_02 in h3 on quiche not newer than version 0.24.4 in which
its bug is fixed: https://github.com/cloudflare/quiche/pull/2278

Ref: https://github.com/cloudflare/quiche/issues/2277
Closes #19770 (original Issue)
Closes #19916

4 days agoGHA/checkurls: add dry run on push
Viktor Szakats [Wed, 10 Dec 2025 10:47:40 +0000 (11:47 +0100)] 
GHA/checkurls: add dry run on push

To verify if the basics work.

Downside is that the scheduled (live) runs are intermixed with the dry
runs and less obvious to find in the default list:
https://github.com/curl/curl/actions/workflows/checkurls.yml

This URL filters for scheduled runs only:
https://github.com/curl/curl/actions/workflows/checkurls.yml?query=event%3Aschedule

Seems fine, because we're only interested in red runs.

Closes #19917

4 days agomdlinkcheck: add --dry-run to only show all found URLs
Daniel Stenberg [Wed, 10 Dec 2025 07:45:34 +0000 (08:45 +0100)] 
mdlinkcheck: add --dry-run to only show all found URLs

- remove the debug tracing leftovers from d9d2e339ced3fa02 that made exit
  unconditonally

Closes #19914

4 days agoCURLOPT_FOLLOWLOCATION.md: s/Authentication:/Authorization:/
Daniel Stenberg [Wed, 10 Dec 2025 08:19:32 +0000 (09:19 +0100)] 
CURLOPT_FOLLOWLOCATION.md: s/Authentication:/Authorization:/

Closes #19915

4 days agotest318: tweak the name a little
Daniel Stenberg [Wed, 10 Dec 2025 08:29:43 +0000 (09:29 +0100)] 
test318: tweak the name a little

to make it properly differ from test 317

4 days agoGHA: update dependencies and actions
renovate[bot] [Wed, 10 Dec 2025 01:51:54 +0000 (01:51 +0000)] 
GHA: update dependencies and actions

- update dependency awslabs/aws-lc to v1.65.1
- update dependency pizlonator/fil-c to v0.676
- update github/codeql-action action to v4.31.7

Closes #19905
Closes #19912
Closes #19913

4 days agotidy-up: URLs (cont.) and mdlinkcheck
Viktor Szakats [Tue, 9 Dec 2025 20:24:28 +0000 (21:24 +0100)] 
tidy-up: URLs (cont.) and mdlinkcheck

- add missing ending slashes.
  To avoid duplicates and to use canonical URLs.
- reapply lost updates.
  Follow-up to 2ae983bf4ea5ef86f0e68ea0ff219a91b1aa3428 #19879
- mdlinkcheck: include the `include` directory.
- mdlinkcheck: show unused whitelist items.
- mdlinkcheck: improve debug output.
- mdlinkcheck: delete redundant whitelist items.
- examples/simplessl: lowercase the protocol part.
- BINDINGS: replace one remaining HTTP URL with HTTPS.
  Issue: https://github.com/pycurl/pycurl/issues/892
- BINDINGS: fix a broken link.
- BINDINGS: follow a refresh content redirect.
- KNOWN_BUGS: whitespace.

Closes #19911

4 days agomemdebug: fix realloc logging
Stefan Eissing [Tue, 9 Dec 2025 14:48:52 +0000 (15:48 +0100)] 
memdebug: fix realloc logging

Do the whole realloc and the subsequent logging under mutex lock. This
fixed log entries that state allocation a memory location before realloc
logs it as being freed.

Closes #19900

4 days agotest: increase altsvc test reliability
Stefan Eissing [Tue, 9 Dec 2025 16:00:52 +0000 (17:00 +0100)] 
test: increase altsvc test reliability

Move new tests from test_12 to test_06 (eyeballing) where they better
fit. Increase reliability by check Alt-Svc redirects from h3 to a lower
version for a port where no h3 is available.

Closes #19903

5 days agobuild: set `-Wno-format-signedness`
Viktor Szakats [Tue, 9 Dec 2025 19:06:33 +0000 (20:06 +0100)] 
build: set `-Wno-format-signedness`

Explicitly disable these warnings to allow using `-Weverything`.

There are around 600 of them across the codebase.

Silencing them has some drawbacks:
- enums (`CURLcode` mostly) would have to be cast to int to avoid
  different signedness depending on C compiler.
  (llvm/gcc: unsigned, MSVC/clang-cl: signed by default)
- hex masks need casts to unsigned to avoid the warning.
- fixing remaining warnings is annoying without fixing the above.
- without fixing all warnings the option cannot be enabled, to keep
  the codebase warning free.

Ref: #18343 (silenced all warnings, but without the enum cast)
Follow-up to 92f215fea1aa8bd5b1709d38f42aab77ab3fc662 #18477
Closes #19907

5 days agomdlinkcheck: do not pick up single quote and backslash after URLs
Viktor Szakats [Tue, 9 Dec 2025 22:27:34 +0000 (23:27 +0100)] 
mdlinkcheck: do not pick up single quote and backslash after URLs

Closes #19910

5 days agomdlinkcheck: exclude self from URL search
Viktor Szakats [Tue, 9 Dec 2025 21:26:41 +0000 (22:26 +0100)] 
mdlinkcheck: exclude self from URL search

To avoid picking up the whitelist.

Closes #19909

5 days agoDEPRECATE: add CMake <3.18 deprecation for April 2026
Viktor Szakats [Wed, 8 Oct 2025 14:20:54 +0000 (16:20 +0200)] 
DEPRECATE: add CMake <3.18 deprecation for April 2026

CMake 3.18 was released on 2020-07-15.

It enables using (and/or dropping workarounds) for these features:
LTO support, better performance and pkg-config support, `OBJECT` target,
`-S`, `-B`, `--verbose`, `--install` on the command-line, lib directory
support in interface targets, target_link_options(), LINK_OPTIONS,
FetchContent, `list(PREPEND ...)`, unity, Ninja, fixed imported global
issues.

Ref: https://github.com/curl/curl/discussions/18704

Closes #19902

5 days agowindows: assume `USE_WIN32_LARGE_FILES`
Viktor Szakats [Tue, 9 Dec 2025 09:31:20 +0000 (10:31 +0100)] 
windows: assume `USE_WIN32_LARGE_FILES`

All Windows platforms support it. It was permanently enabled with most
build methods. The exception is autotools where it is enabled by
default, with an option to disable it. It changed the build in a few
places for rarely tested code paths, but not bringing other advantages
(and used some 64-bit APIs anyway). This patch makes autotools'
`--disable-largefile` option a no-op for Windows.

Closes #19888

5 days agoGHA: make links get checked daily
Daniel Stenberg [Tue, 9 Dec 2025 13:39:16 +0000 (14:39 +0100)] 
GHA: make links get checked daily

Assisted-by: Viktor Szakats
Closes #19898

5 days agoconfigure: delete unused variable
Viktor Szakats [Tue, 9 Dec 2025 14:55:25 +0000 (15:55 +0100)] 
configure: delete unused variable

Follow-up to 4d73854462f30948acab12984b611e9e33ee41e6 #9044

Closes #19901

5 days agoconfig-win32.h: delete obsolete, non-Windows comments
Viktor Szakats [Tue, 9 Dec 2025 14:32:42 +0000 (15:32 +0100)] 
config-win32.h: delete obsolete, non-Windows comments

Closes #19899

5 days agopytest: socksd startup delay
Stefan Eissing [Tue, 9 Dec 2025 11:54:00 +0000 (12:54 +0100)] 
pytest: socksd startup delay

Add a small delay after the startup of the danted socks daemon to
give it more time to become responsive.

Closes #19895

5 days agomulti: remove MSTATE_TUNNELING
Stefan Eissing [Tue, 9 Dec 2025 11:51:17 +0000 (12:51 +0100)] 
multi: remove MSTATE_TUNNELING

MSTATE_TUNNELING is no longer in use now that we have proxy connection
filters. Remove the state.

Remove the http handler `connect_it` method as it was merely a NOP.

Closes #19894

5 days agoalt-svc: more flexibility on same destination
Stefan Eissing [Mon, 8 Dec 2025 12:36:19 +0000 (13:36 +0100)] 
alt-svc: more flexibility on same destination

When the Alt-Svc points to the same host and port, add the destination
ALPN to the `wanted` versions and set it also as the `preferred` version
in negotiations.

This allows Alt-Svc for h3 to point to h2 and have it tried first. Also,
this allows Alt-Svc to say http/1.1 is preferred and changes the ALPN
protocol ordering for the TLS handshake.

Add tests in various combination to verify this works.

Reported-by: yushicheng7788 on github
Fixes #19740
Closes #19874

5 days agoGHA/windows: re-enable `taskkill`
Viktor Szakats [Tue, 9 Dec 2025 13:27:44 +0000 (14:27 +0100)] 
GHA/windows: re-enable `taskkill`

Nothing conclusive for the last ~30 days when `taskkill` was made
a no-op. Jobs remained flaky with all known failure modes. Sometimes
they finish green on the first run, sometimes they fail. Hard to say
more without comparing detailed stats for this period and the
preceding (or upcoming) one.

In almost all runs, the PID to be killed did not exist at the time of
check.

Follow-up to 2701ac6a4d16a62130dad05be1c484903b8545c7 #19421
Closes #19897

5 days agogtls: Call keylog_close in cleanup
Yedaya Katsman [Tue, 2 Dec 2025 19:59:53 +0000 (21:59 +0200)] 
gtls: Call keylog_close in cleanup

5 days agotest: add test 2090 for SSLKEYLOGFILE structure
Yedaya Katsman [Tue, 2 Dec 2025 17:40:07 +0000 (19:40 +0200)] 
test: add test 2090 for SSLKEYLOGFILE structure

Only the TLS 1.2 structure for now since it's simpler, and only has a
single label type. This has the bonus of also testing libressl that only
supports logging keys in TLS 1.2

Closes #19816

5 days agoexamples: use 64-bit `fstat` on Windows
Viktor Szakats [Tue, 9 Dec 2025 11:55:26 +0000 (12:55 +0100)] 
examples: use 64-bit `fstat` on Windows

Closes #19896

5 days agoTODO: remove ancient entries no longer considered
Daniel Stenberg [Tue, 9 Dec 2025 10:53:45 +0000 (11:53 +0100)] 
TODO: remove ancient entries no longer considered

- TCP Fast Open support on Windows

TFO doesn't really work on the internet and isn't really used anywhere.
We use QUIC now.

- get rid of PATH_MAX

Not a priority and when using 3rd party libraries not really up to us.

- auto-detect proxy

A dream we can just stop having.

- config file parsing

Let's not do that in our library.

- add asynch getaddrinfo support

Let's not add a limited glibc specific backend with bad API

- FTP HOST

If we managed this far without name based vhost FTP, let's not.

Closes #19890

5 days agotest1025, 1221: fold long command-lines
Viktor Szakats [Tue, 9 Dec 2025 11:18:31 +0000 (12:18 +0100)] 
test1025, 1221: fold long command-lines

Closes #19893

5 days agotest1464: mark XML-compliant
Viktor Szakats [Tue, 9 Dec 2025 11:14:21 +0000 (12:14 +0100)] 
test1464: mark XML-compliant

Closes #19892

5 days agoDockerfile: update debian:bookworm-slim digest to e899040
renovate[bot] [Tue, 9 Dec 2025 11:03:54 +0000 (11:03 +0000)] 
Dockerfile: update debian:bookworm-slim digest to e899040

Closes #19891

5 days agoDockerfile: update debian:bookworm-slim digest to 1371f81
renovate[bot] [Tue, 9 Dec 2025 04:48:05 +0000 (04:48 +0000)] 
Dockerfile: update debian:bookworm-slim digest to 1371f81

Closes #19883

5 days agoFAQ: fix minor link syntax mistake
Daniel Stenberg [Tue, 9 Dec 2025 10:13:31 +0000 (11:13 +0100)] 
FAQ: fix minor link syntax mistake

5 days agoFAQ/TODO/KNOWN_BUGS: convert to markdown
Daniel Stenberg [Mon, 8 Dec 2025 12:07:49 +0000 (13:07 +0100)] 
FAQ/TODO/KNOWN_BUGS: convert to markdown

- convert to markdown
- auto-generate the TOCs on the website, remove them from the docs
- cleanups
- spellchecked
- updated links

Closes #19875

5 days agoimap: check buffer length before accessing it
Daniel Stenberg [Tue, 9 Dec 2025 09:04:34 +0000 (10:04 +0100)] 
imap: check buffer length before accessing it

Pointed out by ZeroPath

Closes #19887

5 days agoheaders: add length argument to Curl_headers_push()
Daniel Stenberg [Tue, 9 Dec 2025 08:58:48 +0000 (09:58 +0100)] 
headers: add length argument to Curl_headers_push()

- the length is already known by parent functions
- avoids strlen() calls
- avoids strchr() calls for trimming off newline characters

Closes #19886

5 days agotests/data: move section data to external files
Viktor Szakats [Tue, 9 Dec 2025 00:15:29 +0000 (01:15 +0100)] 
tests/data: move section data to external files

To make the test files XML-compliant, and the expected results
possibly easier to manage by keeping them in `.md`, `.html`, `.1`
and `.txt` files.

Non-XML-compliant files are down to 31 (1.6%) after this patch.

Closes #19882

5 days agoRELEASE-NOTES: synced
Daniel Stenberg [Tue, 9 Dec 2025 08:23:35 +0000 (09:23 +0100)] 
RELEASE-NOTES: synced

5 days agocurl_setup.h: fix `FMT_SOCKET_T` to be unsigned on Windows
Viktor Szakats [Thu, 21 Aug 2025 11:59:46 +0000 (13:59 +0200)] 
curl_setup.h: fix `FMT_SOCKET_T` to be unsigned on Windows

To match the Windows socket type.

Ref: https://learn.microsoft.com/windows/win32/winsock/socket-data-type-2

Cherry-picked from #18343
Closes #19881

5 days agotests/data: use more `%TESTNUMBER` macro for previous patch
Viktor Szakats [Tue, 9 Dec 2025 00:46:06 +0000 (01:46 +0100)] 
tests/data: use more `%TESTNUMBER` macro for previous patch

Follow-up to d75716e4e55c7074566f48d8c03bfd721461e105 #19799
Cherry-picked from #19882
Closes #19885

5 days agotests/data: move `--libcurl` output to external data files
Viktor Szakats [Mon, 1 Dec 2025 12:31:42 +0000 (13:31 +0100)] 
tests/data: move `--libcurl` output to external data files

To make the test files XML-compliant, and the expected results
possibly easier to manage by keeping them in `.c` files.

Non-XML-compliant files are down to 36 after this patch.

Also:
- make all macro expansions apply to `%includetext` contents.

Closes #19799

5 days agotidy-up: URLs
Viktor Szakats [Mon, 8 Dec 2025 15:44:29 +0000 (16:44 +0100)] 
tidy-up: URLs

- to avoid dupes.
- missing slashes.
- drop `.git` suffix from GitHub git repo URLs for a few outliers.
- use short YouTube URL like curl-www does.
- sync two RFC doc URLs with others.

Closes #19879

6 days agomk-ca-bundle.md: the file format docs URL is permaredirected
Daniel Stenberg [Mon, 8 Dec 2025 14:50:48 +0000 (15:50 +0100)] 
mk-ca-bundle.md: the file format docs URL is permaredirected

Closes #19877

6 days agoKNOWN_BUGS: remove link to codepoints.net
Daniel Stenberg [Mon, 8 Dec 2025 14:54:38 +0000 (15:54 +0100)] 
KNOWN_BUGS: remove link to codepoints.net

The site is so slow it often triggers a failure for the link checker.

Closes #19878

6 days agoIPFS.md: wrap long lines
Viktor Szakats [Mon, 8 Dec 2025 16:02:26 +0000 (17:02 +0100)] 
IPFS.md: wrap long lines

Closes #19880

6 days agoGHA: bump pip-dependencies ruff, psutil, pytest
dependabot[bot] [Mon, 8 Dec 2025 14:20:54 +0000 (14:20 +0000)] 
GHA: bump pip-dependencies ruff, psutil, pytest

- update `ruff` from 0.14.5 to 0.14.8
- update `psutil` from 7.1.2 to 7.1.3
- update `pytest` from 8.4.2 to 9.0.1

Closes #19876

6 days agoCI/windows: add torture tests with Schannel
Viktor Szakats [Sun, 7 Dec 2025 16:36:54 +0000 (17:36 +0100)] 
CI/windows: add torture tests with Schannel

With Schannel and Unicode, `-shallow=13`. It finishes in 12 minutes,
making it the slowest Windows job. It's still on par with torture jobs
on other platforms (though they manage to fit `-shallow=25`).

Also `-shallow=13` still caught leaks in multiple tests.

Also:
- test2300: exclude from CI Windows torture tests.
- experimental.

The downside of going with deeper torture tests, is that it requires
increasing the job timeout. This in turns means that a hung job takes
more minutes to be killed (due to GitHub bugs where a hung step does not
honor the per-step timeout on Windows, another bug where a hung job gets
killed +5 minutes above the workflow timeout, and another bug (or
feature?) where other failed/hung jobs in the the workflow cannot be
restarted till the last job finishes or gets killed. And all this
probably related to a Perl bug which makes it hang on fork errors, which
is turn related to Cygwin/MSYS2 runtime bugs which breaks fork in case
of curl's mixed MSYS2-Perl/native-curl-binaries environment.)
The end result in longer forced waits before being able to restart flaky
jobs, which slows down iterations and annoying.

Also tried:
- non-c-ares job: detected known issues much less often.
- replaced libidn2 with WinIDN: detected known issues much less often.
- runtests -j9-j20 values: did not make a difference.
- other `-shallow` values: 20 is the max feasible, but comes with the
  downside described above.

Ref: #19675 (reboot of)
Follow-up to f08417c4259a3b9a2e4d72a48fa02ce6502cb587 #19863

Closes #19865

6 days agodocs: switch more URLs to https://
Daniel Stenberg [Mon, 8 Dec 2025 10:11:02 +0000 (11:11 +0100)] 
docs: switch more URLs to https://

Normalize using https:// almost everywhere instead of http://

Closes #19872

6 days agomdlinkcheck: ignore IP numbers, allow '@' in raw URLs
Daniel Stenberg [Mon, 8 Dec 2025 10:16:18 +0000 (11:16 +0100)] 
mdlinkcheck: ignore IP numbers, allow '@' in raw URLs

6 days agoGHA/linux: update dependency pizlonator/fil-c to v0.675
renovate[bot] [Mon, 8 Dec 2025 11:07:26 +0000 (11:07 +0000)] 
GHA/linux: update dependency pizlonator/fil-c to v0.675

Closes #19873

6 days agoGHA/linux: blind try to make Renovate detect Fil-C releases
Viktor Szakats [Mon, 8 Dec 2025 10:06:49 +0000 (11:06 +0100)] 
GHA/linux: blind try to make Renovate detect Fil-C releases

0.675 has been out for 2 weeks, Renovate did not detect it with
`semver-partial`. Try with `semver-coerced`.

Refs:
https://docs.renovatebot.com/modules/versioning/semver-coerced/
https://docs.renovatebot.com/modules/versioning/semver-partial/

Follow-up to 16c6ea36cca6684aacbcb33578af61b28e3fee0d #19391

6 days agoDISTROS: fix a Mageia URL
Daniel Stenberg [Mon, 8 Dec 2025 10:43:12 +0000 (11:43 +0100)] 
DISTROS: fix a Mageia URL

Since we check the provided URLs now, use the direct, working URL.

6 days agognutls: add PROFILE_MEDIUM as default
Stefan Eissing [Fri, 5 Dec 2025 14:38:12 +0000 (15:38 +0100)] 
gnutls: add PROFILE_MEDIUM as default

Raise the default GnuTLS priority settings by adding PROFILE_MEDIUM for
more secure connection handling.

Reported-by: Harry Sintonen
Closes #19853

6 days agotest1475: consistently use %CR in headers
Fabian Keil [Sun, 7 Dec 2025 14:23:00 +0000 (15:23 +0100)] 
test1475: consistently use %CR in headers

Gets the test working when using Privoxy as proxy.

Closes #19870

6 days agohostcheck: fail wildcard match if host starts with a dot
Daniel Stenberg [Mon, 8 Dec 2025 09:20:04 +0000 (10:20 +0100)] 
hostcheck: fail wildcard match if host starts with a dot

A hostname cannot start with a dot when DNS is used, but there are other
ways.

Amend unit test 1397

Closes #19869

6 days agosspi: fix memory leaks on error paths in `Curl_create_sspi_identity()`
Viktor Szakats [Sun, 7 Dec 2025 19:03:38 +0000 (20:03 +0100)] 
sspi: fix memory leaks on error paths in `Curl_create_sspi_identity()`

Detected by Windows torture test 1072 (with `-shallow=20/13`),
test 579 (with `-shallow=18/14/13`), and test 1286 (with `-shallow=15`).

```
** MEMORY FAILURE
Leak detected: memory still allocated: 20 bytes
At 1a1e8136328, there is 18 bytes.
 allocated by D:/a/curl/curl/lib/curl_sspi.c:133
At 1a1e8139368, there is 2 bytes.
 allocated by D:/a/curl/curl/lib/curl_sspi.c:143
 1072: torture FAILED: function number 207 in test.
 invoke with "-t207" to repeat this single case.
Warning: http2 server unexpectedly alive
```
Ref: https://github.com/curl/curl/actions/runs/20008523913/job/57374427439?pr=19865

Also simplify the code a little.

Cherry-picked from #19865
Closes #19866

6 days agocookie: cleanups and improvements
Daniel Stenberg [Sun, 7 Dec 2025 22:44:31 +0000 (23:44 +0100)] 
cookie: cleanups and improvements

- Stricter cookie validation with earlier rejection of empty/invalid
  cookie names

- secure and httponly attributes no longer accept = with empty values
  (only bare keywords)

- Validation checks (length, TAB, prefixes) moved into the first
  name/value pair block for better code organization

- Deferred time(NULL) calls for better performance when expires/max-age
  aren't used

- Simplified loop control flow by removing done flag

- The cookie size restriction now only applies to name + value, not other
  parts of the header line.

- Fixed a gcc 4.8.1 quirk

Closes #19868