![]() |
Qt 6.x
The Qt SDK
|
#include "qsocks5socketengine_p.h"#include "qtcpsocket.h"#include "qudpsocket.h"#include "qtcpserver.h"#include "qdebug.h"#include "qhash.h"#include "qqueue.h"#include "qelapsedtimer.h"#include "qmutex.h"#include "qthread.h"#include "qcoreapplication.h"#include "qurl.h"#include "qauthenticator.h"#include "private/qiodevice_p.h"#include "private/qringbuffer_p.h"#include <qendian.h>#include <qnetworkinterface.h>#include <memory>#include "moc_qsocks5socketengine_p.cpp"
Include dependency graph for qsocks5socketengine.cpp:Go to the source code of this file.
Classes | |
| struct | QSocks5Data |
| struct | QSocks5ConnectData |
| struct | QSocks5BindData |
| struct | QSocks5RevivedDatagram |
| struct | QSocks5UdpAssociateData |
| class | QSocks5BindStore |
Macros | |
| #define | MAX_DATA_DUMP 256 |
| #define | SOCKS5_BLOCKING_BIND_TIMEOUT 5000 |
| #define | Q_INIT_CHECK(returnValue) |
| #define | S5_VERSION_5 0x05 |
| #define | S5_CONNECT 0x01 |
| #define | S5_BIND 0x02 |
| #define | S5_UDP_ASSOCIATE 0x03 |
| #define | S5_IP_V4 0x01 |
| #define | S5_DOMAINNAME 0x03 |
| #define | S5_IP_V6 0x04 |
| #define | S5_SUCCESS 0x00 |
| #define | S5_R_ERROR_SOCKS_FAILURE 0x01 |
| #define | S5_R_ERROR_CON_NOT_ALLOWED 0x02 |
| #define | S5_R_ERROR_NET_UNREACH 0x03 |
| #define | S5_R_ERROR_HOST_UNREACH 0x04 |
| #define | S5_R_ERROR_CONN_REFUSED 0x05 |
| #define | S5_R_ERROR_TTL 0x06 |
| #define | S5_R_ERROR_CMD_NOT_SUPPORTED 0x07 |
| #define | S5_R_ERROR_ADD_TYPE_NOT_SUPORTED 0x08 |
| #define | S5_AUTHMETHOD_NONE 0x00 |
| #define | S5_AUTHMETHOD_PASSWORD 0x02 |
| #define | S5_AUTHMETHOD_NOTACCEPTABLE 0xFF |
| #define | S5_PASSWORDAUTH_VERSION 0x01 |
| #define | QSOCKS5_DEBUG if (0) qDebug() |
| #define | QSOCKS5_Q_DEBUG if (0) qDebug() |
| #define | QSOCKS5_D_DEBUG if (0) qDebug() |
Functions | |
| static QString | dump (const QByteArray &) |
| static bool | qt_socks5_set_host_address_and_port (const QHostAddress &address, quint16 port, QByteArray *pBuf) |
| static bool | qt_socks5_set_host_name_and_port (const QString &hostname, quint16 port, QByteArray *pBuf) |
| static int | qt_socks5_get_host_address_and_port (const QByteArray &buf, QHostAddress *pAddress, quint16 *pPort, int *pPos) |
| static int | nextDescriptor () |
Variables | |
| static const int | MaxWriteBufferSize = 128*1024 |
| static QString | s5StateToString (QSocks5SocketEnginePrivate::Socks5State) |
| #define MAX_DATA_DUMP 256 |
Definition at line 33 of file qsocks5socketengine.cpp.
| #define Q_INIT_CHECK | ( | returnValue | ) |
Definition at line 36 of file qsocks5socketengine.cpp.
Definition at line 107 of file qsocks5socketengine.cpp.
Definition at line 105 of file qsocks5socketengine.cpp.
Definition at line 106 of file qsocks5socketengine.cpp.
| #define S5_AUTHMETHOD_NONE 0x00 |
Definition at line 58 of file qsocks5socketengine.cpp.
| #define S5_AUTHMETHOD_NOTACCEPTABLE 0xFF |
Definition at line 60 of file qsocks5socketengine.cpp.
| #define S5_AUTHMETHOD_PASSWORD 0x02 |
Definition at line 59 of file qsocks5socketengine.cpp.
| #define S5_BIND 0x02 |
Definition at line 43 of file qsocks5socketengine.cpp.
| #define S5_CONNECT 0x01 |
Definition at line 42 of file qsocks5socketengine.cpp.
| #define S5_DOMAINNAME 0x03 |
Definition at line 46 of file qsocks5socketengine.cpp.
| #define S5_IP_V4 0x01 |
Definition at line 45 of file qsocks5socketengine.cpp.
| #define S5_IP_V6 0x04 |
Definition at line 47 of file qsocks5socketengine.cpp.
| #define S5_PASSWORDAUTH_VERSION 0x01 |
Definition at line 62 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_ADD_TYPE_NOT_SUPORTED 0x08 |
Definition at line 56 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_CMD_NOT_SUPPORTED 0x07 |
Definition at line 55 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_CON_NOT_ALLOWED 0x02 |
Definition at line 50 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_CONN_REFUSED 0x05 |
Definition at line 53 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_HOST_UNREACH 0x04 |
Definition at line 52 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_NET_UNREACH 0x03 |
Definition at line 51 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_SOCKS_FAILURE 0x01 |
Definition at line 49 of file qsocks5socketengine.cpp.
| #define S5_R_ERROR_TTL 0x06 |
Definition at line 54 of file qsocks5socketengine.cpp.
| #define S5_SUCCESS 0x00 |
Definition at line 48 of file qsocks5socketengine.cpp.
| #define S5_UDP_ASSOCIATE 0x03 |
Definition at line 44 of file qsocks5socketengine.cpp.
| #define S5_VERSION_5 0x05 |
Definition at line 41 of file qsocks5socketengine.cpp.
| #define SOCKS5_BLOCKING_BIND_TIMEOUT 5000 |
Definition at line 34 of file qsocks5socketengine.cpp.
|
inlinestatic |
Definition at line 110 of file qsocks5socketengine.cpp.
Referenced by QSocks5SocketEnginePrivate::_q_controlSocketReadNotification(), QSocks5SocketEnginePrivate::_q_udpSocketReadNotification(), QQuick3DRenderStats::endRender(), QQuick3DRenderStats::endSync(), QSocks5SocketEnginePrivate::parseRequestMethodReply(), QtModuleInfoStore::populate(), QSocks5SocketEngine::read(), QSocks5SocketEnginePrivate::sendRequestMethod(), QQmlJS::Dom::Token::toString(), QSocks5SocketEngine::write(), and QSocks5SocketEngine::writeDatagram().
Here is the caller graph for this function:
|
static |
Definition at line 965 of file qsocks5socketengine.cpp.
Referenced by QSocks5SocketEngine::initialize().
Here is the caller graph for this function:
|
static |
Definition at line 181 of file qsocks5socketengine.cpp.
References add(), i, pos, qDebug, QSOCKS5_DEBUG, ret, S5_DOMAINNAME, S5_IP_V4, and S5_IP_V6.
Referenced by QSocks5SocketEnginePrivate::_q_udpSocketReadNotification(), and QSocks5SocketEnginePrivate::parseRequestMethodReply().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 117 of file qsocks5socketengine.cpp.
References QByteArray::append(), QByteArray::fromRawData(), QAbstractSocket::IPv4Protocol, QAbstractSocket::IPv6Protocol, ptr(), QSOCKS5_DEBUG, S5_IP_V4, and S5_IP_V6.
Referenced by QSocks5SocketEnginePrivate::sendRequestMethod(), and QSocks5SocketEngine::writeDatagram().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 150 of file qsocks5socketengine.cpp.
References QByteArray::append(), QByteArray::fromRawData(), ptr(), QSOCKS5_DEBUG, S5_DOMAINNAME, QByteArray::size(), and QUrl::toAce().
Referenced by QSocks5SocketEnginePrivate::sendRequestMethod().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 29 of file qsocks5socketengine.cpp.
Referenced by QSocks5SocketEnginePrivate::_q_controlSocketBytesWritten(), QSocks5SocketEngine::waitForWrite(), and QSocks5SocketEngine::write().
|
inlinestatic |
Definition at line 109 of file qsocks5socketengine.cpp.
Referenced by QSocks5SocketEnginePrivate::_q_controlSocketReadNotification().