PeekingPeerConnector.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2021 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #ifndef SQUID_SRC_SSL_PEEKINGPEERCONNECTOR_H
10 #define SQUID_SRC_SSL_PEEKINGPEERCONNECTOR_H
11 
12 #include "security/PeerConnector.h"
13 
14 #if USE_OPENSSL
15 
16 namespace Ssl
17 {
18 
22 public:
24  const Comm::ConnectionPointer &aServerConn,
25  const Comm::ConnectionPointer &aClientConn,
26  AsyncCall::Pointer &aCallback,
27  const AccessLogEntryPointer &alp,
28  time_t timeout = 0);
29 
30  /* Security::PeerConnector API */
31  virtual bool initialize(Security::SessionPointer &);
33  virtual void noteWantWrite();
35  virtual void noteNegotiationDone(ErrorState *error);
36 
40 
43  void checkForPeekAndSplice();
44 
47 
49  void checkForPeekAndSpliceMatched(const Ssl::BumpMode finalMode);
50 
53 
57 
59  void startTunneling();
60 
62  static void cbCheckForPeekAndSpliceDone(Acl::Answer, void *data);
63 
64 private:
65 
68 
71  bool splice;
73 };
74 
75 } // namespace Ssl
76 
77 #endif /* USE_OPENSSL */
78 #endif /* SQUID_SRC_SSL_PEEKINGPEERCONNECTOR_H */
79 
virtual void noteNegotiationDone(ErrorState *error)
void startTunneling()
Abruptly stops TLS negotiation and starts tunneling.
std::shared_ptr< SSL_CTX > ContextPointer
Definition: Context.h:29
void error(char *format,...)
BumpMode
Definition: support.h:126
Ssl::BumpMode checkForPeekAndSpliceGuess() const
Guesses the final bumping decision when no ssl_bump rules match.
virtual bool initialize(Security::SessionPointer &)
A PeerConnector for HTTP origin servers. Capable of SslBumping.
PeekingPeerConnector(HttpRequestPointer &aRequest, const Comm::ConnectionPointer &aServerConn, const Comm::ConnectionPointer &aClientConn, AsyncCall::Pointer &aCallback, const AccessLogEntryPointer &alp, time_t timeout=0)
bool splice
whether we are going to splice or not
Definition: Xaction.cc:49
AsyncCall::Pointer closeHandler
we call this when the connection closed
Comm::ConnectionPointer clientConn
TCP connection to the client.
bool serverCertificateHandled
whether handleServerCertificate() succeeded
std::shared_ptr< SSL > SessionPointer
Definition: Session.h:49
virtual Security::ContextPointer getTlsContext()
void checkForPeekAndSpliceDone(Acl::Answer)
Callback function for ssl_bump acl check in step3 SSL bump step.
static void cbCheckForPeekAndSpliceDone(Acl::Answer, void *data)
A wrapper function for checkForPeekAndSpliceDone for use with acl.
CBDATA_CLASS(PeekingPeerConnector)
void checkForPeekAndSpliceMatched(const Ssl::BumpMode finalMode)
Handles the final bumping decision.
virtual void noteNegotiationError(const Security::ErrorDetailPointer &)
Called when the SSL_connect function aborts with an SSL negotiation error.
void tunnelInsteadOfNegotiating()
Inform caller class that the SSL negotiation aborted.

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors