{"record":{"id":"ea61117b83fe14bf","repo":"apache/hadoop","slug":"plain-auth-failed","errorCode":null,"errorMessage":"PLAIN auth failed: ","messagePattern":"PLAIN auth failed: ","errorType":"exception","errorClass":"SaslException","httpStatus":null,"severity":"error","filePath":"hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/SaslPlainServer.java","lineNumber":109,"sourceCode":"      String[] parts = payload.split(\"\\u0000\", 3);\n      if (parts.length != 3) {\n        throw new IllegalArgumentException(\"Received corrupt response\");\n      }\n      if (parts[0].isEmpty()) { // authz = authn\n        parts[0] = parts[1];\n      }\n      \n      NameCallback nc = new NameCallback(\"SASL PLAIN\");\n      nc.setName(parts[1]);\n      PasswordCallback pc = new PasswordCallback(\"SASL PLAIN\", false);\n      pc.setPassword(parts[2].toCharArray());\n      AuthorizeCallback ac = new AuthorizeCallback(parts[1], parts[0]);\n      cbh.handle(new Callback[]{nc, pc, ac});      \n      if (ac.isAuthorized()) {\n        authz = ac.getAuthorizedID();\n      }\n    } catch (Exception e) {\n      throw new SaslException(\"PLAIN auth failed: \" + e.toString(), e);\n    } finally {\n      completed = true;\n    }\n    return null;\n  }\n\n  private void throwIfNotComplete() {\n    if (!completed) {\n      throw new IllegalStateException(\"PLAIN authentication not completed\");\n    }\n  }\n  \n  @Override\n  public boolean isComplete() {\n    return completed;\n  }\n\n  @Override","sourceCodeStart":91,"sourceCodeEnd":127,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/SaslPlainServer.java#L91-L127","documentation":"Error \"PLAIN auth failed: \" thrown in apache/hadoop.","triggerScenarios":"Thrown at hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/SaslPlainServer.java:109 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the username and password/token used for PLAIN authentication are correct.","Check the server-side secret manager for expired or invalid tokens and re-issue them.","Ensure the client principal matches what the server expects for this connection."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-23T01:17:44.959Z"}