proxie: Rust crate for SOCKS/HTTP proxy client
proxie offers easy SOCKS/HTTP client-side proxy integration into your existing socket program, with support for tokio, async-std and synchronous std::net runtime. docs.rs
Warning: this crate is still under active development. It is POSSIBLE the API might change in the future.
Example
proxie aims to provide a set of API that corresponds to its runtimes' native API. Here is an example of using tokio to make HTTP request via SOCKS5 proxy:
use ;
use future;
use ;
async
This crates replaces the TcpStream creation process with two lines. No other modifications are needed.
To use username and password authentication, simply import proxie::Auth and use this line to create a proxy server instance:
let server = new;
To enable support for each runtime, add corresponding feature into your Cargo.toml:
proxie = { version = "0.1.0", features = ["enable_tokio"] }
# Features currently available are: "enable_sync", "enable_tokio", and "enable_async_std".
Features and to-do
Runtime support:
- synchronous
std::net -
tokio -
async-std
Protocol support:
- HTTP CONNECT
- SOCKS5 CONNECT
- SOCKS5 BIND
- SOCKS5 UDP ASSOCIATE
- SOCKS4a
- HTTPS CONNECT
- Chained proxy
Other works:
- Documentation
- Full implementation of
TcpStreammethods - Unit tests
Development
Basic tests on current features are done, however it is not guaranteed that everything will work. It is also not guaranteed that current API will remain the same forever, though I will do my best to keep it stable. For bug report, feature request and any other suggestions please use GitHub issue or contact me directly.
License
MIT