1#ifndef MYSQL_PLUGIN_AUTH_COMMON_INCLUDED
36#define MYSQL_PLUGIN_AUTH_COMMON_INCLUDED
39#define MYSQL_USERNAME_LENGTH 96
51#define CR_AUTH_ACCOUNT_LOCKED_ERROR 5
58#define CR_AUTH_TEMPORARY_ACCOUNT_LOCKED_ERROR 4
65#define CR_AUTH_PLUGIN_ERROR 3
72#define CR_AUTH_HANDSHAKE 2
79#define CR_AUTH_USER_CREDENTIALS 1
111#define CR_OK_HANDSHAKE_COMPLETE -2
117#define CR_OK_AUTH_IN_SANDBOX_MODE -3
128#if defined(_WIN32) && !defined(MYSQL_ABI_CHECK)
129#ifndef WIN32_LEAN_AND_MEAN
130#define WIN32_LEAN_AND_MEAN
145#if defined(_WIN32) && !defined(MYSQL_ABI_CHECK)
static char buf[MAX_BUF]
Definition: conf_to_src.cc:74
static int handle(int sql_errno, const char *sqlstate, const char *message, void *state)
Bridge function between the C++ API offered by this module and the C API of the parser service.
Definition: services.cc:64
struct result result
Definition: result.h:34
struct MYSQL_PLUGIN_VIO MYSQL_PLUGIN_VIO
Provides plugin access to communication channel.
net_async_status
Definition: plugin_auth_common.h:151
@ NET_ASYNC_NOT_READY
Definition: plugin_auth_common.h:153
@ NET_ASYNC_COMPLETE_NO_MORE_RESULTS
Definition: plugin_auth_common.h:155
@ NET_ASYNC_ERROR
Definition: plugin_auth_common.h:154
@ NET_ASYNC_COMPLETE
Definition: plugin_auth_common.h:152
Definition: plugin_auth_common.h:135
@ MYSQL_VIO_INVALID
Definition: plugin_auth_common.h:137
@ MYSQL_VIO_TCP
Definition: plugin_auth_common.h:138
@ MYSQL_VIO_PIPE
Definition: plugin_auth_common.h:140
@ MYSQL_VIO_SOCKET
Definition: plugin_auth_common.h:139
@ MYSQL_VIO_MEMORY
Definition: plugin_auth_common.h:141
int socket
it's set, if the protocol is SOCKET or TCP
Definition: plugin_auth_common.h:143
bool is_tls_established
Definition: plugin_auth_common.h:144
enum MYSQL_PLUGIN_VIO_INFO::@6 protocol
Provides plugin access to communication channel.
Definition: plugin_auth_common.h:161
enum net_async_status(* read_packet_nonblocking)(struct MYSQL_PLUGIN_VIO *vio, unsigned char **buf, int *result)
Non blocking version of read_packet.
Definition: plugin_auth_common.h:190
int(* write_packet)(struct MYSQL_PLUGIN_VIO *vio, const unsigned char *packet, int packet_len)
Plugin provides a buffer with data and the length and this function sends it as a packet.
Definition: plugin_auth_common.h:173
enum net_async_status(* write_packet_nonblocking)(struct MYSQL_PLUGIN_VIO *vio, const unsigned char *pkt, int pkt_len, int *result)
Non blocking version of write_packet.
Definition: plugin_auth_common.h:197
void(* info)(struct MYSQL_PLUGIN_VIO *vio, struct MYSQL_PLUGIN_VIO_INFO *info)
Fills in a MYSQL_PLUGIN_VIO_INFO structure, providing the information about the connection.
Definition: plugin_auth_common.h:180
int(* read_packet)(struct MYSQL_PLUGIN_VIO *vio, unsigned char **buf)
Plugin provides a pointer reference and this function sets it to the contents of any incoming packet.
Definition: plugin_auth_common.h:167
#define HANDLE
Definition: violite.h:159