You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by ki...@apache.org on 2016/12/09 17:05:23 UTC

hadoop git commit: HADOOP-11859. PseudoAuthenticationHandler fails with httpcomponents v4.4. Contributed by Eugene Koifman.

Repository: hadoop
Updated Branches:
  refs/heads/branch-2.7 c95ab6b89 -> deae1f832


HADOOP-11859. PseudoAuthenticationHandler fails with httpcomponents v4.4. Contributed by Eugene Koifman.

(cherry picked from commit db4419df6bc72e9a1ddd90bac4dd7dcf0fb05479)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/deae1f83
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/deae1f83
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/deae1f83

Branch: refs/heads/branch-2.7
Commit: deae1f83239c3f1d3ac44bda6a6fd90b509f5dfa
Parents: c95ab6b
Author: Kihwal Lee <ki...@apache.org>
Authored: Fri Dec 9 11:05:04 2016 -0600
Committer: Kihwal Lee <ki...@apache.org>
Committed: Fri Dec 9 11:05:04 2016 -0600

----------------------------------------------------------------------
 .../authentication/server/PseudoAuthenticationHandler.java     | 6 +++++-
 hadoop-common-project/hadoop-common/CHANGES.txt                | 3 +++
 2 files changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/deae1f83/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/PseudoAuthenticationHandler.java
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/PseudoAuthenticationHandler.java b/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/PseudoAuthenticationHandler.java
index 50f0cf1..19947aa 100644
--- a/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/PseudoAuthenticationHandler.java
+++ b/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/PseudoAuthenticationHandler.java
@@ -142,7 +142,11 @@ public class PseudoAuthenticationHandler implements AuthenticationHandler {
   }
 
   private String getUserName(HttpServletRequest request) {
-    List<NameValuePair> list = URLEncodedUtils.parse(request.getQueryString(), UTF8_CHARSET);
+    String queryString = request.getQueryString();
+    if(queryString == null || queryString.length() == 0) {
+      return null;
+    }
+    List<NameValuePair> list = URLEncodedUtils.parse(queryString, UTF8_CHARSET);
     if (list != null) {
       for (NameValuePair nv : list) {
         if (PseudoAuthenticator.USER_NAME.equals(nv.getName())) {

http://git-wip-us.apache.org/repos/asf/hadoop/blob/deae1f83/hadoop-common-project/hadoop-common/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt
index b9167b4..0c533c9 100644
--- a/hadoop-common-project/hadoop-common/CHANGES.txt
+++ b/hadoop-common-project/hadoop-common/CHANGES.txt
@@ -104,6 +104,9 @@ Release 2.7.4 - UNRELEASED
     HADOOP-13804. MutableStat mean loses accuracy if add(long, long) is used.
     (Erik Krogen via zhz)
 
+    HADOOP-11859. PseudoAuthenticationHandler fails with httpcomponents v4.4.
+    (Eugene Koifman via jitendra)
+
 Release 2.7.3 - 2016-08-25
 
   INCOMPATIBLE CHANGES


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org