GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||
GeezerVison is showing github.com — mysql: track the auth plugin and seed from an authentication switch request by kibo-andynunes · Pull Request #440 · jasync-sql/jasync-sql Conversation
|
| Run | Result |
|---|---|
| New real-server test, with fix | pass |
| New real-server test, fix reverted | fails with AuthMoreDataMessage is only supported for 'caching_sha2_password' method |
AuthenticationSwitchSpec (6 tests), with fix |
6/6 pass |
AuthenticationSwitchSpec, fix reverted |
3 fail (the switch cases) |
AuthenticationSwitchSpec, plugin line only (seed line removed) |
the RSA/seed test fails (password decrypts to garbage), so both lines are needed |
AuthenticationSpec (all 5, incl. sha256 and old-password flows), with fix |
pass |
:mysql-async:test + :r2dbc-mysql:test, with fix |
no failures attributable to the change (see note) |
ktlintCheck |
pass |
Note: on my machine (Apple silicon, Docker Desktop) MySQLConnectionSpec."connect to a MySQL instance with unix domain socket" fails with and without the change (connection refused), and sha256Authentication failed once in the full run on container startup (mysql:5.7.32) and passed when rerun. Neither relates to this change.
Run locally with JDK 17 and -PTEST_CONTAINERS_VERSION=1.21.4: the pinned Testcontainers 1.17.6 can't talk to a current Docker daemon (API too old). That override is not part of this PR.
🤖 Generated with Claude Code
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…equest MySQLConnection stored the authentication method and seed from the initial handshake only. When the server's default plugin differs from the account's plugin (e.g. the handshake advertises mysql_native_password but the account uses caching_sha2_password), the server answers with an authentication switch request. switchAuthentication() answered it but did not record the new plugin and seed, so a following AuthMoreData packet asking for full authentication was checked against the stale plugin and failed with: AuthMoreDataMessage is only supported for 'caching_sha2_password' method It also scrambled the password with the stale seed on the RSA path. Record the plugin and seed from the switch request before answering it. Tests: AuthenticationSpec gets a case against a real server whose default plugin is mysql_native_password; AuthenticationSwitchSpec covers the packet flows against an in-process fake server without Docker. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
|
Note on the red checks, neither comes from this change:
The new Happy to send a separate PR bumping Testcontainers (or pinning the runner) if you'd like. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
IllegalStateException "AuthMoreDataMessage is only supported for 'caching_sha2_password' method" when the handshake plugin differs from the account's plugin
There was an error while loading. Please reload this page.