ss_rs/lib.rs
1//! An unofficial shadowsocks implementation that can work with official shadowsocks.
2//!
3//! # Features
4//!
5//! - [x] [SOCKS5](https://datatracker.ietf.org/doc/html/rfc1928) CONNECT command
6//! - [x] [AEAD](https://shadowsocks.org/en/wiki/AEAD-Ciphers.html) ciphers
7//! - [x] Defend against [replay attacks](https://github.com/shadowsocks/shadowsocks-org/issues/44)
8//! - [x] [Access control list](https://github.com/shadowsocks/shadowsocks-rust#acl)
9//!
10//! # Get Started
11//!
12//! ## Server
13//!
14//! Start a server listening on port 5421 using `chacha20-ietf-poly1305` AEAD cipher with password `ocfbnj`.
15//!
16//! ~~~bash
17//! ss-rs -s 0.0.0.0:5421 -k ocfbnj -m chacha20-ietf-poly1305
18//! ~~~
19//!
20//! ## Client
21//!
22//! Start a client connecting to the `ocfbnj.cn`.
23//!
24//! The client listens on port 1080 for incoming SOCKS5 connections and uses `chacha20-ietf-poly1305` AEAD cipher with password `ocfbnj`.
25//!
26//! ~~~bash
27//! ss-rs -s ocfbnj.cn:5421 -l localhost:1080 -k ocfbnj -m chacha20-ietf-poly1305
28//! ~~~
29//!
30//! # How to build
31//!
32//! ## Prerequisites
33//!
34//! - Cargo installed (See [this](https://www.rust-lang.org/learn/get-started)).
35//!
36//! ## Building with Cargo
37//!
38//! 1. Clone
39//!
40//! ~~~bash
41//! git clone https://github.com/ocfbnj/ss-rs
42//! cd ss-rs
43//! ~~~
44//!
45//! 2. Build
46//!
47//! ~~~bash
48//! cargo b --release
49//! ~~~
50//!
51//! Now you can find the binary in `./target/release/ss-rs`.
52
53pub mod acl;
54pub mod context;
55pub mod crypto;
56pub mod net;
57pub mod plugin;
58pub mod security;
59pub mod socks5;
60pub mod tcp;
61pub mod url;