[squid-users] ESI requests contain invalid content-length header

From: Duncan Booth <kupuguy_at_gmail.com>
Date: Fri, 03 Jul 2009 10:59:36 +0100

I've noticed a problem when pages returned as a result of a POST
contain esi:include directives: the included content is fetched using
GET but the content-length header from the original POST is forwarded
to the server. Our backend server is running IIS and this rejects the
request as invalid.

Since we're still running squid 2.6 and I haven't had time to check
whether the problem still exists in more recent versions I'm not
submitting a bug report just yet, but thought it still worth sending
to the list just in case anyone else gets the same problem.

We do have a workaround: the ESI requests also pass through squid so I
added a rule to strip out the content-length header:

    acl get_requests method GET
    acl esi_content urlpath_regex -i /esi/.*\.aspx
    request_header_access Content-Length deny get_requests esi_content

Duncan
Received on Fri Jul 03 2009 - 09:59:35 MDT

This archive was generated by hypermail 2.2.0 : Fri Jul 03 2009 - 12:00:02 MDT