mirror of
https://github.com/shadowsocks/shadowsocks-rust.git
synced 2026-02-09 01:59:16 +08:00
230 lines
6.2 KiB
TOML
230 lines
6.2 KiB
TOML
[package]
|
|
name = "shadowsocks-service"
|
|
version = "1.24.0"
|
|
authors = ["Shadowsocks Contributors"]
|
|
description = "shadowsocks is a fast tunnel proxy that helps you bypass firewalls."
|
|
repository = "https://github.com/shadowsocks/shadowsocks-rust"
|
|
readme = "README.md"
|
|
documentation = "https://docs.rs/shadowsocks-service"
|
|
keywords = ["shadowsocks", "proxy", "socks", "socks5", "firewall"]
|
|
license = "MIT"
|
|
edition = "2024"
|
|
rust-version = "1.88"
|
|
|
|
[badges]
|
|
maintenance = { status = "passively-maintained" }
|
|
|
|
[features]
|
|
default = ["hickory-dns", "aead-cipher"]
|
|
|
|
full = [
|
|
"local",
|
|
"server",
|
|
"manager",
|
|
"hickory-dns",
|
|
"local-http",
|
|
"local-redir",
|
|
"local-tunnel",
|
|
"local-socks4",
|
|
"aead-cipher",
|
|
]
|
|
|
|
# Enable local server
|
|
local = ["httparse"]
|
|
# Enable remote server
|
|
server = []
|
|
# Enable manager server
|
|
manager = ["server"]
|
|
|
|
# Enables Hickory-DNS for replacing tokio's builtin DNS resolver
|
|
hickory-dns = ["hickory-resolver", "shadowsocks/trust-dns"]
|
|
# Hickory-DNS was renamed from Trust-DNS, keep compatibility.
|
|
trust-dns = ["hickory-dns"]
|
|
dns-over-tls = [
|
|
"hickory-dns",
|
|
"hickory-resolver/tls-ring",
|
|
"hickory-resolver/webpki-roots",
|
|
]
|
|
dns-over-https = [
|
|
"hickory-dns",
|
|
"hickory-resolver/https-ring",
|
|
"hickory-resolver/webpki-roots",
|
|
]
|
|
dns-over-h3 = ["hickory-dns", "hickory-resolver/h3-ring"]
|
|
|
|
# Enable DNS-relay
|
|
local-dns = ["local", "hickory-dns"]
|
|
# Backward compatibility, DO NOT USE
|
|
local-dns-relay = ["local-dns"]
|
|
# Enable client flow statistic report
|
|
# Currently is only used in Android
|
|
local-flow-stat = ["local"]
|
|
# Enable HTTP protocol for sslocal
|
|
local-http = ["local", "hyper", "http", "http-body-util", "base64"]
|
|
local-http-native-tls = ["local-http", "tokio-native-tls", "native-tls"]
|
|
local-http-native-tls-vendored = [
|
|
"local-http-native-tls",
|
|
"tokio-native-tls/vendored",
|
|
"native-tls/vendored",
|
|
]
|
|
local-http-rustls = [
|
|
"local-http",
|
|
"tokio-rustls",
|
|
"webpki-roots",
|
|
"rustls-native-certs",
|
|
]
|
|
# Enable REDIR protocol for sslocal
|
|
# (transparent proxy)
|
|
local-redir = ["local"]
|
|
# Enable tunnel protocol for sslocal
|
|
local-tunnel = ["local"]
|
|
# Enable socks4 protocol for sslocal
|
|
local-socks4 = ["local"]
|
|
# Enable Tun interface protocol for sslocal
|
|
local-tun = ["local", "etherparse", "tun", "smoltcp"]
|
|
# Enable Fake DNS
|
|
local-fake-dns = ["local", "trust-dns", "rocksdb", "bson"]
|
|
# sslocal support online URL (SIP008 Online Configuration Delivery)
|
|
# https://shadowsocks.org/doc/sip008.html
|
|
local-online-config = [
|
|
"local",
|
|
"local-http",
|
|
"mime",
|
|
"http",
|
|
"flate2",
|
|
"brotli",
|
|
"zstd",
|
|
]
|
|
|
|
# Enable Stream Cipher Protocol
|
|
# WARN: Stream Cipher Protocol is proved to be insecure
|
|
# https://github.com/shadowsocks/shadowsocks-rust/issues/373
|
|
# Users should always avoid using these ciphers in practice
|
|
stream-cipher = ["shadowsocks/stream-cipher"]
|
|
|
|
# Enable AEAD ciphers
|
|
aead-cipher = ["shadowsocks/aead-cipher"]
|
|
|
|
# Enable extra AEAD ciphers
|
|
# WARN: These non-standard AEAD ciphers are not officially supported by shadowsocks community
|
|
aead-cipher-extra = ["aead-cipher", "shadowsocks/aead-cipher-extra"]
|
|
|
|
# Enable AEAD 2022
|
|
aead-cipher-2022 = ["shadowsocks/aead-cipher-2022"]
|
|
# Enable AEAD 2022 with extra ciphers
|
|
aead-cipher-2022-extra = [
|
|
"aead-cipher-2022",
|
|
"shadowsocks/aead-cipher-2022-extra",
|
|
]
|
|
|
|
# Enable detection against replay attack
|
|
security-replay-attack-detect = ["shadowsocks/security-replay-attack-detect"]
|
|
|
|
[dependencies]
|
|
log = "0.4"
|
|
|
|
cfg-if = "1"
|
|
pin-project = "1.1"
|
|
thiserror = "2.0"
|
|
arc-swap = "1.7"
|
|
|
|
spin = { version = "0.10" }
|
|
lru_time_cache = "0.11"
|
|
bytes = "1.7"
|
|
byte_string = "1.0"
|
|
byteorder = "1.5"
|
|
rand = { version = "0.10", features = ["small_rng"] }
|
|
rocksdb = { version = "0.24", optional = true }
|
|
|
|
futures = "0.3"
|
|
tokio = { version = "1.38", features = [
|
|
"io-util",
|
|
"macros",
|
|
"net",
|
|
"parking_lot",
|
|
"rt",
|
|
"sync",
|
|
"time",
|
|
] }
|
|
tokio-native-tls = { version = "0.3", optional = true }
|
|
native-tls = { version = "0.2.8", optional = true, features = ["alpn"] }
|
|
webpki-roots = { version = "1.0", optional = true }
|
|
tokio-rustls = { version = "0.26", optional = true, default-features = false, features = [
|
|
"logging",
|
|
"tls12",
|
|
"ring",
|
|
] }
|
|
rustls-native-certs = { version = "0.8", optional = true }
|
|
trait-variant = "0.1"
|
|
|
|
socket2 = { version = "0.6", features = ["all"] }
|
|
libc = "~0.2.141"
|
|
|
|
hyper = { version = "1.4", optional = true, features = ["full"] }
|
|
http-body-util = { version = "0.1", optional = true }
|
|
http = { version = "1.1", optional = true }
|
|
httparse = { version = "1.9", optional = true }
|
|
|
|
hickory-resolver = { version = "0.25", optional = true, features = ["serde"] }
|
|
|
|
idna = "1.0"
|
|
ipnet = "2.10"
|
|
iprange = "0.6"
|
|
regex = { version = "1.4", default-features = false, features = [
|
|
"std",
|
|
"perf",
|
|
] }
|
|
|
|
mime = { version = "0.3", optional = true }
|
|
flate2 = { version = "1.0", optional = true }
|
|
brotli = { version = "8.0", optional = true }
|
|
zstd = { version = "0.13", optional = true }
|
|
base64 = { version = "0.22", optional = true }
|
|
|
|
etherparse = { version = "0.19", optional = true }
|
|
smoltcp = { version = "0.12", optional = true, default-features = false, features = [
|
|
"std",
|
|
"log",
|
|
"medium-ip",
|
|
"proto-ipv4",
|
|
"proto-ipv4-fragmentation",
|
|
"proto-ipv6",
|
|
"socket-icmp",
|
|
"socket-udp",
|
|
"socket-tcp",
|
|
"socket-tcp-cubic",
|
|
] }
|
|
|
|
serde = { version = "1.0", features = ["derive"] }
|
|
json5 = "1.3"
|
|
serde_json = "1.0"
|
|
bson = { version = "3.0.0", features = ["serde"], optional = true }
|
|
|
|
shadowsocks = { version = "1.24.0", path = "../shadowsocks", default-features = false }
|
|
|
|
# Just for the ioctl call macro
|
|
[target.'cfg(any(target_os = "macos", target_os = "ios", target_os = "freebsd", target_os = "openbsd"))'.dependencies]
|
|
nix = { version = "0.31", features = ["ioctl"] }
|
|
|
|
[target.'cfg(windows)'.dependencies]
|
|
windows-sys = { version = "0.61", features = ["Win32_Networking_WinSock"] }
|
|
|
|
[target.'cfg(any(target_os = "ios", target_os = "macos", target_os = "linux", target_os = "android", target_os = "windows", target_os = "freebsd"))'.dependencies]
|
|
tun = { version = "0.8", optional = true, features = ["async"] }
|
|
|
|
[dev-dependencies]
|
|
byteorder = "1.5"
|
|
env_logger = "0.11"
|
|
|
|
[package.metadata.docs.rs]
|
|
features = [
|
|
"full",
|
|
"local-http-rustls",
|
|
"local-dns",
|
|
"dns-over-tls",
|
|
"dns-over-https",
|
|
]
|
|
|
|
[lints.clippy]
|
|
uninlined_format_args = "allow"
|