1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
--- mariadb/include/errmsg.h 2014-04-04 12:21:01.000000000 +0200
+++ mariadb/include/errmsg.h 2014-09-17 17:47:25.000000000 +0200
@@ -66,6 +66,7 @@
#define CR_PARAMS_NOT_BOUND 2031
#define CR_INVALID_PARAMETER_NO 2034
#define CR_UNSUPPORTED_PARAM_TYPE 2036
+#define CR_SECURE_AUTH 2049
#define CR_NO_DATA 2051
#define CR_NO_STMT_METADATA 2052
#define CR_NOT_IMPLEMENTED 2054
--- mariadb/libmariadb/errmsg.c 2014-04-04 12:21:01.000000000 +0200
+++ mariadb/libmariadb/errmsg.c 2014-09-17 17:48:44.000000000 +0200
@@ -129,7 +129,7 @@
/* 2046 */ "",
/* 2047 */ "",
/* 2048 */ "",
-/* 2049 */ "",
+/* 2049 */ "Connection with old authentication protocol refused.",
/* 2050 */ "",
/* 2051 */ "",
/* 2052 */ "Prepared statement contains no metadata",
--- mariadb/libmariadb/libmariadb.c 2014-04-04 12:21:01.000000000 +0200
+++ mariadb/libmariadb/libmariadb.c 2014-09-17 17:56:13.000000000 +0200
@@ -1864,7 +1864,14 @@
scramble_plugin= native_password_plugin_name;
}
} else
+ {
mysql->server_capabilities&= ~CLIENT_SECURE_CONNECTION;
+ if (mysql->options.secure_auth)
+ {
+ SET_CLIENT_ERROR(mysql, CR_SECURE_AUTH, unknown_sqlstate, 0);
+ goto error;
+ }
+ }
/* Set character set */
if (mysql->options.charset_name)
@@ -3031,7 +3038,9 @@
}
}
break;
-
+ case MYSQL_SECURE_AUTH:
+ mysql->options.secure_auth= *(my_bool *)arg1;
+ break;
default:
va_end(ap);
DBUG_RETURN(-1);
|