#include <socks.h>
Inheritance diagram for PSocksProtocol:

Public Types | |
| enum | { DefaultServerPort = 1080 } |
Public Member Functions | |
| PSocksProtocol (WORD port) | |
| virtual | ~PSocksProtocol () |
| PBoolean | SetServer (const PString &hostname, const char *service="socks 1080") |
| PBoolean | SetServer (const PString &hostname, WORD port) |
| void | SetAuthentication (const PString &username, const PString &password) |
Protected Member Functions | |
| PBoolean | ConnectSocksServer (PTCPSocket &thisSocket) |
| virtual void | SetErrorCodes (PChannel::Errors errCode, int osErr)=0 |
| virtual PBoolean | SendSocksCommand (PTCPSocket &socket, BYTE command, const char *hostname, PIPSocket::Address addr) |
| virtual PBoolean | ReceiveSocksResponse (PTCPSocket &socket, PIPSocket::Address &addr, WORD &port) |
Protected Attributes | |
| PString | serverHost |
| WORD | serverPort |
| PString | authenticationUsername |
| PString | authenticationPassword |
| PIPSocket::Address | remoteAddress |
| WORD | remotePort |
| PIPSocket::Address | localAddress |
| WORD | localPort |
| PSocksProtocol::PSocksProtocol | ( | WORD | port | ) |
| virtual PSocksProtocol::~PSocksProtocol | ( | ) | [inline, virtual] |
| PBoolean PSocksProtocol::SetServer | ( | const PString & | hostname, | |
| const char * | service = "socks 1080" | |||
| ) |
Set the username and password for the SOCKS server authentication. This is for the cleartext authentication only, GSSAPI, Kerberos etc is not yet supported.
| PBoolean PSocksProtocol::ConnectSocksServer | ( | PTCPSocket & | thisSocket | ) | [protected] |
| virtual void PSocksProtocol::SetErrorCodes | ( | PChannel::Errors | errCode, | |
| int | osErr | |||
| ) | [protected, pure virtual] |
Implemented in PSocksSocket, and PSocksUDPSocket.
| virtual PBoolean PSocksProtocol::SendSocksCommand | ( | PTCPSocket & | socket, | |
| BYTE | command, | |||
| const char * | hostname, | |||
| PIPSocket::Address | addr | |||
| ) | [protected, virtual] |
Reimplemented in PSocks4Socket.
| virtual PBoolean PSocksProtocol::ReceiveSocksResponse | ( | PTCPSocket & | socket, | |
| PIPSocket::Address & | addr, | |||
| WORD & | port | |||
| ) | [protected, virtual] |
Reimplemented in PSocks4Socket.
PString PSocksProtocol::serverHost [protected] |
WORD PSocksProtocol::serverPort [protected] |
PString PSocksProtocol::authenticationUsername [protected] |
PString PSocksProtocol::authenticationPassword [protected] |
PIPSocket::Address PSocksProtocol::remoteAddress [protected] |
WORD PSocksProtocol::remotePort [protected] |
PIPSocket::Address PSocksProtocol::localAddress [protected] |
WORD PSocksProtocol::localPort [protected] |
1.5.1