Commit Graph

29019 Commits

Author SHA1 Message Date
Daniel Stenberg
44a02d2532
libssh: setting atime or mtime > 32bit is now just skipped
The libssh API used caps the time to an unsigned 32bit variable. Avoid
nasty surprises by instead not setting such time.

Spotted by Coverity.

Closes #9324
2022-08-16 23:15:57 +02:00
Jay Satiro
ebe3fdb0e3 KNOWN_BUGS: Windows Unicode builds use homedir in current locale
Bug: https://github.com/curl/curl/pull/7252
Reported-by: dEajL3kA@users.noreply.github.com

Ref: https://github.com/curl/curl/pull/7281

Closes https://github.com/curl/curl/pull/9305
2022-08-16 11:30:47 -04:00
Daniel Stenberg
04427fc207
test399: switch it to use a config file instead
... as using a 65535 bytes host name in a URL does not fit on the
command line on some systems - like Windows.

Reported-by: Marcel Raad
Fixes #9321
Closes #9322
2022-08-16 16:35:47 +02:00
Daniel Stenberg
d29de2ab80
RELEASE-NOTES: synced 2022-08-16 09:46:33 +02:00
Daniel Stenberg
14d9d79c87
asyn-ares: make a single alloc out of hostname + async data
This saves one alloc per name resolve and simplifies the exit path.

Closes #9310
2022-08-16 08:54:33 +02:00
Daniel Stenberg
37dbbbb6c1
Curl_close: call Curl_resolver_cancel to avoid memory-leak
There might be a pending (c-ares) resolve that isn't free'd up yet.

Closes #9310
2022-08-16 08:54:30 +02:00
Daniel Stenberg
f236595ecc
asyn-thread: fix socket leak on OOM
Closes #9310
2022-08-16 08:54:25 +02:00
Daniel Stenberg
472369f589
GHA: mv CI torture test from Zuul
Closes #9310
2022-08-16 08:54:09 +02:00
Daniel Stenberg
2e67d451b1
ngtcp2-wolfssl.yml: add GHA to build ngtcp2 + wolfSSL
Closes #9318
2022-08-15 10:59:58 +02:00
Daniel Stenberg
88f1f11e01
test399: verify check of too long host name 2022-08-15 10:57:16 +02:00
Daniel Stenberg
657101ec0c
url: reject URLs with hostnames longer than 65535 bytes
It *probably* causes other problems too since DNS can't resolve such
long names, but the SNI field in TLS is limited to 16 bits length.

Closes #9317
2022-08-15 10:52:26 +02:00
Daniel Stenberg
20d083572a
curl_multi_perform.3: minor language fix
Closes #9316
2022-08-15 10:00:40 +02:00
Daniel Stenberg
e65187e188
ngtcp2: fix picky compiler warnings with wolfSSL for QUIC
Follow-up to 8a13be227e

Closes #9315
2022-08-15 09:39:09 +02:00
Daniel Stenberg
c031ec53f8
ngtcp2: remove leftover variable
Mistake leftover from my edit before push.

Follow-up from 8a13be227e
Reported-by: Viktor Szakats
Bug: https://github.com/curl/curl/pull/9290#issuecomment-1214569167
2022-08-15 08:22:20 +02:00
Viktor Szakats
5fd7cd7302
Makefile.m32: allow -nghttp3/-ngtcp2 without -ssl [ci skip]
Before this patch `-nghttp3`/`-ngtcp2` had an effect only when `-ssl`
was also enabled. `-ssl` meaning OpenSSL (and its forks). After
8a13be227e nghttp3/ngtcp2 can also be
used together with wolfSSL. This patch adds the ability to enable
`-nghttp3`/`-ngtcp2` independently from `-ssl` (OpenSSL), allowing to
use it with wolfSSL or other, future TLS backends.

Before this patch, it was fine to enable `-nghttp3`/`-ngtcp2`
unconditionally. After this patch, this is no longer the case, and now
it's the user's responsibility to enable `-nghttp3`/`-ngtcp2` only
together with a compatible TLS backend.

When using a TLS backend other than OpenSSL, the TLS-specific ngtcp2
library must be configured manually, e.g.:
  `export CURL_LDFLAG_EXTRAS=-lngtcp2_crypto_wolfssl`

(or via `NGTCP2_LIBS`)

Closes #9314
2022-08-15 02:49:59 +00:00
Stefan Eissing
8a13be227e
quic: add support via wolfSSL
- based on ngtcp2 PR https://github.com/ngtcp2/ngtcp2/pull/505
- configure adapted to build against ngtcp2 wolfssl crypto lib
- quic code added for creation of WOLFSSL* instances

Closes #9290
2022-08-15 00:48:55 +02:00
David Carlier
6526b36271 memdebug: add annotation attributes
memory debug tracking annotates whether the returned pointer does not
`alias`, hints where the size required is, for Windows to be better
debugged via Visual Studio.

Closes https://github.com/curl/curl/pull/9306
2022-08-14 10:53:18 +02:00
Daniel Stenberg
c7febe520b
GHA: move libressl CI from zuul to GitHub
Closes #9309
2022-08-14 00:54:01 +02:00
Daniel Stenberg
440fb67755
KNOWN_BUGS: FTPS directory listing hangs on Windows with Schannel
Closes #9161
2022-08-13 00:32:12 +02:00
Daniel Stenberg
5554e45405
KNOWN_BUGS: CURLOPT_CERTINFO results in CURLE_OUT_OF_MEMORY with Schannel
Closes #8741
2022-08-13 00:27:57 +02:00
Daniel Stenberg
46d1b95e69
KNOWN_BUGS: libssh blocking and infinite loop problem
Closes #8632
2022-08-13 00:25:31 +02:00
Daniel Stenberg
633689a294
RELEASE-NOTES: synced 2022-08-13 00:22:25 +02:00
Daniel Stenberg
011788f0b6
msh3: fix the QUIC disconnect function
And free request related memory better in 'done'. Fixes a memory-leak.

Reported-by: Gisle Vanem
Fixes #8915
Closes #9304
2022-08-13 00:19:29 +02:00
Daniel Stenberg
ed6e0febe0
connect: close the happy eyeballs loser connection when using QUIC
Reviewed-by: Nick Banks

Closes #9303
2022-08-12 16:29:12 +02:00
Emil Engler
764c958c52
refactor: split resolve_server() into functions
This commit splits the branch-heavy resolve_server() function into
various sub-functions, in order to reduce the amount of nested
if/else-statements.

Beside this, it also removes many else-sequences, by returning in the
previous if-statement.

Closes #9283
2022-08-12 16:27:36 +02:00
Daniel Stenberg
193772084f
schannel: re-indent to use curl style better
Only white space changes

Closes #9301
2022-08-12 16:04:08 +02:00
Emanuele Torre
2f0056680f
docs/cmdline-opts: fix example and categories for --form-escape
The example was missing a "--form" argument
I also replaced "--form" with "-F" to shorten the line a bit since it
was already very long.

And I also moved --form-escape from the "post" category to the "upload"
category (this is what I originally wanted to fix, before also noticing
the mistake in the example).

Closes #9298
2022-08-12 08:39:03 +02:00
Nick Banks
29b8e67f69
HTTP3.md: update to msh3 v0.4.0
Closes #9297
2022-08-11 23:40:14 +02:00
Daniel Stenberg
b5c0fe20e3
hostip: resolve *.localhost to 127.0.0.1/::1
Following the footsteps of other clients like Firefox/Chrome.  RFC 6761
says clients SHOULD do this.

Add test 389 to verify.

Reported-by: TheKnarf on github
Fixes #9192
Closes #9296
2022-08-11 14:01:37 +02:00
Jay Satiro
586cfc3c2c KNOWN_BUGS: long paths are not fully supported on Windows
Bug: https://github.com/curl/curl/issues/8361
Reported-by: Gisle Vanem

Closes https://github.com/curl/curl/pull/9288
2022-08-11 03:37:25 -04:00
Daniel Stenberg
d48dd1573c
config: remove the check for and use of SIZEOF_SHORT
shorts are 2 bytes on all platforms curl runs and have ever run on.

Closes #9291
2022-08-11 09:07:06 +02:00
Daniel Stenberg
9e11c2791f
configure: introduce CURL_SIZEOF
This is a rewrite of the previously used GPLv3+exception licensed
file. With this change, there is no more reference to GPL so we can
remove that from LICENSES/.

Ref: #9220
Closes #9291
2022-08-11 09:07:02 +02:00
Sean McArthur
d6010c2106
hyper: customize test1274 to how hyper unfolds headers
Closes #9217
2022-08-10 23:49:18 +02:00
Orgad Shaneh
3adc9f3f93
curl-config: quote directories with potential space
On Windows (at least with CMake), the default prefix is
C:/Program Files (x86)/CURL.

Closes #9253
2022-08-10 14:35:40 +02:00
Futaura
55a138acc4
amigaos: fix threaded resolver on AmigaOS 4.x
Replace ip4 resolution function on AmigaOS 4.x, as it requires runtime
feature detection and extra code to make it thread safe.

Closes #9265
2022-08-10 14:14:27 +02:00
Emil Engler
34886a444f
imap: use ISALNUM() for alphanumeric checks
This commit replaces a self-made character check for alphanumeric
characters within imap_is_bchar() with the ISALNUM() macro, as it is
reduces the size of the code and makes the performance better, due to
ASCII arithmetic.

Closes #9289
2022-08-10 14:12:22 +02:00
Daniel Stenberg
272f62f171
RELEASE-NOTES: synced 2022-08-10 08:46:05 +02:00
Cering
6ba3047378
connect: add quic connection information
Fixes #9286
Closes #9287
2022-08-10 08:41:50 +02:00
Philip H
3879d812ad
cirrus/freebsd-ci: bootstrap the pip installer
Signed-off-by: Philip H <47042125+pheiduck@users.noreply.github.com>

Closes #9213
2022-08-08 23:25:56 +02:00
Daniel Stenberg
15f7feac22
urldata: move smaller fields down in connectdata struct
By (almost) sorting the struct fields in connectdata in a decending size
order, having the single char ones last, we reduce the number of holes
in the struct and thus the amount of storage needed.

Closes #9280
2022-08-08 19:57:49 +02:00
Daniel Stenberg
ca528d1de7
ldap: adapt to conn->port now being an 'int'
Remove typecasts. Fix printf() formats.

Follow-up from 764c6bd3bf.
Pointed out by Coverity CID 1507858.

Closes #9281
2022-08-08 19:56:14 +02:00
Daniel Stenberg
09f1e58cfe
KNOWN_BUGS: Negotiate authentication against Hadoop HDFS
Closes #8264
2022-08-08 16:45:51 +02:00
Futaura
23c708cdc8
file: add handling of native AmigaOS paths
On AmigaOS 4.x, handle native absolute paths, whilst blocking relative
paths. Also allow unix style paths if feature enabled at link time.

Inspiration-from: Michael Trebilcock

Closes #9259
2022-08-08 16:42:10 +02:00
Daniel Stenberg
ba2ccf368e
KNOWN_BUGS: cmake build is not thread-safe
The cmake build does not check for and verify presence of a working
Atomic type, which then makes curl_global_init() to not build
thread-safe on non-Windows platforms.

Closes https://github.com/curl/curl/issues/8973
Closes https://github.com/curl/curl/pull/8982
2022-08-08 16:00:17 +02:00
Futaura
c6631e827d
configure: fixup bsdsocket detection code for AmigaOS 4.x
The code that detects bsdsocket.library for AmigaOS did not work
for AmigaOS 4.x. This has been fixed and also cleaned up a little
to reduce duplication. Wasn't technically necessary before, but is
required when building with AmiSSL instead of OpenSSL.

Closes #9268
2022-08-08 15:49:28 +02:00
Futaura
80e9eef737
tool: reintroduce set file comment code for AmigaOS
Amiga specific code which put the URL in the file comment was perhaps
accidentally removed in b889408500 having
originally been added in 5c215bdbdf.
Reworked to fit the code changes and added it back in.

Reported-by: Michael Trebilcock
Originally-added-by: Chris Young

Closes #9258
2022-08-08 15:48:08 +02:00
Daniel Stenberg
a29d34b0b7
urldata: make 'negnpn' use less storage
The connectdata struct field 'negnpn' never holds a value larger than
30, so an unsigned char saves 3 bytes struct space.

Closes #9279
2022-08-08 14:31:06 +02:00
Daniel Stenberg
a550831023
urldata: make three *_proto struct fields smaller
Use 'unsigned char' for storage instead of the enum, for three GSSAPI
related fields in the connectdata struct.

Closes #9278
2022-08-08 14:30:25 +02:00
Daniel Stenberg
0f23341953
connect: set socktype/protocol correctly
So that an address used from the DNS cache that was previously used for
QUIC can be reused for TCP and vice versa.

To make this possible, set conn->transport to "unix" for unix domain
connections ... and store the transport struct field in an unsigned char
to use less space.

Reported-by: ウさん
Fixes #9274
Closes #9276
2022-08-08 13:26:11 +02:00
Futaura
a041ed8cde
amissl: allow AmiSSL to be used with AmigaOS 4.x builds
Enable AmiSSL to be used instead of static OpenSSL link libraries.
for AmigaOS 4.x, as it already is in the AmigaOS 3.x build.

Closes #9269
2022-08-08 10:48:11 +02:00