Commit Graph

5442 Commits

Author SHA1 Message Date
Stefan Eissing
3797f1a4ca
rustls: fix error in recv handling
- when rustls is told to recieve more TLS data and its internal
  plaintext buffers are full, it returns an IOERROR
- avoid receiving TLS data while plaintext is not read empty

pytest:
- increase curl run timeout when invoking pytest with higher verbosity

Closes #10876
2023-03-31 16:05:15 +02:00
Stefan Eissing
544abeea83
http3: improvements across backends
- ngtcp2: using bufq for recv stream data
- internal stream_ctx instead of `struct HTTP` members
  for quiche, ngtcp2 and msh3
- no more QUIC related members in `struct HTTP`
- experimental use of recvmmsg(), disabled by default
  - testing on my old debian box shows no throughput improvements.
  - leaving it in, but disabled, for future revisit
- vquic: common UDP receive code for ngtcp2 and quiche
- vquic: common UDP send code for ngtcp2 and quiche
- added pytest skips for known msh3 failures
- fix unit2601 to survive torture testing
- quiche: using latest `master` from quiche and enabling large download
  tests, now that key change is supported
- fixing test_07_21 where retry handling of starting a stream
  was faulty
- msh3: use bufq for recv buffering headers and data
- msh3: replace fprintf debug logging with LOG_CF where possible
- msh3: force QUIC expire timers on recv/send to have more than
  1 request per second served

Closes #10772
2023-03-31 15:44:57 +02:00
Dan Fandrich
a094ec1a85 test1471/2: add http as a required feature
curl bails out early with a different error message if http support is
compiled out.

Ref: #10705
2023-03-30 23:55:33 -07:00
Dan Fandrich
2dd471d577 tests: limit return code of unit tests and lib tests
Values greater than 125 have special meanings, so cap it there.  Unit
tests and lib tests use the number of failures as the return code, so a
large number of failures (such as test 2601 as a torture test) can
exceed this causing the test to be erroneously reported as having
failed.

Ref: #10720
2023-03-30 19:16:40 -07:00
Dan Fandrich
9fa018dbf7 test1960: point to the correct path for the precheck tool
Otherwise, it might find the binary in .libs which can cause it to use
the system libcurl which can fail. This error is only visible by
noticing that the test is skipped.

Follow-up to e4dfe6fc

Ref: #10651
2023-03-30 17:40:39 -07:00
Dan Fandrich
f754990acf tests: use the proper %LOGDIR path on two tests
Follow-up to e7a021e1

Ref: #10818
2023-03-30 17:40:24 -07:00
Stefan Eissing
041cf77cbd
tests/http: relax connection check in test_07_02
Only 1 connection will be used when curl is slow, happens when
address-sanitized in CI, for example

Closes #10865
2023-03-30 23:51:16 +02:00
Stefan Eissing
744dcf22fa
http2: flow control and buffer improvements
- use bufq for send/receive of network data
- usd bufq for send/receive of stream data
- use HTTP/2 flow control with no-auto updates to control the
  amount of data we are buffering for a stream
  HTTP/2 stream window set to 128K after local tests, defined
  code constant for now
- elminiating PAUSEing nghttp2 processing when receiving data
  since a stream can now take in all DATA nghttp2 forwards

Improved scorecard and adjuste http2 stream window sizes
- scorecard improved output formatting and options default
- scorecard now also benchmarks small requests / second

Closes #10771
2023-03-30 23:11:26 +02:00
Dan Fandrich
4ced75b7ce runtests: show error message if file can't be written 2023-03-30 09:53:57 -07:00
Dan Fandrich
58e85d6d1d tests: fix remaining servers to run with a dynamic log directory
This final commit in the series is sufficient to allow the tests succeed
if $LOGDIR is changed in runtests.pl.

Ref: #10818
Closes #10866
2023-03-30 09:53:57 -07:00
Dan Fandrich
0bdb95ecbf tests: fix fake_ntlm to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
8a298119f1 tests: fix http servers to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
c753418d8b tests: fix ftpserver to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
c102502eae tests: fix C servers to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
1fe081ab42 tests: fix lib tests to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
6e3734f74f tests: fix unit tests to run with a dynamic log directory
Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
e7a021e135 tests: use %LOGDIR to refer to the log directory
This will allow it be set dynamically.

Ref: #10818
2023-03-30 09:53:57 -07:00
Dan Fandrich
0c82fcde79 runtests: track verification time even if no files to compare 2023-03-30 09:53:57 -07:00
Dan Fandrich
07ab5bdd3b getpart: better handle case of file not found 2023-03-30 09:53:57 -07:00
Dan Fandrich
88f1b70546 testcurl: bump version date
It hadn't been updated in 9 years; it's time.
2023-03-30 09:53:57 -07:00
Dan Fandrich
0e3ae25337 tests: switch to 3-argument open in test suite
The perl 2-argument open has been considered not-quite-deprecated since
the 3-argument form was introduced almost a quarter century ago.
2023-03-30 09:53:57 -07:00
Dan Fandrich
b133f70a52 tests: silence some Perl::Critic warnings in test suite
Not all warnings are fixed; many are as much stylistic suggestions than
anything and IMHO don't do much to actually improve the code.

Ref: #10818
Closes #10861
2023-03-30 09:12:52 -07:00
Dan Fandrich
b5cb9a5a36 docs: bump the minimum perl version to 5.6
It's actually been this way since at least 2012 (when a 3-argument open
was added to runtests.pl). Given the lack of complaints in the interim,
it's safe to call this 23 year old perl version the minimum.
2023-03-30 09:12:52 -07:00
Dan Fandrich
2039253c6e runtests: memoize the getpart* subroutines to speed up access
The refactored code calls these functions with the same arguments more
often, so this prevents redundant test case file parsing.

Approved-by: Daniel Stenberg
Ref: #10818
Closes #10833
2023-03-30 09:12:52 -07:00
Dan Fandrich
1f631864f4 runtests: remove duplicated feature variables
Use the feature map stored in the hash table instead. Most of the
variables were only used only once, to set the value in the hash table.

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
e06eb85b3d runtests: also ignore test file problems when ignoring results
This simplifies error handling in the test verification code and makes
it more consistent.

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
d792cd103c runtests: more refactoring for clarity
Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
1ae94c0930 runtests: don't start servers if -l is given 2023-03-30 09:12:52 -07:00
Dan Fandrich
44ec1986da runtests: fix typos 2023-03-30 09:12:52 -07:00
Dan Fandrich
53abe3809d runtests: refactor singletest() into separate functions
This takes it from a 1200 line behemoth into something more manageable.
The content and order of the functions is taken almost directly from
singletest() so the diff sans whitespace is quite short.

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
6c0ee77c8a runtests: refactor singletest() into distinct sections
Namely:
- Verify that this test case should be run
- Start the servers needed to run this test case
- Check that test environment is fine to run this test case
- Prepare the test environment to run this test case
- Run the test command
- Clean up after test command
- Verify test succeeded

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
1dc3088de3 runtests: stop copying a few arrays where not needed
Unlike some other languages that just copy a pointer, perl copies the
entire array contents which takes time for a large array.

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
d428f00db0 runtests: reduce redundant calls to getpart/getpartattr
These functions scan through the entire test file every time to find the
right section, so they can be slow for large test files.

Ref: #10818
2023-03-30 09:12:52 -07:00
Dan Fandrich
dfeda77573 tests: document that the unittest keyword is special
Also, add other features that were missing.
2023-03-30 09:12:52 -07:00
Matt Jolly
0ae0abbe72
hostip: refuse to resolve the .onion TLD
RFC 7686 states that:

> Applications that do not implement the Tor
> protocol SHOULD generate an error upon the use of .onion and
> SHOULD NOT perform a DNS lookup.

Let's do that.

https://www.rfc-editor.org/rfc/rfc7686#section-2

Add test 1471 and 1472 to verify

Fixes #543
Closes #10705
2023-03-30 15:51:06 +02:00
Stefan Eissing
f8f010e469
tests/http: fix log formatting on wrong exit code
Closes #10868
2023-03-30 13:09:12 +02:00
dengjfzh
6c6306f300
rtsp: skip malformed RTSP interleaved frame data
Some IP cameras send malformed RTSP interleaved frames sometimes, which
can cause curl_easy_perform return 1 (CURLE_UNSUPPORTED_PROTOCOL).  This
change attempts to skip clearly incorrect RTSP interleaving frame data.

Closes #10808
2023-03-30 09:59:09 +02:00
Stefan Eissing
61f52a97e9
lib: add bufq and dynhds
Adding `bufq`:
- at init() time configured to hold up to `n` chunks of `m` bytes each.
- various methods for reading from and writing to it.
- `peek` support to get access to buffered data without copy
- `pass` support to allow buffer flushing on write if it becomes full
- use case: IO buffers for dynamic reads and writes that do not blow up
- distinct from `dynbuf` in that:
  - it maintains a read position
  - writes on a full bufq return CURLE_AGAIN instead of nuking itself
- Init options:
  - SOFT_LIMIT: allow writes into a full bufq
  - NO_SPARES: free empty chunks right away
- a `bufc_pool` that can keep a number of spare chunks to
  be shared between different `bufq` instances

Adding `dynhds`:
- a straightforward list of name+value pairs as used for HTTP headers
- headers can be appended dynamically
- headers can be removed again
- headers can be replaced
- headers can be looked up
- http/1.1 formatting into a `dynbuf`
- configured at init() with limits on header counts and total string
  sizes
- use case: pass a HTTP request or response around without being version
  specific
- express a HTTP request without a curl easy handle (used in h2 proxy
  tunnels)
- future extension possibilities:
  - conversions of `dynhds` to nghttp2/nghttp3 name+value arrays

Closes #10720
2023-03-30 09:08:05 +02:00
Stefan Eissing
8cabef6fc3
pytest: improvements for suitable curl and error output
- will check built curl for http and https support and
  skip all tests if not there
- will dump stdout/stderr/trace output on errored responses

Closes #10829
2023-03-29 13:25:18 +02:00
Daniel Stenberg
baeaeecb0a
test1592: add flaky keyword
Closes #10860
2023-03-29 09:11:50 +02:00
Arne Soete
2eadae8673
tests: update tests/httpd references to tests/http
tests/httpd was renamed to tests/http in #10654. This patch updates some
references in the README

Closes #10854
2023-03-28 17:50:59 +02:00
Stefan Eissing
9d107b6954
tests/http: add timeout to running curl in test cases
- we had a CI case once where `curl` seemingly did not
  return and it was hard to guess what happened.
- make curl execution in test cases time out after 60 seconds

Closes #10783
2023-03-26 17:41:46 +02:00
Daniel Stenberg
8963c25db3
server/getpart: clear the buffer before load
Fixes msan warnings:

==54195==WARNING: MemorySanitizer: use-of-uninitialized-value
    #0 0x55ece35e57cb in line_length /home/runner/work/curl/curl/tests/server/getpart.c:111:25
    #1 0x55ece35e3b83 in readline /home/runner/work/curl/curl/tests/server/getpart.c:164:24
    #2 0x55ece35e0269 in getpart /home/runner/work/curl/curl/tests/server/getpart.c:347:18
    #3 0x55ece36180b6 in parse_servercmd /home/runner/work/curl/curl/tests/server/sws.c:283:13

Closes #10822
2023-03-23 14:46:07 +01:00
Daniel Stenberg
70afa0d251
runtests: die if curl version can be found
Closes #10813
2023-03-22 14:01:45 +01:00
Stefan Eissing
b00289843a
tests/http: do not save files for downloads in scorecard testing
Closes #10788
2023-03-17 23:01:04 +01:00
Daniel Stenberg
ba1fba9cad
test422: verify --next used without a prior URL
Closes #10782
2023-03-17 14:07:20 +01:00
Daniel Stenberg
f24014c3eb
lib2305: deal with CURLE_AGAIN
The test does a slightly ugly busy-loop for this case but should be
managable due to it likely being a very short moment.

Mention CURLE_AGAIN in curl_ws_recv.3

Fixes #10760
Reported-by: Jay Satiro
Closes #10781
2023-03-16 23:29:12 +01:00
Daniel Stenberg
5ec15ea48f
lib643: LIB644 is never defined, this is dead code
Closes #10765
2023-03-15 00:08:09 +01:00
Daniel Stenberg
7ce1a6ae75
libtest/Makefile.inc: remove superfluous variables
Rely on the defaults when possible.

Closes #10765
2023-03-15 00:08:01 +01:00
Daniel Stenberg
c46761bd8b
tests/http: remove year ranges from copyrights
Closes #10763
2023-03-15 00:05:29 +01:00
Casey Bodley
495d09810a
aws_sigv4: fall back to UNSIGNED-PAYLOAD for sign_as_s3
all s3 requests default to UNSIGNED-PAYLOAD and add the required
x-amz-content-sha256 header. this allows CURLAUTH_AWS_SIGV4 to correctly
sign s3 requests to amazon with no additional configuration

Signed-off-by: Casey Bodley <cbodley@redhat.com>

Closes #9995
2023-03-14 17:04:47 +01:00
Dan Fandrich
7caaeca6f6 tests: fix control code that hid some text in runtests.1 2023-03-13 17:21:02 -07:00
Dan Fandrich
caf5fd1759 tests: sync option lists in runtests.pl & its man page 2023-03-13 17:13:08 -07: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
0cbfe32fb1 tests: make first.c the same for both lib tests and unit tests
The only difference used to be global variable used in unittest tests.
After cb7ed5a removed individual flag overrides for the unittests, first.c
was no longer recompiled for unit tests to include the flag, so whether it
worked or gave a link error depended on whether it was compiled in
libtest or unittest first. This way also speeds up the build by
eliminating 40 identical compile invocations.

Fixes #10749
2023-03-12 19:14:59 -07:00
Dan Fandrich
4e4a082eff tests: use AM_CPPFILES to modify flags in unit tests
Using CPPFLAGS sometimes caused odd compile issues when building tests
with parallel make and AM_CPPFILES is the right flag, anyway.

Follow-up to cb7ed5a

Ref #10749
2023-03-12 19:04:12 -07:00
Dan Fandrich
ee521a1c88 http: don't send 100-continue for short PUT requests
This is already how curl is documented to behave in Everything curl, but
in actuality only short POSTs skip this. This should knock 30 seconds
off a full run of the test suite since the 100-continue timeout will no
longer be hit.

Closes #10740
2023-03-11 18:57:19 -08:00
Dan Fandrich
970330bded tests: add DELAY keyword to more tests using waits 2023-03-11 18:57:19 -08:00
Dan Fandrich
13b4d050aa tests: hack to build most unit tests under cmake
These are only built when a libcurl static library is available, since
we're not building a special libcurlu library yet and these tests rely
on private symbols that aren't available in the shared library. A few
unit tests do require libcurlu, so those are not built.

Closes #10722
2023-03-11 18:54:21 -08:00
Dan Fandrich
29d7c3bdbd tests: fix MSVC unreachable code warnings in unit tests
Switch unit1654 to use the proper test macros as well.
2023-03-11 18:54:21 -08:00
Dan Fandrich
cb7ed5acf7 tests: make CPPFLAGS common to all unit tests
There's no need to specify them individually.
2023-03-11 18:54:21 -08:00
Dan Fandrich
a76322137b tests: keep cmake unit tests names in sync
Put only the test names into Makefile.inc so they can be used by both
cmake and automake. This will prevent the list of tests from becoming
out of date when they are also built under cmake.
2023-03-11 18:54:21 -08:00
Daniel Stenberg
fcee070cb1
CURLOPT_PROXY.3: curl+NSS does not handle HTTPS over unix domain socket
It results in error "NSS error -5985 (PR_ADDRESS_NOT_SUPPORTED_ERROR)"

Disabled test 1470 for NSS builds and documented the restriction.

Reported-by: Dan Fandrich
Fixes #10723
Closes #10734
2023-03-10 17:50:20 +01:00
Daniel Stenberg
674a0662cf test1903: test use of COOKIEFILE - reset - COOKIEFILE
This also tests for the memory leak bug fixed by parent commit b559ef6f.

Ref: #10694

Closes https://github.com/curl/curl/pull/10712
2023-03-10 03:56:59 -05:00
Dan Fandrich
297ad6ae18 tests: fix some keywords and unused sections 2023-03-10 00:17:29 -08:00
Dan Fandrich
c10c0c0578 tests: fix test1301 to call the right binary
It was refactored in commit 480ac6e5 but this step was missed.
2023-03-10 00:17:29 -08:00
Dan Fandrich
b5d955bc79 tests: add timeout, SLOWDOWN and DELAY keywords to tests
These are tests that are testing timing and end up being quite slow.
2023-03-10 00:17:29 -08:00
Dan Fandrich
37a3c63427 tests: fix tag markup issues in some tests 2023-03-09 10:27:39 -08:00
Marcel Raad
29a19369ec
tests: add cookies features
These tests don't work with `--disable-cookies`.

Closes https://github.com/curl/curl/pull/10713
2023-03-09 14:33:05 +01:00
Marcel Raad
387dbe53c4
test420: add cookies keyword
It fails with `--disable-cookies`.

Closes https://github.com/curl/curl/pull/10713
2023-03-09 14:33:03 +01:00
Daniel Stenberg
3bef98f615
test1671: fix after fix 2023-03-09 00:13:41 +01:00
Daniel Stenberg
27a7600871
test421: -w %{header_json} test with multiple same header names
To reproduce the issue in #10704
2023-03-09 00:13:41 +01:00
Daniel Stenberg
0a0c9b6dfa
urlapi: '%' is illegal in host names
Update test 1560 to verify

Ref: #10708
Closes #10711
2023-03-08 15:33:43 +01:00
Stefan Eissing
7c5637b8b4
url: fix logic in connection reuse to deny reuse on "unclean" connections
- add parameter to `conn_is_alive()` cfilter method that returns
  if there is input data waiting on the connection
- refrain from re-using connnection from the cache that have
  input pending
- adapt http/2 and http/3 alive checks to digest pending input
  to check the connection state
- remove check_cxn method from openssl as that was just doing
  what the socket filter now does.
- add tests for connection reuse with special server configs

Closes #10690
2023-03-07 12:50:31 +01:00
Stefan Eissing
48cd032623
http2: fix handling of RST and GOAWAY to recognize partial transfers
- a reset transfer (HTTP/2 RST) did not always lead to the proper
  error message on receiving its response, leading to wrong reports
  of a successful transfer
- test_05_02 was able to trigger this condition with increased transfer
  count. The simulated response errors did not carry a 'Content-Length'
  so only proper RST handling could detect the abort
- When doing such transfers in parallel, a connection could enter the
  state where
  a) it had been closed (GOAWAY received)
  b) the RST had not been "seen" for the transfer yet
  or c) the GOAWAY announced an error and the last successful
  stream id was not checked against ongoing transfers

Closes #10693
2023-03-06 23:58:24 +01:00
Stefan Eissing
b0564c1d54
tests: use dynamic ports numbers in pytest suite
- necessary ports are bound at start of test suite and then
  given to server fixtures for use.
- this make parallel use of pytest (in separate directories),
  practically safe for use as OS tend to not reuse such port numbers
  for a while

Closes #10692
2023-03-06 23:44:45 +01:00
Stefan Eissing
257416023d
connect: fix time_connect and time_appconnect timer statistics
- time_connect was not updated when the overall connection failed,
  e.g. when SSL verification was unsuccessful, refs #10670
- rework gather those values to interrogate involved filters,
  also from all eyeballing attempts, to report the maximum of
  those values.
- added 3 test cases in test_06 to check reported values on
  successful, partially failed and totally failed connections.

Reported-by: Master Inspire
Fixes #10670
Closes #10671
2023-03-06 20:16:43 +01:00
Daniel Stenberg
93eefa6ba1
test1905: update output cookie order
After the #10685 update
2023-03-06 15:52:00 +01:00
Daniel Stenberg
076764c5d7
test420: verify expiring cookies
Cookies that are loaded fine from a jar but then are expired in headers.
2023-03-06 15:52:00 +01:00
Jay Satiro
c12e8bfa89 tests: fix gnutls-serv check
- If gnutls-serv doesn't exist then don't try to execute it.

Follow-up to 2fdc1d81.

Closes https://github.com/curl/curl/pull/10688
2023-03-06 03:52:46 -05:00
Daniel Stenberg
54605666ed
lib1560: fix enumerated type mixed with another type
Follow-up to c84c0f9aa3

Closes #10684
2023-03-06 08:14:42 +01:00
Daniel Stenberg
c84c0f9aa3
lib1560: test parsing URLs with ridiculously large fields
In the order of 120K.

Closes #10665
2023-03-03 23:23:53 +01:00
Brad Spencer
ad4997e5b2
urlapi: parse IPv6 literals without ENABLE_IPV6
This makes the URL parser API stable and working the same way
independently of libcurl supporting IPv6 transfers or not.

Closes #10660
2023-03-03 10:05:08 +01:00
Balakrishnan Balasubramanian
351ea4ff53
test1470: test socks proxy using unix sockets and connect to https
Similar to test1468 except using https instead of http

Closes #10662
2023-03-03 09:18:21 +01:00
Daniel Stenberg
e4dfe6fc2f
test1960: verify CURL_SOCKOPT_ALREADY_CONNECTED
When returned from the CURLOPT_SOCKOPTFUNCTION, like when we have a
custom socket connected in the app, passed in to libcurl.

Verifies the fix in #10648

Closes #10651
2023-03-03 08:36:25 +01:00
Stefan Eissing
e497a96a0e
tests: rename tests/tests-httpd to tests/http
- httpd is only one server we test with
 - the suite coveres the HTTP protocol in general where
   the default test cases need a more beefy environment

Closes #10654
2023-03-02 14:05:19 +01:00
Stefan Eissing
d9ccc75b00 http2: fix upload busy loop
- Set KEEP_SEND_PAUSE when exhausting remote HTTP/2 window size of a
  stream.

- Clear KEEP_SEND_PAUSE when receiving HTTP/2 window updates on a paused
  stream.

- Also fix http2 send compiler warnings reported in #10449.

Prior to this change, starting in 71b7e016 which precedes 7.88.0,
libcurl may eat CPU during HTTP/2 upload.

Reported-by: Jay Satiro

Fixes https://github.com/curl/curl/issues/10449
Fixes https://github.com/curl/curl/issues/10618
Closes https://github.com/curl/curl/pull/10627
2023-03-01 04:13:49 -05:00
Stefan Eissing
cbe9d82c22
http2: fix for http2-prior-knowledge when reusing connections
- refs #10634 where errors in the HTTP/2 framing layer are observed.
- the bug was that on connection reuse, the code attempted to switch
  in yet another layer of HTTP/2 handling instead of detecting that
  this was already in place.
- added pytest testcase reproducing the issue.

Reported-by: rwmjones on github
Fixes #10634
Closes #10643
2023-02-28 23:04:00 +01:00
Stefan Eissing
a4d015e69f
http: fix unix domain socket use in https connects
- when h2/h3 eyeballing was involved, unix domain socket
  configurations were not honoured
- configuring --unix-socket will disable HTTP/3 as candidate for eyeballing
- combinatino of --unix-socket and --http3-only will fail during initialisation
- adding pytest test_11 to reproduce

Reported-by: Jelle van der Waa
Fixes #10633
Closes #10641
2023-02-28 22:59:19 +01:00
Patrick Monnerat
90756d33d8
tests: test secure mail protocols with explicit SSL requests
New tests 987, 988 and 989, disabled for rustls (hanging).

Closes #10077
2023-02-25 11:49:31 +01:00
Patrick Monnerat
5855c478cb
tests: support for imaps/pop3s/smtps protocols
Closes #10077
2023-02-25 11:49:31 +01:00
Patrick Monnerat
8bfa4d66de
runtests: use a hash table for server port numbers
Closes #10077
2023-02-25 11:49:31 +01:00
Daniel Stenberg
835682661c
misc: remove support for curl_off_t < 8 bytes
Closes #10597
2023-02-24 17:05:33 +01:00
Daniel Stenberg
5da5684cec
test978: mark file as text mode
Follow-up to 4ea5702980

To fix test failures on Windows

Closes #10594
2023-02-23 16:32:43 +01:00
Daniel Stenberg
4ea5702980
test978: verify that --stderr works for -w's stderr as well 2023-02-23 10:05:13 +01:00
Stefan Eissing
463158bfe5
test2600: detect when ALARM_TIMEOUT is in use and adjust
- use higher timeout values > 1s
- skip duration checks

Assisted-by: Marcel Raad
Closes #10513
2023-02-22 16:42:36 +01:00
Daniel Stenberg
0338eb85d3
test686: verify return code for no URL after --next 2023-02-22 08:44:54 +01:00
Daniel Stenberg
2e3da51550
test1278: verify that an extra --no-remote-name cause no warning 2023-02-22 08:43:19 +01:00
Daniel Stenberg
bb11969838
lib1560: add a test using %25 in the userinfo in a URL
Closes #10578
2023-02-21 16:10:13 +01:00
Stefan Eissing
821f6e2a89
CURLOPT_PIPEWAIT: allow waited reuse also for subsequent connections
As tested in test_02_07, when firing off 200 urls with --parallel, 199
wait for the first connection to be established. if that is multiuse,
urls are added up to its capacity.

The first url over capacity opens another connection. But subsequent
urls found the same situation and open a connection too. They should
have waited for the second connection to actually connect and make its
capacity known.

This change fixes that by

- setting `connkeep()` early in the HTTP setup handler. as otherwise
  a new connection is marked as closeit by default and not considered
  for multiuse at all
- checking the "connected" status for a candidate always and continuing
  to PIPEWAIT if no alternative is found.

pytest:
- removed "skip" from test_02_07
- added test_02_07b to check that http/1.1 continues to work as before

Closes #10456
2023-02-21 11:12:48 +01:00