Cookie variable in Apache LogFormat outputs incorrect value

Bug #815865 reported by Richard Mitchell
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Apache2 Web Server
Unknown
Unknown
apache2 (Ubuntu)
Fix Released
Medium
Unassigned
Lucid
Won't Fix
Medium
Unassigned
Maverick
Won't Fix
Medium
Unassigned

Bug Description

Given the example request:
{{{
GET / HTTP/1.1
Host: example.com
Cookie: __foo_bar="baz"; __foo="quux
"
}}}

and the Apache configuration:
{{{
    LogFormat "\"%r\" %>s \"%{__foo}C\" \"%{__foo_bar}C\"" mylogformat
    CustomLog /path/to/log mylogformat
}}}

Then the relevant entry in /path/to/log will be:
{{{
"GET / HTTP/1.1" 200 "bar=\"baz\"" "\"baz\""
}}}
when it ought to read:
{{{
"GET / HTTP/1.1" 200 "\"quux\"" "\"baz\""
}}}

{{{
$ apache2 -v
Server version: Apache/2.2.12 (Ubuntu)
Server built: Nov 18 2010 21:16:51
}}}

Revision history for this message
Richard Mitchell (mitchellrj) wrote :

(Ignore the newline after 'quux' in the example request)

Revision history for this message
Richard Mitchell (mitchellrj) wrote :

Appears to be the same as this upstream bug: https://issues.apache.org/bugzilla/show_bug.cgi?id=28037

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

This was fixed in Apache v2.2.17, which was included in Ubuntu 11.04. This bug affects lucid and maverick.

Changed in apache2 (Ubuntu):
status: New → Fix Released
Changed in apache2 (Ubuntu Lucid):
status: New → Triaged
Changed in apache2 (Ubuntu Maverick):
status: New → Triaged
Changed in apache2 (Ubuntu Lucid):
importance: Undecided → Medium
Changed in apache2 (Ubuntu Maverick):
importance: Undecided → Medium
Changed in apache2 (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Scott Moser (smoser) wrote :

Thank you for taking the time to create a detailed bug report. In the future, some using 'ubuntu-bug apache2' would collect some other information that might be helpful to developers looking to find a fix. In this case, it would have included release information.

And just as a warning, I would guess by your 'apache -v' output that you're running karmic (9.10) which is no longer supported. You should upgrade to lucid to continue to receive security updates.

Revision history for this message
Rolf Leggewie (r0lf) wrote :

maverick has seen the end of its life and is no longer receiving any updates. Marking the maverick task for this ticket as "Won't Fix".

Changed in apache2 (Ubuntu Maverick):
status: Triaged → Won't Fix
Revision history for this message
Rolf Leggewie (r0lf) wrote :

lucid has seen the end of its life and is no longer receiving any updates. Marking the lucid task for this ticket as "Won't Fix".

Changed in apache2 (Ubuntu Lucid):
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.