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 <kih...@apache.org> Authored: Fri Dec 9 11:05:04 2016 -0600 Committer: Kihwal Lee <kih...@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-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-commits-h...@hadoop.apache.org