XpressEngine Core  1.11.2
 All Classes Namespaces Files Functions Variables Pages
Public Member Functions | Protected Member Functions | List of all members
HTTP_Request2_SOCKS5 Class Reference
Inheritance diagram for HTTP_Request2_SOCKS5:
HTTP_Request2_SocketWrapper

Public Member Functions

 __construct ($address, $timeout=10, array $contextOptions=array(), $username=null, $password=null)
 
 connect ($remoteHost, $remotePort)
 
- Public Member Functions inherited from HTTP_Request2_SocketWrapper
 __construct ($address, $timeout, array $contextOptions=array())
 
 __destruct ()
 
 read ($length)
 
 readLine ($bufferSize, $localTimeout=null)
 
 write ($data)
 
 eof ()
 
 setDeadline ($deadline, $timeout)
 
 enableCrypto ()
 

Protected Member Functions

 performAuthentication ($username, $password)
 
- Protected Member Functions inherited from HTTP_Request2_SocketWrapper
 checkTimeout ()
 
 connectionWarningsHandler ($errno, $errstr)
 

Additional Inherited Members

- Protected Attributes inherited from HTTP_Request2_SocketWrapper
 $connectionWarnings = array()
 
 $socket
 
 $deadline
 
 $timeout
 

Detailed Description

Definition at line 36 of file SOCKS5.php.

Constructor & Destructor Documentation

HTTP_Request2_SOCKS5::__construct (   $address,
  $timeout = 10,
array  $contextOptions = array(),
  $username = null,
  $password = null 
)

Constructor, tries to connect and authenticate to a SOCKS5 proxy

Parameters
string$addressProxy address, e.g. 'tcp://localhost:1080'
int$timeoutConnection timeout (seconds)
array$contextOptionsStream context options
string$usernameProxy user name
string$passwordProxy password
Exceptions
HTTP_Request2_LogicException
HTTP_Request2_ConnectionException
HTTP_Request2_MessageException

Definition at line 51 of file SOCKS5.php.

Member Function Documentation

HTTP_Request2_SOCKS5::connect (   $remoteHost,
  $remotePort 
)

Connects to a remote host via proxy

Parameters
string$remoteHostRemote host
int$remotePortRemote port
Exceptions
HTTP_Request2_ConnectionException
HTTP_Request2_MessageException

Definition at line 115 of file SOCKS5.php.

HTTP_Request2_SOCKS5::performAuthentication (   $username,
  $password 
)
protected

Performs username/password authentication for SOCKS5

Parameters
string$usernameProxy user name
string$passwordProxy password
Exceptions
HTTP_Request2_ConnectionException
HTTP_Request2_MessageExceptionhttp://tools.ietf.org/html/rfc1929

Definition at line 92 of file SOCKS5.php.


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