47 #define APR_WANT_STRFUNC
48 #define APR_WANT_MEMFUNC
65 #if APR_HAVE_SYS_TIME_H
81 #define BOOL unsigned int
87 #ifndef OPENSSL_API_COMPAT
88 #define OPENSSL_API_COMPAT 0x10101000
93 #include <openssl/err.h>
94 #include <openssl/x509.h>
95 #include <openssl/pem.h>
96 #include <openssl/crypto.h>
97 #include <openssl/evp.h>
98 #include <openssl/rand.h>
99 #include <openssl/x509v3.h>
100 #include <openssl/x509_vfy.h>
101 #include <openssl/ocsp.h>
102 #include <openssl/dh.h>
103 #if OPENSSL_VERSION_NUMBER >= 0x30000000
104 #include <openssl/core_names.h>
110 #if defined(HAVE_OPENSSL_ENGINE_H) && defined(HAVE_ENGINE_INIT) \
111 && (OPENSSL_VERSION_NUMBER < 0x30000000 \
112 || (defined(OPENSSL_API_LEVEL) && OPENSSL_API_LEVEL < 30000)) \
113 && !defined(OPENSSL_NO_ENGINE)
114 #include <openssl/engine.h>
115 #define MODSSL_HAVE_ENGINE_API 1
117 #ifndef MODSSL_HAVE_ENGINE_API
118 #define MODSSL_HAVE_ENGINE_API 0
124 #if OPENSSL_VERSION_NUMBER >= 0x30000000
125 #define MODSSL_HAVE_OPENSSL_STORE 1
127 #define MODSSL_HAVE_OPENSSL_STORE 0
130 #if (OPENSSL_VERSION_NUMBER < 0x0090801f)
131 #error mod_ssl requires OpenSSL 0.9.8a or later
140 #if (OPENSSL_VERSION_NUMBER >= 0x10000000)
141 #define MODSSL_SSL_CIPHER_CONST const
142 #define MODSSL_SSL_METHOD_CONST const
144 #define MODSSL_SSL_CIPHER_CONST
145 #define MODSSL_SSL_METHOD_CONST
148 #if defined(LIBRESSL_VERSION_NUMBER)
150 #if LIBRESSL_VERSION_NUMBER < 0x2060000f
151 #define SSL_CTRL_SET_MIN_PROTO_VERSION 123
152 #define SSL_CTRL_SET_MAX_PROTO_VERSION 124
153 #define SSL_CTX_set_min_proto_version(ctx, version) \
154 SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MIN_PROTO_VERSION, version, NULL)
155 #define SSL_CTX_set_max_proto_version(ctx, version) \
156 SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MAX_PROTO_VERSION, version, NULL)
162 #if LIBRESSL_VERSION_NUMBER < 0x2070000f
163 #define MODSSL_USE_OPENSSL_PRE_1_1_API 1
165 #define MODSSL_USE_OPENSSL_PRE_1_1_API 0
168 #if OPENSSL_VERSION_NUMBER < 0x10100000L
169 #define MODSSL_USE_OPENSSL_PRE_1_1_API 1
171 #define MODSSL_USE_OPENSSL_PRE_1_1_API 0
175 #if OPENSSL_VERSION_NUMBER < 0x10101000
176 #define MODSSL_USE_SSLRAND
179 #if defined(OPENSSL_FIPS) || OPENSSL_VERSION_NUMBER >= 0x30000000L
183 #if defined(SSL_OP_NO_TLSv1_2)
187 #if defined(SSL_CONF_FLAG_FILE)
188 #define HAVE_SSL_CONF_CMD
192 #if MODSSL_USE_OPENSSL_PRE_1_1_API
195 #define IDCONST const
202 #if !defined(OPENSSL_NO_TLSEXT) && defined(SSL_set_tlsext_host_name)
207 #if !defined(OPENSSL_NO_EC) && defined(TLSEXT_ECPOINTFORMAT_uncompressed)
212 #if !defined(OPENSSL_NO_OCSP) && defined(SSL_CTX_set_tlsext_status_cb)
213 #define HAVE_OCSP_STAPLING
215 #if OPENSSL_VERSION_NUMBER < 0x10100000L
217 #ifndef sk_OPENSSL_STRING_num
218 #define sk_OPENSSL_STRING_num sk_num
220 #ifndef sk_OPENSSL_STRING_value
221 #define sk_OPENSSL_STRING_value sk_value
223 #ifndef sk_OPENSSL_STRING_pop
224 #define sk_OPENSSL_STRING_pop sk_pop
230 #if defined(SSL_CTX_set_tlsext_ticket_key_cb)
231 #define HAVE_TLS_SESSION_TICKETS
232 #define TLSEXT_TICKET_KEY_LEN 48
233 #ifndef tlsext_tick_md
234 #ifdef OPENSSL_NO_SHA256
235 #define tlsext_tick_md EVP_sha1
237 #define tlsext_tick_md EVP_sha256
243 #if !defined(OPENSSL_NO_SRP) \
244 && (OPENSSL_VERSION_NUMBER < 0x30000000L \
245 || (defined(OPENSSL_API_LEVEL) && OPENSSL_API_LEVEL < 30000)) \
246 && defined(SSL_CTRL_SET_TLS_EXT_SRP_USERNAME_CB)
248 #include <openssl/srp.h>
252 #if defined(TLSEXT_TYPE_application_layer_protocol_negotiation)
253 #define HAVE_TLS_ALPN
258 #if MODSSL_USE_OPENSSL_PRE_1_1_API
259 #define BN_get_rfc2409_prime_768 get_rfc2409_prime_768
260 #define BN_get_rfc2409_prime_1024 get_rfc2409_prime_1024
261 #define BN_get_rfc3526_prime_1536 get_rfc3526_prime_1536
262 #define BN_get_rfc3526_prime_2048 get_rfc3526_prime_2048
263 #define BN_get_rfc3526_prime_3072 get_rfc3526_prime_3072
264 #define BN_get_rfc3526_prime_4096 get_rfc3526_prime_4096
265 #define BN_get_rfc3526_prime_6144 get_rfc3526_prime_6144
266 #define BN_get_rfc3526_prime_8192 get_rfc3526_prime_8192
267 #define BIO_set_init(x,v) (x->init=v)
268 #define BIO_get_data(x) (x->ptr)
269 #define BIO_set_data(x,v) (x->ptr=v)
270 #define BIO_get_shutdown(x) (x->shutdown)
271 #define BIO_set_shutdown(x,v) (x->shutdown=v)
272 #define DH_bits(x) (BN_num_bits(x->p))
273 #define X509_up_ref(x) (CRYPTO_add(&(x)->references, +1, CRYPTO_LOCK_X509))
274 #define EVP_PKEY_up_ref(pk) (CRYPTO_add(&(pk)->references, +1, CRYPTO_LOCK_EVP_PKEY))
276 void init_bio_methods(
void);
277 void free_bio_methods(
void);
280 #if OPENSSL_VERSION_NUMBER < 0x10002000L || \
281 (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2070000f)
282 #define X509_STORE_CTX_get0_store(x) (x->ctx)
285 #if OPENSSL_VERSION_NUMBER < 0x10000000L
286 #ifndef X509_STORE_CTX_get0_current_issuer
287 #define X509_STORE_CTX_get0_current_issuer(x) (x->current_issuer)
292 #ifndef X509_get_notBefore
293 #define X509_get_notBefore X509_getm_notBefore
295 #ifndef X509_get_notAfter
296 #define X509_get_notAfter X509_getm_notAfter
299 #if OPENSSL_VERSION_NUMBER >= 0x10101000L && !defined(LIBRESSL_VERSION_NUMBER)
300 #define HAVE_OPENSSL_KEYLOG
304 #if OPENSSL_VERSION_NUMBER >= 0x30000000L
305 #define modssl_fips_is_enabled() EVP_default_properties_is_fips_enabled(NULL)
306 #define modssl_fips_enable(to) EVP_default_properties_enable_fips(NULL, (to))
308 #define modssl_fips_is_enabled() FIPS_mode()
309 #define modssl_fips_enable(to) FIPS_mode_set((to))
329 #define RAND_MAX INT_MAX
336 #define UCHAR unsigned char
342 #define strEQ(s1,s2) (strcmp(s1,s2) == 0)
343 #define strNE(s1,s2) (strcmp(s1,s2) != 0)
344 #define strEQn(s1,s2,n) (strncmp(s1,s2,n) == 0)
345 #define strNEn(s1,s2,n) (strncmp(s1,s2,n) != 0)
347 #define strcEQ(s1,s2) (strcasecmp(s1,s2) == 0)
348 #define strcNE(s1,s2) (strcasecmp(s1,s2) != 0)
349 #define strcEQn(s1,s2,n) (strncasecmp(s1,s2,n) == 0)
350 #define strcNEn(s1,s2,n) (strncasecmp(s1,s2,n) != 0)
352 #define strIsEmpty(s) (s == NULL || s[0] == NUL)
354 #define myConnConfig(c) \
355 ((SSLConnRec *)ap_get_module_config(c->conn_config, &ssl_module))
356 #define myConnConfigSet(c, val) \
357 ap_set_module_config(c->conn_config, &ssl_module, val)
358 #define mySrvConfig(srv) \
359 ((SSLSrvConfigRec *)ap_get_module_config(srv->module_config, &ssl_module))
360 #define myDirConfig(req) \
361 ((SSLDirConfigRec *)ap_get_module_config(req->per_dir_config, &ssl_module))
362 #define myConnCtxConfig(c, sc) \
363 (c->outgoing ? myConnConfig(c)->dc->proxy : sc->server)
364 #define myModConfig(srv) mySrvConfig((srv))->mc
365 #define mySrvFromConn(c) myConnConfig(c)->server
366 #define myDirConfigFromConn(c) myConnConfig(c)->dc
367 #define mySrvConfigFromConn(c) mySrvConfig(mySrvFromConn(c))
368 #define myModConfigFromConn(c) myModConfig(mySrvFromConn(c))
373 #ifndef SSL_SESSION_CACHE_TIMEOUT
374 #define SSL_SESSION_CACHE_TIMEOUT 300
378 #ifndef DEFAULT_RENEG_BUFFER_SIZE
379 #define DEFAULT_RENEG_BUFFER_SIZE (128 * 1024)
383 #ifndef DEFAULT_OCSP_MAX_SKEW
384 #define DEFAULT_OCSP_MAX_SKEW (60 * 5)
388 #ifndef DEFAULT_OCSP_TIMEOUT
389 #define DEFAULT_OCSP_TIMEOUT 10
395 #define SSL_OPT_NONE (0)
396 #define SSL_OPT_RELSET (1<<0)
397 #define SSL_OPT_STDENVVARS (1<<1)
398 #define SSL_OPT_EXPORTCERTDATA (1<<3)
399 #define SSL_OPT_FAKEBASICAUTH (1<<4)
400 #define SSL_OPT_STRICTREQUIRE (1<<5)
401 #define SSL_OPT_OPTRENEGOTIATE (1<<6)
402 #define SSL_OPT_LEGACYDNFORMAT (1<<7)
403 #define SSL_OPT_EXPORTCB64DATA (1<<8)
409 #define SSL_PROTOCOL_NONE (0)
410 #ifndef OPENSSL_NO_SSL3
411 #define SSL_PROTOCOL_SSLV3 (1<<1)
413 #define SSL_PROTOCOL_TLSV1 (1<<2)
414 #ifndef OPENSSL_NO_SSL3
415 #define SSL_PROTOCOL_BASIC (SSL_PROTOCOL_SSLV3|SSL_PROTOCOL_TLSV1)
417 #define SSL_PROTOCOL_BASIC (SSL_PROTOCOL_TLSV1)
420 #define SSL_PROTOCOL_TLSV1_1 (1<<3)
421 #define SSL_PROTOCOL_TLSV1_2 (1<<4)
422 #define SSL_PROTOCOL_TLSV1_3 (1<<5)
424 #ifdef SSL_OP_NO_TLSv1_3
425 #define SSL_HAVE_PROTOCOL_TLSV1_3 (1)
426 #define SSL_PROTOCOL_ALL (SSL_PROTOCOL_BASIC| \
427 SSL_PROTOCOL_TLSV1_1|SSL_PROTOCOL_TLSV1_2|SSL_PROTOCOL_TLSV1_3)
429 #define SSL_HAVE_PROTOCOL_TLSV1_3 (0)
430 #define SSL_PROTOCOL_ALL (SSL_PROTOCOL_BASIC| \
431 SSL_PROTOCOL_TLSV1_1|SSL_PROTOCOL_TLSV1_2)
434 #define SSL_PROTOCOL_ALL (SSL_PROTOCOL_BASIC)
436 #ifndef OPENSSL_NO_SSL3
437 #define SSL_PROTOCOL_DEFAULT (SSL_PROTOCOL_ALL & ~SSL_PROTOCOL_SSLV3)
439 #define SSL_PROTOCOL_DEFAULT (SSL_PROTOCOL_ALL)
454 #define SSL_VERIFY_PEER_STRICT \
455 (SSL_VERIFY_PEER|SSL_VERIFY_FAIL_IF_NO_PEER_CERT)
457 #define ssl_verify_error_is_optional(errnum) \
458 ((errnum == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) \
459 || (errnum == X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN) \
460 || (errnum == X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY) \
461 || (errnum == X509_V_ERR_CERT_UNTRUSTED) \
462 || (errnum == X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE))
499 #define SSL_PCM_EXISTS 1
500 #define SSL_PCM_ISREG 2
501 #define SSL_PCM_ISDIR 4
502 #define SSL_PCM_ISNONZERO 8
590 NON_SSL_SET_ERROR_MSG
593 #ifndef SSL_OP_NO_RENEGOTIATION
619 #define MODSSL_RETAINED_KEY "mod_ssl-retained-1"
656 #ifdef MODSSL_USE_SSLRAND
661 #if defined(HAVE_OPENSSL_ENGINE_H) && defined(HAVE_ENGINE_INIT)
662 const char *szCryptoDevice;
665 #ifdef HAVE_OCSP_STAPLING
672 #ifdef HAVE_OPENSSL_KEYLOG
730 #ifdef HAVE_TLS_SESSION_TICKETS
732 const char *file_path;
733 unsigned char key_name[16];
734 #if OPENSSL_VERSION_NUMBER < 0x30000000L
735 unsigned char hmac_secret[16];
737 OSSL_PARAM mac_params[3];
739 unsigned char aes_key[16];
740 } modssl_ticket_key_t;
743 #ifdef HAVE_SSL_CONF_CMD
758 #ifdef HAVE_TLS_SESSION_TICKETS
759 modssl_ticket_key_t *ticket_key;
776 #ifdef HAVE_OCSP_STAPLING
778 BOOL stapling_enabled;
779 long stapling_resptime_skew;
780 long stapling_resp_maxage;
781 int stapling_cache_timeout;
782 BOOL stapling_return_errors;
783 BOOL stapling_fake_trylater;
784 int stapling_errcache_timeout;
786 const char *stapling_force_url;
791 char *srp_unknown_user_seed;
792 SRP_VBASE *srp_vbase;
813 #ifdef HAVE_SSL_CONF_CMD
814 SSL_CONF_CTX *ssl_ctx_config;
835 #ifndef OPENSSL_NO_COMP
927 #ifdef HAVE_TLS_SESSION_TICKETS
928 const char *ssl_cmd_SSLSessionTicketKeyFile(
cmd_parms *cmd,
void *dcfg,
const char *arg);
948 #ifdef HAVE_SSL_CONF_CMD
949 const char *ssl_cmd_SSLOpenSSLConfCmd(
cmd_parms *cmd,
void *dcfg,
const char *arg1,
const char *arg2);
953 const char *ssl_cmd_SSLSRPVerifierFile(
cmd_parms *cmd,
void *dcfg,
const char *arg);
954 const char *ssl_cmd_SSLSRPUnknownUserSeed(
cmd_parms *cmd,
void *dcfg,
const char *arg);
996 int ssl_callback_ServerNameIndication(SSL *,
int *,
modssl_ctx_t *);
998 #if OPENSSL_VERSION_NUMBER >= 0x10101000L && !defined(LIBRESSL_VERSION_NUMBER)
999 int ssl_callback_ClientHello(SSL *,
int *,
void *);
1001 #ifdef HAVE_TLS_SESSION_TICKETS
1002 int ssl_callback_SessionTicket(SSL *ssl,
1003 unsigned char *keyname,
1005 EVP_CIPHER_CTX *cipher_ctx,
1006 #
if OPENSSL_VERSION_NUMBER < 0x30000000L
1009 EVP_MAC_CTX *mac_ctx,
1014 #ifdef HAVE_TLS_ALPN
1015 int ssl_callback_alpn_select(SSL *ssl,
const unsigned char **out,
1016 unsigned char *outlen,
const unsigned char *in,
1017 unsigned int inlen,
void *arg);
1031 #ifdef HAVE_OCSP_STAPLING
1032 const char *ssl_cmd_SSLStaplingCache(
cmd_parms *,
void *,
const char *);
1033 const char *ssl_cmd_SSLUseStapling(
cmd_parms *,
void *,
int);
1034 const char *ssl_cmd_SSLStaplingResponseTimeSkew(
cmd_parms *,
void *,
const char *);
1035 const char *ssl_cmd_SSLStaplingResponseMaxAge(
cmd_parms *,
void *,
const char *);
1036 const char *ssl_cmd_SSLStaplingStandardCacheTimeout(
cmd_parms *,
void *,
const char *);
1037 const char *ssl_cmd_SSLStaplingErrorCacheTimeout(
cmd_parms *,
void *,
const char *);
1038 const char *ssl_cmd_SSLStaplingReturnResponderErrors(
cmd_parms *,
void *,
int);
1039 const char *ssl_cmd_SSLStaplingFakeTryLater(
cmd_parms *,
void *,
int);
1040 const char *ssl_cmd_SSLStaplingResponderTimeout(
cmd_parms *,
void *,
const char *);
1041 const char *ssl_cmd_SSLStaplingForceURL(
cmd_parms *,
void *,
const char *);
1043 void ssl_stapling_certinfo_hash_init(
apr_pool_t *);
1048 int ssl_callback_SRPServerParams(SSL *,
int *,
void *);
1051 #ifdef HAVE_OPENSSL_KEYLOG
1053 void modssl_callback_keylog(
const SSL *ssl,
const char *line);
1065 #ifdef MODSSL_USE_SSLRAND
1069 #define ssl_rand_seed(s, p, ctx, c)
1075 const char *
const *);
1078 const char *
const *);
1080 #if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API
1096 const char *vhostid,
1097 const char *certid,
const char *keyid,
1098 X509 **pubkey, EVP_PKEY **privkey);
1101 #if OPENSSL_VERSION_NUMBER < 0x30000000L
1104 EVP_PKEY *modssl_dh_pkey_from_file(
const char *);
1107 EC_GROUP *modssl_ec_group_from_file(
const char *);
1126 #define SSL_CACHE_MUTEX_TYPE "ssl-cache"
1127 #define SSL_STAPLING_CACHE_MUTEX_TYPE "ssl-stapling"
1128 #define SSL_STAPLING_REFRESH_MUTEX_TYPE "ssl-stapling-refresh"
1142 X509 *cert,
const char *format, ...)
1147 const
char *format, ...)
1152 const
char *format, ...)
1155 #define SSLLOG_MARK __FILE__,__LINE__
1178 #ifndef OPENSSL_NO_OCSP
1199 #if MODSSL_USE_OPENSSL_PRE_1_1_API
1216 extern int ssl_running_on_valgrind;
1220 X509 **pcert, EVP_PKEY **pkey,
1221 const char **pcert_file,
const char **pkey_file);
Symbol export macros and hook functions.
Small object cache provider interface.
APR Platform Definitions.
APR Global Locking Routines.
APR general purpose library routines.
APR-UTIL registration of functions exported by modules.
APR Standard Headers Support.
struct ap_conf_vector_t ap_conf_vector_t
Definition: http_config.h:512
struct ap_socache_instance_t ap_socache_instance_t
Definition: ap_socache.h:49
request_rec * r
Definition: mod_dav.h:518
const char * s
Definition: mod_dav.h:1327
apr_bucket_brigade ap_input_mode_t mode
Definition: mod_dav.h:2662
const dav_resource dav_lockdb dav_lock * request
Definition: mod_dav.h:1441
apr_bucket_brigade request_rec apr_pool_t * pool
Definition: mod_dav.h:557
const char const char * uri
Definition: mod_dav.h:631
const char * name
Definition: mod_dav.h:805
modssl_reneg_state
Definition: ssl_private.h:552
const char * ssl_cmd_SSLProxyVerify(cmd_parms *, void *, const char *)
const authz_provider ssl_authz_provider_require_ssl
const char * ssl_cmd_SSLProxyCARevocationFile(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLCADNRequestPath(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLSessionCacheTimeout(cmd_parms *, void *, const char *)
int ssl_callback_NewSessionCacheEntry(SSL *, SSL_SESSION *)
apr_status_t modssl_load_engine_keypair(server_rec *s, apr_pool_t *p, const char *vhostid, const char *certid, const char *keyid, X509 **pubkey, EVP_PKEY **privkey)
const char * ssl_cmd_SSLProxyMachineCertificateChainFile(cmd_parms *, void *, const char *)
apr_status_t ssl_die(server_rec *)
int modssl_request_is_tls(const request_rec *r, SSLConnRec **sslconn)
void ssl_scache_kill(server_rec *)
int modssl_is_engine_id(const char *name)
const char * ssl_cmd_SSLCARevocationCheck(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLEngine(cmd_parms *, void *, const char *)
void ssl_log_xerror(const char *file, int line, int level, apr_status_t rv, apr_pool_t *p, server_rec *s, X509 *cert, const char *format,...) __attribute__((format(printf
apr_status_t ssl_init_CheckServers(server_rec *, apr_pool_t *)
const char * ssl_cmd_SSLProxyCheckPeerName(cmd_parms *cmd, void *dcfg, int flag)
const char * ssl_cmd_SSLCARevocationPath(cmd_parms *, void *, const char *)
module AP_MODULE_DECLARE_DATA ssl_module
const char * ssl_cmd_SSLOCSPOverrideResponder(cmd_parms *cmd, void *dcfg, int flag)
apr_array_header_t * ssl_ext_list(apr_pool_t *p, conn_rec *c, int peer, const char *extension)
const char * ssl_var_lookup(apr_pool_t *p, server_rec *s, conn_rec *c, request_rec *r, const char *name) AP_FN_ATTR_NONNULL((1
ssl_ocspcheck_t
Definition: ssl_private.h:479
const char * ssl_cmd_SSLCertificateChainFile(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLFIPS(cmd_parms *cmd, void *dcfg, int flag)
int ssl_hook_Fixup(request_rec *)
DH * modssl_dh_from_file(const char *)
ssl_enabled_t
Definition: ssl_private.h:508
const char * ssl_cmd_SSLVerifyClient(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLProxyEngine(cmd_parms *cmd, void *dcfg, int flag)
const char * ssl_cmd_SSLOCSPResponseTimeSkew(cmd_parms *cmd, void *dcfg, const char *arg)
SSLSrvConfigRec * ssl_policy_lookup(apr_pool_t *pool, const char *name)
const char * ssl_cmd_SSLCADNRequestFile(cmd_parms *, void *, const char *)
DH * ssl_callback_TmpDH(SSL *, int, int)
BOOL ssl_scache_store(server_rec *, IDCONST UCHAR *, int, apr_time_t, SSL_SESSION *, apr_pool_t *)
int ssl_hook_Auth(request_rec *)
const char * ssl_cmd_SSLOCSPDefaultResponder(cmd_parms *cmd, void *dcfg, const char *arg)
const char * ssl_cmd_SSLProxyCACertificateFile(cmd_parms *, void *, const char *)
ssl_rsctx_t
Definition: ssl_private.h:526
const char * ssl_cmd_SSLRenegBufferSize(cmd_parms *cmd, void *dcfg, const char *arg)
const char * ssl_cmd_SSLSessionTickets(cmd_parms *, void *, int flag)
* ssl_init_FindCAList(server_rec *, apr_pool_t *, const char *, const char *)
const char * ssl_cmd_SSLProtocol(cmd_parms *, void *, const char *)
int ssl_init_ssl_connection(conn_rec *c, request_rec *r)
const char * ssl_cmd_SSLCARevocationFile(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLInsecureRenegotiation(cmd_parms *cmd, void *dcfg, int flag)
char * ssl_util_vhostid(apr_pool_t *, server_rec *)
const char * ssl_cmd_SSLProxyCACertificatePath(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLPassPhraseDialog(cmd_parms *, void *, const char *)
const char AP_FN_ATTR_WARN_UNUSED_RESULT
Definition: ssl_private.h:1167
SSL_SESSION * ssl_callback_GetSessionCacheEntry(SSL *, IDCONST unsigned char *, int, int *)
apr_status_t ssl_init_Module(apr_pool_t *, apr_pool_t *, apr_pool_t *, server_rec *)
int ssl_proto_t
Definition: ssl_private.h:441
apr_status_t ssl_scache_init(server_rec *, apr_pool_t *)
ssl_asn1_t * ssl_asn1_table_get(apr_hash_t *table, const char *key)
int ssl_callback_SSLVerify_CRL(int, X509_STORE_CTX *, conn_rec *)
const char * ssl_cmd_SSLHonorCipherOrder(cmd_parms *cmd, void *dcfg, int flag)
ssl_verify_t
Definition: ssl_private.h:446
int modssl_verify_ocsp(X509_STORE_CTX *ctx, SSLSrvConfigRec *sc, server_rec *s, conn_rec *c, apr_pool_t *pool)
const char * ssl_cmd_SSLProxyCARevocationPath(cmd_parms *, void *, const char *)
ssl_crlcheck_t
Definition: ssl_private.h:467
apr_status_t ssl_load_encrypted_pkey(server_rec *, apr_pool_t *, int, const char *, apr_array_header_t **)
const char * ssl_cmd_SSLOCSPResponderTimeout(cmd_parms *cmd, void *dcfg, const char *arg)
apr_status_t ssl_init_ModuleKill(void *data)
void ssl_scache_remove(server_rec *, IDCONST UCHAR *, int, apr_pool_t *)
const char * ssl_cmd_SSLProxyMachineCertificatePath(cmd_parms *, void *, const char *)
void ssl_util_thread_id_setup(apr_pool_t *)
void * ssl_config_server_create(apr_pool_t *, server_rec *)
char * ssl_util_readfilter(server_rec *, apr_pool_t *, const char *, const char *const *)
BOOL ssl_util_vhost_matches(const char *servername, server_rec *s)
const char * ssl_cmd_SSLStrictSNIVHostCheck(cmd_parms *cmd, void *dcfg, int flag)
void * ssl_config_perdir_merge(apr_pool_t *, void *, void *)
const char * ssl_cmd_SSLUserName(cmd_parms *, void *, const char *)
void void ssl_log_cxerror(const char *file, int line, int level, apr_status_t rv, conn_rec *c, X509 *cert, const char *format,...) __attribute__((format(printf
void modssl_set_reneg_state(SSLConnRec *sslconn, modssl_reneg_state state)
void ssl_io_filter_register(apr_pool_t *)
const char * ssl_cmd_SSLVerifyDepth(cmd_parms *, void *, const char *)
#define IDCONST
Definition: ssl_private.h:193
BOOL ssl_config_global_isfixed(SSLModConfigRec *)
DH * modssl_get_dh_params(unsigned keylen)
int ssl_proxy_section_post_config(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *s, ap_conf_vector_t *section_config)
const char * ssl_cmd_SSLOCSPEnable(cmd_parms *cmd, void *dcfg, const char *arg)
void ssl_config_proxy_merge(apr_pool_t *, SSLDirConfigRec *, SSLDirConfigRec *)
void ssl_scache_status_register(apr_pool_t *p)
const char * ssl_cmd_SSLProxyMachineCertificateFile(cmd_parms *, void *, const char *)
SSL_SESSION * ssl_scache_retrieve(server_rec *, IDCONST UCHAR *, int, apr_pool_t *)
const char * ssl_cmd_SSLCACertificatePath(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLProxyCARevocationCheck(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLProxyProtocol(cmd_parms *, void *, const char *)
apr_status_t ssl_io_filter_init(conn_rec *, request_rec *r, SSL *)
const char * ssl_cmd_SSLCompression(cmd_parms *, void *, int flag)
int ssl_opt_t
Definition: ssl_private.h:404
ssl_rssrc_t
Definition: ssl_private.h:530
int ssl_mutex_off(server_rec *)
int ssl_hook_Upgrade(request_rec *)
const char * ssl_cmd_SSLRequire(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLRandomSeed(cmd_parms *, void *, const char *, const char *, const char *)
#define UCHAR
Definition: ssl_private.h:336
void ssl_log_ssl_error(const char *, int, int, server_rec *)
unsigned int ssl_pathcheck_t
Definition: ssl_private.h:503
const char * ssl_cmd_SSLCryptoDevice(cmd_parms *, void *, const char *)
int ssl_is_challenge(conn_rec *c, const char *servername, X509 **pcert, EVP_PKEY **pkey, const char **pcert_file, const char **pkey_file)
BOOL ssl_util_path_check(ssl_pathcheck_t, const char *, apr_pool_t *)
const char * ssl_cmd_SSLOCSPResponseMaxAge(cmd_parms *cmd, void *dcfg, const char *arg)
const char * ssl_cmd_SSLOCSPResponderCertificateFile(cmd_parms *cmd, void *dcfg, const char *arg)
const char * ssl_cmd_SSLCACertificateFile(cmd_parms *, void *, const char *)
int ssl_stapling_mutex_reinit(server_rec *, apr_pool_t *)
void ssl_callback_Info(const SSL *, int, int)
void ssl_rand_seed(server_rec *, apr_pool_t *, ssl_rsctx_t, char *)
#define UNSET
Definition: ssl_private.h:322
const char * ssl_cmd_SSLCipherSuite(cmd_parms *, void *, const char *, const char *)
void modssl_set_io_callbacks(SSL *ssl)
const char * ssl_cmd_SSLOCSPNoVerify(cmd_parms *cmd, void *dcfg, int flag)
const char * ssl_cmd_SSLRequireSSL(cmd_parms *, void *)
const char * ssl_cmd_SSLSessionCache(cmd_parms *, void *, const char *)
int ssl_hook_ReadReq(request_rec *)
void void void ssl_log_rxerror(const char *file, int line, int level, apr_status_t rv, request_rec *r, X509 *cert, const char *format,...) __attribute__((format(printf
void ssl_callback_DelSessionCacheEntry(SSL_CTX *, SSL_SESSION *)
apr_status_t ssl_init_Engine(server_rec *, apr_pool_t *)
const char * ssl_cmd_SSLOCSPUseRequestNonce(cmd_parms *cmd, void *dcfg, int flag)
void * ssl_config_perdir_create(apr_pool_t *, char *)
const authz_provider ssl_authz_provider_verify_client
void ssl_util_thread_setup(apr_pool_t *)
const char * ssl_cmd_SSLCertificateKeyFile(cmd_parms *, void *, const char *)
const char * ssl_cmd_SSLProxyCheckPeerExpire(cmd_parms *cmd, void *dcfg, int flag)
apr_status_t ssl_init_ConfigureServer(server_rec *, apr_pool_t *, apr_pool_t *, SSLSrvConfigRec *, apr_array_header_t *)
int ssl_hook_UserCheck(request_rec *)
int ssl_hook_Access(request_rec *)
const char * ssl_cmd_SSLCertificateFile(cmd_parms *, void *, const char *)
ssl_pphrase_t
Definition: ssl_private.h:489
const char * ssl_cmd_SSLOptions(cmd_parms *, void *, const char *)
int ssl_mutex_init(server_rec *, apr_pool_t *)
void modssl_var_extract_dns(apr_table_t *t, SSL *ssl, apr_pool_t *p)
const char * ssl_cmd_SSLProxyCheckPeerCN(cmd_parms *cmd, void *dcfg, int flag)
void ssl_init_Child(apr_pool_t *, server_rec *)
#define BOOL
Definition: ssl_private.h:81
int ssl_io_buffer_fill(request_rec *r, apr_size_t maxlen)
void * ssl_config_server_merge(apr_pool_t *, void *, void *)
apr_file_t * ssl_util_ppopen(server_rec *, apr_pool_t *, const char *, const char *const *)
const char * ssl_cmd_SSLProxyVerifyDepth(cmd_parms *, void *, const char *)
int ssl_mutex_reinit(server_rec *, apr_pool_t *)
const char * ssl_cmd_SSLPolicyApply(cmd_parms *, void *, const char *)
int ssl_callback_proxy_cert(SSL *ssl, X509 **x509, EVP_PKEY **pkey)
int ssl_mutex_on(server_rec *)
ssl_shutdown_type_e
Definition: ssl_private.h:570
ssl_asn1_t * ssl_asn1_table_set(apr_hash_t *table, const char *key, EVP_PKEY *pkey)
const char * ssl_cmd_SSLProxyCipherSuite(cmd_parms *, void *, const char *, const char *)
void ssl_var_register(apr_pool_t *p)
const char * ssl_cmd_SSLOCSPProxyURL(cmd_parms *cmd, void *dcfg, const char *arg)
void ssl_init_ocsp_certificates(server_rec *s, modssl_ctx_t *mctx)
void ssl_hook_ConfigTest(apr_pool_t *pconf, server_rec *s)
void modssl_var_extract_san_entries(apr_table_t *t, SSL *ssl, apr_pool_t *p)
void ssl_config_global_fix(SSLModConfigRec *)
OCSP_RESPONSE * modssl_dispatch_ocsp_request(const apr_uri_t *uri, apr_interval_time_t timeout, OCSP_REQUEST *request, conn_rec *c, apr_pool_t *p)
void ssl_util_ppclose(server_rec *, apr_pool_t *, apr_file_t *)
int ssl_callback_SSLVerify(int, X509_STORE_CTX *)
@ RENEG_INIT
Definition: ssl_private.h:553
@ RENEG_ALLOW
Definition: ssl_private.h:556
@ RENEG_ABORT
Definition: ssl_private.h:558
@ RENEG_REJECT
Definition: ssl_private.h:554
@ SSL_OCSPCHECK_CHAIN
Definition: ssl_private.h:482
@ SSL_OCSPCHECK_LEAF
Definition: ssl_private.h:481
@ SSL_OCSPCHECK_NONE
Definition: ssl_private.h:480
@ SSL_OCSPCHECK_NO_OCSP_FOR_CERT_OK
Definition: ssl_private.h:483
@ SSL_ENABLED_TRUE
Definition: ssl_private.h:511
@ SSL_ENABLED_UNSET
Definition: ssl_private.h:509
@ SSL_ENABLED_FALSE
Definition: ssl_private.h:510
@ SSL_ENABLED_OPTIONAL
Definition: ssl_private.h:512
@ SSL_RSCTX_CONNECT
Definition: ssl_private.h:528
@ SSL_RSCTX_STARTUP
Definition: ssl_private.h:527
@ SSL_CVERIFY_OPTIONAL
Definition: ssl_private.h:449
@ SSL_CVERIFY_OPTIONAL_NO_CA
Definition: ssl_private.h:451
@ SSL_CVERIFY_UNSET
Definition: ssl_private.h:447
@ SSL_CVERIFY_NONE
Definition: ssl_private.h:448
@ SSL_CVERIFY_REQUIRE
Definition: ssl_private.h:450
@ SSL_CRLCHECK_NO_CRL_FOR_CERT_OK
Definition: ssl_private.h:473
@ SSL_CRLCHECK_LEAF
Definition: ssl_private.h:469
@ SSL_CRLCHECK_NONE
Definition: ssl_private.h:468
@ SSL_CRLCHECK_CHAIN
Definition: ssl_private.h:470
@ SSL_RSSRC_EGD
Definition: ssl_private.h:534
@ SSL_RSSRC_BUILTIN
Definition: ssl_private.h:531
@ SSL_RSSRC_FILE
Definition: ssl_private.h:532
@ SSL_RSSRC_EXEC
Definition: ssl_private.h:533
@ SSL_PPTYPE_PIPE
Definition: ssl_private.h:493
@ SSL_PPTYPE_BUILTIN
Definition: ssl_private.h:491
@ SSL_PPTYPE_FILTER
Definition: ssl_private.h:492
@ SSL_PPTYPE_UNSET
Definition: ssl_private.h:490
@ SSL_SHUTDOWN_TYPE_STANDARD
Definition: ssl_private.h:572
@ SSL_SHUTDOWN_TYPE_UNCLEAN
Definition: ssl_private.h:573
@ SSL_SHUTDOWN_TYPE_ACCURATE
Definition: ssl_private.h:574
@ SSL_SHUTDOWN_TYPE_UNSET
Definition: ssl_private.h:571
AP_FN_ATTR_NONNULL((1, 2, 5)) AP_FN_ATTR_WARN_UNUSED_RESULT
int apr_status_t
Definition: apr_errno.h:44
struct apr_hash_t apr_hash_t
Definition: apr_hash.h:52
struct apr_pool_t apr_pool_t
Definition: apr_pools.h:60
struct apr_table_t apr_table_t
Definition: apr_tables.h:56
apr_int64_t apr_interval_time_t
Definition: apr_time.h:55
apr_int64_t apr_time_t
Definition: apr_time.h:45
Apache connection library.
#define STACK_OF(x)
Definition: macros.h:26
#define AP_MODULE_DECLARE_DATA
Definition: macros.h:16
Authentication and Authorization Extension for Apache.
Interface to OpenSSL-specific APIs provided by mod_ssl.
#define SSL_CRLCHECK_FLAGS
Definition: ssl_private.h:472
Additional Utility Functions for OpenSSL.
Definition: ssl_private.h:577
int service_unavailable
Definition: ssl_private.h:605
modssl_reneg_state reneg_state
Definition: ssl_private.h:598
const char * verify_error
Definition: ssl_private.h:583
const char * verify_info
Definition: ssl_private.h:582
const char * client_dn
Definition: ssl_private.h:579
int disabled
Definition: ssl_private.h:585
@ NON_SSL_SEND_REQLINE
Definition: ssl_private.h:588
@ NON_SSL_SEND_HDR_SEP
Definition: ssl_private.h:589
ssl_shutdown_type_e shutdown_type
Definition: ssl_private.h:581
int verify_depth
Definition: ssl_private.h:584
SSLDirConfigRec * dc
Definition: ssl_private.h:602
X509 * client_cert
Definition: ssl_private.h:580
int vhost_found
Definition: ssl_private.h:606
server_rec * server
Definition: ssl_private.h:601
SSL * ssl
Definition: ssl_private.h:578
const char * cipher_suite
Definition: ssl_private.h:604
Definition: ssl_private.h:847
BOOL bSSLRequired
Definition: ssl_private.h:848
ssl_verify_t nVerifyClient
Definition: ssl_private.h:854
ssl_opt_t nOptionsAdd
Definition: ssl_private.h:851
const char * szCipherSuite
Definition: ssl_private.h:853
ssl_opt_t nOptions
Definition: ssl_private.h:850
apr_size_t nRenegBufferSize
Definition: ssl_private.h:857
int nVerifyDepth
Definition: ssl_private.h:855
BOOL proxy_enabled
Definition: ssl_private.h:860
BOOL proxy_post_config
Definition: ssl_private.h:861
apr_array_header_t * aRequirement
Definition: ssl_private.h:849
ssl_opt_t nOptionsDel
Definition: ssl_private.h:852
modssl_ctx_t * proxy
Definition: ssl_private.h:859
const char * szUserName
Definition: ssl_private.h:856
Definition: ssl_private.h:640
apr_array_header_t * aRandSeed
Definition: ssl_private.h:658
pid_t pid
Definition: ssl_private.h:657
ap_socache_instance_t * sesscache_context
Definition: ssl_private.h:652
apr_global_mutex_t * pMutex
Definition: ssl_private.h:654
BOOL bFixed
Definition: ssl_private.h:641
modssl_retained_data_t * retained
Definition: ssl_private.h:647
long sesscache_mode
Definition: ssl_private.h:644
const ap_socache_provider_t * sesscache
Definition: ssl_private.h:651
Definition: ssl_private.h:823
const char * vhost_id
Definition: ssl_private.h:826
BOOL insecure_reneg
Definition: ssl_private.h:830
const unsigned char * vhost_md5
Definition: ssl_private.h:827
SSLModConfigRec * mc
Definition: ssl_private.h:824
modssl_ctx_t * server
Definition: ssl_private.h:831
ssl_enabled_t enabled
Definition: ssl_private.h:825
BOOL cipher_server_pref
Definition: ssl_private.h:829
BOOL session_tickets
Definition: ssl_private.h:838
BOOL compression
Definition: ssl_private.h:836
int session_cache_timeout
Definition: ssl_private.h:828
Definition: ap_socache.h:89
Definition: apr_arch_file_io.h:107
Definition: apr_arch_global_mutex.h:23
Definition: mod_auth.h:141
Definition: http_config.h:288
Structure to store things which are per connection.
Definition: httpd.h:1193
Definition: ssl_private.h:713
ssl_verify_t verify_mode
Definition: ssl_private.h:722
const char * cipher_suite
Definition: ssl_private.h:718
const char * ca_cert_file
Definition: ssl_private.h:716
int verify_depth
Definition: ssl_private.h:721
const char * ca_cert_path
Definition: ssl_private.h:715
const char * tls13_ciphers
Definition: ssl_private.h:727
Definition: ssl_private.h:750
long ocsp_resp_maxage
Definition: ssl_private.h:802
int crl_check_mask
Definition: ssl_private.h:774
ssl_pphrase_t pphrase_dialog_type
Definition: ssl_private.h:766
BOOL ocsp_force_default
Definition: ssl_private.h:798
const char * ocsp_responder
Definition: ssl_private.h:800
int ocsp_mask
Definition: ssl_private.h:797
ssl_proto_t protocol
Definition: ssl_private.h:762
SSLSrvConfigRec * sc
Definition: ssl_private.h:751
modssl_auth_ctx_t auth
Definition: ssl_private.h:795
SSL_CTX * ssl_ctx
Definition: ssl_private.h:752
long ocsp_resptime_skew
Definition: ssl_private.h:801
BOOL ssl_check_peer_name
Definition: ssl_private.h:819
int protocol_set
Definition: ssl_private.h:763
const char * crl_path
Definition: ssl_private.h:772
STACK_OF(X509) *ocsp_certs
BOOL ssl_check_peer_cn
Definition: ssl_private.h:818
int ocsp_verify_flags
Definition: ssl_private.h:809
BOOL ocsp_use_request_nonce
Definition: ssl_private.h:804
const char * pphrase_dialog_path
Definition: ssl_private.h:767
BOOL ocsp_noverify
Definition: ssl_private.h:807
const char * ocsp_certs_file
Definition: ssl_private.h:810
modssl_pk_proxy_t * pkp
Definition: ssl_private.h:756
modssl_pk_server_t * pks
Definition: ssl_private.h:755
BOOL ssl_check_peer_expire
Definition: ssl_private.h:820
const char * crl_file
Definition: ssl_private.h:773
const char * cert_chain
Definition: ssl_private.h:769
apr_interval_time_t ocsp_responder_timeout
Definition: ssl_private.h:803
apr_uri_t * proxy_uri
Definition: ssl_private.h:805
Definition: ssl_private.h:698
const char * cert_file
Definition: ssl_private.h:700
const char * ca_cert_file
Definition: ssl_private.h:702
STACK_OF(X509_INFO) *certs
const char * cert_path
Definition: ssl_private.h:701
STACK_OF(X509) **ca_certs
Definition: ssl_private.h:684
apr_array_header_t * key_files
Definition: ssl_private.h:687
apr_array_header_t * cert_files
Definition: ssl_private.h:686
int service_unavailable
Definition: ssl_private.h:695
const char * ca_name_path
Definition: ssl_private.h:691
const char * ca_name_file
Definition: ssl_private.h:692
Definition: ssl_private.h:621
apr_hash_t * key_ids
Definition: ssl_private.h:629
apr_hash_t * privkeys
Definition: ssl_private.h:635
Definition: http_config.h:348
A structure that represents the current request.
Definition: httpd.h:856
A structure to store information for each virtual server.
Definition: httpd.h:1382
Definition: ssl_private.h:546
apr_time_t source_mtime
Definition: ssl_private.h:549
long int nData
Definition: ssl_private.h:547
unsigned char * cpData
Definition: ssl_private.h:548
Definition: ssl_private.h:536
char * cpPath
Definition: ssl_private.h:539
int nBytes
Definition: ssl_private.h:540
ssl_rssrc_t nSrc
Definition: ssl_private.h:538
ssl_rsctx_t nCtx
Definition: ssl_private.h:537
Definition: ssl_private.h:518
const char * cpExpr
Definition: ssl_private.h:519
ap_expr_info_t * mpExpr
Definition: ssl_private.h:520
Utilities for EBCDIC conversion.
Apache Mutex support library.