Fix a logic bug that could cause Privoxy to reuse a tainted server socket
authorFabian Keil <fk@fabiankeil.de>
Sun, 16 Oct 2011 12:40:34 +0000 (12:40 +0000)
committerFabian Keil <fk@fabiankeil.de>
Sun, 16 Oct 2011 12:40:34 +0000 (12:40 +0000)
commit9f64327796090c2d4c10400df689ef0eedf78ab6
treef5f861f52c4cdb7827a8b48e3c0f951b62a05149
parent8931748f574279927c586ce0096edf77eff94147
Fix a logic bug that could cause Privoxy to reuse a tainted server socket

It could happen for server sockets that got tainted by a
server-header-tagger-induced block, in which case Privoxy
doesn't necessarily read the whole server response.

If keep-alive was enabled and the request following the
blocked one was to the same host and using the same
forwarding settings, Privoxy would send it on the tainted
server socket.

While the server would simply treat it as a pipelined request,
Privoxy would later on fail to properly parse the server's
response as it would try to parse the unread data from the
first response as server headers for the second one.

Regression introduced in jcc.c,v 1.315.
jcc.c