Botan 3.6.1
Crypto and TLS for C&
|
#include <tls_handshake_transitions.h>
Public Member Functions | |
bool | change_cipher_spec_expected () const |
void | confirm_transition_to (Handshake_Type msg_type) |
bool | received_handshake_msg (Handshake_Type msg_type) const |
void | set_expected_next (const std::vector< Handshake_Type > &msg_types) |
void | set_expected_next (Handshake_Type msg_type) |
Manages the expectations for incoming handshake messages in both TLS 1.2 and 1.3. This does not bear any knowledge about the actual state machine but is a mere helper to implement state transition validation.
Definition at line 24 of file tls_handshake_transitions.h.
bool Botan::TLS::Handshake_Transitions::change_cipher_spec_expected | ( | ) | const |
Check whether a Change Cipher Spec must be expected
Definition at line 175 of file tls_handshake_transitions.cpp.
References Botan::TLS::HandshakeCCS.
Referenced by Botan::TLS::Handshake_State::get_next_handshake_msg().
void Botan::TLS::Handshake_Transitions::confirm_transition_to | ( | Handshake_Type | msg_type | ) |
Confirm that we were expecting this message type
msg_type | the message type |
Definition at line 131 of file tls_handshake_transitions.cpp.
References Botan::TLS::handshake_type_to_string().
Referenced by Botan::TLS::Handshake_State::confirm_transition_to().
bool Botan::TLS::Handshake_Transitions::received_handshake_msg | ( | Handshake_Type | msg_type | ) | const |
Return true iff we have received a particular message already
msg_type | the message type |
Definition at line 125 of file tls_handshake_transitions.cpp.
Referenced by Botan::TLS::Handshake_State::received_handshake_msg().
void Botan::TLS::Handshake_Transitions::set_expected_next | ( | const std::vector< Handshake_Type > & | msg_types | ) |
Record that we are expecting one of the enumerated message types next. Note that receiving any of the expected messages in confirm_transition_to
resets all the expectations.
msg_types | the message types |
Definition at line 169 of file tls_handshake_transitions.cpp.
References set_expected_next().
void Botan::TLS::Handshake_Transitions::set_expected_next | ( | Handshake_Type | msg_type | ) |
Record that we are expecting a particular message type next
msg_type | the message type |
Definition at line 165 of file tls_handshake_transitions.cpp.
Referenced by Botan::TLS::Client_Impl_13::Client_Impl_13(), Botan::TLS::Handshake_State::set_expected_next(), and set_expected_next().