OPENSSL-ENV(7ossl)
π OPENSSL-ENV π
okay bestie, welcome to the openssl-env page β that's section 7ossl of the OpenSSL manual, and honestly? it's the cheat sheet of every environment variable the OpenSSL libraries will peek at. grab a snack, we're going through all of them π
β¨ NAME β¨
openssl-env β OpenSSL environment variables, aka the secret little knobs the libraries read from your shell π
πΈ DESCRIPTION πΈ
so here's the vibe: the OpenSSL libraries use environment variables to override the compiled-in default paths for all kinds of data. cute, right? but β and this is the important part β to avoid security risks, the environment is usually not consulted when the executable is set-user-ID or set-group-ID. no cap, that's a real thing π«Ά
π¦ the variables, one by one
CTLOG_FILEβ gives the path to a certificate transparency log list. seeCTLOG_STORE_new(3). βOPENSSLβ gives the path to theopensslexecutable. it's used by therehashscript (see "Script Configuration" inopenssl-rehash(1)) and by theCA.plscript (see "NOTES" inCA.pl(1)).OPENSSL_CONF,OPENSSL_CONF_INCLUDEβ gives the path to a configuration file, plus the directory for included files. seeconfig(5). πOPENSSL_CONFIGβ gives a configuration option and filename for thereqandcacommands when they're invoked by theCA.plscript. seeCA.pl(1).OPENSSL_ENGINESβ gives the directory that dynamic engines get loaded from. seeopenssl-engine(1). π₯OPENSSL_MALLOC_FD,OPENSSL_MALLOC_FAILURESβ if OpenSSL was built with debugging, this lets memory allocation fail on purpose. seeOPENSSL_malloc(3).OPENSSL_MODULESβ gives the directory that cryptographic providers get loaded from. equivalently, you can use the generic-provider-pathcommand-line option instead. β¨OPENSSL_TRACEβ by default, the OpenSSL trace feature is disabled statically. to enable it, OpenSSL has to be built with tracing support, which you can configure like this:
./config enable-trace
unless OpenSSL tracing support is generally disabled, you can turn on trace output for specific parts of the OpenSSL libraries by name. this output usually only makes sense if you know OpenSSL internals well π
the value of this environment variable is a comma-separated list of names, and here's what's available:
TRACEβ traces the OpenSSL trace API itself.INITβ traces OpenSSL library initialization and cleanup.TLSβ traces the TLS/SSL protocol.TLS_CIPHERβ traces the ciphers used by the TLS/SSL protocol.CONFβ shows details about provider and engine configuration.ENGINE_TABLEβ the function that's used by RSA, DSA (etc) code to select registered ENGINEs, cache defaults and functional references (etc), will generate debugging summaries.ENGINE_REF_COUNTβ reference counts in the ENGINE structure will be monitored with a line generated for each change.PKCS5V2β traces PKCS#5 v2 key generation.PKCS12_KEYGENβ traces PKCS#12 key generation.PKCS12_DECRYPTβ traces PKCS#12 decryption.X509V3_POLICYβ generates the complete policy tree at various points during X.509 v3 policy evaluation.BN_CTXβ traces BIGNUM context operations.CMPβ traces CMP client and server activity.STOREβ traces STORE operations.DECODERβ traces decoder operations.ENCODERβ traces encoder operations.REF_COUNTβ traces decrementing certain ASN.1 structure references.HTTPβ traces the HTTP client and server, like messages being sent and received. π
OPENSSL_RUNNING_UNIT_TESTSβ this one flags the fact that unit tests are being run (i.e.make test). it's how OpenSSL detects that it should behave in a special manner during unit tests (i.e. when unit tests are being run on fuzzing builds). it should generally not be set by users, bestie πOPENSSL_WIN32_UTF8β if it's set, thenUI_OpenSSL(3)returns UTF-8 encoded strings instead of ones encoded in the current code page, and theopenssl(1)program also transcodes the command-line parameters from the current code page to UTF-8. this environment variable is only checked on Microsoft Windows platforms. πRANDFILEβ the state file for the random number generator. honestly you shouldn't need this in normal use. seeRAND_load_file(3).SSL_CERT_DIR,SSL_CERT_FILEβ specify the default directory or file containing CA certificates.SSL_CERT_DIRcan contain multiple directories separated by colons (or semicolons on Windows). seeSSL_CTX_load_verify_locations(3). πTSGETβ additional arguments for thetsget(1)command.OPENSSL_ia32cap,OPENSSL_sparcv9cap,OPENSSL_ppccap,OPENSSL_armcap,OPENSSL_s390xcap,OPENSSL_riscvcapβ OpenSSL supports a number of different algorithm implementations for various machines and, by default, it determines which to use based on the processor capabilities and run time feature enquiry. these environment variables let you exert more control over that selection process. seeOPENSSL_armcap(3),OPENSSL_ia32cap(3),OPENSSL_ppccap(3),OPENSSL_riscvcap(3)andOPENSSL_s390xcap(3). βNO_PROXY,HTTPS_PROXY,HTTP_PROXYβ specify a proxy hostname. seeOSSL_HTTP_parse_url(3). π§QLOGDIRβ specifies a QUIC qlog output directory. seeopenssl-qlog(7).OSSL_QFILTERβ used to set a QUIC qlog filter specification. seeopenssl-qlog(7). πSSLKEYLOGFILEβ used to produce the standard format output file for SSL key logging. optionally set this variable to a filename to log all secrets produced by SSL connections. note: using this environment variable is predicated on configuring OpenSSL at build time with theenable-sslkeylogfeature. the file format standard lives at <https://datatracker.ietf.org/doc/draft-ietf-tls-keylogfile/>.
π¨ bestie, real talk: the use of SSLKEYLOGFILE poses an explicit security risk. by recording the exchanged keys during an SSL session, it allows any available party with read access to the file to decrypt application traffic sent over that session. use of this feature should be restricted to test and debug environments only. π
π COPYRIGHT π
Copyright 2019-2026 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>. πΈ
and that's the whole page, bestie β you ate that π«Άβ¨ this was OPENSSL-ENV(7ossl), version 3.5.9, dated 2026-09-29. go forth and configure responsibly, mwah π
π
π¦ where this page comes from
- alpine 3.23: openssl-doc 3.5.9-r0 Β· Apache-2.0
- alpine 3.24: openssl-doc 3.5.9-r0 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms