You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2012/11/18 12:39:10 UTC

[Bug 54163] New: Issue in content length header of response

https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

            Bug ID: 54163
           Summary: Issue in content length header of response
           Product: Apache httpd-2
           Version: 2.2.21
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: critical
          Priority: P2
         Component: Core
          Assignee: bugs@httpd.apache.org
          Reporter: shivaprasad.s@trianz.com
    Classification: Unclassified

Dear Team,

We have a filter which is sending response back to the server with entity, the
datagram has content-length header already but the Apache 2.2.21 is adding
content length again to the http header.

Say if the existing content-length header has 140, its adding 142 as an
additional content length header, which is causing issue in Chrome browser
which is restricting the multiple content length header with different values.

Can you please advise on this.

Please let me know for further details.

Thank you!

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Ruediger Pluem <rp...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |WORKSFORME

--- Comment #6 from Eric Covener <co...@gmail.com> ---
Never reported anywhere else, closing.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

--- Comment #2 from Shivaprasad <sh...@trianz.com> ---
Thanks for the reply!

Below are the headers passsed to Apache by setting the content and headers for
http response.

expires:0
pragma:no-cache
cache-control=no-store, no-cache, private
content-type=text/html
content-length=140
<html>......</html>

HTTP headers passed to Browser from Apache webserver:

expires:0
pragma:no-cache
cache-control=no-store, no-cache, private
content-type=text/html
content-length=140
expires:0
pragma:no-cache
cache-control=no-store, no-cache, private
content-type=text/html
content-length=142  (Issue is here, the content length is 2 bytes extra)
keep-alive: time-out=5, max=95
Connection: keep-alive
<html>......</html>

Can you please suggest whether we can do any thing for this,by adding
additional transfer-code header or any alternative if available..

Thank you!

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #1 from Eric Covener <co...@gmail.com> ---
Can you post an example module and headers it generates?  When does your filter
run and how does it set the content length?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Shivaprasad <sh...@trianz.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |shivaprasad.s@trianz.com

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

--- Comment #4 from Ruediger Pluem <rp...@apache.org> ---
How do you generate your headers? Via apr_table_set(n)(r->headers_out, ...)?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Shivaprasad <sh...@trianz.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

--- Comment #3 from Ruediger Pluem <rp...@apache.org> ---
Try to omit the content length calculation in your filter and let httpd do
this. If it can't it will switch to chunked encoding automatically.
Regarding the two byte difference: The httpd code counts the amount of data
that is sent as body. So if its two bytes more then your filter is calculating
you likely have a bug in your filter or the content is changed again by a
following filter.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


[Bug 54163] Issue in content length header of response

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54163

Shivaprasad <sh...@trianz.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #5 from Shivaprasad <sh...@trianz.com> ---
Yes we are using the apr_table_set ((req_rec)?req_rec->headers_out:NULL, name,
(value?value:""));
(In reply to comment #4)
> How do you generate your headers? Via apr_table_set(n)(r->headers_out, ...)?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org