Skip to content

Commit 95900c4

Browse files
committed
[CONC-654, MDEV-31585] CLIENT_CAN_SSL_V2 capability bit should not be MariaDB-specific
MySQL is also certainly affected, and we will likely try to get them to follow the fixes for these TLS vulnerabilities as well, so the SSL_V2 capability bit should not be MariaDB-specific. All new code of the whole pull request, including one or several files that are either new files or modified ones, are contributed under the BSD-new license. I am contributing on behalf of my employer Amazon Web Services, Inc.
1 parent ea4282e commit 95900c4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

include/mariadb_com.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ enum enum_server_command
174174
* after the TLS handshake.
175175
*
176176
*/
177-
#define CLIENT_CAN_SSL_V2 (1ULL << 37)
177+
#define CLIENT_CAN_SSL_V2 (1ULL << 28)
178178
#define CLIENT_PROGRESS (1UL << 29) /* client supports progress indicator */
179179
#define CLIENT_PROGRESS_OBSOLETE CLIENT_PROGRESS
180180
#define CLIENT_SSL_VERIFY_SERVER_CERT (1UL << 30)

plugins/auth/my_auth.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ static int send_client_reply_packet(MCPVIO_EXT *mpvio,
211211

212212
#if defined(HAVE_TLS) && !defined(EMBEDDED_LIBRARY)
213213
bool server_supports_ssl_v2=
214-
mysql->extension->mariadb_server_capabilities & (MARIADB_CLIENT_CAN_SSL_V2 >> 32);
214+
mysql->server_capabilities & CLIENT_CAN_SSL_V2;
215215
#endif
216216

217217
/* see end= buff+32 below, fixed size of the packet is 32 bytes */

0 commit comments

Comments
 (0)