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 we...@apache.org on 2019/08/02 00:37:13 UTC
[hadoop] branch branch-3.2 updated: HADOOP-15681.
AuthenticationFilter should generate valid date format for Set-Cookie
header regardless of default Locale. Contributed by Cao Manh Dat.
This is an automated email from the ASF dual-hosted git repository.
weichiu pushed a commit to branch branch-3.2
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/branch-3.2 by this push:
new 490b18f HADOOP-15681. AuthenticationFilter should generate valid date format for Set-Cookie header regardless of default Locale. Contributed by Cao Manh Dat.
490b18f is described below
commit 490b18fd4f35a19dc2dd48249cb38a96dbf2f85c
Author: Wei-Chiu Chuang <we...@apache.org>
AuthorDate: Thu Aug 1 17:34:56 2019 -0700
HADOOP-15681. AuthenticationFilter should generate valid date format for Set-Cookie header regardless of default Locale. Contributed by Cao Manh Dat.
(cherry picked from commit e20b19543ba148cf0242884a3e553ad2f39421b3)
---
.../hadoop/security/authentication/server/AuthenticationFilter.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/AuthenticationFilter.java b/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/AuthenticationFilter.java
index 5aeddac..94d11f48 100644
--- a/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/AuthenticationFilter.java
+++ b/hadoop-common-project/hadoop-auth/src/main/java/org/apache/hadoop/security/authentication/server/AuthenticationFilter.java
@@ -681,7 +681,7 @@ public class AuthenticationFilter implements Filter {
if (expires >= 0 && isCookiePersistent) {
Date date = new Date(expires);
SimpleDateFormat df = new SimpleDateFormat("EEE, " +
- "dd-MMM-yyyy HH:mm:ss zzz");
+ "dd-MMM-yyyy HH:mm:ss zzz", Locale.US);
df.setTimeZone(TimeZone.getTimeZone("GMT"));
sb.append("; Expires=").append(df.format(date));
}
---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org