Registry / networking / tokio-socks

tokio-socks

JSON →
library0.5.3rscratesunverified

Asynchronous SOCKS proxy support for Rust using Tokio.

# Cargo.toml [dependencies] tokio-socks = "0.5.3"
INSTALL
IMPORT
SIG · TOKIO-SOCKS
T
tokio-socks
networkingrustv0.5.3
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Socks5Stream
use tokio_socks::tcp::Socks5Stream;

Connects to a remote host through a SOCKS5 proxy.

use tokio_socks::tcp::Socks5Stream; #[tokio::main] async fn main() -> Result<(), Box<dyn std::error::Error>> { let stream = Socks5Stream::connect("127.0.0.1:1080", "example.com:80", None).await?; println!("Connected via SOCKS5"); Ok(()) }
Debug
Known issues
gotchaRequires Tokio runtime; will panic if used outside async context.
fix
Ensure you are running within a Tokio runtime (e.g., #[tokio::main]).
affects: >=0.5.0
Upgrade
Version history
0.5.3latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
28 hits · last 30 days
node
24
OpenAI (training)
1
Resources
tokio-socks — cargo add tokio-socks · libregistry