Rabbit Remote Control 0.0.30
Loading...
Searching...
No Matches
Public Types | Signals | Public Member Functions | Private Member Functions | Private Attributes | List of all members
CChannelSSHTunnelForward Class Reference

Includes SSH tunneling and a local socket service for forwarding data. More...

#include <ChannelSSHTunnelForward.h>

Inheritance diagram for CChannelSSHTunnelForward:
CChannelSSHTunnel CChannel

Public Types

enum class  SOCKET_TYPE { UnixSocket , Socket }
 

Signals

void sigServer (QString szHost, quint16 nPort)
 
void sigServer (QString szUnixDomainSocket)
 
- Signals inherited from CChannelSSHTunnel
void sigBlockShowMessageBox (const QString &szTitle, const QString &szMessage, QMessageBox::StandardButtons buttons, QMessageBox::StandardButton &nRet, bool &checkBox, QString checkBoxContext=QString())
 Block background threads and display message dialogs in foreground threads (QMessageBox)
 
void sigBlockShowWidget (const QString &className, int &nRet, void *pContext)
 Blocks the background thread and displays the window in the foreground thread.
 
- Signals inherited from CChannel
void sigConnected ()
 emit when the channel is connected.
 
void sigDisconnected ()
 emit when the channel is disconnected
 
void sigError (int nErr, const QString &szErr)
 emit when the channel is error
 

Public Member Functions

 CChannelSSHTunnelForward (QSharedPointer< CParameterChannelSSH > parameter, QObject *parent=nullptr)
 
virtual bool open (OpenMode mode) override
 
virtual void close () override
 
virtual int Process ()
 
- Public Member Functions inherited from CChannelSSHTunnel
 CChannelSSHTunnel (QSharedPointer< CParameterChannelSSH > parameter, bool bWakeUp=true, QObject *parent=nullptr)
 
virtual QString GetDetails () override
 
int Process ()
 
virtual int WakeUp ()
 
- Public Member Functions inherited from CChannel
 CChannel (QTcpSocket *pSocket, QObject *parent=nullptr)
 CChannel.
 

Private Member Functions

int CloseSocket (socket_t &s)
 
int AcceptConnect ()
 
int ReadConnect ()
 
int SSHReadyRead ()
 
int OpenSocket ()
 

Private Attributes

socket_t m_Listen
 
socket_t m_Connector
 
SOCKET_TYPE m_SocketType
 
char * m_pBuffer
 
const int m_BufferLength = 1024
 

Additional Inherited Members

- Static Public Member Functions inherited from CChannel
static int InitTranslation ()
 
static int RemoveTranslation ()
 
- Protected Member Functions inherited from CChannelSSHTunnel
virtual qint64 readData (char *data, qint64 maxlen) override
 
virtual qint64 writeData (const char *data, qint64 len) override
 
- Protected Member Functions inherited from CChannel
 CChannel (QObject *parent=nullptr)
 
virtual bool isSequential () const override
 
- Protected Attributes inherited from CChannelSSHTunnel
ssh_session m_Session
 
ssh_channel m_Channel
 

Detailed Description

Includes SSH tunneling and a local socket service for forwarding data.

Data is forwarded over a local socket and SSH tunnel. It is suitable for cases where the library does not implement a transport layer interface, only socket.

Note
It is only used in CSSHTunnelThread
See also
CSSHTunnelThread

Definition at line 22 of file ChannelSSHTunnelForward.h.

Member Enumeration Documentation

◆ SOCKET_TYPE

enum class CChannelSSHTunnelForward::SOCKET_TYPE
strong

Definition at line 36 of file ChannelSSHTunnelForward.h.

Constructor & Destructor Documentation

◆ ~CChannelSSHTunnelForward()

CChannelSSHTunnelForward::~CChannelSSHTunnelForward ( )
virtual

Definition at line 44 of file ChannelSSHTunnelForward.cpp.

Member Function Documentation

◆ AcceptConnect()

int CChannelSSHTunnelForward::AcceptConnect ( )
private

Definition at line 241 of file ChannelSSHTunnelForward.cpp.

◆ close()

void CChannelSSHTunnelForward::close ( )
overridevirtual

Reimplemented from CChannelSSHTunnel.

Definition at line 215 of file ChannelSSHTunnelForward.cpp.

◆ CloseSocket()

int CChannelSSHTunnelForward::CloseSocket ( socket_t &  s)
private

Definition at line 225 of file ChannelSSHTunnelForward.cpp.

◆ open()

bool CChannelSSHTunnelForward::open ( OpenMode  mode)
overridevirtual
Parameters
pSocketThe Owner is the instance of this class.

Reimplemented from CChannelSSHTunnel.

Definition at line 201 of file ChannelSSHTunnelForward.cpp.

◆ OpenSocket()

int CChannelSSHTunnelForward::OpenSocket ( )
private

Definition at line 51 of file ChannelSSHTunnelForward.cpp.

◆ Process()

int CChannelSSHTunnelForward::Process ( )
virtual

Definition at line 361 of file ChannelSSHTunnelForward.cpp.

◆ ReadConnect()

int CChannelSSHTunnelForward::ReadConnect ( )
private

Definition at line 276 of file ChannelSSHTunnelForward.cpp.

◆ SSHReadyRead()

int CChannelSSHTunnelForward::SSHReadyRead ( )
private

Definition at line 321 of file ChannelSSHTunnelForward.cpp.

Member Data Documentation

◆ m_BufferLength

const int CChannelSSHTunnelForward::m_BufferLength = 1024
private

Definition at line 60 of file ChannelSSHTunnelForward.h.

◆ m_Connector

socket_t CChannelSSHTunnelForward::m_Connector
private

Definition at line 47 of file ChannelSSHTunnelForward.h.

◆ m_Listen

socket_t CChannelSSHTunnelForward::m_Listen
private

Definition at line 46 of file ChannelSSHTunnelForward.h.

◆ m_pBuffer

char* CChannelSSHTunnelForward::m_pBuffer
private

Definition at line 59 of file ChannelSSHTunnelForward.h.

◆ m_SocketType

SOCKET_TYPE CChannelSSHTunnelForward::m_SocketType
private

Definition at line 49 of file ChannelSSHTunnelForward.h.


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