Skip to content

Commit

Permalink
[Fix](Authenticator)defaultAuthenticator not init
Browse files Browse the repository at this point in the history
1: The `defaultAuthenticator` is not initialized. When a configured authentication plugin implements the `canDea`l method and returns `false`, the `defaultAuthenticator` will be used, resulting in a login failure. The client exception message is `RROR 2013 (HY000): Lost connection to MySQL server at 'reading authorization packet', system error: 2`. This issue only affects users who use non-built-in authentication plugins that implement `canDeal` and return false under certain circumstances.

apache#40113 introduced this issue
  • Loading branch information
CalvinKirs committed Nov 1, 2024
1 parent 55fde45 commit 2d9ca67
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public class AuthenticatorManager {

public AuthenticatorManager(String type) {
LOG.info("Authenticate type: {}", type);

defaultAuthenticator = new DefaultAuthenticator();
if (authTypeAuthenticator == null) {
synchronized (AuthenticatorManager.class) {
if (authTypeAuthenticator == null) {
Expand Down

0 comments on commit 2d9ca67

Please sign in to comment.