Daniel Stenberg
32f6812b5a
c-hyper: initial step for 100-continue support
...
Enabled test 154
Closes #7568
2021-08-13 23:18:21 +02:00
Daniel Stenberg
c495dcd02e
http: consider cookies over localhost to be secure
...
Updated test31.
Added test 392 to verify secure cookies used for http://localhost
Reviewed-by: Daniel Gustafsson
Fixes #6733
Closes #7263
2021-08-10 11:20:21 +02:00
Jay Satiro
26f93cf038
test1565: fix windows build errors
...
- Use our wait_ms() instead of sleep() since Windows doesn't have the
latter.
- Use a separate variable to keep track of whether the pthread_t thread
id is valid.
On Windows pthread_t is not an integer type. pthread offers no macro for
invalid pthread_t thread id, so validity is kept track of separately.
Closes https://github.com/curl/curl/pull/7527
2021-08-10 03:29:40 -04:00
Bin Lan
5b9fedb461
tool/tests: fix potential year 2038 issues
...
The length of 'long' in a 32-bit system is 32 bits, which cannot be used
to save timestamps after 2038. Most operating systems have extended
time_t to 64 bits.
Remove the castings to long.
Closes #7466
2021-07-30 16:06:37 +02:00
Bernhard M. Wiedemann
8d0c1137c1
tests: make three tests pass until 2037
...
after 2038 something in test1915 fails on 32-bit OSes
Closes #7512
2021-07-30 12:39:34 +02:00
Marc Hoersken
c34bd93f60
tests/*server.py: remove pidfile on server termination
...
Avoid pidfile leaking/laying around after server already exited.
Reviewed-by: Daniel Stenberg
Closes #7506
2021-07-29 08:08:07 +02:00
Marc Hoersken
4a7bf79fcc
tests/servers: remove obsolete pid variable
...
Variable is not used since pidfile handling moved to util.[ch]
Reviewed-by: Jay Satiro
Closes #7482
2021-07-25 20:00:18 +02:00
Marc Hoersken
d9d26a6b2c
tests/servers: use our platform-aware pid for server verification
...
The pid used for server verification is later stored as pid2 in
the hash of running test servers and therefore used for shutdown.
The pid used for shutdown must be the platform-aware (Win32) pid
to avoid leaking test servers while running them using Cygwin/msys.
Reviewed-by: Jay Satiro
Closes #7481
2021-07-25 19:59:58 +02:00
Marc Hoersken
893f39c596
tests/runtests.pl: cleanup copy&paste mistakes and unused code
...
Reviewed-by: Jay Satiro
Part of #7481
2021-07-25 19:59:14 +02:00
Josh Soref
de1004eb0f
cleanup: spell DoH with a lowercase o
...
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
Closes #7413
2021-07-16 23:53:13 +02:00
Daniel Stenberg
9053dbbf62
msnprintf: return number of printed characters excluding null byte
...
... even when the output is "capped" by the maximum length argument.
Clarified in the docs.
Closes #7361
2021-07-08 10:05:39 +02:00
Daniel Stenberg
e7416cfd2b
infof: remove newline from format strings, always append it
...
- the data needs to be "line-based" anyway since it's also passed to the
debug callback/application
- it makes infof() work like failf() and consistency is good
- there's an assert that triggers on newlines in the format string
- Also removes a few instances of "..."
- Removes the code that would append "..." to the end of the data *iff*
it was truncated in infof()
Closes #7357
2021-07-07 22:54:01 +02:00
Daniel Stenberg
c3d612662d
test1147: hyper doesn't allow "crazy" request headers like built-in
...
... so strip that from the test.
Closes #7349
2021-07-05 22:51:13 +02:00
Daniel Stenberg
a62ece3f57
c-hyper: bail on too long response headers
...
To match with built-in behaviors. Makes test 1154 work.
Closes #7350
2021-07-05 22:49:12 +02:00
Daniel Stenberg
0965348cd8
test1151: added missing CRLF to work with hyper
...
Closes #7350
2021-07-05 22:49:02 +02:00
Daniel Stenberg
e41feede34
test1116: hyper doesn't pass through "surprise-trailers"
...
Closes #7344
2021-07-05 22:39:42 +02:00
Daniel Stenberg
07fa74d34a
test1519: adjusted to work with hyper
...
Closes #7333
2021-07-01 14:26:06 +02:00
Daniel Stenberg
a80f8ea182
test1518: adjusted to work with hyper
...
... by making sure the stdout output doesn't look like HTTP headers.
Closes #7333
2021-07-01 14:25:57 +02:00
Daniel Stenberg
7f11282d5f
test1514: add a CRLF to the response to make it correct
...
Makes hyper accept it fine instead returning HYPERE_UNEXPECTED_EOF on
us.
Closes #7334
2021-07-01 14:19:55 +02:00
Daniel Stenberg
ca60a4398f
lib677: make it survive torture testing
...
Follow-up to a5ab72d5ed
Closes #7300
2021-06-27 23:20:18 +02:00
Daniel Stenberg
a5ab72d5ed
test677: IMAP CONNECT_ONLY, custom command and then exit
...
Adjusted ftpserver.pl to add support for the IMAP IDLE command
Adjusted test 660 to sync with the fix
2021-06-24 09:07:40 +02:00
Li Xinwei
30e491e5c9
cmake: fix support for UnixSockets feature on Win32
...
Move the definition of sockaddr_un struct from config-win32.h to
curl_setup.h, so that it could be shared by all build systems.
Add ADDRESS_FAMILY typedef for old mingw, now old mingw can also use
unix sockets.
Also fix the build of tests/server/sws.c on Win32 when USE_UNIX_SOCKETS
is defined.
Closes #7034
2021-06-21 14:52:27 +02:00
Daniel Stenberg
80e1054fe5
hyper: propagate errors back up from read callbacks
...
Makes test 513 work with hyper
Closes #7266
2021-06-17 08:19:31 +02:00
Daniel Stenberg
b67d3ba73e
curl_url_set: reject spaces in URLs w/o CURLU_ALLOW_SPACE
...
They were never officially allowed and slipped in only due to sloppy
parsing. Spaces (ascii 32) should be correctly encoded (to %20) before
being part of a URL.
The new flag bit CURLU_ALLOW_SPACE when a full URL is set, makes libcurl
allow spaces.
Updated test 1560 to verify.
Closes #7073
2021-06-15 10:49:49 +02:00
Daniel Stenberg
bbbc5de93f
netrc: skip 'macdef' definitions
...
Add test 494 to verify
Reported-by: Harry Sintonen
Fixes #7238
Closes #7244
2021-06-13 23:44:41 +02:00
Gealber Morales
791937b881
mqtt: add support for username and password
...
Minor-edits-by: Daniel Stenberg
Added test 2200 to 2205
Closes #7243
2021-06-12 23:50:13 +02:00
Daniel Stenberg
f60f51721c
runtests: init $VERSION to avoid warnings when using -l
2021-06-11 14:26:32 +02:00
Daniel Stenberg
a15d146f47
tests: update README about servers and port numbers
...
Closes #7242
2021-06-11 12:48:56 +02:00
Christian Weisgerber
02dfe71937
sws: malloc request struct instead of using stack
...
... 2MB requests is otherwise just too big for some systems.
(The allocations are not freed properly.)
Bug: https://curl.se/mail/lib-2021-06/0018.html
Closes #7235
2021-06-11 11:13:24 +02:00
yb999
b9cdcc7a17
tests: update README.md with a missing single quote
...
Closes #7231
2021-06-10 16:11:03 +02:00
Daniel Stenberg
7cfd8f037a
tests/data/DISABLED: add tests not working with hyper
...
The goal is to remove them all from here over time.
Closes #7209
2021-06-10 08:42:55 +02:00
Daniel Stenberg
dd47b0cce9
runtests: also find the last test in Makefile.inc
...
Closes #7209
2021-06-10 08:42:52 +02:00
Daniel Stenberg
77ae8f26ad
test3010: work with hyper mode
...
Closes #7209
2021-06-10 08:42:50 +02:00
Daniel Stenberg
75391045cf
test1594/1595/1596: fix to work in hyper mode
...
Closes #7209
2021-06-10 08:42:44 +02:00
Daniel Stenberg
30e50de53e
test1438/1457: add HTTP keyword to make hyper mode work
...
Closes #7209
2021-06-10 08:42:41 +02:00
Daniel Stenberg
5f70cb6461
test1340/1341: adjusted for hyper mode
...
Closes #7209
2021-06-10 08:42:38 +02:00
Daniel Stenberg
769d9176e3
test1218: adjusted for hyper mode
...
Closes #7209
2021-06-10 08:42:35 +02:00
Daniel Stenberg
6101ddc24e
test1216: adjusted for hyper mode
...
Closes #7209
2021-06-10 08:42:33 +02:00
Daniel Stenberg
340d6b4589
test1230: adjust to work in hyper mode
...
Closes #7209
2021-06-10 08:42:30 +02:00
Daniel Stenberg
c214a6a17b
c-hyper: abort CONNECT response reading early on non 2xx responses
...
Fixes test 493
Closes #7209
2021-06-10 08:42:27 +02:00
Daniel Stenberg
aeb064db03
test434: add HTTP keyword
...
Closes #7209
2021-06-10 08:42:23 +02:00
Daniel Stenberg
e7ae6f013d
test599: adjusted to work in hyper mode
...
Closes #7209
2021-06-10 08:42:19 +02:00
Daniel Stenberg
cd5ca9bb38
test566: adjust to work with hyper mode
...
Closes #7209
2021-06-10 08:42:13 +02:00
Daniel Stenberg
76035e612a
runtests: skip disabled tests unless -f is used
...
To make it easier to write ranges like '115 to 229' without that
explicitly enabling tests that are listed in DISABLED, this makes
runtests always skip disabled tests unless the -f command line option is
used.
Previously the code attempted to not run such tests, but didn't do it
correctly.
Closes #7212
2021-06-08 23:35:37 +02:00
Daniel Stenberg
3ac9b80525
test644: remove as duplicate of test 587
...
Closes #7208
2021-06-08 16:07:56 +02:00
Daniel Stenberg
48b0cca65e
test500: adjust to work with hyper mode
2021-06-07 23:54:54 +02:00
Daniel Stenberg
57e46dce58
test433: adjust for hyper mode
...
Closes #7205
2021-06-07 23:14:09 +02:00
Daniel Stenberg
528f22736d
test395: hyper cannot work around > 64 bit content-lengths like built-in
...
Closes #7205
2021-06-07 23:14:06 +02:00
Daniel Stenberg
77590673e9
test394: hyper returns a different error
...
Closes #7205
2021-06-07 23:14:03 +02:00
Daniel Stenberg
1449713dd3
test393: make Content-Length fit within 64 bit for hyper
...
Closes #7205
2021-06-07 23:14:00 +02:00