|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72638 client fails to set "CLIENT_CONNECT_ATTRS" in capability flag
Submitted: 2016-07-21 02:43 UTC Modified: -
Avg. Score:3.3 ± 0.5
Reproduced:3 of 3 (100.0%)
Same Version:2 (66.7%)
Same OS:2 (66.7%)
From: littlewintergrass at gmail dot com Assigned:
Status: Open Package: MySQL related
PHP Version: Irrelevant OS: any
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
Solve the problem:
42 + 28 = ?
Subscribe to this entry?

 [2016-07-21 02:43 UTC] littlewintergrass at gmail dot com
Client will send handshake response to MySQL server after receiving server greeting packet.

mysqlnd extension adds client attribute "_client_name" as "mysqlnd" in the handshake response packet:

According to MySQL protocol, client should set "CLIENT_CONNECT_ATTRS" bit in its capability flag if any client attribute is added:

However it is never set in handshake response.
The macro is defined here:

For those MySQL servers that strictly follow the protocol, this will cause packet parsing failure.


fix-connection-attributes-in-mysqlnd (last revision 2016-11-16 15:22 UTC by mateusz dot kijowski at gmail dot com)

Add a Patch

Pull Requests

Add a Pull Request

PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Thu Oct 06 04:03:57 2022 UTC