libcurl-env(3)

πŸ“¦ version 7.72.0, in nixos 26.05, nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, welcome to the libcurl-env(3) page β€” environment variables libcurl understands 🫢

✨ DESCRIPTION ✨

So like, libcurl reads and understands a whole set of environment variables, and if you set them they will control and change behaviors. This is the full list of variables to set and what they do β€” no cap, every single one is here. Also note that curl, the command line tool, supports a set of additional environment variables independently of this.

  • [scheme]_proxy β€” when libcurl is given a URL to use in a transfer, it first extracts the "scheme" part from the URL and checks if there is a given proxy set for that in its corresponding environment variable. A URL like http://example.com will hence use the http_proxy variable, while a URL like ftp://example.com will use the ftp_proxy variable. These proxy variables are also checked for in their uppercase versions, except the http_proxy one which is only used lowercase. Note also that some systems actually have a case insensitive handling of environment variables and then of course HTTP_PROXY will still work...
  • ALL_PROXY β€” this is a setting to set proxy for all URLs, independently of what scheme is being used. Note that the scheme specific variables will override this one if set.
  • CURL_SSL_BACKEND β€” when libcurl is built to support multiple SSL backends, it will select a specific backend at first use. If no selection is done by the program using libcurl, this variable's selection will be used. It should be set to the full SSL backend name to use (case insensitive).
  • HOME β€” when the netrc feature is used (CURLOPT_NETRC(3)), this variable is checked as the primary way to find the "current" home directory in which the .netrc file is likely to exist.
  • LOGNAME β€” user name to use when invoking the ntlm-wb tool, if NTLMUSER wasn't set.
  • NO_PROXY β€” this has the same functionality as the CURLOPT_NOPROXY(3) option: it gives libcurl a comma-separated list of host name patterns for which libcurl should not use a proxy.
  • NTLMUSER β€” user name to use when invoking the ntlm-wb tool.
  • SSLKEYLOGFILE β€” when set and libcurl runs with a SSL backend that supports this feature, libcurl will save SSL secrets into the given file name. Using those SSL secrets, other tools (such as Wireshark) can decrypt the SSL communication and analyze/view the traffic.
  • SSL_DIR β€” when libcurl runs with the NSS backends for TLS features, this variable is used to find the directory for NSS PKI database instead of the built-in.
  • USER β€” user name to use when invoking the ntlm-wb tool, if NTLMUSER and LOGNAME weren't set.

🧚 Debug Variables 🧚

🚨 There's a set of variables only recognized and used if libcurl was built "debug enabled", which should never be true for a library used in production. Like, fr fr, do not ship these.
  • CURL_GETHOSTNAME β€” Debug-only variable.
  • CURL_FORCETIME β€” Debug-only variable.
  • CURL_ENTROPY β€” Debug-only variable. Used to set a fixed faked value to use instead of a proper random number so that functions in libcurl that are otherwise getting random outputs can be tested for what they generate.
  • CURL_TRACE β€” Debug-only variable. Used for debugging the lib/ldap implementation.
  • CURL_NTLM_WB_FILE β€” Debug-only variable. Used to set to a debug-version of the ntlm-wb executable.
  • CURL_OPENLDAP_TRACE β€” Debug-only variable. Used for debugging the lib/openldap.c implementation.

okay that's the whole page 🫢 sending you off with the footer deets: this is libcurl-env(3), version libcurl 7.58.0, dated 20 January 2018 πŸ’…βœ¨

πŸ“¦ where this page comes from