Remoto - VFS: VFSQTcpServer Class Reference
Remoto - VFS

This is a subclass of QTcpServer, needed to enable SSL. More...

#include <VFS_tcp_server.h>

Inheritance diagram for VFSQTcpServer:

Public Member Functions

 VFSQTcpServer (QObject *parent=nullptr, bool ssl=false)
 Create a VFSQTcpServer, which allows to create QSslSocket instances if _ssl is true. More...
 
void setSslConfiguration (QSslConfiguration sslConfiguration)
 Set the SSL configuration. More...
 

Protected Slots

void modeChanged (QSslSocket::SslMode mode)
 A slot for when the SSL mode has changed. More...
 
void sslErrors (const QList< QSslError > &errors)
 One or more ssl errors have occurred. More...
 
void sslReady ()
 SSL is ready, but do nothing. More...
 

Protected Member Functions

void incomingConnection (qintptr socketDescriptor)
 Handle a new incoming connection. More...
 

Protected Attributes

bool _ssl
 Use ssl? More...
 
QSslConfiguration _sslConfiguration
 The ssl configuration, which will include cert files and ssl mode. More...
 

Detailed Description

This is a subclass of QTcpServer, needed to enable SSL.

This is for internal use, and should not be created by other code.

Definition at line 10 of file VFS_tcp_server.h.

Constructor & Destructor Documentation

◆ VFSQTcpServer()

VFSQTcpServer::VFSQTcpServer ( QObject *  parent = nullptr,
bool  ssl = false 
)

Create a VFSQTcpServer, which allows to create QSslSocket instances if _ssl is true.

Parameters
parentPointer to the VFS_tcp_server, which is the owner
sslUse ssl?

Definition at line 23 of file VFS_tcp_server.cpp.

Member Function Documentation

◆ incomingConnection()

void VFSQTcpServer::incomingConnection ( qintptr  socketDescriptor)
protected

Handle a new incoming connection.

Parameters
socketDescriptorIf _ssl is true, create a QSslSocket instead of a regular QTcpSocket.

Definition at line 39 of file VFS_tcp_server.cpp.

◆ modeChanged

void VFSQTcpServer::modeChanged ( QSslSocket::SslMode  mode)
protectedslot

A slot for when the SSL mode has changed.

Parameters
modeThe new SSL mode

This is for subclasses, but is currently unused.

Definition at line 103 of file VFS_tcp_server.cpp.

◆ setSslConfiguration()

void VFSQTcpServer::setSslConfiguration ( QSslConfiguration  sslConfiguration)

Set the SSL configuration.

This is for internal use.

Parameters
sslConfigurationThe SSL configuration to apply.

Definition at line 71 of file VFS_tcp_server.cpp.

◆ sslErrors

void VFSQTcpServer::sslErrors ( const QList< QSslError > &  errors)
protectedslot

One or more ssl errors have occurred.

Log them as errors, and do nothing.

Parameters
errorsThe list of QSslErrors to log

Definition at line 81 of file VFS_tcp_server.cpp.

◆ sslReady

void VFSQTcpServer::sslReady ( )
protectedslot

SSL is ready, but do nothing.

Definition at line 91 of file VFS_tcp_server.cpp.

Member Data Documentation

◆ _ssl

bool VFSQTcpServer::_ssl
protected

Use ssl?

Definition at line 19 of file VFS_tcp_server.h.

◆ _sslConfiguration

QSslConfiguration VFSQTcpServer::_sslConfiguration
protected

The ssl configuration, which will include cert files and ssl mode.

Definition at line 20 of file VFS_tcp_server.h.


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