26#ifndef ROUTING_CLASSIC_AUTH_CACHING_SHA2_INCLUDED 
   27#define ROUTING_CLASSIC_AUTH_CACHING_SHA2_INCLUDED 
   31#include <system_error> 
   42  static constexpr const std::string_view 
kName{
"caching_sha2_password"};
 
   48  static std::optional<std::string> 
scramble(std::string_view nonce,
 
   49                                             std::string_view pwd);
 
   54  template <
class Proto>
 
   62      const std::string &public_key);
 
   64  template <
class Proto>
 
   78  template <
class Proto>
 
   88  template <
class Proto>
 
Definition: classic_auth.h:48
 
Definition: classic_auth_caching_sha2.h:38
 
static constexpr const std::string_view kPublicKeyRequest
Definition: classic_auth_caching_sha2.h:44
 
static stdx::expected< size_t, std::error_code > send_plaintext_password_request(Channel &dst_channel, ClassicProtocolState &dst_protocol)
Definition: classic_auth_caching_sha2.cc:60
 
static constexpr const uint8_t kFastAuthDone
Definition: classic_auth_caching_sha2.h:45
 
static bool is_public_key_request(const std::string_view &data)
Definition: classic_auth_caching_sha2.cc:87
 
static stdx::expected< size_t, std::error_code > send_public_key(TlsSwitchableConnection< Proto > &conn, const std::string &public_key)
Definition: classic_auth_caching_sha2.h:65
 
static bool is_public_key(const std::string_view &data)
Definition: classic_auth_caching_sha2.cc:92
 
static stdx::expected< size_t, std::error_code > send_public_key_request(Channel &dst_channel, ClassicProtocolState &dst_protocol)
Definition: classic_auth_caching_sha2.cc:42
 
static std::optional< std::string > scramble(std::string_view nonce, std::string_view pwd)
Definition: classic_auth_caching_sha2.cc:36
 
static stdx::expected< size_t, std::error_code > send_public_key_request(TlsSwitchableConnection< Proto > &conn)
Definition: classic_auth_caching_sha2.h:55
 
static stdx::expected< size_t, std::error_code > send_encrypted_password(TlsSwitchableConnection< Proto > &conn, const std::string &password)
Definition: classic_auth_caching_sha2.h:89
 
static constexpr const std::string_view kName
Definition: classic_auth_caching_sha2.h:42
 
static constexpr const size_t kNonceLength
Definition: classic_auth_caching_sha2.h:40
 
static stdx::expected< size_t, std::error_code > send_plaintext_password(Channel &dst_channel, ClassicProtocolState &dst_protocol, const std::string &password)
Definition: classic_auth_caching_sha2.cc:69
 
static stdx::expected< size_t, std::error_code > send_plaintext_password(TlsSwitchableConnection< Proto > &conn, const std::string &password)
Definition: classic_auth_caching_sha2.h:79
 
static constexpr const uint8_t kPerformFullAuth
Definition: classic_auth_caching_sha2.h:46
 
static stdx::expected< size_t, std::error_code > send_public_key(Channel &dst_channel, ClassicProtocolState &dst_protocol, const std::string &public_key)
Definition: classic_auth_caching_sha2.cc:51
 
static stdx::expected< size_t, std::error_code > send_encrypted_password(Channel &dst_channel, ClassicProtocolState &dst_protocol, const std::string &password)
Definition: classic_auth_caching_sha2.cc:79
 
SSL aware socket buffers.
Definition: channel.h:65
 
protocol state of a classic protocol connection.
Definition: classic_protocol_state.h:40
 
a Connection that can be switched to TLS.
Definition: connection_base.h:265
 
Channel & channel()
Definition: connection_base.h:360
 
protocol_state_type & protocol()
Definition: connection_base.h:399
 
static char * password
Definition: mysql_secure_installation.cc:58