RTS API Documentation
1.10.11
|
Go to the source code of this file.
Functions | |
static void | switch_ssl_ssl_lock_callback (int mode, int type, char *file, int line) |
static void | switch_ssl_ssl_thread_id (CRYPTO_THREADID *id) |
void | switch_ssl_init_ssl_locks (void) |
void | switch_ssl_destroy_ssl_locks (void) |
static const EVP_MD * | get_evp_by_name (const char *name) |
int | switch_core_cert_verify (dtls_fingerprint_t *fp) |
int | switch_core_cert_expand_fingerprint (dtls_fingerprint_t *fp, const char *str) |
int | switch_core_cert_extract_fingerprint (X509 *x509, dtls_fingerprint_t *fp) |
int | switch_core_cert_gen_fingerprint (const char *prefix, dtls_fingerprint_t *fp) |
static int | mkcert (X509 **x509p, EVP_PKEY **pkeyp, int bits, int serial, int days) |
int | switch_core_gen_certs (const char *prefix) |
switch_bool_t | switch_core_check_dtls_pem (const char *file) |
Variables | |
static switch_mutex_t ** | ssl_mutexes |
static switch_memory_pool_t * | ssl_pool = NULL |
static int | ssl_count = 0 |
|
static |
Definition at line 106 of file switch_core_cert.c.
Referenced by switch_core_cert_extract_fingerprint().
|
static |
Definition at line 412 of file switch_core_cert.c.
References name, and switch_assert.
Referenced by switch_core_cert_gen_fingerprint(), and switch_core_gen_certs().
int switch_core_cert_expand_fingerprint | ( | dtls_fingerprint_t * | fp, |
const char * | str | ||
) |
Definition at line 162 of file switch_core_cert.c.
References dtls_fp_s::data, and MAX_FPLEN.
Referenced by switch_rtp_add_dtls().
int switch_core_cert_extract_fingerprint | ( | X509 * | x509, |
dtls_fingerprint_t * | fp | ||
) |
Definition at line 178 of file switch_core_cert.c.
References dtls_fp_s::data, get_evp_by_name(), dtls_fp_s::len, dtls_fp_s::str, SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, switch_log_printf(), and dtls_fp_s::type.
Referenced by do_dtls(), dtls_state_setup(), and switch_core_cert_gen_fingerprint().
int switch_core_cert_gen_fingerprint | ( | const char * | prefix, |
dtls_fingerprint_t * | fp | ||
) |
Definition at line 199 of file switch_core_cert.c.
References switch_directories::certs_dir, mkcert(), SWITCH_CHANNEL_LOG, switch_core_cert_extract_fingerprint(), switch_file_exists(), SWITCH_GLOBAL_dirs, SWITCH_LOG_ERROR, switch_log_printf(), switch_mprintf(), SWITCH_PATH_SEPARATOR, and SWITCH_STATUS_SUCCESS.
Referenced by generate_local_fingerprint().
int switch_core_cert_verify | ( | dtls_fingerprint_t * | fp | ) |
Definition at line 143 of file switch_core_cert.c.
References dtls_fp_s::data, MAX_FPLEN, and dtls_fp_s::str.
Referenced by do_dtls(), and dtls_state_setup().
switch_bool_t switch_core_check_dtls_pem | ( | const char * | file | ) |
Definition at line 338 of file switch_core_cert.c.
References switch_directories::certs_dir, SWITCH_CHANNEL_LOG, SWITCH_FALSE, switch_file_exists(), SWITCH_GLOBAL_dirs, switch_is_file_path(), SWITCH_LOG_DEBUG, SWITCH_LOG_ERROR, switch_log_printf(), SWITCH_LOG_WARNING, switch_mprintf(), SWITCH_PATH_SEPARATOR, switch_safe_free, SWITCH_STATUS_SUCCESS, and SWITCH_TRUE.
Referenced by switch_core_media_init().
int switch_core_gen_certs | ( | const char * | prefix | ) |
Definition at line 250 of file switch_core_cert.c.
References switch_directories::certs_dir, mkcert(), SWITCH_CHANNEL_LOG, switch_file_exists(), SWITCH_GLOBAL_dirs, switch_is_file_path(), SWITCH_LOG_ERROR, switch_log_printf(), switch_mprintf(), SWITCH_PATH_SEPARATOR, switch_safe_free, SWITCH_STATUS_SUCCESS, and switch_stristr().
Referenced by load_config(), and switch_core_media_init().
void switch_ssl_destroy_ssl_locks | ( | void | ) |
Definition at line 85 of file switch_core_cert.c.
References ssl_count, ssl_mutexes, ssl_pool, switch_core_destroy_memory_pool, and switch_mutex_destroy().
Referenced by switch_core_cert_extract_fingerprint(), and switch_core_destroy().
void switch_ssl_init_ssl_locks | ( | void | ) |
Definition at line 58 of file switch_core_cert.c.
References ssl_count, ssl_mutexes, ssl_pool, switch_assert, switch_core_new_memory_pool, switch_mutex_init(), SWITCH_MUTEX_NESTED, switch_ssl_ssl_lock_callback(), and switch_ssl_ssl_thread_id().
Referenced by switch_core_cert_extract_fingerprint(), and switch_core_init().
|
inlinestatic |
Definition at line 41 of file switch_core_cert.c.
References ssl_mutexes, switch_mutex_lock(), and switch_mutex_unlock().
Referenced by switch_ssl_init_ssl_locks().
|
inlinestatic |
Definition at line 51 of file switch_core_cert.c.
References switch_thread_self().
Referenced by switch_ssl_init_ssl_locks().
|
static |
Definition at line 37 of file switch_core_cert.c.
Referenced by switch_ssl_destroy_ssl_locks(), and switch_ssl_init_ssl_locks().
|
static |
Definition at line 35 of file switch_core_cert.c.
Referenced by switch_ssl_destroy_ssl_locks(), switch_ssl_init_ssl_locks(), and switch_ssl_ssl_lock_callback().
|
static |
Definition at line 36 of file switch_core_cert.c.
Referenced by switch_ssl_destroy_ssl_locks(), and switch_ssl_init_ssl_locks().