Technically, the two connections can be maintained independently, but since we
are pretending to be a dumb tunnel to the origin server, it is useful to have
the client close when the server does because it reduces both the number of
persistent connection races (zero replies on the server side that force us to
re-connect and re-forward the failed request) and the possibility that we will
reconnect to the wrong HTTPS server without client knowing.
} else if (fdUsageHigh()&& !request->flags.must_keepalive) {
debugs(88, 3, "clientBuildReplyHeader: Not many unused FDs, can't keep-alive");
request->flags.proxy_keepalive = 0;
+ } else if (request->flags.sslBumped && !reply->persistent()) {
+ // We do not really have to close, but we pretend we are a tunnel.
+ debugs(88, 3, "clientBuildReplyHeader: bumped reply forces close");
+ request->flags.proxy_keepalive = 0;
}
// Decide if we send chunked reply