Replace the one-intermediate-peer relay with protocol-scoped connectivity graphs and precomputed shortest-path/ECMP forwarding snapshots. Independent transport readers forward opaque transit frames without a plugin or TUN round trip. Carry source, destination, a bounded hop limit and stable flow tags; preserve end-to-end WireGuard links across topology changes. Classify IP flows before encryption and preserve their tags through the WireGuard pending queue. Add offline four-agent path-change coverage, loop and isolation tests, and an opt-in release forwarding microbenchmark. Bump control/data ALPNs while preserving persistent network identities and state. Also include the pending Windows Mainline idle-timeout fix and its regression test, using a reproducible vendored dependency patch. Validation: fmt, workspace Clippy with warnings denied, and 307 release tests passed. Two pre-existing Windows SQLite wipe failures were excluded; public DHT and the manual benchmark remain ignored by default. The forwarding microbenchmark measured 103 ns (64 B) and 202 ns (1280 B) per transit packet, excluding encryption and socket I/O.
148 lines
2.8 KiB
TOML
148 lines
2.8 KiB
TOML
# 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 = "2021"
|
|
rust-version = "1.85"
|
|
name = "mainline"
|
|
version = "8.0.0"
|
|
authors = [
|
|
"nuh.dev",
|
|
"SeverinAlexB <severin@synonym.to>",
|
|
"SHAcollision <shacollision@synonym.to>",
|
|
"dzdidi <denys@synonym.to>",
|
|
"Kevin Karsopawiro <kevin@synonym.to>",
|
|
]
|
|
build = false
|
|
exclude = [
|
|
"/docs/*",
|
|
"/examples/*",
|
|
]
|
|
autolib = false
|
|
autobins = false
|
|
autoexamples = false
|
|
autotests = false
|
|
autobenches = false
|
|
description = "Simple, robust, BitTorrent's Mainline DHT implementation"
|
|
homepage = "https://github.com/pubky/mainline"
|
|
readme = "README.md"
|
|
keywords = [
|
|
"bittorrent",
|
|
"torrent",
|
|
"dht",
|
|
"kademlia",
|
|
"mainline",
|
|
]
|
|
categories = ["network-programming"]
|
|
license = "MIT"
|
|
repository = "https://github.com/pubky/mainline"
|
|
|
|
[package.metadata.docs.rs]
|
|
all-features = true
|
|
|
|
[features]
|
|
async = [
|
|
"node",
|
|
"flume/async",
|
|
"dep:futures-lite",
|
|
]
|
|
default = ["full"]
|
|
full = ["async"]
|
|
node = ["dep:flume"]
|
|
|
|
[lib]
|
|
name = "mainline"
|
|
path = "src/lib.rs"
|
|
|
|
[dependencies.crc]
|
|
version = "3.4.0"
|
|
default-features = false
|
|
|
|
[dependencies.document-features]
|
|
version = "0.2.12"
|
|
|
|
[dependencies.dyn-clone]
|
|
version = "1.0.20"
|
|
default-features = false
|
|
|
|
[dependencies.ed25519-dalek]
|
|
version = "3.0.0-pre.1"
|
|
default-features = false
|
|
|
|
[dependencies.flume]
|
|
version = "0.12.0"
|
|
optional = true
|
|
default-features = false
|
|
|
|
[dependencies.futures-lite]
|
|
version = "2.6.1"
|
|
optional = true
|
|
default-features = false
|
|
|
|
[dependencies.getrandom]
|
|
version = "0.4"
|
|
default-features = false
|
|
|
|
[dependencies.lru]
|
|
version = "0.16.2"
|
|
default-features = false
|
|
|
|
[dependencies.serde]
|
|
version = "1.0.228"
|
|
features = ["derive"]
|
|
|
|
[dependencies.serde_bencode]
|
|
version = "0.2.4"
|
|
default-features = false
|
|
|
|
[dependencies.serde_bytes]
|
|
version = "0.11.19"
|
|
|
|
[dependencies.sha1_smol]
|
|
version = "1.0.1"
|
|
default-features = false
|
|
|
|
[dependencies.thiserror]
|
|
version = "2.0.18"
|
|
default-features = false
|
|
|
|
[dependencies.tracing]
|
|
version = "0.1.44"
|
|
|
|
[dev-dependencies.clap]
|
|
version = "4.5.57"
|
|
features = ["derive"]
|
|
|
|
[dev-dependencies.colored]
|
|
version = "3.1.1"
|
|
|
|
[dev-dependencies.ctrlc]
|
|
version = "3.5.1"
|
|
|
|
[dev-dependencies.dashmap]
|
|
version = "6.1"
|
|
|
|
[dev-dependencies.flume]
|
|
version = "0.12.0"
|
|
default-features = false
|
|
|
|
[dev-dependencies.futures]
|
|
version = "0.3.31"
|
|
|
|
[dev-dependencies.histo]
|
|
version = "1.0.0"
|
|
|
|
[dev-dependencies.rayon]
|
|
version = "1.11.0"
|
|
|
|
[dev-dependencies.tracing-subscriber]
|
|
version = "0.3"
|