An example SOCKSv5 server implementation with tokio
Latest commit 6dcf104 Dec 29, 2016 @alexcrichton alexcrichton committed on GitHub Merge pull request #4 from inejge/edits
Two comment edits


An implementation of a SOCKSv5 proxy server built on top of tokio-core.

Build Status Build status


First, run the server

$ cargo run
Listening for socks5 proxy connections on

Then in a separate window you can test out the proxy:

$ export https_proxy=socks5h://localhost:8080
$ curl -v

If you have an older version of libcurl which doesn't support the socks5h scheme, you can try:

$ curl -v --socks5-hostname localhost:8080

The server is hardcoded to use Google's public DNS resolver (IPv4 address If you can't use external DNS services, change the address in the source and rebuild the server.


tokio-socks5 is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0), with portions covered by various BSD-like licenses.

See LICENSE-APACHE, and LICENSE-MIT for details.