OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
OVSDB::OvsdbClientSsl Class Reference

#include <ovsdb_client_ssl.h>

Inheritance diagram for OVSDB::OvsdbClientSsl:
Collaboration diagram for OVSDB::OvsdbClientSsl:

Public Types

typedef std::pair< Ip4Address,
uint16_t > 
SessionKey
 
typedef std::map< SessionKey,
OvsdbClientSslSession * > 
SessionMap
 
- Public Types inherited from SslServer
typedef
boost::asio::ssl::stream
< boost::asio::ip::tcp::socket > 
SslSocket
 
- Public Types inherited from TcpServer
typedef
boost::asio::ip::tcp::endpoint 
Endpoint
 
typedef
boost::asio::ip::tcp::socket 
Socket
 
typedef
boost::asio::ip::tcp::socket::native_handle_type 
NativeSocketType
 
- Public Types inherited from OVSDB::OvsdbClient
typedef boost::function< void(OvsdbClientSession *)> SessionEventCb
 

Public Member Functions

 OvsdbClientSsl (Agent *agent, IpAddress tor_ip, int tor_port, IpAddress tsn_ip, int keepalive_interval, int ha_stale_route_interval, const std::string &ssl_cert, const std::string &ssl_privkey, const std::string &ssl_cacert, OvsPeerManager *manager)
 
virtual ~OvsdbClientSsl ()
 
virtual SslSessionAllocSession (SslSocket *socket)
 
void RegisterClients ()
 
void OnSessionEvent (TcpSession *session, TcpSession::Event event)
 
const std::string protocol ()
 
const std::string server ()
 
uint16_t port ()
 
Ip4Address tsn_ip ()
 
void shutdown ()
 
OvsdbClientSessionFindSession (Ip4Address ip, uint16_t port)
 
OvsdbClientSessionNextSession (OvsdbClientSession *session)
 
void AddSessionInfo (SandeshOvsdbClient &client)
 
- Public Member Functions inherited from SslServer
 SslServer (EventManager *evm, boost::asio::ssl::context::method m, bool ssl_enabled=true, bool ssl_handshake_delayed=false)
 
virtual ~SslServer ()
 
- Public Member Functions inherited from TcpServer
 TcpServer (EventManager *evm)
 
virtual ~TcpServer ()
 
virtual bool Initialize (unsigned short port)
 
virtual bool Initialize (unsigned short port, const IpAddress &host_ip, int intf_id=-1)
 
bool InitializeInternal (boost::asio::ip::tcp::endpoint localaddr)
 
const std::string ToString () const
 
void SetAcceptor ()
 
void ResetAcceptor ()
 
void Shutdown ()
 
void ClearSessions ()
 
void UpdateSessionsDscp (uint8_t dscp)
 
virtual TcpSessionCreateSession ()
 
virtual void DeleteSession (TcpSession *session)
 
virtual void Connect (TcpSession *session, Endpoint remote)
 
virtual bool DisableSandeshLogMessages () const
 
int GetPort () const
 
const io::SocketStatsGetSocketStats () const
 
size_t GetSessionCount () const
 
EventManagerevent_manager ()
 
bool HasSessionReadAvailable () const
 
bool HasSessions () const
 
TcpSessionGetSession (Endpoint remote)
 
void WaitForEmpty ()
 
void GetRxSocketStats (SocketIOStats *socket_stats) const
 
void GetTxSocketStats (SocketIOStats *socket_stats) const
 
void GetRxSocketStats (SocketIOStats &socket_stats) const
 
void GetTxSocketStats (SocketIOStats &socket_stats) const
 
int SetMd5SocketOption (NativeSocketType fd, uint32_t peer_ip, const std::string &md5_password)
 
int SetListenSocketMd5Option (uint32_t peer_ip, const std::string &md5_password)
 
int SetDscpSocketOption (NativeSocketType fd, uint8_t value)
 
uint8_t GetDscpValue (NativeSocketType fd) const
 
int SetListenSocketDscp (uint8_t value)
 
int SetSocketOptions (const SandeshConfig &sandesh_config)
 
int SetKeepAliveSocketOption (int fd, const SandeshConfig &sandesh_config)
 
- Public Member Functions inherited from OVSDB::OvsdbClient
 OvsdbClient (OvsPeerManager *manager, int keepalive_interval, int ha_stale_route_interval)
 
virtual ~OvsdbClient ()
 
void set_connect_complete_cb (SessionEventCb cb)
 
void set_pre_connect_complete_cb (SessionEventCb cb)
 
void RegisterConnectionTable (Agent *agent)
 
ConnectionStateTableconnection_table ()
 
KSyncObjectManagerksync_obj_manager ()
 
int keepalive_interval () const
 
int ha_stale_route_interval () const
 
void Init ()
 

Private Member Functions

bool AcceptSession (TcpSession *session)
 
 DISALLOW_COPY_AND_ASSIGN (OvsdbClientSsl)
 

Private Attributes

Agentagent_
 
uint32_t ssl_server_port_
 
Ip4Address tsn_ip_
 
bool shutdown_
 
SessionMap session_map_
 

Friends

class OvsdbClientSslSession
 

Additional Inherited Members

- Static Public Member Functions inherited from OVSDB::OvsdbClient
static OvsdbClientAllocate (Agent *agent, TorAgentParam *params, OvsPeerManager *manager)
 
- Static Public Attributes inherited from OVSDB::OvsdbClient
static const uint32_t OVSDBKeepAliveTimer = 10000
 
static const int OVSDBMinKeepAliveTimer = 2000
 
static const uint32_t OVSDBHaStaleRouteTimer = 300000
 
static const int OVSDBMinHaStaleRouteTimer = 60000
 
- Protected Types inherited from TcpServer
typedef boost::intrusive_ptr
< TcpServer
TcpServerPtr
 
typedef boost::intrusive_ptr
< TcpSession
TcpSessionPtr
 
- Protected Member Functions inherited from SslServer
boost::asio::ssl::context * context ()
 
- Protected Member Functions inherited from TcpServer
void set_socket_open_failure (bool flag)
 
bool socket_open_failure () const
 
Endpoint LocalEndpoint () const
 
- Protected Attributes inherited from OVSDB::OvsdbClient
OvsPeerManagerpeer_manager_
 
SessionEventCb connect_complete_cb_
 
SessionEventCb pre_connect_complete_cb_
 

Detailed Description

Definition at line 86 of file ovsdb_client_ssl.h.

Member Typedef Documentation

typedef std::pair<Ip4Address, uint16_t> OVSDB::OvsdbClientSsl::SessionKey

Definition at line 88 of file ovsdb_client_ssl.h.

Constructor & Destructor Documentation

OvsdbClientSsl::OvsdbClientSsl ( Agent agent,
IpAddress  tor_ip,
int  tor_port,
IpAddress  tsn_ip,
int  keepalive_interval,
int  ha_stale_route_interval,
const std::string &  ssl_cert,
const std::string &  ssl_privkey,
const std::string &  ssl_cacert,
OvsPeerManager manager 
)

Definition at line 21 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

OvsdbClientSsl::~OvsdbClientSsl ( )
virtual

Definition at line 63 of file ovsdb_client_ssl.cc.

Member Function Documentation

bool OvsdbClientSsl::AcceptSession ( TcpSession session)
privatevirtual

Reimplemented from TcpServer.

Definition at line 159 of file ovsdb_client_ssl.cc.

void OvsdbClientSsl::AddSessionInfo ( SandeshOvsdbClient &  client)
virtual

Implements OVSDB::OvsdbClient.

Definition at line 146 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

SslSession * OvsdbClientSsl::AllocSession ( SslSocket socket)
virtual

Implements SslServer.

Definition at line 71 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

OVSDB::OvsdbClientSsl::DISALLOW_COPY_AND_ASSIGN ( OvsdbClientSsl  )
private
OvsdbClientSession * OvsdbClientSsl::FindSession ( Ip4Address  ip,
uint16_t  port 
)
virtual

Implements OVSDB::OvsdbClient.

Definition at line 115 of file ovsdb_client_ssl.cc.

OvsdbClientSession * OvsdbClientSsl::NextSession ( OvsdbClientSession session)
virtual

Implements OVSDB::OvsdbClient.

Definition at line 129 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

void OvsdbClientSsl::OnSessionEvent ( TcpSession session,
TcpSession::Event  event 
)

Definition at line 79 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

uint16_t OvsdbClientSsl::port ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 93 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

const std::string OvsdbClientSsl::protocol ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 85 of file ovsdb_client_ssl.cc.

void OvsdbClientSsl::RegisterClients ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 66 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

const std::string OvsdbClientSsl::server ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 89 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

void OvsdbClientSsl::shutdown ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 101 of file ovsdb_client_ssl.cc.

Here is the call graph for this function:

Ip4Address OvsdbClientSsl::tsn_ip ( )
virtual

Implements OVSDB::OvsdbClient.

Definition at line 97 of file ovsdb_client_ssl.cc.

Friends And Related Function Documentation

friend class OvsdbClientSslSession
friend

Definition at line 114 of file ovsdb_client_ssl.h.

Member Data Documentation

Agent* OVSDB::OvsdbClientSsl::agent_
private

Definition at line 119 of file ovsdb_client_ssl.h.

SessionMap OVSDB::OvsdbClientSsl::session_map_
private

Definition at line 123 of file ovsdb_client_ssl.h.

bool OVSDB::OvsdbClientSsl::shutdown_
private

Definition at line 122 of file ovsdb_client_ssl.h.

uint32_t OVSDB::OvsdbClientSsl::ssl_server_port_
private

Definition at line 120 of file ovsdb_client_ssl.h.

Ip4Address OVSDB::OvsdbClientSsl::tsn_ip_
private

Definition at line 121 of file ovsdb_client_ssl.h.


The documentation for this class was generated from the following files: