Botan 3.4.0
Crypto and TLS for C&
|
#include <tls_session.h>
Public Member Functions | |
Ciphersuite | ciphersuite () const |
uint16_t | ciphersuite_code () const |
uint16_t | dtls_srtp_profile () const |
const std::vector< X509_Certificate > & | peer_certs () const |
std::shared_ptr< const Public_Key > | peer_raw_public_key () const |
const Server_Information & | server_info () const |
Session_Base (std::chrono::system_clock::time_point start_time, Protocol_Version version, uint16_t ciphersuite, Connection_Side connection_side, uint16_t srtp_profile, bool extended_master_secret, bool encrypt_then_mac, std::vector< X509_Certificate > peer_certs, std::shared_ptr< const Public_Key > peer_raw_public_key, Server_Information server_info) | |
Connection_Side | side () const |
std::chrono::system_clock::time_point | start_time () const |
bool | supports_encrypt_then_mac () const |
bool | supports_extended_master_secret () const |
Protocol_Version | version () const |
Protected Member Functions | |
Session_Base ()=default | |
Protected Attributes | |
uint16_t | m_ciphersuite |
Connection_Side | m_connection_side |
bool | m_encrypt_then_mac |
bool | m_extended_master_secret |
std::vector< X509_Certificate > | m_peer_certs |
std::shared_ptr< const Public_Key > | m_peer_raw_public_key |
Server_Information | m_server_info |
uint16_t | m_srtp_profile |
std::chrono::system_clock::time_point | m_start_time |
Protocol_Version | m_version |
Represents basic information about a session that can be both persisted for resumption and presented to the application as a summary of a specific just-established TLS session.
Definition at line 137 of file tls_session.h.
|
inline |
Definition at line 139 of file tls_session.h.
|
protecteddefault |
Ciphersuite Botan::TLS::Session_Base::ciphersuite | ( | ) | const |
Get the ciphersuite info of the negotiated TLS session
Definition at line 86 of file tls_session.cpp.
References Botan::TLS::Ciphersuite::by_id(), and m_ciphersuite.
Referenced by Botan::TLS::Server_Hello_12::Server_Hello_12().
|
inline |
Get the ciphersuite code of the negotiated TLS session
Definition at line 177 of file tls_session.h.
Referenced by Botan::TLS::Client_Hello_12::Client_Hello_12(), and Botan::TLS::Session::Session().
|
inline |
|
inline |
Return the certificate chain of the peer (possibly empty)
Definition at line 209 of file tls_session.h.
|
inline |
Return the raw public key of the peer (possibly empty)
Definition at line 214 of file tls_session.h.
|
inline |
Get information about the TLS server
Definition at line 219 of file tls_session.h.
Referenced by Botan::TLS::Client_Hello_12::Client_Hello_12(), and Botan::TLS::Session_Manager_SQL::store().
|
inline |
Get which side of the connection we are/were acting as.
Definition at line 187 of file tls_session.h.
Referenced by Botan::TLS::Session_Manager::establish(), and Botan::TLS::Session_Manager_Stateless::establish().
|
inline |
Get the wall clock time this session began
Definition at line 167 of file tls_session.h.
Referenced by Botan::TLS::Session::Session(), and Botan::TLS::Session_Manager_SQL::store().
|
inline |
Returns true if a TLS 1.2 session negotiated "encrypt then MAC"; TLS 1.3 sessions will always return false as they always use an AEAD.
Definition at line 198 of file tls_session.h.
Referenced by Botan::TLS::Client_Hello_12::Client_Hello_12().
|
inline |
Returns true if a TLS 1.2 session negotiated "extended master secret"; TLS 1.3 sessions will always return true (see RFC 8446 Appendix D).
Definition at line 204 of file tls_session.h.
|
inline |
Get the negotiated protocol version of the TLS session
Definition at line 172 of file tls_session.h.
Referenced by Botan::TLS::Client_Hello_12::Client_Hello_12(), Botan::TLS::Session_Manager_Hybrid::establish(), Botan::TLS::Channel_Impl::request_downgrade_for_resumption(), Botan::TLS::Session::Session(), Botan::TLS::Session::Session(), and Botan::TLS::Callbacks::tls_should_persist_resumption_information().
|
protected |
Definition at line 225 of file tls_session.h.
Referenced by ciphersuite(), Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 226 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 230 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 229 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 232 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 233 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 234 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 227 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 222 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), and Botan::TLS::Session::Session().
|
protected |
Definition at line 224 of file tls_session.h.
Referenced by Botan::TLS::Session::DER_encode(), Botan::TLS::Session::Session(), and Botan::TLS::Session::Session().