Commit Graph

34814 Commits

Author SHA1 Message Date
Viktor Szakats
68c358619f
tests: replace hard-coded /dev/null with variable
- add variable for the null device filename and use that in Perl code.
- initialize this variable with `NUL` on native Windows.
- add `%DEV_NULL` variable and use it in tests.

Fixes `The system cannot find the path specified.` messages seen when
running `runtests.pl` with native Windows Perl.

Also adjust code to not break mcedit syntax highlighting.

Cherry-picked from #14949
Closes #15098
2024-10-01 12:07:19 +02:00
Viktor Szakats
31a29fc6bd
tests: add and use %PERL variable to refer to the Perl binary
To ensure Perl invocations within tests call the same Perl binary used
for running the tests, as specified or auto-detected via `PERL` env
(autotools) or `PERL_EXECUTABLE` setting (cmake). Instead of the first
`perl` executable found in `PATH`.)

Cherry-picked from #14949
Closes #15097
2024-10-01 12:04:50 +02:00
Viktor Szakats
f6cb707b6a
tests: replace %PWD with %FILE_PWD for file://
Before this patch not all tests used `%FILE_PWD` with the `file://`
protocol.

Keep `%PWD` for test1145, to keep it fail on Windows like the test
expects.

Cherry-picked from #14949

Closes #15090
2024-09-30 23:48:00 +02:00
Viktor Szakats
18143579ba
cmake: readd generate-curl.1 dependency for src just in case
Trying to fix intermittent build failures with MSVC 2008:
```
unity_0.obj : error LNK2019: unresolved external symbol _showhelp referenced in function _tool_help
unity_0.obj : error LNK2019: unresolved external symbol _hugehelp referenced in function _operate
```
https://ci.appveyor.com/project/curlorg/curl/builds/50700212/job/h3ekljnbccosej5k#L154
https://ci.appveyor.com/project/curlorg/curl/builds/50701615/job/61mkg9og1eooqli8#L155

Follow-up to 496da69aa0 #14883

Closes #15088
2024-09-30 14:11:23 +02:00
Viktor Szakats
212ff19b60
runtests: drop unused code for old/classic-mingw support
Follow-up to 38029101e2 #11625

Closes #15087
2024-09-30 14:11:23 +02:00
Viktor Szakats
aed3f02317
GHA: move Cygwin jobs back into the Windows workflow
Cygwin jobs took 30 minutes and was the reason for moving them to their
own workflow. After recent changes, they finish in 8 minutes, which is
on par or lower than the longest Windows jobs. Thus, Cygwin can now be
moved back to the Windows workflow without causing extra wait for all
the workflow jobs to complete (and allowing a manual retry for the
remaining flaky jobs).

Notice that Cygwin still uses the cygwin/cygwin-install-action action to
install Cygwin itself. This action uses no caching and the time it takes
fluctuates widely depending on mirror speed, congestion and other
things. If Cygwin tends to hold up jobs again for this or other reasons,
this patch may be reverted.

Follow-up to 80a8e24956 #15083
Follow-up to 2d8464c4cb #14366

Closes #15086
2024-09-30 14:11:23 +02:00
Viktor Szakats
7bc653a1d6
appveyor: bump to OpenSSL 3.3
Closes #15085
2024-09-30 10:54:46 +02:00
Viktor Szakats
069a9654ca
appveyor: delete unused WebSockets option remains [ci skip] 2024-09-30 10:37:00 +02:00
dependabot[bot]
b85d37a3b9
CI: bump vmactions/omnios-vm from 1.0.6 to 1.0.7
Bumps [vmactions/omnios-vm](https://github.com/vmactions/omnios-vm) from 1.0.6 to 1.0.7.
- [Release notes](https://github.com/vmactions/omnios-vm/releases)
- [Commits](2f97978b47...bc3c64398d)

---
updated-dependencies:
- dependency-name: vmactions/omnios-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Closes #15018
2024-09-30 08:54:48 +02:00
Stefan Eissing
97c0f89bd0
quic: use send/recvmmsg when available
add checks for sendmmsg in configure and CmakeLists.txt for enabling use
of these functions in ngtcp2/quiche quic.

Closes #14880
2024-09-30 08:51:16 +02:00
renovate[bot]
876f17ad24
ci: update dependency awslabs/aws-lc to v1.36.0
Closes #14955
2024-09-30 08:45:45 +02:00
dependabot[bot]
256fa63934
CI: bump github/codeql-action from 3.26.6 to 3.26.8
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.26.6 to 3.26.8.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](4dd16135b6...294a9d9291)

---
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 #15019
2024-09-30 08:44:00 +02:00
Daniel Stenberg
cd63629733
CI/winbuild: remove enabling of websocket - done by default now
Closes #15076
2024-09-30 07:58:54 +02:00
Viktor Szakats
e474b02301
runtests: fix indentation 2024-09-30 01:51:12 +02:00
Viktor Szakats
80a8e24956
GHA/cygwin, msys: move tests to cmake jobs, to finish faster
Move test runs from autotools jobs to cmake ones for Cygwin and MSYS.
This makes producing test results and finishing the workflows faster,
because the cmake build steps are much faster than autotools in these
envs.

Also:
- drop building examples with Cygwin autotools. It takes almost
  4 minutes. Keep building them with cmake, taking 20 seconds.
- drop building examples in MSYS autotools jobs that run tests.
  Keep building them in autotools jobs without tests. It makes
  the longest running job 2 minutes shorter.

After this patch Cygwin job times are on par with or lower than Windows
ones. It means Cygwin doesn't cause extra delay to finish the whole
workflow, allowing to re-merge these jobs into the Windows workflow.

Closes #15083
2024-09-30 01:45:01 +02:00
Viktor Szakats
47d604ae7e
GHA/windows: fix find in old-mingw-w64 curl -V step
By default it runs the Windows `find` command and fails.
Tweak the `PATH` to find the MSYS shell implementation.
2024-09-29 22:35:48 +02:00
Viktor Szakats
2c419fc14b
ci: tidy-ups
- http3-linux: add newlines for readability.
- http3-linux: use `make pytest` to run pytest.
- checksrc: use `|` multiline to sync with other uses.
- checksrc: prefer `$()`.
- prefer `>-` over `>` for folded option lists.
- cygwin: drop a `grep` no longer necessary.

Closes #15081
2024-09-29 17:39:55 +02:00
Viktor Szakats
8a8719d2e1
cmake: websockets tidy-ups
- restore change lost after websockets-default update.
  Ref: 6a1dcdc5d2 #14998
- delete unused line after websockets is on by default.
  Follow-up to d78e129d50 #14936

Closes #15078
2024-09-29 17:39:55 +02:00
Viktor Szakats
842f88434f
GHA linux: restore apt-get update
It seems like the Ubuntu apt mirror list or other preloaded data on the
Linux runner can go stale (?) throughout a single week causing failures
like this, in some of the jobs:
```
Ign:16 http://security.ubuntu.com/ubuntu jammy-updates/main amd64 libapr1-dev amd64 1.7.0-8ubuntu0.22.04.1
Err:16 mirror+file:/etc/apt/apt-mirrors.txt jammy-updates/main amd64 libapr1-dev amd64 1.7.0-8ubuntu0.22.04.1
  404  Not Found [IP: 40.81.13.82 80]
Get:24 http://azure.archive.ubuntu.com/ubuntu jammy-updates/main amd64 libnghttp2-dev amd64 1.43.0-1ubuntu0.2 [117 kB]
Get:25 http://azure.archive.ubuntu.com/ubuntu jammy-updates/main amd64 vsftpd amd64 3.0.5-0ubuntu1.1 [123 kB]
Fetched 4029 kB in 2s (1682 kB/s)
E: Failed to fetch mirror+file:/etc/apt/apt-mirrors.txt/pool/main/a/apr/libapr1-dev_1.7.0-8ubuntu0.22.04.1_amd64.deb  404  Not Found [IP: 40.81.13.82 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
Error: Process completed with exit code 100.
```
https://github.com/curl/curl/actions/runs/11074211380/job/30772496037#step:32:63

Restore `apt update` to fix it.

Follow-up to 1b8449674a #14992

Closes #15082
2024-09-28 20:59:22 +02:00
Tatsuhiro Tsujikawa
7048d1d211
docs/cmdline-opts: GnuTLS supports PKCS#11 URI in --cert option
Closes #15075
2024-09-28 18:09:05 +02:00
Viktor Szakats
f2ce14e10a
singleuse: limit checks to non-unity jobs
`singleuse.pl` requires non-unity builds. With unity builds, it remains
silent.

- make some jobs non-unity to allow singleuse to do its job.
- since all jobs used the `--unit` singleuse checker option, make this
  option permanent.

Closes #15065
2024-09-27 18:24:31 +02:00
Viktor Szakats
9541e66623
GHA/windows: formatting, adjust timeouts, tidy-ups
- reduce job timeouts for msys2 and old-mingw-w64 jobs.
- fold long lines and reorder options in MSVC jobs.
- make some options default in MSVC jobs.

Closes #15017
2024-09-27 18:24:31 +02:00
Dan Fandrich
95d33905fb CI: update 32-bit CI to Ubuntu 24.04 and enable more
Enable librtmp, libssh, libidn2 and c-ares support for broader 32-bit
test coverage. Bump the gcc version to 14.

Closes #15068
2024-09-27 08:59:55 -07:00
Stefan Eissing
7f3d598276
CI: improvements in test reliability and performance
- CI default: raise parallelism to 20
- CI valgind: set parallelism to 6
- CI non-native: adapt parallelism for OS builds
- CI Windows: no longer ignore FTP, TFTP, MQTT and SMTP
- CI Windows: restrict test timeout to 10 minutes
- CI Windows: do not run tests for msh3 build
- tests, various: restrict curl invocation to ipv4 to avoid talking to
  any ipv6 test server running in parallel
- tests: requiring http/2 server no longer needs to mention http server
- test 190: use a fixed timeout of 10 seconds instead of %FTPTIME2, as
  that value rises under parallel load beyond what the server is waiting
  and then produces different results
- test 1540: add debug logging
- testrunner: add verify checks for http/2 and http/3 server

Closes #15040
2024-09-27 16:47:37 +02:00
Daniel Stenberg
aca28abac7
lib: fix disabled-verbose-strings + enable-debug build warnings 2024-09-27 13:20:25 +02:00
Daniel Stenberg
d78e129d50
WebSockets: make support official (non-experimental)
Inverts the configure/cmake options to instead provide options that
disable WebSockets and have them (ws + wss) enabled by default.

Closes #14936
2024-09-27 13:20:25 +02:00
Viktor Szakats
cfae354a9a
codespell: extend checks to more subdirs
- fix issues found.
- fix a few more found locally.

Closes #15072
2024-09-27 10:27:08 +02:00
Viktor Szakats
6b2824dae1
GHA/torture: prefer pip --break-system-packages for speed
Follow-up to c5e3d8ba94 #14972

Closes #15071
2024-09-27 10:27:08 +02:00
Viktor Szakats
fcc89619d9
singleuse: make git grep faster, add Apple nm support
- avoid regexp in grep to make it run faster.
- add support for parsing Apple `nm` output:
  - skip leading underscore from function names.
  - pick object name from output.

Closes #15070
2024-09-27 10:27:08 +02:00
Viktor Szakats
f0f9e2c61f
GHA/http3-linux: add name to align with other Linux workflows
Closes #15069
2024-09-27 10:27:08 +02:00
Daniel Stenberg
1b0da9cfc7
RELEASE-NOTES: synced 2024-09-26 23:52:59 +02:00
Viktor Szakats
44505adb36
GHA/linux: improve cmake use, switch to Ninja
- cmake: allow easy switching of generator (= make tool).
- merge autotools/cmake job steps.
- cmake: switch to Ninja.
  (build was already fast, Ninja doesn't make it noticeably faster)

Closes #15023
2024-09-26 23:43:45 +02:00
Daniel Stenberg
d08d16cac3
multi: avoid reading whole struct pointer from pointer
The proper alignment is not guaranteed. This function now instead uses
only the first and last byte of the key since they are the ones likely
to change most (one of them, depending on CPU endian) and the hash is
tiny anyway.

Closes #15063
2024-09-26 23:37:15 +02:00
Stefan Eissing
6f2a1666a1
tests: use '-4' where needed
Our test servers run either on ipv4 *or* on ipv6, as requested.
A test case using 'localhost' or '*.local' in the url needs to
run with the specific version of the server started.

Otherwise, curl's "happy eyeball"ing will connect to another
server that may be running due to parallel testing or for some
other reasons.

Note that port reuse here depends on the OS strategy and it
seems netbsd is especially likely to hit this.

Closes #15060
2024-09-26 23:36:09 +02:00
Stefan Eissing
841fbdb63c
tests: improve mqtt server handling
Check that the mqtt server process actually is running.
Handle its port number similar to other servers.

Closes #15059
2024-09-26 23:35:13 +02:00
Stefan Eissing
e61c5eb417
tests: check http/2 and http/3 server responsiveness
Check responsiveness of http/3 server when running.

Also, a test case with http/2 or http/3 server requirement
now implicitly drags in a 'http' server and we need no longer
mention that in testdata.

Closes #15058
2024-09-26 23:34:16 +02:00
Stefan Eissing
ef400f4f38
test190: replace %FTPTIME2 with a fixed value
The variable FTPTIME2 may, on a loaded test server, become so
large that the timeout does not happen before the fixed 60 seconds
the server waits.

Closes #15056
2024-09-26 23:33:18 +02:00
Daniel Stenberg
dc284be4cc
tests: remove the %FTPTIME3 variable
Nothing uses it.

Ref: #15056
Closes #15064
2024-09-26 23:25:47 +02:00
Daniel Stenberg
af60bdf4ec
socks_gssapi: switch to dynbuf from buffer with strcpy
Closes #15057
2024-09-26 23:24:14 +02:00
Dan Fandrich
8e9a8dd978 tests: add file: tests with existing files
Windows sometimes has issues when opening the same file twice, so these
test two situations where that could potentially occur.

Reported-by: ralfjunker on github
Ref: #15043
Closes #15045
2024-09-26 10:10:36 -07:00
Daniel Stenberg
dd0405c909
test518: restore valgrind disable
Follow-up to c91c37b6e8

The test does not work well when run with valgrind

Closes #15062
2024-09-26 17:02:09 +02:00
Daniel Stenberg
5d7275d5df
openssl: convert a memcpy to dynbuf use
and avoid an alloc for CN handling unless necessary

Closes #15049
2024-09-26 17:00:43 +02:00
Stefan Eissing
b2dc95540a
test1540: add debug logging
Closes #15055
2024-09-26 16:58:42 +02:00
Stefan Eissing
cbbf4d8ed2
test504: fix handling on pending connect
Test expected a connect to a port no one is listening to immediately
fail. But Windows has its internal retry logic that may fail this.

As fix, multi_perform()/multi_wait() until transfer is done.

Closes #15054
2024-09-26 16:57:51 +02:00
Stefan Eissing
17a7e12e1b
test2502: add libtest debug tracing
Closes #15053
2024-09-26 16:57:13 +02:00
Stefan Eissing
f518982775
testrun: explicitly set proper IP address for stunnel listen/connect
Closes #15051
2024-09-26 16:55:52 +02:00
Gabriel Marin
8289ac1be6
lib/cw-out: initialize 'flush_all' directly
Closes #15044
2024-09-26 16:55:01 +02:00
Stefan Eissing
21fb30b5d1
test1035: convert host name back to utf8 as should be
Follow-up to 0b70b23ef4

Closes #15050
2024-09-26 16:54:03 +02:00
Daniel Stenberg
4e22d7c56a
openssl: remove two strcpy() calls
Closes #15052
2024-09-26 15:51:47 +02:00
Daniel Stenberg
f383a17617
tool_doswin: simplify; remove unused options and strncpy calls
SANITIZE_ALLOW_TRUNCATE and SANITIZE_ALLOW_COLONS were never used by
code, thus only making the code complicated for no good use.

Since nothing should truncate, using strncpy() is wrong.

Two cases of malloc + copy replaced with proper strdup() calls.

Fixup unit test 1604 accordingly.

Closes #15047
2024-09-26 10:45:08 +02:00