summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* urlapi: skip a strlen(), pass in zerobagder/urlapi-skip-strlenDaniel Stenberg2021-10-152-3/+2
| | | | | | ... to let curl_easy_escape() itself do the strlen. This avoids a (false positive) Coverity warning and it avoids us having to store the strlen() return value in an int variable.
* examples/htmltidy: correct wrong printf() useDaniel Stenberg2021-10-151-4/+4
| | | | | | | | | ... and update the includes to match how current htmltidy wants them used. Reported-by: Stathis Kapnidis Fixes #7860 Closes #7861
* http: set content length earlierJay Satiro2021-10-153-45/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Make content length (ie download size) accessible to the user in the header callback, but only after all headers have been processed (ie only in the final call to the header callback). Background: For a long time the content length could be retrieved in the header callback via CURLINFO_CONTENT_LENGTH_DOWNLOAD_T as soon as it was parsed by curl. Changes were made in 8a16e54 (precedes 7.79.0) to ignore content length if any transfer encoding is used. A side effect of that was that content length was not set by libcurl until after the header callback was called the final time, because until all headers are processed it cannot be determined if content length is valid. This change keeps the same intention --all headers must be processed-- but now the content length is available before the final call to the header function that indicates all headers have been processed (ie a blank header). Bug: https://github.com/curl/curl/commit/8a16e54#r57374914 Reported-by: sergio-nsk@users.noreply.github.com Co-authored-by: Daniel Stenberg Fixes https://github.com/curl/curl/issues/7804 Closes https://github.com/curl/curl/pull/7803
* aws-sigv4: make signature work when post data is binaryAbhinav Singh2021-10-158-3/+219
| | | | | | | | | User sets the post fields size for binary data. Hence, we should not be using strlen on it. Added test 1937 and 1938 to verify. Closes #7844
* MacOSX-Framework: remove redundant ';'a13460542021-10-151-1/+1
| | | | Closes #7859
* RELEASE-NOTES: syncedDaniel Stenberg2021-10-141-7/+30
|
* openssl: with OpenSSL 1.1.0+ a failed RAND_status means goawayDaniel Stenberg2021-10-141-12/+23
| | | | | | | | | One reason we know it can fail is if a provider is used that doesn't do a proper job or is wrongly configured. Reported-by: Michael Baentsch Fixes #7840 Closes #7856
* cmake: add CURL_ENABLE_SSL option and make CMAKE_USE_* SSL backend options ↵Ryan Mast2021-10-141-7/+8
| | | | | | depend on it Closes https://github.com/curl/curl/pull/7822
* http: remove assert that breaks hyperDaniel Stenberg2021-10-141-1/+1
| | | | | | Reported-by: Jay Satiro Fixes #7852 Closes #7855
* http_proxy: fix one more result assign for hyperDaniel Stenberg2021-10-141-1/+1
| | | | | | and remove the bad assert again, since it was run even with no error! Closes #7854
* sws: fix memory leak on exitJay Satiro2021-10-141-5/+7
| | | | | | | | | - Free the allocated http request struct on cleanup. Prior to this change if sws was built with leak sanitizer it would report a memory leak error during testing. Closes https://github.com/curl/curl/pull/7849
* c-hyper: make Curl_http propagate errors betterDaniel Stenberg2021-10-141-41/+78
| | | | | | | | Pass on better return codes when errors occur within Curl_http instead of insisting that CURLE_OUT_OF_MEMORY is the only possible one. Pointed-out-by: Jay Satiro Closes #7851
* http_proxy: make hyper CONNECT() return the correct error codeDaniel Stenberg2021-10-141-12/+39
| | | | | | | | | For every 'goto error', make sure the result variable holds the error code for what went wrong. Reported-by: Rafał Mikrut Fixes #7825 Closes #7846
* docs/Makefile.am: repair 'make html'Daniel Stenberg2021-10-141-1/+1
| | | | | | by removing index.html which isn't around anymore Closes #7853
* curl: correct grammar in generated libcurl codeБорис Верховский2021-10-1311-10/+10
| | | | Closes #7802
* tests: disable test 2043Daniel Stenberg2021-10-131-0/+1
| | | | | | | | It uses revoked.badssl.com which now is expired and therefor this now permafails. We should not use external sites for tests, this test should be converted to use our own infra. Closes #7845
* runtests: split out ignored testsDaniel Stenberg2021-10-121-3/+7
| | | | | | | | | | | Report ignore tests separately from the actual fails. Don't exit non-zero if test servers couldn't get killed. Assisted-by: Jay Satiro Fixes #7818 Closes #7841
* http2: make getsock not wait for write if there's no remote windowDaniel Stenberg2021-10-121-5/+21
| | | | | | | | | | While uploading, check for remote window availability in the getsock function so that we don't wait for a writable socket if no data can be sent. Reported-by: Steini2000 on github Fixes #7821 Closes #7839
* test368: verify dash is appended for "-r [num]"Daniel Stenberg2021-10-112-1/+50
| | | | Follow-up to 8758a26f8878
* curl: actually append "-" to --range without number onlyБорис Верховский2021-10-111-2/+1
| | | | Closes #7837
* RELEASE-NOTES: syncedDaniel Stenberg2021-10-111-9/+29
|
* urlapi: URL decode percent-encoded host namesDaniel Stenberg2021-10-113-39/+143
| | | | | | | | | | | | | | | | | | | | | | The host name is stored decoded and can be encoded when used to extract the full URL. By default when extracting the URL, the host name will not be URL encoded to work as similar as possible as before. When not URL encoding the host name, the '%' character will however still be encoded. Getting the URL with the CURLU_URLENCODE flag set will percent encode the host name part. As a bonus, setting the host name part with curl_url_set() no longer accepts a name that contains space, CR or LF. Test 1560 has been extended to verify percent encodings. Reported-by: Noam Moshe Reported-by: Sharon Brizinov Reported-by: Raul Onitza-Klugman Reported-by: Kirill Efimov Fixes #7830 Closes #7834
* CI/makefiles: introduce dedicated test targetMarc Hoersken2021-10-089-9/+19
| | | | | | | | | | Make it easy to use the same set of test flags throughout all current and future CI builds. Reviewed-by: Jay Satiro Follow up to #7690 Closes #7785
* maketgz: redirect updatemanpages.pl output to /dev/nullDaniel Stenberg2021-10-081-2/+2
|
* CURLOPT_HTTPHEADER.3: add descripion for specific headersDaniel Stenberg2021-10-081-0/+10
| | | | | | | Settting Host: or Transfer-Encoding: chunked actually have special meanings to libcurl. This change tries to document them Closes #7829
* c-hyper: use hyper_request_set_uri_parts to make h2 betterDaniel Stenberg2021-10-081-6/+31
| | | | | | | | and make sure to not send Host: over h2. Fixes #7679 Reported-by: David Cook Closes #7827
* curl-openssl.m4: modify library order for openssl linkingMichael Afanasiev2021-10-081-2/+2
| | | | | | | | lcrypto may depend on lz, and configure corrently fails with when statically linking as the order is "-lz -lcrypto". This commit switches the order to "-lcrypto -lz". Closes #7826
* sha256: use high-level EVP interface for OpenSSLMarcel Raad2021-10-071-41/+70
| | | | | | | Available since OpenSSL 0.9.7. The low-level SHA256 interface is deprecated in OpenSSL v3, and its usage was discouraged even before. Closes https://github.com/curl/curl/pull/7808
* curl_ntlm_core: use OpenSSL only if DES is availableMarcel Raad2021-10-071-5/+12
| | | | | | | This selects another SSL backend then if available, or otherwise at least gives a meaningful error message. Closes https://github.com/curl/curl/pull/7808
* md5: fix compilation with OpenSSL 3.0 APIMarcel Raad2021-10-071-7/+15
| | | | | | | | | | Only use OpenSSL's MD5 code if it's available. Also fix wolfSSL build with `NO_MD5`, in which case neither the wolfSSL/OpenSSL implementation nor the fallback implementation was used. Closes https://github.com/curl/curl/pull/7808
* print_category: printf %*s needs an int argumentDaniel Stenberg2021-10-071-1/+1
| | | | | | | ... not a size_t! Detected by Coverity: CID 1492331. Closes #7823
* version_win32: use actual version instead of manifested versionJay Satiro2021-10-073-5/+50
| | | | | | | | | | | | | | | | | | - Use RtlVerifyVersionInfo instead of VerifyVersionInfo, when possible. Later versions of Windows have normal version functions that compare and return versions based on the way the application is manifested, instead of the actual version of Windows the application is running on. We prefer the actual version of Windows so we'll now call the Rtl variant of version functions (RtlVerifyVersionInfo) which does a proper comparison of the actual version. Reported-by: Wyatt O'Day Ref: https://github.com/curl/curl/pull/7727 Fixes https://github.com/curl/curl/issues/7742 Closes https://github.com/curl/curl/pull/7810
* RELEASE-NOTES: syncedDaniel Stenberg2021-10-061-10/+29
|
* http: fix Basic auth with empty name field in URLDaniel Stenberg2021-10-063-2/+50
| | | | | | | | Add test 367 to verify. Reported-by: Rick Lane Fixes #7819 Closes #7820
* CURLOPT_MAXLIFETIME_CONN: maximum allowed lifetime for conn reuseJeffrey Tolar2021-10-0616-12/+272
| | | | | | | | | ... and close connections that are too old instead of reusing them. By default, this behavior is disabled. Bug: https://curl.se/mail/lib-2021-09/0058.html Closes #7751
* docs/examples: add missing binaries to gitignoreDaniel Gustafsson2021-10-061-0/+2
| | | | | | | | Commit f65d7889b added getreferrer, and commit ae8e11ed5 multi-legacy, both of which missed adding .gitignore clauses for the built binaries. Closes #7817 Reviewed-by: Daniel Stenberg <daniel@haxx.se>
* HTTP3: fix the HTTP/3 Explained book linkJosip Medved2021-10-051-1/+1
| | | | Closes #7813
* misc: fix a few issues on MidnightBSDLucas Holt2021-10-055-7/+13
| | | | Closes #7812
* tool_main: fix typo in comment8U61ife2021-10-041-1/+1
| | | | | Closes: #7811 Reviewed-by: Daniel Gustafsson <daniel@yesql.se>
* BINDINGS: URL updatesRyan Mast2021-10-041-7/+7
| | | | | | For cpr, BBHTTP, Eiffel, Harbour, Haskell, Mono, and Rust Closes #7809
* scripts/delta: hide a git error message we don't care aboutDaniel Stenberg2021-10-021-1/+1
| | | | fatal: path 'src/tool_listhelp.c' exists on disk, but not in [tag]
* sasl: binary messagesPatrick Monnerat2021-10-026-230/+304
| | | | | | | | | | Capabilities of sasl module are extended to exchange messages in binary as an alternative to base64. If http authentication flags have been set, those are used as sasl default preferred mechanisms. Closes #6930
* wolfssl: use for SHA256, MD4, MD5, and setting DES odd parityHayden Roche2021-10-025-7/+37
| | | | | | | | Prior to this commit, OpenSSL could be used for all these functions, but not wolfSSL. This commit makes it so wolfSSL will be used if USE_WOLFSSL is defined. Closes #7806
* scripts/delta: count command line options in the new fileDaniel Stenberg2021-10-011-2/+2
| | | | ... which makes the shown delta number wrong until next release.
* RELEASE-NOTES: syncedDaniel Stenberg2021-10-011-5/+24
|
* print_category: print help descriptions alignedDaniel Stenberg2021-10-014-19/+36
| | | | | | | | Adjust the description position to make an aligned column when doing help listings, which is more pleasing to the eye. Suggested-by: Gisle Vanem Closes #7792
* lib/mk-ca-bundle.pl: skip certs passed Not Valid After dateDaniel Stenberg2021-09-301-2/+18
| | | | | | | | | With this change applied, the now expired 'DST Root CA X3' cert will no longer be included in the output. Details: https://letsencrypt.org/docs/dst-root-ca-x3-expiration-september-2021/ Closes #7801
* tool_listhelp: easier to generate with gen.plDaniel Stenberg2021-09-309-790/+862
| | | | | | | | | | | | | | | tool_listhelp.c is now a separate file with only the command line --help output, exactly as generated by gen.pl. This makes it easier to generate updates according to what's in the docs/cmdline-opts docs. cd $srcroot/docs/cmdline-opts ./gen.pl listhelp *.d > $srcroot/src/tool_listhelp.c With a configure build, this also works: make -C src listhelp Closes #7787
* wolfssl: allow setting of groups/curvesAnthony Hu2021-09-301-1/+70
| | | | | | | In particular, the quantum safe KEM and hybrid curves if wolfSSL is built to support them. Closes #7728
* connnect: use sysaddr_un fron sys/un.h or custom-defined for windowsJan Mazur2021-09-302-2/+3
| | | | Closes #7737