Граф коммитов

72 Коммитов

Автор SHA1 Сообщение Дата
Stefan Eissing 18c61aa036
GHA: configure OpenSSL's libdir as 'lib' only
Also mention in HTTP3.md

OpenSSL has a bug that messes the config `--libdir=path` to become the
wrong path in its pkgconfig files. If we just pass `--libdir=lib` it
should avoid this.

Ref: #14099
See also: https://github.com/openssl/openssl/issues/23569

Closes #14102
2024-07-05 10:16:08 +02:00
renovate[bot] 8b368fa3c9
GHA: update pinned actions
- github/codeql-action digest to 23acc5c
- actions/checkout digest to 692973e
- rojopolis/spellcheck-github-actions digest to d354a4d

Closes #13935
Closes #13945
Closes #13946
2024-06-14 09:36:22 +02:00
Stefan Eissing 5f9017d4e2
mbedtls: v3.6.0 workarounds
- add special sauce to disable unwanted peer verification by mbedtls
  when negotiating TLS v1.3
- add special sauce for MBEDTLS_ERR_SSL_RECEIVED_NEW_SESSION_TICKET
  return code on *writing* TLS data. We assume the data had not been
  written and EAGAIN.
- return correct Curl error code when peer verification failed.
- disable test_08_05 with 50 HTTP/1.1 connections, as mbedtls reports a
  memory allocation failed during handshake.
- bump CI mbedtls version to 3.6.0

Fixes #13653
Closes #13838
2024-06-04 09:02:37 +02:00
Viktor Szakats 464282ddfb
GHA: bump all build jobs to nproc+1
- bump rest of the workflows (windows, macos, distrocheck).

- non-native virtualized envs have 2 CPUs, bump down accordingly.
  (for `vmactions/omnios-vm` it's just a guess.)

- bump all to nproc + 1.

Follow-up to e838b341a0 #12927
Closes #13807
2024-06-02 21:39:49 +02:00
Ayesh Karunaratne e838b341a0
GHA: adjust parallel job counts
Adjusts the `make -j` flag to match the latest GitHub-hosted runner
hardware specs[^1]:

 - `ubuntu-latest` on 4 CPU cores
 - `macos-latest` on 3 CPU cores

The processor count is ideally obtained from `nproc`, but setting env
vars from the current CI yaml files is not possible because they expect
literal strings.

[^1]: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories

Closes #12927
2024-05-30 09:57:50 +02:00
Viktor Szakats 4521eac45a
CI: disable dependency tracking in most autotools builds
For better build performance. Dependency tracking causes a build
overhead while compiling to help a subsequent build, but in CI there is
never one and the extra work is discarded.

Closes #13794
2024-05-27 22:25:14 +02:00
dependabot[bot] ac68a2dd85
GHA: bump actions/checkout from 4.1.4 to 4.1.6
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.1.4 to 4.1.6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](0ad4b8fada...a5ac7e51b4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Closes #13720
2024-05-22 09:14:10 +02:00
Stefan Eissing 345557248e
pytest: fixes for recent python, add FTP tests
Fixes:
- in uds tests, abort also silently on os errors
- be conservative on the h3 goaway duration
- detect curl debug build and use in checks
- fix caddy version check for slight difference under linux
- set caddy default path fitting for linux
- fix deprecation warnings in valid time checks

FTP tests:
- add '--with-test-vsftpd=path' to configure
- use vsftpd default path suitable for linux
- add test_30 with plain FTP tests
- add test_31 with --ssl-reqd FTP tests
- add vsftpd to linux GHA for pytest workflows

Closes #13661
2024-05-17 16:53:17 +02:00
renovate[bot] 7398037abe
GHA: pin dependencies
Closes #13628
2024-05-15 13:35:45 +02:00
renovate[bot] 7b4f80ebae
ci: update libressl-portable/portable to v3.9.2
Closes #13649
2024-05-15 07:59:01 +02:00
Max Dymond 599fe1e4c5 ci: handle git submodules for mbedTLS 2024-05-14 16:26:11 +01:00
Max Dymond 4f262ee0e1 Add the remainder of the workflows 2024-05-13 22:34:46 +01:00
Max Dymond 73a3602120 Add some basic versioning for some workflows to check whether this is detected properly 2024-05-13 22:34:46 +01:00
Philip H. 303bb8785c
ci: remove microsoft-prod.list
This is added by default, and it is often broken, but we don't need
anything from it.

Closes #13473
2024-04-25 23:27:42 +02:00
Stefan Eissing 7f26fd17dd
CI: update component versions
- ngtcp2: v1.4.0
- nghttp3: v1.2.0
- nghttp2: v1.61.0
- mod_h2: v2.0.27

Closes #13316
2024-04-08 16:19:23 +02:00
Daniel McCarney 5b1a88e2c0
deps: update librustls 0.12.0 -> 0.13.0
This commit updates the optional rustls-ffi librustls dependency from
0.12.0 to 0.13.0. This version is based on the latest available rustls
release (0.23.4).

The breaking API changes from 0.12.0 to 0.13.0 are in API surface unused
by curl, so this is an in-place update without any code changes.

The `RUSTLS.md` documentation is updated to reflect the new version in
use, and to clarify that `cbindgen` isn't required to build `librustls`
- it's only used by developers to update the vendored `rustls.h` header
file maintained upstream.

Closes #13238
2024-03-30 22:39:42 +01:00
Daniel Stenberg 09f367977a
GHA/linux: add sysctl trick to work-around GitHub runner issue
The GitHub image runner update from 20240304.1.0 to 20240310.1
introduces a problem for clang-14. The issue is caused by
incompatibility between llvm 14 provided in ubuntu-22.04 image and the
much newer kernel configured with high-entropy ASLR.

As a work-around, we issue a sysctl command to lower the entropy and get
clang-14 to work again.

URL: https://github.com/actions/runner-images/issues/9491

Closes #13124
2024-03-14 14:04:23 +01:00
kpcyrd e3a4273c41
rustls: make curl compile with 0.12.0
Closes #12989
2024-02-26 08:59:43 +01:00
Graham Campbell 621cab26a9
GHA: bump ngtcp2, gnutls, mod_h2, quiche
- ngtcp2 to v1.2.0
- gnutls to 3.8.3
- mod_h2 to 2.0.26
- quiche to 0.20.0

Closes #12778
Closes #12779
Closes #12780
Closes #12781
2024-01-25 08:57:09 +01:00
Stefan Eissing 5125ddbb10 CI: remove unnecessary OpenSSL 3 option `enable-tls1_3`
.. and switch OpenSSL 3 libdir from lib64 to lib for consistency.

Closes https://github.com/curl/curl/pull/12758
2024-01-23 14:24:22 -05:00
dependabot[bot] dfe34d2559
CI: bump actions/cache from 3 to 4
Bumps [actions/cache](https://github.com/actions/cache) from 3 to 4.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Closes #12756
2024-01-23 08:39:58 +01:00
Daniel Stenberg d18811b52b
CI: install libpsl or configure --without-libpsl in builds
As a follow-up to the stricted libpsl check in configure
2024-01-09 09:10:58 +01:00
Viktor Szakats 2d4d0c1fd3
appveyor: replace PowerShell with bash + parallel autotools
PowerShell works (after a steep development curve), but one property of
it stuck and kept causing unresolvable usability issues: With
`$ErrorActionPreference=Stop`, it does abort on failures, but shows only
the first line of the error message. In `Continue` mode, it shows the
full error message, but doesn't stop on all errors. Another issue is
PowerShell considering any stderr output as if the command failed (this
has been improved in 7.2 (2021-Nov), but fixed versions aren't running
in CI and will not be for a long time in all test images.)

Thus, we're going with bash.

Also:
- use `-j2` with autotools tests, making them finish 5-15 minutes per
  job faster.
- omit `POSIX_PATH_PREFIX`.
- use `WINDIR`.
- prefer forward slashes.

Follow-up to: 75078a415d #11999
Ref: #12444

Fixes #12560
Closes #12572
2023-12-21 22:54:07 +00:00
Viktor Szakats 2dbe75bd7f
build: fix some `-Wsign-conversion`/`-Warith-conversion` warnings
- enable `-Wsign-conversion` warnings, but also setting them to not
  raise errors.
- fix `-Warith-conversion` warnings seen in CI.
  These are triggered by `-Wsign-converion` and causing errors unless
  explicitly silenced. It makes more sense to fix them, there just a few
  of them.
- fix some `-Wsign-conversion` warnings.
- hide `-Wsign-conversion` warnings with a `#pragma`.
- add macro `CURL_WARN_SIGN_CONVERSION` to unhide them on a per-build
  basis.
- update a CI job to unhide them with the above macro:
  https://github.com/curl/curl/actions/workflows/linux.yml -> OpenSSL -O3

Closes #12492
2023-12-19 12:45:28 +00:00
Viktor Szakats bda2129114
tidy-up: fix yamllint whitespace issues
Closes #12466
2023-12-06 17:25:59 +00:00
Viktor Szakats 413a0fedd0
autotools: stop setting `-std=gnu89` with `--enable-warnings`
Do not alter the C standard when building with `--enable-warnings` when
building with gcc.

On one hand this alters warning results compared to a default build.
On the other, it may produce different binaries, which is unexpected.

Also fix new warnings that appeared after removing `-std=gnu89`:

- include: fix public curl headers to use the correct printf mask for
  `CURL_FORMAT_CURL_OFF_T` and `CURL_FORMAT_CURL_OFF_TU` with mingw-w64
  and Visual Studio 2013 and newer. This fixes the printf mask warnings
  in examples and tests. E.g. [1]

- conncache: fix printf format string [2].

- http2: fix potential null pointer dereference [3].
  (seen on Slackware with gcc 11.)

- libssh: fix printf format string in SFTP code [4].
  Also make MSVC builds compatible with old CRT versions.

- libssh2: fix printf format string in SFTP code for MSVC.
  Applying the same fix as for libssh above.

- unit1395: fix `argument is null` and related issues [5]:
  - stop calling `strcmp()` with NULL to avoid undefined behaviour.
  - fix checking results if some of them were NULL.
  - do not pass NULL to printf `%s`.

- ci: keep a build job with `-std=gnu89` to continue testing for
  C89-compliance. We can apply this to other gcc jobs as needed.
  Ref: b23ce2cee7 (2022-09-23) #9542

[1] https://dev.azure.com/daniel0244/curl/_build/results?buildId=18581&view=logs&jobId=ccf9cc6d-2ef1-5cf2-2c09-30f0c14f923b
[2] https://github.com/curl/curl/actions/runs/6896854263/job/18763831142?pr=12346#step:6:67
[3] https://github.com/curl/curl/actions/runs/6896854253/job/18763839238?pr=12346#step:30:214
[4] https://github.com/curl/curl/actions/runs/6896854253/job/18763838007?pr=12346#step:29:895
[5] https://github.com/curl/curl/actions/runs/6896854253/job/18763836775?pr=12346#step:33:1689

Closes #12346
2023-11-20 22:28:17 +00:00
Stefan Eissing 5a3e277290
GHA: fix checkout of quictls repository to use correct branch name
Follow-up to c868b0e30f

Closes #12232
2023-10-30 16:58:45 +01:00
Daniel Stenberg c868b0e30f
GHA: bump ngtcp2, nghttp3, nghttp2 and quictls versions
ngtcp2 1.0.1
nghttp3 1.0.0
nghttp2 1.58.0
quictls 3.1.4+quic

also sync HTTP3.md with these changes

Closes #12132
2023-10-29 17:39:23 +01:00
Stefan Eissing 8cb95850c0
GHA: move mod_h2 version in CI to v2.0.25
Closes #12157
2023-10-19 16:51:59 +02:00
Viktor Szakats 9243ed6f4b
GHA/linux: mbedtls 3.5.0 + minor dep bumps
Closes #12057
2023-10-07 20:34:53 +00:00
Viktor Szakats c39585d9b7
gha: bump actions to latest versions
- actions@checkout@v4 (from v3 and v2)

- fsfe/reuse-action@v2 (from v1)

Closes #12000
2023-10-01 12:16:23 +00:00
Daniel Stenberg 367be426d9
GHA/linux: run singleuse to detect single-use global functions
Use --unit for configure --enable-debug builds

Closes #11932
2023-09-25 17:06:09 +02:00
Dan Fandrich 14108c1b80 CI: run pytest with the -v option
This lists of the test cases being run so it can be tracked over time.

Closes #11824
2023-09-11 09:20:40 -07:00
Stefan Eissing 3b30cc1a0d
pytest: improvements
- set CURL_CI for pytest runs in CI environments
- exclude timing sensitive tests from CI runs
- for failed results, list only the log and stat of
  the failed transfer

- fix type in http.c comment

Closes #11812
2023-09-07 10:30:14 +02:00
Dan Fandrich cc746076e0 CI: move the Alpine build from Cirrus to GHA
Cirrus is reducing their free tier to next to nothing, so we must move
builds elsewhere.
2023-08-30 23:50:16 -07:00
Viktor Szakats ddb179586f
gha: bump libressl and mbedtls versions
Closes #11573
2023-08-02 10:39:01 +00:00
Daniel Stenberg 7c8bae0d9c
nss: remove support for this TLS library
Closes #11459
2023-07-29 23:44:28 +02:00
Stefan Eissing b0f3e030c0
GHA/linux.yml: add caching
Closes #11532
2023-07-28 23:10:41 +02:00
Stefan Eissing 2284104c3f
CI: quiche updates
- remove quiche from standard `linux` workflow
- add mod_h2 caching to quiche workflow
- rename quiche to quiche-linux
- move version definitions into env section

Closes #11528
2023-07-27 17:47:09 +02:00
Jacob Hoffman-Andrews 69c536b9c0
rustls: update rustls-ffi 0.10.0
This brings in version 0.21.0 of the upstream rustls implementation,
which notable includes support for IP address certificates.

Closes #10865
2023-07-22 23:40:44 +02:00
Dan Fandrich 356208c16f CI: enable verbose test output on pytest
This shows individual pass/fail status on tests and makes this output
consistent with other jobs' pytest invocations.
2023-07-07 13:47:34 -07:00
Dan Fandrich fb802b521a CI: enable parallel make in more builds
Most CI services provide at least two cores, so enable parallel make
jobs to take advantage of that for builds. Some dependencies aren't safe
to build in parallel so leave those as-is.  Also, rename a few
workflows to eliminate duplicate names and provide a better idea what
they're about.
2023-06-24 14:40:39 -07:00
Stefan Eissing acd82c8bfd
tests/http: more tests with specific clients
- Makefile support for building test specific clients in tests/http/clients
- auto-make of clients when invoking pytest
- added test_09_02 for server PUSH_PROMISEs using clients/h2-serverpush
- added test_02_21 for lib based downloads and pausing/unpausing transfers

curl url parser:
- added internal method `curl_url_set_authority()` for setting the
  authority part of a url (used for PUSH_PROMISE)

http2:
- made logging of PUSH_PROMISE handling nicer

Placing python test requirements in requirements.txt files
- separate files to base test suite and http tests since use
  and module lists differ
- using the files in the gh workflows

websocket test cases, fixes for we and bufq
- bufq: account for spare chunks in space calculation
- bufq: reset chunks that are skipped empty
- ws: correctly encode frames with 126 bytes payload
- ws: update frame meta information on first call of collect
  callback that fills user buffer
- test client ws-data: some test/reporting improvements

Closes #11006
2023-04-26 23:24:46 +02:00
Philip H 314dc407d6
GHA: suppress git clone output
Follow-up: 8203aa6ed4

Closes #10949
2023-04-13 17:22:13 +02:00
Philip H 8203aa6ed4
GHA: suppress git clone output
Closes #10939
2023-04-13 08:56:48 +02:00
Daniel Stenberg d03c4dc165
GHA: add a memory-sanitizer job
Closes #10815
2023-03-24 11:04:59 +01:00
Daniel Stenberg caf92a57b0
GHA: run all linux test jobs with valgrind
Closes #10798
2023-03-22 13:51:28 +01:00
Daniel Stenberg 5bfe3dc3b6
GHA-linux: add an address-sanitizer build
Closes #10810
2023-03-22 13:37:49 +01:00
Stefan Eissing 7fa6e36583
tests/http: add pytest to GHA and improve tests
- added to: ngtcp2-quictls, ngtcp2-gnutls and the linux varians
  quiche, bearssl, libressl, mbedtls, openssl3, rustls
- added disabled in ngtcp2-wolfssl due to weird SSL_connect() errors
  not reproducable locally

Improvements on pytest:

-  handling of systems with nghttpx in $PATH
   - configure will seach $PATH got nghttpx used in pytest
   - pytest fixes for managing nghttpx without h3 support
   - ngtcp2-wolfssl: use a fully enabled wolfssl build

- lower parallel count for http/1.1 tests, since we do not
   want to test excessive connections.
- check built curl for HTTPS-proxy support in proxy tests
- bearssl does not like one of our critical cert extensions, making
  it non-critical now
- bearssl is too slow for test_12, skipping
- making sure we do h3 tests only when curl and server support is there

Closes #10699
2023-03-13 14:06:57 +01:00
Dan Fandrich 395b9175b7 CI: don't run CI jobs if only another CI was changed
Also skip builds on non-Windows platforms when only Windows build files
have changed.

This should reduce the number of useless builds and the associated
waiting time and chance of spurious failures, freeing resources for
new PRs.

Closes #10742
2023-03-11 18:59:45 -08:00