trojan 0.4.0

A Rust implementation of the Trojan protocol
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
name = "trojan"
version = "0.4.0"
authors = ["0x72757374 <257538187+0x72757374@users.noreply.github.com>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A Rust implementation of the Trojan protocol"
homepage = "https://github.com/trojan-rs/trojan-rs"
documentation = "https://docs.rs/trojan"
readme = "README.md"
keywords = [
    "trojan",
    "proxy",
    "tls",
    "network",
]
categories = ["network-programming"]
license = "GPL-3.0-only"
repository = "https://github.com/trojan-rs/trojan-rs"
resolver = "2"

[features]
cert = [
    "cli",
    "dep:trojan-cert",
]
cli = [
    "trojan-auth/cli",
    "dep:clap",
    "dep:tokio",
]
default = [
    "cli",
    "sql-sqlite",
]
sql-mysql = ["trojan-auth/sql-mysql"]
sql-postgres = ["trojan-auth/sql-postgres"]
sql-sqlite = ["trojan-auth/sql-sqlite"]
upgrade = [
    "cli",
    "dep:reqwest",
    "dep:serde",
    "dep:serde_json",
    "dep:self-replace",
    "dep:flate2",
    "dep:tar",
    "dep:sha2",
    "dep:hex",
    "dep:tokio-util",
    "dep:futures-util",
    "dep:tempfile",
    "dep:zip",
]

[lib]
name = "trojan"
path = "src/lib.rs"

[[bin]]
name = "trojan"
path = "src/main.rs"
required-features = ["cli"]

[dependencies.clap]
version = "4"
features = ["derive"]
optional = true

[dependencies.flate2]
version = "1"
optional = true

[dependencies.futures-util]
version = "0.3"
optional = true

[dependencies.hex]
version = "0.4"
optional = true

[dependencies.reqwest]
version = "0.12"
features = [
    "json",
    "stream",
    "rustls-tls",
]
optional = true
default-features = false

[dependencies.self-replace]
version = "1"
optional = true

[dependencies.serde]
version = "1"
features = ["derive"]
optional = true

[dependencies.serde_json]
version = "1"
optional = true

[dependencies.sha2]
version = "0.10"
optional = true

[dependencies.tar]
version = "0.4"
optional = true

[dependencies.tempfile]
version = "3"
optional = true

[dependencies.tokio]
version = "1"
features = [
    "rt-multi-thread",
    "macros",
]
optional = true

[dependencies.tokio-util]
version = "0.7"
features = ["io"]
optional = true

[dependencies.trojan-auth]
version = "0.4.0"

[dependencies.trojan-cert]
version = "0.4.0"
optional = true

[dependencies.trojan-client]
version = "0.4.0"

[dependencies.trojan-config]
version = "0.4.0"

[dependencies.trojan-core]
version = "0.4.0"

[dependencies.trojan-metrics]
version = "0.4.0"

[dependencies.trojan-proto]
version = "0.4.0"

[dependencies.trojan-relay]
version = "0.4.0"

[dependencies.trojan-server]
version = "0.4.0"

[target."cfg(windows)".dependencies.zip]
version = "2"
features = ["deflate"]
optional = true
default-features = false

[profile.release]
opt-level = 3
lto = "fat"
codegen-units = 1
panic = "abort"
strip = true