[squid-dev] [PATCH] ICAP trailer support

Eduard Bagdasaryan eduard.bagdasaryan at measurement-factory.com
Sat Nov 12 18:01:38 UTC 2016


2016-11-11 8:27 GMT+03:00 Amos Jeffries <squid3 at treenet.co.nz>:

 > In Adaptation::Icap::ModXact::expectIcapTrailers() please use
 > getByIdIfPresent(Http::TRAILER, ...) since Trailer is a registered
 > header.

Fixed.

 > In answer to "TODO: should we add a new Http::scInvalidTrailer?" only if
 > the draft defines an HTTP 5xx status code called "Ivalid > Trailer".
 > Since the Http::sc* are HTTP status codes.

The draft does not define HTTP 5xx status codes for invalid trailers.
Also please note that scInvalidHeader (600 code) is marked for
internal/Squid-only use. Probably we could similarly use
scInvalidTrailer with code 602 (for example).

 > Only if all the callers of this function are handling the case where it
 > produces non-1 and adding a terminator LF explicitly for a re-parse
 > attempt.

I have only found such 're-parse' logic inside
HttpStateData::processReplyHeader(), marked with the comment. However
this code does not use the patch-affected HttpHeader::parse(): it uses
Http::One::Parser::grabMimeBlock() instead. So, nothing to fix here, IMO.


Eduard.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: SQUID-157-parse-icap-trailer-t9.patch
Type: text/x-patch
Size: 57149 bytes
Desc: not available
URL: <http://lists.squid-cache.org/pipermail/squid-dev/attachments/20161112/b927e240/attachment-0001.bin>


More information about the squid-dev mailing list