summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* urlapi: reject short file URLsbagder/short-file-urlDaniel Stenberg2021-11-222-0/+10
| | | | | | | file URLs that are 6 bytes or shorter are not complete. Return CURLUE_MALFORMED_INPUT for those. Extended test 1560 to verify. Triggered by #8041
* urlapi: cleanup scheme parsingStefan Eissing2021-11-221-16/+22
| | | | | | | Makea Curl_is_absolute_url() always leave a defined 'buf' and avoids copying on urls that do not start with a scheme. Closes #8043
* tool_operate: only set SSH related libcurl options for SSH URLsDaniel Stenberg2021-11-213-36/+83
| | | | | | | For example, this avoids trying to find and set the known_hosts file (or warn for its absence) if SFTP or SCP are not used. Closes #8040
* rustls: remove comment about checking handshakingJacob Hoffman-Andrews2021-11-201-3/+0
| | | | | | | | The comment is incorrect in two ways: - It says the check needs to be last, but the check is actually first. - is_handshaking actually starts out true. Closes #8038
* openssl: use non-deprecated API to read key parametersMarcel Raad2021-11-201-28/+66
| | | | | | | With OpenSSL 3.0, the parameters are read directly from the `EVP_PKEY` using `EVP_PKEY_get_bn_param`. Closes https://github.com/curl/curl/pull/7893
* openssl: reduce code duplicationMarcel Raad2021-11-201-25/+12
| | | | | | `BN_print`'s `BIGNUM` parameter has been `const` since OpenSSL 0.9.4. Closes https://github.com/curl/curl/pull/7893
* openssl: remove `RSA_METHOD_FLAG_NO_CHECK` handling if unavailableMarcel Raad2021-11-201-1/+2
| | | | | | The flag has been deprecated without replacement in OpenSSL 3.0. Closes https://github.com/curl/curl/pull/7893
* openssl: remove usage of deprecated `SSL_get_peer_certificate`Marcel Raad2021-11-201-2/+6
| | | | | | | The function name was changed to `SSL_get1_peer_certificate` in OpenSSL 3.0. Closes https://github.com/curl/curl/pull/7893
* page-footer: fix typoDaniel Stenberg2021-11-191-1/+1
| | | | Closes #8036
* http: enable haproxy support for hyper backendDaniel Stenberg2021-11-193-10/+3
| | | | | | | | | | | | | | This is done by having native code do the haproxy header output before hyper issues its request. The little downside with this approach is that we need the entire Curl_buffer_send() function built, which is otherwise not used for hyper builds. If hyper ends up getting native support for the haproxy protocols we can backpedal on this. Enables test 1455 and 1456 Closes #8034
* configure: fix runtime-lib detection on macOSBernhard Walle2021-11-181-4/+10
| | | | | | | | | | | | With a non-standard installation of openssl we get this error: checking run-time libs availability... failed configure: error: one or more libs available at link-time are not available run-time. Libs used at link-time: -lnghttp2 -lssl -lcrypto -lssl -lcrypto -lz There's already code to set LD_LIBRARY_PATH on Linux, so set DYLD_LIBRARY_PATH equivalent on macOS. Closes #8028
* cmake: don't set _USRDLL on a static Windows buildDon2021-11-181-4/+1
| | | | Closes #8030
* page-footer: document more environment variablesDaniel Stenberg2021-11-171-0/+29
| | | | | | ... that curl might use. Closes #8027
* netrc.d: edit the .netrc example to look nicerDaniel Stenberg2021-11-171-2/+4
| | | | | | Works nicely thanks to d1828b470f43d Closes #8025
* tftp: mark protocol as not possible to do over CONNECTDaniel Stenberg2021-11-154-7/+14
| | | | | | | | | ... and make connect_init() refusing trying to tunnel protocols marked as not working. Avoids a double-free. Reported-by: Even Rouault Fixes #8018 Closes #8020
* docs/cmdline-opts: do not say "protocols: all"Daniel Stenberg2021-11-153-3/+0
| | | | | | | | Remove the lines saying "protocols: all". It makes the output in the manpage look funny, and the expectation is probably by default that if not anything is mentioned about protocols the option apply to them all. Closes #8021
* curl.1: require "see also" for every documented optionDaniel Stenberg2021-11-15168-8/+179
| | | | | | | | | | gen.pl now generates a warning if the "See Also" field is not filled in for a command line option All command line options now provide one or more related options. 167 "See alsos" added! Closes #8019
* insecure.d: expand and clarifyDaniel Stenberg2021-11-151-7/+9
| | | | Closes #8017
* gen.pl: improve example output formatDaniel Stenberg2021-11-153-10/+16
| | | | | | | | | Treat consecutive lines that start with a space to be "examples". They are output enclosed by .nf and .fi Updated form.d to use this new fanciness Closes #8016
* Revert "form-escape.d: double the back-slashes for proper man page output"Daniel Stenberg2021-11-151-1/+1
| | | | | | This reverts commit a2d8eac04a4eb1d5a98cf24b4e5cec5cec565d27. silly me, it was intended to be one backslash!
* form-escape.d: double the back-slashes for proper man page outputDaniel Stenberg2021-11-151-1/+1
|
* page-footer: add a mention of how to report bugs to the man pageDaniel Stenberg2021-11-151-0/+3
|
* RELEASE-NOTES: syncedDaniel Stenberg2021-11-152-11/+37
| | | | and bump to 7.81.0-DEV
* mime: use percent-escaping for multipart form field and file namesPatrick Monnerat2021-11-1523-31/+464
| | | | | | | | | | | | | | | | | | Until now, form field and file names where escaped using the backslash-escaping algorithm defined for multipart mails. This commit replaces this with the percent-escaping method for URLs. As this may introduce incompatibilities with server-side applications, a new libcurl option CURLOPT_MIME_OPTIONS with bitmask CURLMIMEOPT_FORMESCAPE is introduced to revert to legacy use of backslash-escaping. This is controlled by new cli tool option --form-escape. New tests and documentation are provided for this feature. Reported by: Ryan Sleevi Fixes #7789 Closes #7805
* zuul.d: update rustls-ffi to version 0.8.2Kevin Burke2021-11-152-3/+3
| | | | | | | | This version fixes errors with ALPN negotiation in rustls, which is necessary for HTTP/2 support. For more information see the rustls-ffi changelog. Closes #8013
* configure: better diagnostics if hyper is built wrongDaniel Stenberg2021-11-141-1/+7
| | | | | | | | | | If hyper is indeed present in the specified directory but couldn't be used to find the correct symbol, then offer a different error message to better help the user understand the issue. Suggested-by: Jacob Hoffman-Andrews Fixes #8001 Closes #8005
* test1939: require proxy support to runDaniel Stenberg2021-11-141-0/+3
| | | | | | Follow-up to f0b7099a10d1a Closes #8011
* test302[12]: run only with the libssh2 backendDaniel Stenberg2021-11-142-0/+8
| | | | | | | | ... as the others don't support --hostpubsha256 Reported-by: Paul Howarth Fixes #8009 Closes #8010
* runtests: make the SSH library a testable featureDaniel Stenberg2021-11-142-0/+18
| | | | libssh2, libssh and wolfssh
* rustls: read of zero bytes might be okayJacob Hoffman-Andrews2021-11-131-8/+18
| | | | | | | | | | | | | When we're reading out plaintext from rustls' internal buffers, we might get a read of zero bytes (meaning a clean TCP close, including close_notify). However, we shouldn't return immediately when that happens, since we may have already copied out some plaintext bytes. Break out of the loop when we get a read of zero bytes, and figure out which path we're dealing with. Acked-by: Kevin Burke Closes #8003
* rustls: remove incorrect EOF checkJacob Hoffman-Andrews2021-11-131-5/+0
| | | | | | | | | | | | | | | | | | | | | | The update to rustls-ffi 0.8.0 changed handling of EOF and close_notify. From the CHANGELOG: > Handling of unclean close and the close_notify TLS alert. Mirroring > upstream changes, a rustls_connection now tracks TCP closed state like > so: rustls_connection_read_tls considers a 0-length read from its > callback to mean "TCP stream was closed by peer." If that happens > before the peer sent close_notify, rustls_connection_read will return > RUSTLS_RESULT_UNEXPECTED_EOF once the available plaintext bytes are > exhausted. This is useful to protect against truncation attacks. Note: > some TLS implementations don't send close_notify. If you are already > getting length information from your protocol (e.g. Content-Length in > HTTP) you may choose to ignore UNEXPECTED_EOF so long as the number of > plaintext bytes was as expected. That means we don't need to check for unclean EOF in `cr_recv()`, because `process_new_packets()` will give us an error if appropriate. Closes #8003
* lib1939: make it endure torture testsDaniel Stenberg2021-11-131-29/+26
| | | | | | Follow-up to f0b7099a10d1a Closes #8007
* azure: make the "w/o HTTP/SMTP/IMAP" build disable SSL properDaniel Stenberg2021-11-131-1/+1
| | | | | | | | | | The configure line would previously depend on a configure mistake using --without-openssl that is fixed and now this configure line needs adjusting to use --without-ssl. Follow-up to b589696f0312d Closes #8006
* configure: add -lm to configure for rustls build.Jacob Hoffman-Andrews2021-11-131-8/+3
| | | | | | | | | Note: The list of libraries that rustc tells us we need to include is longer, but also includes some more platform-specific libraries that I am not sure how to effectively incorporate. Adding just -lm seems to solve an immediate problem, so I'm adding just that. Closes #8002
* curl_share_setopt.3: refer to CURLSHOPT_USERDATA(3) properlyDaniel Stenberg2021-11-121-2/+1
|
* curl_share_setopt.3: split out options into their own manpagesDaniel Stenberg2021-11-127-70/+370
| | | | | | | | | | CURLSHOPT_LOCKFUNC.3 CURLSHOPT_SHARE.3 CURLSHOPT_UNLOCKFUNC.3 CURLSHOPT_UNSHARE.3 CURLSHOPT_USERDATA.3 Closes #7998
* http_proxy: make Curl_connect_done() work for proxy disabled buildsDaniel Stenberg2021-11-121-1/+2
| | | | | | | | | ... by making it an empty macro then. Follow-up to f0b7099a10d1a Reported-by: Vincent Grande Fixes #7995 Closes #7996
* Curl_connect_done: handle being called twiceDaniel Stenberg2021-11-121-2/+3
| | | | | | | | | | Follow-up to f0b7099a10d1a7c When torture testing 1021, it turns out the Curl_connect_done function might be called twice and that previously then wrongly cleared the HTTP pointer in the second invoke. Closes #7999
* configure: don't enable TLS when --without-* flags are usedStan Hu2021-11-121-9/+27
| | | | | | | | | | | | | | | | | | Previously specifying `--without-gnutls` would unexpectedly attempt to compile with GnuTLS, effectively interpreting this as `--with-gnutls`. This caused a significant amount of confusion when `libcurl` was built with SSL disabled since GnuTLS wasn't present. 68d89f24 dropped the `--without-*` options from the configure help, but `AC_ARG_WITH` still defines these flags automatically. As https://www.gnu.org/software/autoconf/manual/autoconf-2.60/html_node/External-Software.html describes, the `action-if-given` is called when the user specifies `--with-*` or `--without-*` options. To prevent this confusion, we make the `--without` flag do the right thing by ignoring the value if it set to "no". Closes #7994
* docs/checksrc: Add documentation for STRERRORRikard Falkeborn2021-11-111-1/+3
| | | | Closes #7991
* vtls/rustls: adapt to the updated rustls_version protoDaniel Stenberg2021-11-113-13/+20
| | | | Closes #7956
* vtls/rustls: handle RUSTLS_RESULT_PLAINTEXT_EMPTYKevin Burke2021-11-111-7/+4
| | | | | | | | | | | | Previously we'd return CURLE_READ_ERROR if we received this, instead of triggering the error handling logic that's present in the next if block down. After this change, curl requests to https://go.googlesource.com using HTTP/2 complete successfully. Fixes #7949 Closes #7948
* zuul: update build environment for rustls-ffi 0.8.0Kevin Burke2021-11-112-3/+3
|
* vtls/rustls: update to compile with rustls-ffi v0.8.0Kevin Burke2021-11-113-8/+8
| | | | | | | | | | | | Some method names, as well as the generated library name, were changed in a recent refactoring. Further, change the default configuration instructions to check for Hyper in either "target/debug" or "target/release" - the latter contains an optimized build configuration. Fixes #7947 Closes #7948
* RELEASE-NOTES: syncedDaniel Stenberg2021-11-112-268/+14
| | | | and bump the version to 7.80.1
* multi: shut down CONNECT in Curl_detach_connnectionDaniel Stenberg2021-11-116-7/+138
| | | | | | | | | | ... to prevent a lingering pointer that would lead to a double-free. Added test 1939 to verify. Reported-by: Stephen M. Coakley Fixes #7982 Closes #7986
* curl_easy_cleanup.3: remove from multi handle firstDaniel Stenberg2021-11-101-0/+4
| | | | | | | | | Easy handles that are used by the multi interface should be removed from the multi handle before they are cleaned up. Reported-by: Stephen M. Coakley Ref: #7982 Closes #7983
* url.c: fix the SIGPIPE comment for Curl_closeDaniel Stenberg2021-11-101-3/+1
| | | | Closes #7984
* RELEASE-NOTES: syncedcurl-7_80_0Daniel Stenberg2021-11-101-15/+34
| | | | for curl 7.80.0
* THANKS: add contributors from the 7.80.0 cycleDaniel Stenberg2021-11-101-0/+45
|