--TEST-- Test socks proxy --SKIPIF-- --FILE-- getSocket(ZMQ::SOCKET_REP, null) ->bind('tcp://127.0.0.1:5556'); $context = new ZMQContext(); $client = $context->getSocket(ZMQ::SOCKET_REQ, null); $client->setSockOpt(ZMQ::SOCKOPT_SOCKS_PROXY, "localhost:5557"); $client ->connect('tcp://127.0.0.1:5556'); $client->sendmsg("Hello world!"); $message = $server->recvmsg(); var_dump($message); $server->sendmsg($message); $message = $client->recvmsg(); var_dump($message); --EXPECT-- string(12) "Hello world!" string(12) "Hello world!"