Bug 66183 - AccessLogValve - %{xxx}c should output the value of all cookies with the same name
Summary: AccessLogValve - %{xxx}c should output the value of all cookies with the same...
Status: RESOLVED FIXED
Alias: None
Product: Tomcat 10
Classification: Unclassified
Component: Catalina (show other bugs)
Version: unspecified
Hardware: PC Mac OS X 10.1
: P2 normal (vote)
Target Milestone: ------
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-07-28 14:51 UTC by Han Li
Modified: 2022-08-23 08:22 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Han Li 2022-07-28 14:51:12 UTC
According to RFC 6265, the server should be able to process cookies with the same name, and tomcat has implemented this functionality. So when using %{xxx}c in accesslog, we should alse output the values of all cookies with same name. Currently only the first value is output and the other values are ignored.
Comment 1 Han Li 2022-07-28 14:53:08 UTC
If it's confirmed that a fix is needed, I'd be happy to provide pr, and I'd probably splice multiple values with commas, just like this: value1,value2,value3
Comment 2 Mark Thomas 2022-08-16 04:24:50 UTC
I agree that this needs to be fixed. Your plan sounds reasonable to me.
Comment 3 Han Li 2022-08-16 05:05:57 UTC
(In reply to Mark Thomas from comment #2)
> I agree that this needs to be fixed. Your plan sounds reasonable to me.
Ok, I'll go ahead and fix this bug today.

Thanks Mark!

Han
Comment 4 Han Li 2022-08-16 05:21:23 UTC
There is also this problem in Extended Access Log Valve.
Comment 5 Han Li 2022-08-16 05:44:37 UTC
PR: https://github.com/apache/tomcat/pull/541
Comment 6 Mark Thomas 2022-08-23 08:22:37 UTC
Thanks for the report and the PR.

Fixed in:
- 10.1.x for 10.1.0-M18 onwards
- 10.0.x for 10.0.24 onwards
-  9.0.x for  9.0.66 onwards
-  8.5.x for  8.5.83 onwards