Embedded server with authenticaction fixed after connection attributes port.
This commit is contained in:
parent
60c55522c3
commit
81957483d3
@ -701,6 +701,7 @@ err:
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef NO_EMBEDDED_ACCESS_CHECKS
|
||||||
static void
|
static void
|
||||||
emb_transfer_connect_attrs(MYSQL *mysql)
|
emb_transfer_connect_attrs(MYSQL *mysql)
|
||||||
{
|
{
|
||||||
@ -723,7 +724,6 @@ emb_transfer_connect_attrs(MYSQL *mysql)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#ifdef NO_EMBEDDED_ACCESS_CHECKS
|
|
||||||
int check_embedded_connection(MYSQL *mysql, const char *db)
|
int check_embedded_connection(MYSQL *mysql, const char *db)
|
||||||
{
|
{
|
||||||
int result;
|
int result;
|
||||||
@ -766,7 +766,8 @@ int check_embedded_connection(MYSQL *mysql, const char *db)
|
|||||||
(mysql->options.extension) ?
|
(mysql->options.extension) ?
|
||||||
mysql->options.extension->connection_attributes_length : 0;
|
mysql->options.extension->connection_attributes_length : 0;
|
||||||
|
|
||||||
buf= my_alloca(USERNAME_LENGTH + SCRAMBLE_LENGTH + 1 + 2*NAME_LEN + 2 +
|
buf= (char *)my_alloca(USERNAME_LENGTH + SCRAMBLE_LENGTH + 1 +
|
||||||
|
2*NAME_LEN + 2 +
|
||||||
connect_attrs_len + 2);
|
connect_attrs_len + 2);
|
||||||
if (mysql->options.client_ip)
|
if (mysql->options.client_ip)
|
||||||
{
|
{
|
||||||
@ -801,7 +802,8 @@ int check_embedded_connection(MYSQL *mysql, const char *db)
|
|||||||
int2store(end, (ushort) mysql->charset->number);
|
int2store(end, (ushort) mysql->charset->number);
|
||||||
end+= 2;
|
end+= 2;
|
||||||
|
|
||||||
end= strmake(end, "mysql_native_password", NAME_LEN) + 1;
|
// There is no pluging compatibility in the embedded server
|
||||||
|
//end= strmake(end, "mysql_native_password", NAME_LEN) + 1;
|
||||||
|
|
||||||
/* the server does the same as the client */
|
/* the server does the same as the client */
|
||||||
mysql->server_capabilities= mysql->client_flag;
|
mysql->server_capabilities= mysql->client_flag;
|
||||||
|
@ -8398,7 +8398,10 @@ static bool parse_com_change_user_packet(MPVIO_EXT *mpvio, uint packet_length)
|
|||||||
if ((mpvio->thd->client_capabilities & CLIENT_CONNECT_ATTRS) &&
|
if ((mpvio->thd->client_capabilities & CLIENT_CONNECT_ATTRS) &&
|
||||||
read_client_connect_attrs(&next_field, end,
|
read_client_connect_attrs(&next_field, end,
|
||||||
mpvio->thd->charset()))
|
mpvio->thd->charset()))
|
||||||
return packet_error;
|
{
|
||||||
|
my_message(ER_UNKNOWN_COM_ERROR, ER(ER_UNKNOWN_COM_ERROR), MYF(0));
|
||||||
|
DBUG_RETURN(packet_error);
|
||||||
|
}
|
||||||
|
|
||||||
DBUG_PRINT("info", ("client_plugin=%s, restart", client_plugin));
|
DBUG_PRINT("info", ("client_plugin=%s, restart", client_plugin));
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user