back to home

shadowsocks / shadowsocks-libev

Bug-fix-only libev port of shadowsocks. Future development moved to shadowsocks-rust

16,132 stars
6,285 forks
134 issues
CShellCMake

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing shadowsocks/shadowsocks-libev in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Source files are only loaded when you start an analysis to optimize performance.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind.in/repo/shadowsocks/shadowsocks-libev)
Preview:Analyzed by RepoMind

Repository Overview (README excerpt)

Crawler view

shadowsocks-libev Intro Shadowsocks-libev is a lightweight secured SOCKS5 proxy for embedded devices and low-end boxes. It is a port of Shadowsocks created by @clowwindy, and maintained by @madeye and @linusyang. Current version: 3.3.6 | Changelog Features Shadowsocks-libev is written in pure C and depends on libev. It's designed to be a lightweight implementation of shadowsocks protocol, in order to keep the resource usage as low as possible. For a full list of feature comparison between different versions of shadowsocks, refer to the Wiki page. Quick Start Snap is the recommended way to install the latest binaries. Install snap core https://snapcraft.io/core Install from snapcraft.io Stable channel: Edge channel: Installation Distribution-specific guide • Debian & Ubuntu • Install from repository • Build deb package from source • Configure and start the service • Fedora & RHEL • Build from source with centos • Archlinux & Manjaro • NixOS • Nix • Directly build and install on UNIX-like system • FreeBSD • Install • Configuration • Run • Run as client • OpenWRT • OS X • Windows (MinGW) • Docker • * * Build from source (CMake) shadowsocks-libev uses CMake as its sole build system. Start by pulling submodules: Then build: To run unit tests: CMake options For a complete list of available options, run from a build directory. Commonly used options: | Option | Default | Description | |---|---|---| | | | Use system libcork/libipset/libbloom instead of bundled submodules | | | | Skip man page generation (removes asciidoc/xmlto dependency) | | | | Disable unit tests | | | | Linux netfilter conntrack QoS support | | | | nftables firewall integration | On macOS, if libraries are installed via Homebrew, specify paths: Debian & Ubuntu Install from repository (not recommended) Shadowsocks-libev is available in the official repository for following distributions: • Debian 8 or higher, including oldoldstable (jessie), old stable (stretch), stable (buster), testing (bullseye) and unstable (sid) • Ubuntu 16.10 or higher Build deb package from source You can build shadowsocks-libev and all its dependencies by script: For older systems, building packages is not supported. Please try to build and install directly from source. See the Linux section below. Configure and start the service Fedora & RHEL Supported distributions: • Recent Fedora versions (until EOL) • RHEL 6, 7 and derivatives (including CentOS, Scientific Linux) Build from source with centos If you are using CentOS 7, you need to install these prerequirements to build from source code: Archlinux & Manjaro Please refer to downstream PKGBUILD script for extra modifications and distribution-specific bugs. NixOS Nix Linux In general, you need the following build dependencies: • cmake (>= 3.2) • a C compiler (gcc or clang) • pkg-config • libmbedtls • libsodium (>= 1.0.4) • libpcre2 • libev • libc-ares • asciidoc (for documentation only) • xmlto (for documentation only) If your system is too old to provide libmbedtls and libsodium (>= 1.0.4), you will need to either install those libraries manually or upgrade your system. Install build dependencies for your distribution: Then build and install: FreeBSD Install Shadowsocks-libev is available in FreeBSD Ports Collection. You can install it in either way, or . **pkg (recommended)** **ports** Configuration Edit your file. By default, it's located in . To enable shadowsocks-libev, add the following rc variable to your file: Run Start the Shadowsocks server: Run as client By default, shadowsocks-libev is running as a server in FreeBSD. If you would like to start shadowsocks-libev in client mode, you can modify the rc script ( ) manually. Note that is simply a workaround, each time you upgrade the port your changes will be overwritten by the new version. OpenWRT The OpenWRT project is maintained here: openwrt-shadowsocks. OS X For OS X, use Homebrew to install or build. Install Homebrew: Install shadowsocks-libev: Windows (MinGW) To build Windows native binaries, the recommended method is to use Docker: • On Windows: double-click in • On Unix-like system: cd shadowsocks-libev/docker/mingw make A tarball with 32-bit and 64-bit binaries will be generated in the same directory. You could also manually use MinGW-w64 compilers to build in Unix-like shell (MSYS2/Cygwin), or cross-compile on Unix-like systems (Linux/MacOS). Please refer to build scripts in . Currently you need to use a patched libev library for MinGW: • https://github.com/shadowsocks/libev/archive/mingw.zip Notice that TCP Fast Open (TFO) is only available on **Windows 10**, **1607** or later version (precisely, build >= 14393). If you are using **1709** (build 16299) or later version, you also need to run the following command in PowerShell/Command Prompt **as Administrator** and **reboot** to use TFO properly: netsh int tcp set global fastopenfallback=disabled Docker As you expect, simply pull the image and run. More information about the image can be found here. Usage For a detailed and complete list of all supported arguments, you may refer to the man pages of the applications, respectively. ss-[local|redir|server|tunnel|manager] -s Host name or IP address of your remote server. -p Port number of your remote server. -l Port number of your local server. -k Password of your remote server. -m Encrypt method: rc4-md5, aes-128-gcm, aes-192-gcm, aes-256-gcm, aes-128-cfb, aes-192-cfb, aes-256-cfb, aes-128-ctr, aes-192-ctr, aes-256-ctr, camellia-128-cfb, camellia-192-cfb, camellia-256-cfb, bf-cfb, chacha20-ietf-poly1305, xchacha20-ietf-poly1305, salsa20, chacha20 and chacha20-ietf. The default cipher is chacha20-ietf-poly1305. [-a ] Run as another user. [-f ] The file path to store pid. [-t ] Socket timeout in seconds. [-c ] The path to config file. [-n ] Max number of open files. [-i ] Network interface to bind. (not available in redir mode) [-b…