Commit Graph

34076 Commits

Author SHA1 Message Date
Daniel Stenberg
fab526c032
Makefile: remove 'scripts' duplicate from DIST_SUBDIRS
Also fix the .dist replacing by avoiding all Makefiles because it
otherwise also went into the temporary release folder and got confused
about the Makefile.dist in there.
2024-08-02 23:05:41 +02:00
Daniel Stenberg
d0afb33959
dmaketgz: only run 'make distclean' if Makefile exists
... so that we can avoid the build failure if we run this in a clean
checkout.

Also remove -it from the docker invoke since it is not interactive and
it needs no TTY. They made the job fail in the CI.
2024-08-02 23:05:41 +02:00
Viktor Szakats
4d34fd26db
autotools: fix typo in tests/data target
Ref: c1b369fd4c (2002-12-12)
Closes #14355
2024-08-02 14:36:16 +02:00
Viktor Szakats
c6cf411bac
GHA/non-native: reduce FreeBSD test parallelism to -j8 [ci skip]
To reduce flakiness.
2024-08-02 14:36:13 +02:00
Stefan Eissing
45246ebca1
tests: gitignore newly generated files
Closes #14351
2024-08-02 11:19:10 +02:00
Stefan Eissing
ba44ac62e3
progress: ratelimit/progress tweaks
- multi.c: when ratelimiting a transfer stops (MSTATE_RATELIMITING ->
  MSTATE_PERFORMING), run the MSTATE_PERFORMING state right away

- urldata.h: factor out upload and download progress counters into a
  struct, use that for passing these to progress update functions

- progress.c/getinfo.c: change names of moved progress counters

- progress.c: use new structs and a helper struct to factor repeated
  calculation into static helpers

Closes #14335
2024-08-02 11:17:44 +02:00
Stefan Eissing
eb0a366b70
http2: improve rate limiting of downloads
Set the initial stream window size to 64KB and increase that to the 10MB
we used to start with on the first server reply, unless a rate limit is
in effect.

Continously monitory changes to the transfers rate limit and adjust the
stream window size accordingly. `max_recv_speed` is a transfer propert
that can be changed during processing by a callback.

Closes #14326
2024-08-02 08:45:01 +02:00
renovate[bot]
4abf97b0a6
GHA: update awslabs/aws-lc to v1.33.0
Closes #14347
2024-08-02 08:43:17 +02:00
Stefan Eissing
f6cb3c6308
tests/http: configure test httpd to honor client cipher order
Let the client, e.g. curl, influence the cipher selected in a TLS
handshake. TLS backends have different preferences and honor that
in httpd the same as Caddy does.

Also makes for a more fair compare of different TLS backends.

Closes #14338
2024-08-02 08:32:34 +02:00
Daniel Stenberg
754acd1a9d
dist: fix reproducible build from release tarball
Make it possible to rebuild an identical copy from a release tarball. It
was previously only possible from a checked out git repository.

- add release-tools.sh to dist
- keep Makefile.dist around to include it in dist
- regenerate tool_huge.c with the new version in dist
- fix the dist CI job to not do make clean like before

Closes #14336
2024-08-02 08:28:56 +02:00
Tal Regev
c73b80a3cd
cmake: add gnutls to multissl feature
Closes #14345
2024-08-02 08:27:31 +02:00
Daniel Stenberg
1f61db5907
curl: allow 500MB data URL encode strings
Previously it would bail out of the generated data reached 8MB in
memory.

Reported-by: Antoine du Hamel
Fixes #14337
Closes #14340
2024-08-02 08:26:36 +02:00
Daniel Stenberg
9bfc7f9234
escape: allow curl_easy_escape to generate 3*input length output
Instead of capping it to the 3 * CURL_MAX_INPUT_LENGTH. To allow users
to URL encode larger chunks of data.

Closes #14339
2024-08-01 23:03:21 +02:00
Daniel Stenberg
8a9c22796b
CHANGES: rename to CHANGES.md, no longer generated
- scripts/log2changes.pl was not included in release tarballs, which broke
  reproducible builds

- since log2changes uses git to generate the contents, it makes it difficult
  to generate the same contents later (it would need to be fixed)

- the CHANGES file has outlived its purpose. the main changes are in the
  RELEASE-NOTES, the rest are better tracked directly using git or on GitHub

- put a fixed CHANGES.md in there instead pointing out where the info lives
  now

Closes #14331
2024-08-01 13:37:12 +02:00
Daniel Stenberg
12774f4505
RELEASE-NOTES: synced
Plus add a link to https://curl.se/changes.html
2024-08-01 13:36:28 +02:00
Daniel Stenberg
e3240db0a7
GHA: scan git repository and detect unvetted binary files
The only binary-looking files that are accepted in the git repository
need to match the checksums in the sha256sum file
".github/scripts/binarycheck.sums".

This is done to make sure that no one has planted any hidden (encrypted)
potentially dangerous payload in the tree.

Closes #14333
2024-08-01 12:30:36 +02:00
Viktor Szakats
c3fe2dd25c
GHA/windows: drop FTP tests
Try reducing hangs.

Closes #14330
2024-08-01 00:32:00 +02:00
Tal Regev
a79dc7b601
GHA/windows: remove vcpkg bin path in MSVC jobs
- the path is wrong, because we compile on debug, and we are using
  the release bin path.
- the path is not needed, cmake curl copy the needed dlls to the
  compilation cmake folder where the curl exe is found.

Closes #14329
2024-08-01 00:32:00 +02:00
Viktor Szakats
0d12528729
GHA/windows: timeout earlier with hung tests
Finishing tests takes on average 10 or less minutes depending on
platform. Reduce job step timeouts to reflect that. It helps
concluding hung/failed tests earlier, which allows to retry them
earlier.

This makes it more difficult to tell from a job if it hung or not,
because we lose the long runtime as a telltale sign. Let's see how it
works out and adjust as necessary.

Also fix a comment while here.

Closes #14236
2024-08-01 00:32:00 +02:00
Daniel Stenberg
65ece771f4
INSTALL.md: MultiSSL and QUIC are mutually exclusive
Reported-by: Matt Jolly
Fixes #14308
Closes #14328
2024-07-31 23:26:40 +02:00
Stefan Eissing
02e0151a3a
lib: convert some debugf()s into traces
Use CURL_TRC_CF() for some useful tracing information instead of
DEBUGF().

Closes #14322
2024-07-31 23:14:24 +02:00
Viktor Szakats
a118a6ecdd
cmake: distcheck for files in CMake subdir
- add CMake option to verify if the `CMake/*.cmake`, `CMake/*.in` files
  are listed as distributable in autotools' `EXTRA_DIST`. The check can
  be enabled with `-DENABLE_DIST_TEST=ON` CMake option.

- add CI job to that effect.

Ref: #14320
Closes #14323
2024-07-31 22:31:56 +02:00
Viktor Szakats
404679d25f
libcurl.pc: add Cflags.private
Ref: https://manpages.debian.org/bookworm/pkgconf/pc.5.en.html#PROPERTY_KEYWORDS
Ref: https://www.msys2.org/docs/pkgconfig/#cflagsprivate-static-libraries

Closes #14321
2024-07-31 20:24:30 +02:00
Viktor Szakats
58946eed20
dist: add missing FindNettle.cmake
Follow-up to 669ce42275 #14285
Reported-by: Christoph Reiter
Bug: https://github.com/curl/curl/pull/14285#issuecomment-2259880050
Closes #14320
2024-07-31 16:34:09 +02:00
Daniel Stenberg
8f89218b19
tests: provide docs a as curldown, not nroff
As runtests.md and testcurl.md. Very few people actually need these as
manpages anyway.

With this, we have no more nroff formatted documents in git.

Closes #14324
2024-07-31 14:51:12 +02:00
Daniel Stenberg
a9f63b8e0e
RELEASE-NOTES: synced
Bump to 8.10.0
2024-07-31 10:48:48 +02:00
Joe Birr-Pixton
dd95a49d49
rustls: make all tests pass
- supports IP addresses in certs since 0.21
- Remove workaround, and re-enable tests

Closes #14317
2024-07-31 10:44:10 +02:00
Tal Regev
ec41cfb809
GHA/windows: enable MulitSSL in an MSVC job
Ref: 98da147b18 #14305
Closes #14276
2024-07-31 10:22:34 +02:00
Daniel Stenberg
83bedbd730
RELEASE-NOTES: synced 2024-07-31 08:50:04 +02:00
Daniel Stenberg
6ba773b6db
THANKS: add names from the 8.9.1 release notes
Also remove duplicates
2024-07-31 08:50:04 +02:00
Stefan Eissing
27959ecce7
x509asn1: unittests and fixes for gtime2str
Fix issues in GTime2str() and add unit test cases to verify correct
behaviour.

Follow-up to 3c914bc680

Closes #14316
2024-07-30 23:08:59 +02:00
Tal Regev
98da147b18
vtls: avoid forward declaration in MultiSSL builds
The MSVC compiler cannot have forward declaration with const and static
variable, causing this error:
```
curl\lib\vtls\vtls.c(417,44): warning C4132: 'Curl_ssl_multi': const object should be initialized
```

Ref: #14276
Closes #14305
2024-07-30 22:11:20 +02:00
Viktor Szakats
8153b8e580
tidy-up: URL updates (one more)
Follow-up to 767d5811b5 #14318
2024-07-30 21:36:39 +02:00
Viktor Szakats
767d5811b5
tidy-up: URL updates
Closes #14318
2024-07-30 21:27:12 +02:00
Viktor Szakats
b92ead34dd
cmake: drop if(PKG_CONFIG_FOUND) guard for pkg_check_modules()
The oldest cmake supported by curl is v3.7.0, which already has such
guard (using `PKG_CONFIG_EXECUTABLE`) inside `pkg_check_modules()`. The
advantage of leaving that guard to CMake is that it will define/reset
all output variables, while the manual guard doesn't do this and also
leaves for example `NETTLE_FOUND` undefined.

Delete the single use of this guard from the recently added `nettle`
detection, where I included it by accident. Then possibly re-introduce
it universally if we find it useful after more evaluation.

Follow-up to 669ce42275 #14285
Closes #14309
2024-07-30 14:33:50 +02:00
Daniel Stenberg
d40bba3ff9
mailmap: dedupe an author showing up twice in shortlog -s 2024-07-30 14:25:30 +02:00
Ivan Kuchin
b2696ac37a
misc: cleanup after removing years from copyright
- remove leftover copyright years from few test files
- fix email in copyright lines
- consistent format of copyright lines

Closes #14312
2024-07-30 14:11:48 +02:00
Alex Snast
f87a958e9e
wolfssl: avoid calling get_cached_x509_store if store is uncachable
There's no need for get_cached_x509_store call if the return value won't
be used for caching anyway.

Closes #14306
2024-07-30 13:02:17 +02:00
Daniel Stenberg
e358a6e542
contrithanks.sh: use -F with -v to match lines as strings
Makes names involving [brackets] work.
2024-07-30 12:17:00 +02:00
Viktor Szakats
f6f49a4627
GHA/non-native: bump FreeBSD/arm64 python modules
FreeBSD seems to upgrade their Python separately for arm64
and Intel. Today, arm64 caught up with the Intel packages.
Update our CI to reflect it.

Closes #14310
2024-07-30 12:10:29 +02:00
dependabot[bot]
fd1cee7752
GHA: bump github/codeql-action and msys2/setup-msys2
- bump github/codeql-action from 3.25.13 to 3.25.15

Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.25.13 to 3.25.15.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](2d790406f5...afb54ba388)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Closes #14300

- bump msys2/setup-msys2 from 2.23.0 to 2.24.0

Bumps [msys2/setup-msys2](https://github.com/msys2/setup-msys2) from 2.23.0 to 2.24.0.
- [Release notes](https://github.com/msys2/setup-msys2/releases)
- [Changelog](https://github.com/msys2/setup-msys2/blob/main/CHANGELOG.md)
- [Commits](d0e80f58df...5df0ca6cbf)

---
updated-dependencies:
- dependency-name: msys2/setup-msys2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Closes #14301
2024-07-30 11:59:02 +02:00
Daniel Stenberg
3c914bc680
x509asn1: clean up GTime2str
Co-authored-by: Stefan Eissing
Reported-by: Dov Murik

Closes #14307
2024-07-30 11:22:36 +02:00
Daniel Stenberg
abdf612221
tool_operate: more defensive socket code
- use 'struct sockaddr' to getsockname() and its sa_family member

- use 'curl_socklen_t' instead of 'socklen_t'

- check for AF_INET6 to exist instead assuming it does

Should be generally more portable.

Reported-by: Harry Sintonen
Closes #14304
2024-07-30 09:10:30 +02:00
Viktor Szakats
c879554b7d
configure: limit __builtin_available test to Darwin
This feature test always fails on non-Apple systems. (For Apple targets
it's supported by llvm and Apple clang.)

Syncs behaviour with CMake.

Follow-up to cfd6f43d6c #14127
Cherry-picked from #14097
Closes #14196
2024-07-29 21:39:17 +02:00
Daniel Stenberg
6821e54c08
RELEASE-NOTES: synced 2024-07-29 21:24:32 +02:00
Daniel Stenberg
674e102504
CURLOPT_SSL_CTX_FUNCTION.md: mention CA caching
and add a few more see-also

Closes #14302
2024-07-29 21:19:53 +02:00
Viktor Szakats
e8acb2e55a
cmake: detect libssh via pkg-config
Also:
- fix broken libssh `pkg-config` behaviour on old Linux.
  (when found, `LIBSSH_LINK_LIBRARIES` remains undefined.)

- delete manual libssh config from Old Linux CI job,
  it's no longer necessary.

Closes #14199
2024-07-29 21:08:17 +02:00
Viktor Szakats
efce544418
GHA/non-native: improve, migrate x86_64 FreeBSD with tests from Cirrus CI
- run tests via `make test-ci` instead of `make check` with autotools.
- add `x86_64` job for FreeBSD, with tests.
  It matches the existing Cirrus CI job, with these differences:
  - finishes 3x faster (thanks to parallel tests enabled).
  - librtmp is not enabled because it's slated for removal by FreeBSD.
    (already past the removal deadline, thought the package still
    installs.)
  - DICT and TELNET servers fail to start. Couldn't figure out why.
    It means skipping test 1450 and 1452.
  - it runs more tests, e.g. websockets and ip6-localhost.
  - no `pkg update -f`.
  - it misses the `CRYPTOGRAPHY_DONT_BUILD_RUST=1`, `pkg delete curl`,
    `chmod 777`, `sudo -u nobody` and `sysctl net.inet.tcp.blackhole`
    tricks. The latter is the default in these runners, the others did
    not affect results.
- set `-j0` for tests in the NetBSD job. Flaky otherwise.

Closes #14244
2024-07-29 20:46:40 +02:00
Viktor Szakats
669ce42275
cmake: detect nettle when building with GnuTLS
`nettle` is a direct dependency of curl, when building with GnuTLS.
Add a new `Find` module to detect it.

Also:
- GHA/macos: drop `nettle` hack no longer necessary.
- add `nettle` to `libcurl.pc`.
- also add `nettle` to `libcurl.pc` in autotools builds.

Follow-up to 781242ffa4 #11967
Closes #14285
2024-07-29 20:41:39 +02:00
Viktor Szakats
5f6b9244ce
macos: fix Apple SDK bug workaround for non-macOS targets
Turns out that MAC != OSX, despite what these names otherwise mean and
what's suggested by source code comments. "MAC" in fact means Darwin
(aka Apple), not macOS. "OSX" means macOS.

GitHub bumped the macos-14 runner default to Xcode 15.4, hitting the
llvm@15 incompatibility bug by default. Meaning the previous workaround
for the SDK bug is necessary.

This patch extend the workaround to not apply to mobile OS variants.

Follow-up to ff784af461 #14159
Reported-by: Sergey
Confirmed-by: Marcel Raad
Fixes #14269
Closes #14275
2024-07-29 20:41:39 +02:00