Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Support for Protocol::AuthSwitchRequest #104

Closed
dickson-michael opened this issue Jan 6, 2021 · 0 comments
Closed

Implement Support for Protocol::AuthSwitchRequest #104

dickson-michael opened this issue Jan 6, 2021 · 0 comments

Comments

@dickson-michael
Copy link
Contributor

dickson-michael commented Jan 6, 2021

Request: Implement support for Protocol::AuthSwitchRequest

Testing: Set up a MySQL 8.0 server with caching_sha2_password as the default. Set up a user with mysql_native_password authentication. Attempt to log in to that user.

Expectation: Login is attempted using mysql_native_password.

Result: Connection closed unexpectedly.

Trace:

  1. Client enters Processor::handleHandshake() and sends a response package noting capabilities include CLIENT_PLUGIN_AUTH and requesting authentication using caching_sha2_password.
  2. The server replies back with a Protocol::AuthSwitchRequest packet (2c 00 00 02 fe).
  3. Client is in Processor::parsePayload() with connectionState === self::ESTABLISHED, and expects the packet to be either 0x00, 0xff, or 0x01.
  4. Packet 0xfe is ignored.
  5. Connection times out and is closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants