You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by GitBox <gi...@apache.org> on 2021/10/22 15:06:47 UTC
[GitHub] [hadoop] fapifta commented on a change in pull request #3579: HADOOP-17975 Fallback to simple auth does not work for a secondary DistributedFileSystem instance.
fapifta commented on a change in pull request #3579:
URL: https://github.com/apache/hadoop/pull/3579#discussion_r734626158
##########
File path: hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Client.java
##########
@@ -909,6 +898,35 @@ public AuthMethod run()
connectingThread.set(null);
}
}
+
+ private void setFallBackToSimpleAuth(AtomicBoolean fallbackToSimpleAuth)
+ throws IOException {
+ if (fallbackToSimpleAuth == null) {
+ LOG.trace("Connection {} skips setting fallbackToSimpleAuth as it is null.", remoteId);
+ return;
+ }
+ if (authMethod == null) {
+ // setupIOStreams() will set up authMethod first, then call this method again.
+ return;
+ }
+ LOG.trace(
+ "Setting fallbackToSimpleAuth. AuthMethod is {}. Fallback allowed by configuration: {}. "
+ + "Security is {}.",
+ authMethod, fallbackAllowed,
+ UserGroupInformation.isSecurityEnabled() ? "enabled" : "disabled");
+ if (authMethod != AuthMethod.SIMPLE) {
+ LOG.trace("Disabling fallbackToSimpleAuth target does not require SIMPLE authentication.");
+ fallbackToSimpleAuth.set(false);
+ } else if (UserGroupInformation.isSecurityEnabled()) {
+ if (!fallbackAllowed) {
+ throw new IOException("Server asks us to fall back to SIMPLE auth, but this client is "
Review comment:
Yes, you are right, I am unsure how that has been changed... but I have added a commit to fix it, thank you for the review and spotting it!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org