26#ifndef MYSQL_HARNESS_TLS_CLIENT_CONTEXT_INCLUDED
27#define MYSQL_HARNESS_TLS_CLIENT_CONTEXT_INCLUDED
34#include <system_error>
46 void operator()(SSL_SESSION *sess) { SSL_SESSION_free(sess); }
48 using SslSession = std::unique_ptr<SSL_SESSION, SslSessionDeleter>;
89 const std::string &ciphers);
102 const std::string &server_host);
Client TLS Context.
Definition: tls_client_context.h:43
std::unique_ptr< Sessions > sessions_
Definition: tls_client_context.h:125
std::unique_ptr< SSL_SESSION, SslSessionDeleter > SslSession
Definition: tls_client_context.h:48
TlsClientContext & operator=(TlsClientContext &&)=default
TlsClientContext(TlsClientContext &&)=default
std::chrono::seconds session_cache_timeout_
Definition: tls_client_context.h:129
bool session_cache_mode_
Definition: tls_client_context.h:127
TlsClientContext(const TlsClientContext &)=delete
TlsClientContext & operator=(const TlsClientContext &)=delete
size_t session_cache_size_
Definition: tls_client_context.h:128
wraps SSL_CTX.
Definition: tls_context.h:85
std::vector< std::string > cipher_list() const
get current cipher-list.
Definition: tls_context.cc:392
Definition: expected.h:286
bool verify(const std::string &digest, const std::string &message, const std::string &public_key_content)
Verify a message signed by the private key pair of the provided public key.
Definition: my_base64_encode.cc:115
mode
Definition: file_handle.h:61
Definition: tls_client_context.h:118
std::list< SessionData > sessions_
Definition: tls_client_context.h:122
std::pair< SessionId, SslSession > SessionData
Definition: tls_client_context.h:120
std::mutex mtx_
Definition: tls_client_context.h:123
std::vector< uint8_t > SessionId
Definition: tls_client_context.h:119
Definition: tls_client_context.h:45
void operator()(SSL_SESSION *sess)
Definition: tls_client_context.h:46
double seconds()
Definition: task.cc:310
TlsVerify
Verification of Cerifiticates.
Definition: tls_context.h:62
#define HARNESS_TLS_EXPORT
Definition: tls_export.h:15