Documentation Home
MySQL Internals Manual Authentication Fails

Server indicates that client is not permitted to connect by sending ERR_Packet. This can happen at any moment after initial handshake.

  1. the client connecting to the server

  2. the server responds with the Initial Handshake Packet

  3. the client sends the Handshake Response Packet

  4. client and server possibly exchange further packets as required by the authentication method used

  5. the server responds with ERR_Packet and closes connection

Again, the Extra Authentication Data packets sent by server during step 4 start with 0x01 byte and thus can never be confused with the ERR_Packet.