aboutsummaryrefslogtreecommitdiff
path: root/lib/curl_setup.h
AgeCommit message (Collapse)Author
2020-05-21Add gemini protocol supportBen Burwell
The gemini protocol's "speculative specification" is documented at the following URLs: https://gemini.circumlunar.space/docs/spec-spec.txt gopher://gemini.circumlunar.space/1/docs/spec-spec.txt gemini://gemini.circumlunar.space/docs/spec-spec.txt This patch introduces preliminary support for version 0.11.0 of the specification, as of March 1st 2020.
2020-05-14curl_setup: support Unicode functions to open files on WindowsMarcel Raad
Use them only if `_UNICODE` is defined, in which case command-line arguments have been converted to UTF-8. Closes https://github.com/curl/curl/pull/3784
2020-03-21lib/curl_setup: adjust the copyright year rangeDaniel Stenberg
Follow-up from d820224b8
2020-03-21curl_setup: define _WIN32_WINNT_[OS] symbolsJay Satiro
.. because not all Windows build systems have those symbols, and even those that do may be missing newer symbols (eg the Windows 7 SDK does not define _WIN32_WINNT_WIN10). Those symbols are used in build-time logic to decide which API to use and prior to this change if the symbols were missing it would have resulted in deprecated API being used when more recent functions were available (eg GetVersionEx used instead of VerifyVersionInfo). Reported-by: FuccDucc@users.noreply.github.com Probably fixes https://github.com/curl/curl/issues/4995 Closes https://github.com/curl/curl/pull/5057
2019-12-05curl_setup: fix `CURLRES_IPV6` conditionMarcel Raad
Move the definition of `CURLRES_IPV6` to before undefining `HAVE_GETADDRINFO`. Regression from commit 67a08dca27a which caused some tests to fail and others to be skipped with c-ares. Fixes https://github.com/curl/curl/issues/4673 Closes https://github.com/curl/curl/pull/4677
2019-12-03curl_setup: disable IPv6 resolver without `getaddrinfo`Marcel Raad
Also, use `CURLRES_IPV6` only for actual DNS resolution, not for IPv6 address support. This makes it possible to connect to IPv6 literals by setting `ENABLE_IPV6` even without `getaddrinfo` support. It also fixes the CMake build when using the synchronous resolver without `getaddrinfo` support. Closes https://github.com/curl/curl/pull/4662
2019-12-01build: Disable Visual Studio warning "conditional expression is constant"Jay Satiro
- Disable warning C4127 "conditional expression is constant" globally in curl_setup.h for when building with Microsoft's compiler. This mainly affects building with the Visual Studio project files found in the projects dir. Prior to this change the cmake and winbuild build systems already disabled 4127 globally for when building with Microsoft's compiler. Also, 4127 was already disabled for all build systems in the limited circumstance of the WHILE_FALSE macro which disabled the warning specifically for while(0). This commit removes the WHILE_FALSE macro and all other cruft in favor of disabling globally in curl_setup. Background: We have various macros that cause 0 or 1 to be evaluated, which would cause warning C4127 in Visual Studio. For example this causes it: #define Curl_resolver_asynch() 1 Full behavior is not clearly defined and inconsistent across versions. However it is documented that since VS 2015 Update 3 Microsoft has addressed this somewhat but not entirely, not warning on while(true) for example. Prior to this change some C4127 warnings occurred when I built with Visual Studio using the generated projects in the projects dir. Closes https://github.com/curl/curl/pull/4658
2019-11-26TLS: add BearSSL vtls implementationMichael Forney
Closes #4597
2019-08-20cleanup: remove DOT_CHAR completelyDaniel Stenberg
Follow-up to f9c7ba9096ec The use of DOT_CHAR for ".ssh" was probably a mistake and is removed now. Pointed-out-by: Gisle Vanem Bug: https://github.com/curl/curl/pull/4230#issuecomment-522960638 Closes #4247
2019-07-31plan9: add support for running on Plan 9lufia
Closes #3701
2019-07-21HTTP3: initial (experimental) supportDaniel Stenberg
USe configure --with-ngtcp2 or --with-quiche Using either option will enable a HTTP3 build. Co-authored-by: Alessandro Ghedini <alessandro@ghedini.me> Closes #3500
2019-06-10wolfssl: refer to it as wolfSSL onlyDaniel Stenberg
Remove support for, references to and use of "cyaSSL" from the source and docs. wolfSSL is the current name and there's no point in keeping references to ancient history. Assisted-by: Daniel Gustafsson Closes #3903
2019-05-22PolarSSL: deprecate support step 1. Removed from configure.Daniel Stenberg
Also removed mentions from most docs. Discussed: https://curl.haxx.se/mail/lib-2019-05/0045.html Closes #3888
2019-05-06ssh: define USE_SSH if SSH is enabled (any backend)Daniel Stenberg
Closes #3846
2019-03-15configure: add --with-amisslChris Young
AmiSSL is an Amiga native library which provides a wrapper over OpenSSL. It also requires all programs using it to use bsdsocket.library directly, rather than accessing socket functions through clib, which libcurl was not necessarily doing previously. Configure will now check for the headers and ensure they are included if found. Closes #3677
2019-02-28Secure Transport: no more "darwinssl"Daniel Stenberg
Everyone calls it Secure Transport, now we do too. Reviewed-by: Nick Zitzmann Closes #3619
2019-02-10cleanup: make local functions staticDaniel Stenberg
urlapi: turn three local-only functions into statics conncache: make conncache_find_first_connection static multi: make detach_connnection static connect: make getaddressinfo static curl_ntlm_core: make hmac_md5 static http2: make two functions static http: make http_setup_conn static connect: make tcpnodelay static tests: make UNITTEST a thing to mark functions with, so they can be static for normal builds and non-static for unit test builds ... and mark Curl_shuffle_addr accordingly. url: make up_free static setopt: make vsetopt static curl_endian: make write32_le static rtsp: make rtsp_connisdead static warnless: remove unused functions memdebug: remove one unused function, made another static
2018-11-01axtls: removedDaniel Stenberg
As has been outlined in the DEPRECATE.md document, the axTLS code has been disabled for 6 months and is hereby removed. Use a better supported TLS library! Assisted-by: Daniel Gustafsson Closes #3194
2018-10-09curl_setup: define NOGDI on WindowsMarcel Raad
This avoids an ERROR macro clash between <wingdi.h> and <arpa/tftp.h> on MinGW. Closes https://github.com/curl/curl/pull/3113
2018-09-13vtls: add a MesaLink vtls backendYiming Jing
Closes #2984
2018-08-13http: fix for tiny "HTTP/0.9" responseDaniel Stenberg
Deal with tiny "HTTP/0.9" (header-less) responses by checking the status-line early, even before a full "HTTP/" is received to allow detecting 0.9 properly. Test 1266 and 1267 added to verify. Fixes #2420 Closes #2872
2018-07-09lib/curl_setup.h: remove unicode characterJay Satiro
Follow-up to 82ce416. Ref: https://github.com/curl/curl/commit/8272ec5#commitcomment-29646818
2018-07-09lib/curl_setup.h: remove unicode bom from 8272ec50f02Daniel Stenberg
2018-07-09curl_setup: include <winerror.h> before <windows.h>Marcel Raad
Otherwise, only part of it gets pulled in through <windows.h> on original MinGW. Fixes https://github.com/curl/curl/issues/2361 Closes https://github.com/curl/curl/pull/2721
2018-05-31configure: check for declaration of getpwuid_rBernhard Walle
On our x86 Android toolchain, getpwuid_r is implemented but the header is missing: netrc.c:81:7: error: implicit declaration of function 'getpwuid_r' [-Werror=implicit-function-declaration] Unfortunately, the function is used in curl_ntlm_wb.c, too, so I moved the prototype to curl_setup.h. Signed-off-by: Bernhard Walle <bernhard@bwalle.de> Closes #2609
2018-04-07curl_setup: provide a CURL_SA_FAMILY_T type if none existsDaniel Stenberg
... and use this type instead of 'sa_family_t' in the code since several platforms don't have it. Closes #2463
2018-03-20vauth/cleartext: fix integer overflow checkDaniel Stenberg
Make the integer overflow check not rely on the undefined behavior that a size_t wraps around on overflow. Detected by lgtm.com Closes #2408
2018-01-31curl_setup: move the precautionary define of SIZEOF_TIME_TDaniel Stenberg
... up to before it may be used for the TIME_T_MAX/MIN logic. Reported-by: Michael Kaufmann
2018-01-30time: support > year 2038 time stamps for system with 32bit longDaniel Stenberg
... with the introduction of CURLOPT_TIMEVALUE_LARGE and CURLINFO_FILETIME_T. Fixes #2238 Closes #2264
2018-01-25parsedate: fix date parsing for systems with 32 bit longDaniel Stenberg
Make curl_getdate() handle dates before 1970 as well (returning negative values). Make test 517 test dates for 64 bit time_t. This fixes bug (3) mentioned in #2238 Closes #2250
2018-01-24Fix small typo.Gisle Vanem
2018-01-08progress: calculate transfer speed on milliseconds if possibleDaniel Stenberg
to increase accuracy for quick transfers Fixes #2200 Closes #2206
2017-10-27curl_setup.h: oops, shorten the too long lineDaniel Stenberg
2017-10-27curl_setup: Improve detection of CURL_WINDOWS_APPMartin Storsjo
If WINAPI_FAMILY is defined, it should be safe to try to include winapifamily.h to check what the define evaluates to. This should fix detection of CURL_WINDOWS_APP if building with _WIN32_WINNT set to 0x0600. Closes #2025
2017-09-05openssl: Integrate Peter Wu's SSLKEYLOGFILE implementationJay Satiro
This is an adaptation of 2 of Peter Wu's SSLKEYLOGFILE implementations. The first one, written for old OpenSSL versions: https://git.lekensteyn.nl/peter/wireshark-notes/tree/src/sslkeylog.c The second one, written for BoringSSL and new OpenSSL versions: https://github.com/curl/curl/pull/1346 Note the first one is GPL licensed but the author gave permission to waive that license for libcurl. As of right now this feature is disabled by default, and does not have a configure option to enable it. To enable this feature define ENABLE_SSLKEYLOGFILE when building libcurl and set environment variable SSLKEYLOGFILE to a pathname that will receive the keys. And in Wireshark change your preferences to point to that key file: Edit > Preferences > Protocols > SSL > Master-Secret Co-authored-by: Peter Wu Ref: https://github.com/curl/curl/pull/1030 Ref: https://github.com/curl/curl/pull/1346 Closes https://github.com/curl/curl/pull/1866
2017-08-17system.h: remove all CURL_SIZEOF_* definesDaniel Stenberg
... as they're not used externally and internally we check for the sizes already in configure etc. Closes #1767
2017-08-15cmake: remove dead code for CURL_DISABLE_RTMPBenbuck Nason
Closes #1785
2017-08-01curl_setup: Define CURL_NO_OLDIES for building libcurlJay Satiro
.. to catch accidental use of deprecated error codes. Ref: https://github.com/curl/curl/issues/1688#issuecomment-316764237
2017-07-11curl_setup: always define WIN32_LEAN_AND_MEAN on WindowsMarcel Raad
Make sure to always define WIN32_LEAN_AND_MEAN before including any Windows headers to avoid pulling in unnecessary headers. This avoids unnecessary macro clashes and compiler warnings. Ref: https://github.com/curl/curl/issues/1562 Closes https://github.com/curl/curl/pull/1672
2017-06-15curl_setup.h: error out on CURL_WANTS_CA_BUNDLE_ENV useDaniel Stenberg
... to make it really apparent if there's any user using this on purpose. Suggested-by: Jay Satiro Closes #1542
2017-06-15lib/curl_setup.h: remove CURL_WANTS_CA_BUNDLE_ENVDaniel Stenberg
When this define was set, libcurl would check the environment variable named CURL_CA_BUNDLE at run-time and use that CA cert bundle. This feature was only defined by the watcom and m32 makefiles and caused inconsistent behaviours among libcurls built on different platforms. The curl tool does already feature its own similar logic and the library does not really need it, and it isn't documented libcurl behavior. So this change removes it. Ref: #1538
2017-06-14includes: remove curl/curlbuild.h and curl/curlrules.hDaniel Stenberg
Rely entirely on curl/system.h now. Introduced in Aug 2008 with commit 14240e9e109f. Now gone. Fixes #1456
2017-05-01curl_setup: Ensure no more than one IDN lib is enabledJay Satiro
Prior to this change it was possible for libcurl to be built with both Windows' native IDN lib (normaliz) and libidn2 enabled. It appears that doesn't offer any benefit --and could cause a bug-- since libcurl's IDN handling is written to use either one but not both. Bug: https://github.com/curl/curl/issues/1441#issuecomment-297689856 Reported-by: Gisle Vanem
2017-04-21mbedtls: enable NTLM (& SMB) even if MD4 support is unavailableDan Fandrich
In that case, use libcurl's internal MD4 routine. This fixes tests 1013 and 1014 which were failing due to configure assuming NTLM and SMB were always available whenever mbed TLS was in use (which is now true).
2017-04-03include: curl/system.h is a run-time version of curlbuild.hDaniel Stenberg
system.h is aimed to replace curlbuild.h at a later point in time when we feel confident system.h works sufficiently well. curl/system.h is currently used in parallel with curl/curlbuild.h curl/system.h determines a data sizes, data types and include file status based on available preprocessor defines instead of getting generated at build-time. This, in order to avoid relying on a build-time generated file that makes it complicated to do 32 and 64 bit bields from the same installed set of headers. Test 1541 verifies that system.h comes to the same conclusion that curlbuild.h offers. Closes #1373
2016-11-24checksrc: code style: use 'char *name' styleDaniel Stenberg
2016-10-31idn: switch to libidn2 use and IDNA2008 supportDaniel Stenberg
CVE-2016-8625 Bug: https://curl.haxx.se/docs/adv_20161102K.html Reported-by: Christian Heimes
2016-09-12mbedtls: switch off NTLM in build if md4 isn't availableTony Kelman
NTLM support with mbedTLS was added in 497e7c9 but requires that mbedTLS is built with the MD4 functions available, which it isn't in default builds. This now adapts if the funtion isn't there and builds libcurl without NTLM support if so. Fixes #1004
2016-08-21win: Basic support for Universal Windows Platform appsMarco Deckel
Closes #820
2016-08-03mbedtls: Added support for NTLMBill Nagel