18 stable releases

1.12.4 Dec 16, 2021
1.12.3 Nov 28, 2021
1.11.2 Jul 24, 2021
1.11.1 Jun 6, 2021
1.9.1 Feb 26, 2021

#507 in Network programming

Download history 56/week @ 2021-09-28 38/week @ 2021-10-05 40/week @ 2021-10-12 32/week @ 2021-10-19 37/week @ 2021-10-26 89/week @ 2021-11-02 131/week @ 2021-11-09 68/week @ 2021-11-16 94/week @ 2021-11-23 93/week @ 2021-11-30 43/week @ 2021-12-07 92/week @ 2021-12-14 41/week @ 2021-12-21 58/week @ 2021-12-28 61/week @ 2022-01-04 50/week @ 2022-01-11

215 downloads per month
Used in shadowsocks-rust

MIT license

775KB
18K SLoC

shadowsocks-service

License crates.io docs.rs

This is a port of shadowsocks.

shadowsocks is a fast tunnel proxy that helps you bypass firewalls.

Features

  • Local Server

    • SOCKS 5
    • SOCKS 4/4a (local-socks4)
    • HTTP (local-http)
    • Tunnel (local-tunnel)
    • Redir, aka Transparent Proxy (local-redir)
    • DNS (local-dns)
    • Tun (local-tun)
  • Server

  • Manager


lib.rs:

Shadowsocks Service

https://shadowsocks.org/

shadowsocks is a fast tunnel proxy that helps you bypass firewalls.

Usage

Build shadowsocks and you will get at least 2 binaries: sslocal and ssserver

Write your servers in a configuration file. Format is defined in shadowsocks' documentation

For example:

{
   "server": "my_server_ip",
   "server_port": 8388,
   "local_address": "127.0.0.1",
   "local_port": 1080,
   "password": "mypassword",
   "timeout": 300,
   "method": "aes-256-cfb"
}

Save it in file shadowsocks.json and run local proxy server with

cargo run --bin sslocal -- -c shadowsocks.json

Now you can use SOCKS5 protocol to proxy your requests, for example:

curl --socks5-hostname 127.0.0.1:1080 https://www.google.com

On the server side, you can run the server with

cargo run --bin ssserver -- -c shadowsocks.json

Server should use the same configuration file as local, except the listen addresses for servers must be socket addresses.

Of course, you can also use cargo install to install binaries.

Dependencies

~9–16MB
~335K SLoC