Commit Graph

27638 Commits

Author SHA1 Message Date
Daniel Stenberg
dbe693e769
write-out.d: clarify size_download/upload
They show the number of "body" bytes transfered.
Fixes #7702
Closes #7706
2021-09-12 12:33:02 +02:00
Daniel Stenberg
3cb8a74867
http2: Curl_http2_setup needs to init stream data in all invokes
Thus function was written to avoid doing multiple connection data
initializations, which is fine, but since it also initiates stream
related data it is crucial that it doesn't skip those even if called
again for the same connection. Solved by moving the stream
initializations before the "doing-it-again" check.

Reported-by: Inho Oh
Fixes #7630
Closes #7692
2021-09-11 23:01:23 +02:00
Daniel Stenberg
e41e1b2a4d
url: fix compiler warning in no-verbose builds
Follow-up from 2f0bb864c1

Closes #7700
2021-09-10 19:10:14 +02:00
Daniel Stenberg
94da56269f
non-ascii: fix build errors from strerror fix
Follow-up to 2f0bb864c1

Closes #7697
2021-09-10 19:07:18 +02:00
Daniel Stenberg
2b99f5e02c
parse_args: redo the warnings for --remote-header-name combos
... to avoid the memory leak risk pointed out by scan-build.

Follow-up from 7a3e981781

Closes #7698
2021-09-10 17:02:21 +02:00
Daniel Stenberg
4fb5a643c8
ngtcp2: adapt to new size defintions upstream
Reviewed-by: Tatsuhiro Tsujikawa
Closes #7699
2021-09-10 16:52:29 +02:00
Daniel Stenberg
0cc8fc8825
rustls: add strerror.h include
Follow-up to 2f0bb864c1
2021-09-10 15:20:20 +02:00
Daniel Stenberg
ab2f27cf88
docs: the security list is reached at security at curl.se now
Also update the FAQ section a bit to encourage users to rather submit
security issues on hackerone than sending email.

Closes #7689
2021-09-10 10:51:12 +02:00
Marc Hoersken
60efeb1e0d
runtests: add option -u to error on server unexpectedly alive
Let's try to actually handle the server unexpectedly alive
case by first making them visible on CI builds as failures.

This is needed to detect issues with killing of the test
servers completely including nested process chains with
multiple PIDs per test server (including bash and perl).

On Windows/cygwin platforms this is especially helpful with
debugging PID mixups due to cygwin using its own PID space.

Reviewed-by: Daniel Stenberg
Closes #7180
2021-09-09 21:28:26 +02:00
Daniel Stenberg
1fbd822b64
opts docs: unify phrasing in NAME header
- avoid writing "set ..." or "enable/disable ..." or "specify ..."
  *All* options for curl_easy_setopt() are about setting or enabling
  things and most of the existing options didn't use that way of
  description.

- start with lowercase letter, unless abbreviation. For consistency.

- Some additional touch-ups

Closes #7688
2021-09-09 09:55:24 +02:00
Daniel Stenberg
fe7b64228d
strerror.h: remove the #include from files not using it 2021-09-09 07:53:42 +02:00
Daniel Stenberg
2f0bb864c1
lib: don't use strerror()
We have and provide Curl_strerror() internally for a reason: strerror()
is not necessarily thread-safe so we should always try to avoid it.

Extended checksrc to warn for this, but feature the check disabled by
default and only enable it in lib/

Closes #7685
2021-09-09 07:53:42 +02:00
Daniel Gustafsson
71f9a8fa6f cirrus: Add FreeBSD 13.0 job and disable sanitizer build
As alluded to the in the now removed comment, a 13.0 image became
available and is now ready to be used.

The sanitizer builds were running on the 12.1 image which since has
been removed from the config, leaving the builds not running at all.
When enabled it turns out that they don't actually work due to very
long timeouts in executing the tests, so keep the disabled for now
but a bit more controlled.

Closes #7592
2021-09-08 10:14:45 +02:00
Daniel Stenberg
d9b2d1d90f
copyrights: update copyright year ranges 2021-09-08 09:36:49 +02:00
Daniel Stenberg
a22b9980b9
RELEASE-NOTES: synced 2021-09-08 08:54:29 +02:00
Daniel Stenberg
a2f8ec038d
INTERNALS: c-ares has a new home: c-ares.org 2021-09-07 14:56:09 +02:00
Daniel Stenberg
3c40840ca7
docs: remove experimental mentions from HSTS and MQTT
Reported-by: Jonathan Cardoso
Bug: https://github.com/curl/curl/pull/6700#issuecomment-913792863
Closes #7681
2021-09-07 08:21:40 +02:00
Cao ZhenXiang
7a3e981781
curl: add warning for incompatible parameters usage
--continue-at - and --remote-header-name are known incompatible parameters

Closes #7674
2021-09-06 16:59:08 +02:00
git-bruh
033d15a6c5
examples/*hiperfifo.c: fix calloc arguments to match function proto
Closes #7678
2021-09-06 16:16:52 +02:00
Daniel Stenberg
db50fc6e95
INTERNALS: bump c-ares requirement to 1.16.0
Since ba904db070 we use ares_getaddrinfo, added in c-ares 1.16.0
2021-09-06 16:00:52 +02:00
Daniel Stenberg
eb2a5171da
curl: stop retry if Retry-After: is longer than allowed
If Retry-After: specifies a period that is longer than what fits within
--retry-max-time, then stop retrying immediately.

Added test 366 to verify.

Reported-by: Kari Pahula
Fixes #7675
Closes #7676
2021-09-06 14:46:45 +02:00
MAntoniak
37fb213a2e
mbedtls: avoid using a large buffer on the stack
Use dynamic memory allocation for the buffer used in checking "pinned
public key". The PUB_DER_MAX_BYTES parameter with default settings is
set to a value greater than 2kB.

Co-authored-by: Daniel Stenberg
Closes #7586
2021-09-06 10:02:08 +02:00
Daniel Stenberg
9829b94361
configure: make --disable-hsts work
The AC_ARG_ENABLE() macro itself uses a variable called
'enable_[option]', so when our script also used a variable with that
name for the purpose of storing what the user wants, it also
accidentally made it impossible to switch off the feature with
--disable-hsts. Fix this by renaming our variable.

Reported-by: Michał Antoniak
Fixes #7669
Closes #7672
2021-09-05 22:28:18 +02:00
Jay Satiro
c1f7a7b525 config.d: note that curlrc is used even when --config
Bug: https://github.com/curl/curl/pull/7666#issuecomment-912214751
Reported-by: Viktor Szakats

Closes https://github.com/curl/curl/pull/7667
2021-09-05 02:34:14 -04:00
Daniel Stenberg
e514e67c61
RELEASE-NOTES: synced 2021-09-04 11:42:05 +02:00
Daniel Stenberg
8fbdf8331e
test1173: check references to libcurl options
... that they refer to actual existing libcurl options.

Reviewed-by: Daniel Gustafsson
Closes #7656
2021-09-04 11:27:56 +02:00
Daniel Stenberg
7d1bd8a301
CURLOPT_UNIX_SOCKET_PATH.3: remove nginx reference, add see also
Closes #7656
2021-09-04 11:27:51 +02:00
Daniel Stenberg
12a2ed970f
opt-docs: verify man page sections + order
In every libcurl option man page there are now 8 mandatory sections that
must use the right name in the correct order and test 1173 verifies
this. Only 14 man pages needed adjustments.

The sections and the order is as follows:

 - NAME
 - SYNOPSIS
 - DESCRIPTION
 - PROTOCOLS
 - EXAMPLE
 - AVAILABILITY
 - RETURN VALUE
 - SEE ALSO

Reviewed-by: Daniel Gustafsson
Closes #7656
2021-09-04 11:27:46 +02:00
Daniel Stenberg
1731a77989
opt-docs: make sure all man pages have examples
Extended manpage-syntax.pl (run by test 1173) to check that every man
page for a libcurl option has an EXAMPLE section that is more than two
lines. Then fixed all errors it found and added examples.

Reviewed-by: Daniel Gustafsson
Closes #7656
2021-09-04 11:27:04 +02:00
Daniel Stenberg
c8210ef06d
get.d: provide more useful examples
Closes #7668
2021-09-04 00:16:53 +02:00
Daniel Stenberg
d02d8d93ff
page-header: add GOPHERS, simplify wording in the 1st para
Closes #7665
2021-09-03 08:39:48 +02:00
Daniel Stenberg
424051d78b
connect: get local port + ip also when reusing connections
Regression. In d6a37c23a3 (7.75.0) we removed the duplicated storage
(connection + easy handle), so this info needs be extracted again even
for re-used connections.

Add test 435 to verify

Reported-by: Max Dymond
Fixes #7660
Closes #7662
2021-09-02 23:42:18 +02:00
Marcel Raad
1b70748e86
multi: fix compiler warning with CURL_DISABLE_WAKEUP
`use_wakeup` is unused in this case.

Closes https://github.com/curl/curl/pull/7661
2021-09-02 15:52:00 +02:00
Daniel Stenberg
3f4b1b4ee5
tests: adjust the tftpd output to work with hyper mode
By making them look less like http headers, the hyper mode "tweak"
doesn't interfere.

Enable test 2002 and 2003 in hyper builds (and 1280 which is unrelated
but should be enabled).

Closes #7658
2021-09-01 23:40:28 +02:00
Gisle Vanem
3a6d30cfd3 openssl: annotate SSL3_MT_SUPPLEMENTAL_DATA
This adds support for the previously unhandled supplemental data which
in -v output was printed like:

    TLSv1.2 (IN), TLS header, Unknown (23):

These will now be printed with proper annotation:

    TLSv1.2 (OUT), TLS header, Supplemental data (23):

Closes #7652
Reviewed-by: Daniel Stenberg <daniel@haxx.se>
2021-09-01 22:46:21 +02:00
Daniel Stenberg
68784d73c3
curl.1: provide examples for each option
The file format for each option now features a "Example:" header that
can provide one or more examples that get rendered appropriately in the
output. All options MUST have at least one example or gen.pl complains
at build-time.

This fix also does a few other minor format and consistency cleanups.

Closes #7654
2021-09-01 14:02:43 +02:00
Daniel Stenberg
c905459e87
progress: make trspeed avoid floats
and compiler warnings for data conversions.

Reported-by: Michał Antoniak
Fixes #7645
Closes #7653
2021-09-01 08:35:31 +02:00
Daniel Stenberg
e8c8775eaa
test365: verify response with chunked AND Content-Length headers 2021-08-31 10:04:03 +02:00
Daniel Stenberg
8a16e54c0c
http: ignore content-length if any transfer-encoding is used
Fixes #7643
Closes #7649
2021-08-31 10:04:03 +02:00
Daniel Stenberg
bde355c484
RELEASE-NOTES: synced 2021-08-31 08:55:45 +02:00
Daniel Stenberg
c364f5f6fa
Revert "http2: skip immediate parsing of payload following protocol switch"
This reverts commit 455a63c66f.

Reported-by: Tk Xiong
Fixes #7633
Closes #7648
2021-08-30 17:57:32 +02:00
Daniel Stenberg
a4f337a9c2
KNOWN_BUGS: HTTP/3 doesn't support client certs
Closes #7625
2021-08-30 13:23:24 +02:00
Daniel Stenberg
d4d53d99b1
mailing lists: move from cool.haxx.se to lists.haxx.se 2021-08-30 09:51:07 +02:00
Daniel Stenberg
4fee6c644f
http_proxy: only wait for writable socket while sending request
Otherwise it would wait socket writability even after the entire CONNECT
request has sent and make curl basically busy-loop while waiting for a
response to come back.

The previous fix attempt in #7484 (c27a70a591) was inadequate.

Reported-by: zloi-user on github
Reported-by: Oleguer Llopart
Fixes #7589
Closes #7647
2021-08-27 23:34:37 +02:00
Daniel Stenberg
5dc594e44f
http: disallow >3-digit response codes
Make the built-in HTTP parser behave similar to hyper and reject any
HTTP response using more than 3 digits for the response code.

Updated test 1432 accordingly.
Enabled test 1432 in the hyper builds.

Closes #7641
2021-08-26 22:43:38 +02:00
Tatsuhiro Tsujikawa
14da6eb4e5
ngtcp2: stop buffering crypto data
Stop buffering crypto data because libngtcp2 now buffers submitted
crypto data.

Closes #7637
2021-08-26 16:31:59 +02:00
Daniel Stenberg
9df52bf17a
test1280: CRLFify the response to please hyper
Closes #7639
2021-08-26 16:17:10 +02:00
Daniel Stenberg
9a30ac0957
tests: enable test 1129 for hyper builds
Closes #7638
2021-08-26 16:15:48 +02:00
Daniel Stenberg
e8e656c845
curl: better error message when -O fails to get a good name
Due to how this currently works internally, it needs a working initial
file name to store contents in, so it may still fail even with -J is
used (and thus accepting a name from content-disposition:) if the file
name part of the URL isn't "good enough".

Fixes #7628
Closes #7635
2021-08-26 10:41:15 +02:00
Daniel Stenberg
1a042be270
curl_easy_setopt: tweak the string copy wording
Reported-by: Yaobin Wen
Fixes #7632
Closes #7634
2021-08-26 09:18:42 +02:00