← Back to team overview

maria-developers team mailing list archive

Re: [Commits] cae1945: MDEV-9117: Client Server capability negotiation for MariaDB specific functionality


On 17.01.2016 21:55, Sergei Golubchik wrote:
Hi, Oleksandr!

On Jan 17, Oleksandr Byelkin wrote:

+      if (ext_client_capabilities & MARIADB_CLIENT_EXTENDED_FLAGS)
+        client_capabilities|= ext_client_capabilities;
+      else
+      {
+        DBUG_PRINT("error", ("CLIENT_PROTOCOL_41: on, "
+                             "CLIENT_LONG_PASSWORD/CLIENT_MYSQL off, "
+                             "but MARIADB_CLIENT_EXTENDED_FLAGS is off. "
+                             "flags: %llx ext flags %llx",
+                             client_capabilities, ext_client_capabilities));
+        return packet_error;
Why do you need that (MARIADB_CLIENT_EXTENDED_FLAGS and the check)?
I meant flag CLIENT_MYSQL. But there is other function, report extended
functionality to client  (clein also can understand that it is mariaDB
server, but the flag alwais set in extended flag area is additional check.
I don't understand. What additional safety does this additional check
give you?

We checked the bytes of extended flag and the bit should be ON alway if it is MariaDB.

It is not so good as some signature but better then nothing (especially taking into account that all bits are 0).

Follow ups