From fe39ffb8b90ae4e002ed73fe98617cd590abb467 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 27 Apr 2024 08:33:50 +0200 Subject: Adding upstream version 2.4.56. Signed-off-by: Daniel Baumann --- modules/tls/tls_cache.h | 63 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 modules/tls/tls_cache.h (limited to 'modules/tls/tls_cache.h') diff --git a/modules/tls/tls_cache.h b/modules/tls/tls_cache.h new file mode 100644 index 0000000..64ca077 --- /dev/null +++ b/modules/tls/tls_cache.h @@ -0,0 +1,63 @@ +/* Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +#ifndef tls_cache_h +#define tls_cache_h + +/* name of the global session cache mutex, should we need it */ +#define TLS_SESSION_CACHE_MUTEX_TYPE "tls-session-cache" + + +/** + * Set the specification of the session cache to use. The syntax is + * "default|none|(:)?" + * + * @param spec the cache specification + * @param gconf the modules global configuration + * @param p pool for permanent allocations + * @param ptemp pool for temporary allocations + * @return NULL on success or an error message + */ +const char *tls_cache_set_specification( + const char *spec, tls_conf_global_t *gconf, apr_pool_t *p, apr_pool_t *ptemp); + +/** + * Setup before configuration runs, announces our potential global mutex. + */ +void tls_cache_pre_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp); + +/** + * Verify the cache settings at the end of the configuration and + * create the default session cache, if not already done. + */ +apr_status_t tls_cache_post_config(apr_pool_t *p, apr_pool_t *ptemp, server_rec *s); + +/** + * Started a new child, make sure that global mutex we might use is set up. + */ +void tls_cache_init_child(apr_pool_t *p, server_rec *s); + +/** + * Free all cache related resources. + */ +void tls_cache_free(server_rec *s); + +/** + * Initialize the session store for the server's config builder. + */ +apr_status_t tls_cache_init_server( + rustls_server_config_builder *builder, server_rec *s); + +#endif /* tls_cache_h */ \ No newline at end of file -- cgit v1.2.3