client_side.cc
Go to the documentation of this file.
158 typedef void (*Handler)(AnyP::PortCfgPointer &portCfg, const Ipc::FdNoteId note, const Subscription::Pointer &sub);
159 ListeningStartedDialer(Handler aHandler, AnyP::PortCfgPointer &aPortCfg, const Ipc::FdNoteId note, const Subscription::Pointer &aSub):
184static void clientListenerConnectionOpened(AnyP::PortCfgPointer &s, const Ipc::FdNoteId portTypeNote, const Subscription::Pointer &sub);
197static void ClientSocketContextPushDeferredIfNeeded(Http::StreamPointer deferredRequest, ConnStateData * conn);
411 al->cache.objectSize = loggingEntry()->contentLen(); // payload duplicate ?? with or without TE ?
419 al->http.clientReplySz.payloadData = out.size - out.headers_sz; // pretend its all un-encoded data for now.
531 debugs(33, 2, "WARNING: Ignoring duplicate connection-auth for " << clientConnection << " from " << by);
572 debugs(33, 2, "WARNING: Graceful closure on " << clientConnection << " due to connection-auth erase from " << by);
575 // XXX: need to test whether the connection re-auth challenge is sent. If not, how to trigger it from here.
576 // NP: the current situation seems to fix challenge loops in Safari without visible issues in others.
577 // we stop receiving more traffic but can leave the Job running to terminate after the error or challenge is delivered.
584 debugs(33, 2, "ERROR: Closing " << clientConnection << " due to change of connection-auth from " << by);
601 AsyncCall::Pointer callback = JobCallback(33, 5, TimeoutDialer, this, ConnStateData::requestTimeout);
609 AsyncCall::Pointer callback = JobCallback(5, 4, TimeoutDialer, this, ConnStateData::lifetimeTimeout);
676 debugs(33, DBG_IMPORTANT, "ERROR: Squid BUG: ConnStateData did not close " << clientConnection);
679 debugs(33, DBG_IMPORTANT, "ERROR: Squid BUG: ConnStateData was not destroyed properly; " << clientConnection);
733clientPackRangeHdr(const HttpReplyPointer &rep, const HttpHdrRangeSpec * spec, String boundary, MemBuf * mb)
784 debugs(33, 6, "clientMRangeCLen: (clen += " << mb.size << " + " << (*pos)->length << ") == " << clen);
828 if (!http->getConn() || !cbdataReferenceValid(http->getConn()) || !Comm::IsConnOpen(http->getConn()->clientConnection))
896ClientSocketContextPushDeferredIfNeeded(Http::StreamPointer deferredRequest, ConnStateData * conn)
926 debugs(33, 2, clientConnection << " Connection was pinned but server side gone. Terminating client connection");
1118 static const CharacterSet uriScheme = CharacterSet("URI-scheme","+-.") + CharacterSet::ALPHA + CharacterSet::DIGIT;
1169 snprintf(uri, url_sz, SQUIDSBUFPH "://" SQUIDSBUFPH SQUIDSBUFPH, SQUIDSBUFPRINT(scheme), SQUIDSBUFPRINT(host), SQUIDSBUFPRINT(url));
1173 debugs(33, 5, "ACCEL DEFAULTSITE REWRITE: defaultsite=" << conn->port->defaultsite << " + vport=" << vport);
1180 const int url_sz = scheme.length() + strlen(conn->port->defaultsite) + sizeof(vportStr) + url.length() + 32;
1281 /* Attempt to parse the first line; this will define where the method, url, version and header begin */
1320 debugs(33, DBG_IMPORTANT, "WARNING: CONNECT method received on " << transferProtocol << " Accelerator port " << port->s.port());
1321 debugs(33, DBG_IMPORTANT, "WARNING: for request: " << hp->method() << " " << hp->requestUri() << " " << hp->messageProtocol());
1331 debugs(33, DBG_IMPORTANT, "WARNING: PRI method received on " << transferProtocol << " port " << port->s.port());
1332 debugs(33, DBG_IMPORTANT, "WARNING: for request: " << hp->method() << " " << hp->requestUri() << " " << hp->messageProtocol());
1338 debugs(33, DBG_IMPORTANT, "WARNING: Unsupported method: " << hp->method() << " " << hp->requestUri() << " " << hp->messageProtocol());
1505 const auto sslErrors = std::make_unique<Security::CertErrors>(Security::CertError(SQUID_X509_V_ERR_DOMAIN_MISMATCH, srvCert));
1521 const auto err = new ErrorState(ERR_SECURE_CONNECT_FAIL, Http::scServiceUnavailable, request, http->al);
1580 if (request != nullptr && request->flags.resetTcp && Comm::IsConnOpen(conn->clientConnection)) {
1588clientProcessRequest(ConnStateData *conn, const Http1::RequestParserPointer &hp, Http::Stream *context)
1614 ((request->flags.sslBumped || conn->port->transport.protocol == AnyP::PROTO_HTTPS) ? Http::Message::srcHttps : Http::Message::srcHttp);
1654 repContext->setReplyToError(ERR_INVALID_REQ, frameStatus, nullptr, conn, request.getRaw(), nullptr, nullptr);
1765 debugs(33, 3, clientConnection << " max concurrent requests reached (" << concurrentRequestLimit << ")");
1832 debugs(33, 5, "PROXY/" << proxyProtocolHeader_->version() << " upgrade: " << clientConnection);
1923 debugs(33, 5, "monitoring half-closed while processing parsed requests: " << clientConnection);
2103 const err_type error = receivedFirstByte_ ? ERR_REQUEST_PARSE_TIMEOUT : ERR_REQUEST_START_TIMEOUT;
2159 debugs(33, 2, "WARNING: Path MTU discovery disabling failed on " << clientConnection << " : " << xstrerr(xerrno));
2165 debugs(33, DBG_IMPORTANT, "WARNING: Path MTU discovery disabling is not supported on your platform.");
2325 debugs(83, (handshakeResult.important ? Important(62) : 2), "ERROR: " << handshakeResult.errorDescription <<
2326 " while accepting a TLS connection on " << conn->clientConnection << ": " << handshakeResult.errorDetail);
2371 debugs(83, 4, "With " OPENSSL_VERSION_TEXT ", session details are available only defining ALLOW_ALWAYS_SSL_SESSION_DETAIL=1 in the source.");
2450 debugs(33, 2, "sslBump action " << Ssl::bumpMode(answer.kind) << "needed for " << connState->clientConnection);
2477 debugs(33, 2, "httpsAccept: " << params.port->listenConn << ": accept failure: " << xstrerr(params.xerrno));
2521 ACLFilledChecklist *acl_checklist = new ACLFilledChecklist(Config.accessList.ssl_bump, request, nullptr);
2560 debugs(33, 3, "Connection gone while waiting for ssl_crtd helper reply; helper reply:" << reply);
2565 debugs(33, 5, "Certificate for " << tlsConnectHostOrIp << " cannot be generated. ssl_crtd response: " << reply);
2570 if (reply_message.parse(reply.other().content(), reply.other().contentSize()) != Ssl::CrtdMessage::OK) {
2574 debugs(33, 5, "Certificate for " << tlsConnectHostOrIp << " cannot be generated. ssl_crtd response: " << reply_message.getBody());
2576 debugs(33, 5, "Certificate for " << tlsConnectHostOrIp << " was successfully received from ssl_crtd");
2577 if (sslServerBump && (sslServerBump->act.step1 == Ssl::bumpPeek || sslServerBump->act.step1 == Ssl::bumpStare)) {
2580 bool ret = Ssl::configureSSLUsingPkeyAndCertFromMemory(ssl, reply_message.getBody().c_str(), *port);
2587 Security::ContextPointer ctx(Ssl::GenerateSslContextUsingPkeyAndCertFromMemory(reply_message.getBody().c_str(), port->secure, (signAlgorithm == Ssl::algSignTrusted)));
2602 certProperties.commonName = sslCommonName_.isEmpty() ? tlsConnectHostOrIp.c_str() : sslCommonName_.c_str();
2676ConnStateData::getTlsContextFromCache(const SBuf &cacheKey, const Ssl::CertificateProperties &certProperties)
2679 Ssl::LocalContextStorage * ssl_ctx_cache = Ssl::TheGlobalContextStorage.getLocalStorage(port->s);
2685 debugs(33, 5, "Cached SSL certificate for " << certProperties.commonName << " is out of date. Delete this certificate from cache");
2696 Ssl::LocalContextStorage *ssl_ctx_cache = Ssl::TheGlobalContextStorage.getLocalStorage(port->s);
2711 if (!(sslServerBump && (sslServerBump->act.step1 == Ssl::bumpPeek || sslServerBump->act.step1 == Ssl::bumpStare))) {
2725 debugs(33, 5, "Generating SSL certificate for " << certProperties.commonName << " using ssl_crtd.");
2742 if (sslServerBump && (sslServerBump->act.step1 == Ssl::bumpPeek || sslServerBump->act.step1 == Ssl::bumpStare)) {
2751 Security::ContextPointer dynCtx(Ssl::GenerateSslContext(certProperties, port->secure, (signAlgorithm == Ssl::algSignTrusted)));
2773 debugs(83, DBG_IMPORTANT, "Closing " << clientConnection->remote << " as lacking TLS context");
2911 if (!sslServerBump || sslServerBump->act.step1 == Ssl::bumpClientFirst) { // Either means client-first.
2920 FwdState::Start(clientConnection, sslServerBump->entry, sslServerBump->request.getRaw(), http ? http->al : nullptr);
3004 ACLFilledChecklist *acl_checklist = new ACLFilledChecklist(Config.accessList.ssl_bump, sslServerBump->request.getRaw(), nullptr);
3014 Security::ContextPointer unConfiguredCTX(Ssl::createSSLContext(port->secure.signingCa.cert, port->secure.signingCa.pkey, port->secure));
3044 FwdState::Start(clientConnection, sslServerBump->entry, sslServerBump->request.getRaw(), http ? http->al : nullptr);
3073 debugs(83, (handshakeResult.important ? DBG_IMPORTANT : 2), "ERROR: " << handshakeResult.errorDescription <<
3074 " while SslBump-accepting a TLS connection on " << clientConnection << ": " << handshakeResult.errorDetail);
3092 debugs(33, 5, "PeekAndSplice mode, proceed with client negotiation. Current state:" << SSL_state_string_long(ssl));
3104 Must(pipeline.empty() || pipeline.front()->http == nullptr || pipeline.front()->http->request == pic.request.getRaw());
3118ConnStateData::initiateTunneledRequest(HttpRequest::Pointer const &cause, const char *reason, const SBuf &payload)
3194ConnStateData::buildFakeRequest(SBuf &useHost, const AnyP::KnownPort usePort, const SBuf &payload)
3231 request->sources |= ((switchedToHttps() || port->transport.protocol == AnyP::PROTO_HTTPS) ? Http::Message::srcHttps : Http::Message::srcHttp);
3289 debugs(33, DBG_IMPORTANT, "WARNING: No ssl_bump configured. Disabling ssl-bump on " << scheme << "_port " << s->s);
3293 debugs(1, DBG_IMPORTANT, "Will not bump SSL at " << scheme << "_port " << s->s << " due to TLS initialization failure.");
3306 debugs(1, DBG_CRITICAL, "ERROR: Ignoring " << scheme << "_port " << s->s << " due to TLS context initialization failure.");
3322clientStartListeningOn(AnyP::PortCfgPointer &port, const RefCount< CommCbFunPtrCallT<CommAcceptCbPtrFun> > &subCall, const Ipc::FdNoteId fdNote)
3350clientListenerConnectionOpened(AnyP::PortCfgPointer &s, const Ipc::FdNoteId portTypeNote, const Subscription::Pointer &sub)
3370 Must(AddOpenedHttpSocket(s->listenConn)); // otherwise, we have received a fd we did not ask for
3555 return clientConnection != nullptr && (clientConnection->flags & (COMM_TRANSPARENT|COMM_INTERCEPTION));
3671 AsyncCall::Pointer call = JobCallback(33, 5, Dialer, this, HttpControlMsgSink::wroteControlMsg);
3715ConnStateData::pinBusyConnection(const Comm::ConnectionPointer &pinServer, const HttpRequest::Pointer &request)
3736ConnStateData::pinConnection(const Comm::ConnectionPointer &pinServer, const HttpRequest &request)
3824 debugs(83, DBG_IMPORTANT, pinning.serverConnection << " TLS SSL_ERROR_WANT_WRITE request for idle pinned connection");
3943 /* NOTE: pinning.pinned should be kept. This combined with fd == -1 at the end of a request indicates that the host
4049std::ostream &
4055std::ostream &
void accessLogLog(const AccessLogEntryPointer &, ACLChecklist *)
Definition: access_log.cc:136
RefCount< AsyncCallT< Dialer > > asyncCall(int aDebugSection, int aDebugLevel, const char *aName, const Dialer &aDialer)
Definition: AsyncCall.h:156
#define JobCallback(dbgSection, dbgLevel, Dialer, job, method)
Convenience macro to create a Dialer-based job callback.
Definition: AsyncJobCalls.h:69
CommCbFunPtrCallT< Dialer > * commCbCall(int debugSection, int debugLevel, const char *callName, const Dialer &dialer)
Definition: CommCalls.h:312
ErrorDetail::Pointer MakeNamedErrorDetail(const char *name)
Definition: Detail.cc:54
void httpHeaderAddContRange(HttpHeader *, HttpHdrRangeSpec, int64_t)
Definition: HttpHeaderTools.cc:76
std::ostream & CurrentException(std::ostream &os)
prints active (i.e., thrown but not yet handled) exception
Definition: TextException.cc:88
@ tlsBump1
@ tlsBump2
@ tlsBump3
void error(char *format,...)
void banAction(const Acl::Answer &action)
add action to the list of banned actions
Definition: Checklist.cc:395
void nonBlockingCheck(ACLCB *callback, void *callback_data)
Definition: Checklist.cc:237
Definition: FilledChecklist.h:32
void setIdent(const char *userIdentity)
configure rfc931 user identity for the first time
Definition: FilledChecklist.cc:255
void setRequest(HttpRequest *)
configure client request-related fields for the first time
Definition: FilledChecklist.cc:236
CbcPointer< Security::CertErrors > sslErrors
Definition: FilledChecklist.h:94
AccessLogEntry::Pointer al
info for the future access.log, and external ACL
Definition: FilledChecklist.h:101
void syncAle(HttpRequest *adaptedRequest, const char *logUri) const override
assigns uninitialized adapted_request and url ALE components
Definition: FilledChecklist.cc:121
char * last_meta
image of the last ICAP response header or eCAP meta received
Definition: AccessLogEntry.h:187
MessageSizes clientRequestSz
counters for the original request received from client
Definition: AccessLogEntry.h:103
Definition: AccessLogEntry.h:41
class AccessLogEntry::CacheDetails cache
class AccessLogEntry::IcapLogEntry icap
class AccessLogEntry::Headers headers
Comm::ConnectionPointer tcpClient
TCP/IP level details about the client connection.
Definition: AccessLogEntry.h:83
class AccessLogEntry::HttpDetails http
class AccessLogEntry::AdaptationDetails adapt
class AccessLogEntry::IcpDetails icp
ProxyProtocol::HeaderPointer proxyProtocolHeader
see ConnStateData::proxyProtocolHeader_
Definition: AccessLogEntry.h:210
void updateError(const Error &)
sets (or updates the already stored) transaction error as needed
Definition: AccessLogEntry.cc:212
Definition: Acl.h:128
HttpHeader lastMeta
Last received meta header (REQMOD or RESPMOD, whichever comes last).
Definition: History.h:61
Definition: ProtocolVersion.h:24
Definition: UriScheme.h:32
void setScheme(const AnyP::ProtocolType &p, const char *str)
convert the URL scheme to that given
Definition: Uri.h:70
Definition: AsyncCall.h:41
a smart AsyncCall pointer for delivery of future results
Definition: AsyncCallbacks.h:32
Definition: AsyncJob.h:32
virtual void callException(const std::exception &e)
called when the job throws during an async call
Definition: AsyncJob.cc:143
Definition: BodyPipe.h:62
Definition: BodyPipe.h:91
void enableAutoConsumption()
start or continue consuming when producing without consumer
Definition: BodyPipe.cc:316
void stopProducingFor(RefCount< BodyPipe > &, bool atEof)
Definition: BodyPipe.cc:107
Definition: CachePeer.h:31
Definition: AsyncCall.h:107
Definition: Subscription.h:49
optimized set of C chars, with quick membership test and merge support
Definition: CharacterSet.h:18
std::vector< ClientDelayPool::Pointer > pools
Definition: ClientDelayConfig.h:47
Definition: client_side_request.h:38
struct ClientHttpRequest::Out out
void clearRequest()
resets the current request and log_uri to nil
Definition: client_side_request.cc:1682
void initRequest(HttpRequest *)
Definition: client_side_request.cc:1609
void checkForInternalAccess()
Checks whether the current request is internal and adjusts it accordingly.
Definition: client_side_request.cc:1648
void updateError(const Error &)
if necessary, stores new error information (if any)
Definition: client_side_request.cc:1568
size_t req_sz
raw request size on input, not current request size
Definition: client_side_request.h:162
struct ClientHttpRequest::Flags flags
bool multipartRangeRequest() const
Definition: client_side.cc:720
ClientRequestContext * calloutContext
Definition: client_side_request.h:179
const LogTags & loggingTags() const
the processing tags associated with this request transaction.
Definition: client_side_request.h:97
StoreEntry * loggingEntry() const
Definition: client_side_request.h:68
struct ClientHttpRequest::Redirect redirect
Definition: ClientInfo.h:34
void setWriteLimiter(const int aWriteSpeedLimit, const double anInitialBurst, const double aHighWatermark)
Definition: comm.cc:1376
Definition: ClientRequestContext.h:29
Definition: ClpMap.h:41
static void Reset()
forgets the current context, setting it to nil/unknown
Definition: CodeContext.cc:77
Definition: CommCalls.h:93
AnyP::PortCfgPointer port
the configuration listening port this call relates to (may be nil)
Definition: CommCalls.h:100
Definition: CommCalls.h:196
Definition: CommCalls.h:281
Definition: CommCalls.h:166
Definition: CommCalls.h:128
Definition: CommCalls.h:114
Definition: CommCalls.h:134
time_t timeLeft(const time_t idleTimeout) const
Definition: Connection.cc:146
Security::NegotiationHistory * tlsNegotiations()
Definition: Connection.cc:156
Definition: TcpAcceptor.h:39
parameters for the async notePinnedConnectionBecameIdle() call
Definition: client_side.h:183
HttpRequest::Pointer request
to-server request that initiated serverConnection
Definition: client_side.h:188
noteTakeServerConnectionControl() callback parameter
Definition: client_side.h:213
Definition: client_side.h:84
virtual int pipelinePrefetchMax() const
returning N allows a pipeline of 1+N requests (see pipeline_prefetch)
Definition: client_side.cc:1736
void postHttpsAccept()
the second part of old httpsAccept, waiting for future HttpsServer home
Definition: client_side.cc:2494
bool fakeAConnectRequest(const char *reason, const SBuf &payload)
Definition: client_side.cc:3165
virtual void clientPinnedConnectionClosed(const CommCloseCbParams &io)
Our close handler called by Comm when the pinned connection is closed.
Definition: client_side.cc:3697
char * prepareTlsSwitchingURL(const Http1::RequestParserPointer &hp)
Definition: client_side.cc:1220
Security::KeyLogger keyLogger
managers logging of the being-accepted TLS connection secrets
Definition: client_side.h:384
void afterClientRead() override
processing to be done after a Comm::Read()
Definition: client_side.cc:1930
Ssl::ServerBump * sslServerBump
HTTPS server cert. fetching state for bump-ssl-server-first.
Definition: client_side.h:494
Http::Stream * parseHttpRequest(const Http1::RequestParserPointer &)
Definition: client_side.cc:1279
virtual bool writeControlMsgAndCall(HttpReply *rep, AsyncCall::Pointer &call)=0
handle a control message received by context from a peer and call back
void switchToHttps(ClientHttpRequest *, Ssl::BumpMode bumpServerMode)
Definition: client_side.cc:2801
void startPinnedConnectionMonitoring()
Definition: client_side.cc:3781
const char * stoppedReceiving() const
true if we stopped receiving the request
Definition: client_side.h:159
void consumeInput(const size_t byteCount)
remove no longer needed leading bytes from the input buffer
Definition: client_side.cc:1433
void clientAfterReadingRequests()
Definition: client_side.cc:1441
ClientHttpRequest * buildFakeRequest(SBuf &useHost, AnyP::KnownPort usePort, const SBuf &payload)
build a fake http request
Definition: client_side.cc:3194
virtual void handleReply(HttpReply *header, StoreIOBuffer receivedData)=0
void setAuth(const Auth::UserRequest::Pointer &aur, const char *cause)
Definition: client_side.cc:518
virtual Http::Stream * parseOneRequest()=0
void sendControlMsg(HttpControlMsg) override
called to send the 1xx message and notify the Source
Definition: client_side.cc:3651
const Auth::UserRequest::Pointer & getAuth() const
Definition: client_side.h:123
void getSslContextStart()
Start to create dynamic Security::ContextPointer for host or uses static port SSL context.
Definition: client_side.cc:2704
void httpsPeeked(PinnedIdleContext pic)
called by FwdState when it is done bumping the server
Definition: client_side.cc:3100
bool initiateTunneledRequest(HttpRequest::Pointer const &cause, const char *reason, const SBuf &payload)
generates and sends to tunnel.cc a fake request with a given payload
Definition: client_side.cc:3118
bool splice()
Splice a bumped client connection on peek-and-splice mode.
Definition: client_side.cc:2959
SBuf tlsClientSni_
TLS client delivered SNI value. Empty string if none has been received.
Definition: client_side.h:490
Error bareError
a problem that occurred without a request (e.g., while parsing headers)
Definition: client_side.h:381
void expectNoForwarding()
cleans up virgin request [body] forwarding state
Definition: client_side.cc:3608
Http::Stream * abortRequestParsing(const char *const errUri)
stop parsing the request and create context for relaying error info
Definition: client_side.cc:1022
void sslCrtdHandleReply(const Helper::Reply &reply)
Process response from ssl_crtd.
Definition: client_side.cc:2557
err_type handleChunkedRequestBody()
parses available chunked encoded body bytes, checks size, returns errors
Definition: client_side.cc:2013
void resetSslCommonName(const char *name)
Definition: client_side.h:293
void afterClientWrite(size_t) override
processing to sync state after a Comm::Write()
Definition: client_side.cc:1007
void terminateAll(const Error &, const LogTagsErrors &) override
abort any pending transactions and prevent new ones (by closing)
Definition: client_side.cc:3948
void abortChunkedRequestBody(const err_type error)
quit on errors related to chunked request body handling
Definition: client_side.cc:2054
void pinConnection(const Comm::ConnectionPointer &pinServerConn, const HttpRequest &request)
Forward future client requests using the given server connection.
Definition: client_side.cc:3736
bool preservingClientData_
whether preservedClientData is valid and should be kept up to date
Definition: client_side.h:434
void callException(const std::exception &) override
called when the job throws during an async call
Definition: client_side.cc:639
static void sslCrtdHandleReplyWrapper(void *data, const Helper::Reply &reply)
Callback function. It is called when squid receive message from ssl_crtd.
Definition: client_side.cc:2550
void lifetimeTimeout(const CommTimeoutCbParams ¶ms)
Definition: client_side.cc:2121
Security::ContextPointer getTlsContextFromCache(const SBuf &cacheKey, const Ssl::CertificateProperties &certProperties)
Definition: client_side.cc:2676
AnyP::Port tlsConnectPort
The TLS server port number as passed in the CONNECT request.
Definition: client_side.h:486
Auth::UserRequest::Pointer auth_
some user details that can be used to perform authentication on this connection
Definition: client_side.h:474
Comm::ConnectionPointer borrowPinnedConnection(HttpRequest *, const AccessLogEntryPointer &)
ConnStateData-specific part of BorrowPinnedConnection()
Definition: client_side.cc:3874
bool shouldPreserveClientData() const
Definition: client_side.cc:4010
void notePinnedConnectionBecameIdle(PinnedIdleContext pic)
Called when a pinned connection becomes available for forwarding the next request.
Definition: client_side.cc:3721
void stopPinnedConnectionMonitoring()
The caller assumes responsibility for connection closure detection.
Definition: client_side.cc:3793
void pinBusyConnection(const Comm::ConnectionPointer &pinServerConn, const HttpRequest::Pointer &request)
Definition: client_side.cc:3715
bool handleIdleClientPinnedTlsRead()
Definition: client_side.cc:3803
bool proxyProtocolError(const char *reason)
Definition: client_side.cc:1798
bool serveDelayedError(Http::Stream *)
Definition: client_side.cc:1467
struct ConnStateData::@37 pinning
const char * stoppedSending_
the reason why we no longer write the response or nil
Definition: client_side.h:499
void resetReadTimeout(time_t timeout)
(re)sets timeout for receiving more bytes from the client
Definition: client_side.cc:598
void quitAfterError(HttpRequest *request)
Definition: client_side.cc:1455
SBuf tlsConnectHostOrIp
The TLS server host name appears in CONNECT request or the server ip address for the intercepted requ...
Definition: client_side.h:485
struct ConnStateData::@36 flags
void receivedFirstByte() override
Update flags and timeout after the first byte received.
Definition: client_side.cc:1844
uint64_t parsedBumpedRequestCount
The number of parsed HTTP requests headers on a bumped client connection.
Definition: client_side.h:481
BodyPipe::Pointer expectRequestBody(int64_t size)
Definition: client_side.cc:3559
void clientPinnedConnectionRead(const CommIoCbParams &io)
Definition: client_side.cc:3845
static Comm::ConnectionPointer BorrowPinnedConnection(HttpRequest *, const AccessLogEntryPointer &)
Definition: client_side.cc:3905
void stopReceiving(const char *error)
note request receiving error and close as soon as we write the response
Definition: client_side.cc:3588
void checkLogging()
log the last (attempt at) transaction if nobody else did
Definition: client_side.cc:3991
void unpinConnection(const bool andClose)
Undo pinConnection() and, optionally, close the pinned connection.
Definition: client_side.cc:3917
void handleSslBumpHandshakeError(const Security::IoResult &)
process a problematic Security::Accept() result on the SslBump code path
Definition: client_side.cc:3049
void startPeekAndSplice()
Initializes and starts a peek-and-splice negotiation with the SSL client.
Definition: client_side.cc:2993
bool concurrentRequestQueueFilled() const
Definition: client_side.cc:1750
ConnStateData(const MasterXactionPointer &xact)
Definition: client_side.cc:2131
ProxyProtocol::HeaderPointer proxyProtocolHeader_
the parsed PROXY protocol header
Definition: client_side.h:470
bool shouldCloseOnEof() const override
whether to stop serving our client after reading EOF on its connection
Definition: client_side.cc:1413
void fillChecklist(ACLFilledChecklist &) const override
configure the given checklist (to reflect the current transaction state)
Definition: client_side.cc:3515
void requestTimeout(const CommTimeoutCbParams ¶ms)
Definition: client_side.cc:2098
virtual time_t idleTimeout() const =0
timeout to use when waiting for the next request
void finishDechunkingRequest(bool withSuccess)
put parsed content into input buffer and clean up
Definition: client_side.cc:3628
virtual void processParsedRequest(Http::StreamPointer &)=0
start processing a freshly parsed request
void getSslContextDone(Security::ContextPointer &)
finish configuring the newly created SSL context"