medialam/proxy-server

HTTP and SOCKS proxy server api

v0.1.1 2020-10-06 13:58 UTC

This package is auto-updated.

Last update: 2022-06-06 18:08:52 UTC


README

Simple proxy server aimed to provide unit tests for proxies

Usage

use Serps\ProxyServer\ProxyServer;

$server = new ProxyServer();

// Adds a SOCKS4 proxy server listening on localhost:20104
$server->listenSocks4(20104, 'localhost');
// Adds a SOCKS5 proxy server listening on localhost:20105
$server->listenSocks5(20105, 'localhost');
// Adds a HTTP proxy server listening on localhost:20106
$server->listenHttp(20106, 'localhost');

// Starts all servers
$server->getLoop()->run();