A waiting peer or speed-test animation in an immediate egui viewport repainted the parent and its other windows. Each pass also supersampled the same 64-pixel logo and handed the new allocation to the OS. Give each Devices window its own repaint schedule. Wake it when status or shared controls change, reuse the native icon, and skip measuring the wide roster when its remembered minimum width exceeds the viewport. Use the bundled Phosphor StopCircle for single and batch tests. Bind incoming throughput probes to the signed address pair for the running diagnostic. Cache its validity across packets under a routing revision. A change of ownership, including removal or reassignment, revalidates the pair under the routing read lock. This removes a lock and a linear peer search from the steady-state receive path and keeps the timing, byte limits and wire protocol compatible. Give the traffic inspector a pinned header and compact, aligned rows with readable text in both themes. The column chooser keeps the peer visible on a narrow screen. Clicking a header sorts the complete filtered capture with a stable cursor across pages. Maintain one sort index on the window's scratch database and expire idle rates there. Address sorting uses numeric IP and port values. Peer and network sorting follows displayed names, including live name changes. Bump the applications, Android package and Nix package to 1.0.8. On macOS, verified formatting, workspace Clippy and all-target tests, including real encrypted tests between local agents. Rendered the monitor in light and dark desktop themes and at phone width. Built the arm64 Android debug APK and cross-checked the Windows GNU target. Across 500 optimized viewport updates, egui produced 500 native icon replacements on 1.0.7 and zero with this change.
122 lines
5.0 KiB
TOML
122 lines
5.0 KiB
TOML
[package]
|
|
name = "tsunagi-core"
|
|
version = "1.0.8"
|
|
description = "Small private mesh networks: persistent agent identity, deterministic network spaces, an iroh control plane, signed state and a local DNS view."
|
|
readme = "../../README.md"
|
|
keywords = ["mesh", "p2p", "iroh", "networking"]
|
|
categories = ["network-programming"]
|
|
edition.workspace = true
|
|
rust-version.workspace = true
|
|
license.workspace = true
|
|
repository.workspace = true
|
|
|
|
[lib]
|
|
name = "tsunagi"
|
|
|
|
[features]
|
|
default = []
|
|
# A real TUN device, so a plugin can carry actual IP traffic. On Linux it
|
|
# needs CAP_NET_ADMIN; on Windows the process must run elevated and
|
|
# `wintun.dll` must be reachable. Without either the in-memory device serves
|
|
# tests. The platform-specific dependencies are declared per target, so
|
|
# enabling this only pulls what the target it is built for actually uses.
|
|
tun-device = [
|
|
"dep:tun",
|
|
"dep:rtnetlink",
|
|
"dep:caps",
|
|
"dep:futures-util",
|
|
]
|
|
# Telling the operating system where to send its DNS questions. systemd-resolved
|
|
# on Linux, the Name Resolution Policy Table on Windows; the zone and the
|
|
# server work without it either way.
|
|
dns-publish = ["dep:zbus"]
|
|
# The test harness in `testing`, for this crate's own tests and for a
|
|
# protocol crate's. Not on by default: it is only of use to a test.
|
|
testing = ["dep:tempfile", "dep:tracing-subscriber"]
|
|
|
|
[dependencies]
|
|
tsunagi-speedtest = { path = "../tsunagi-speedtest", version = "0.1.0" }
|
|
arc-swap = "1.9"
|
|
iroh.workspace = true
|
|
# `net` for the local control interface: a Unix socket on Unix, a named pipe
|
|
# on Windows. Both live behind the same `net` feature.
|
|
tokio = { workspace = true, features = ["net"] }
|
|
tokio-stream = "0.1"
|
|
serde.workspace = true
|
|
postcard.workspace = true
|
|
bytes.workspace = true
|
|
thiserror.workspace = true
|
|
tracing.workspace = true
|
|
hex.workspace = true
|
|
data-encoding.workspace = true
|
|
rusqlite = { version = "0.40", features = ["bundled"] }
|
|
hkdf = "0.13"
|
|
hmac = "0.13"
|
|
sha2 = "0.11"
|
|
subtle = "2.6"
|
|
zeroize = { version = "1.9", features = ["derive"] }
|
|
rand = "0.10"
|
|
# Already in the tree through iroh. A packet codec, not a DNS server: the
|
|
# zone logic is ours and a full server framework would be a large dependency
|
|
# for answering A records from memory.
|
|
simple-dns = "0.12"
|
|
# IPv4 packet and checksum codecs shared by the Android VPN and Wintun.
|
|
smoltcp = { version = "0.12", default-features = false, features = ["std", "proto-ipv4"] }
|
|
# The IANA top-level domain list, compiled in: one function, no
|
|
# dependencies, no network. Used only to warn that a zone name shadows a
|
|
# real public domain, never to refuse one.
|
|
tld = "2.40"
|
|
fs4 = { version = "1.1", features = ["sync"] }
|
|
directories = "6.0"
|
|
# The real system hostname, without a libc call of our own: this crate is
|
|
# forbidden `unsafe` and will not make one.
|
|
gethostname = "1.1"
|
|
netwatch = "0.19.3"
|
|
netdev = "0.46"
|
|
mainline = "8.0"
|
|
futures-lite = "2.6"
|
|
tun = { version = "0.8", features = ["async"], optional = true }
|
|
# Only for the `testing` harness, which a protocol crate's tests use too.
|
|
tempfile = { version = "3.24", optional = true }
|
|
tracing-subscriber = { version = "0.3", features = ["env-filter"], optional = true }
|
|
|
|
# Linux-only interface provisioning. `rtnetlink` configures the interface in
|
|
# process, so no `ip` invocation is ever needed; `caps` keeps CAP_NET_ADMIN
|
|
# out of the effective set except during the moments it is used.
|
|
[target.'cfg(target_os = "linux")'.dependencies]
|
|
rtnetlink = { version = "0.23", optional = true }
|
|
# Pure Rust D-Bus, no libdbus to link against. `tokio` rather than the
|
|
# default reactor, because the agent brings its own.
|
|
zbus = { version = "5.19", default-features = false, features = ["tokio"], optional = true }
|
|
caps = { version = "0.5", optional = true }
|
|
futures-util = { version = "0.3", default-features = false, optional = true }
|
|
|
|
# Windows-only interface provisioning. The Wintun adapter itself is created
|
|
# and driven through the `tun` dependency, whose safe wrapper is the only way
|
|
# in — loading `wintun.dll` is an `unsafe` call this crate forbids. `netdev`
|
|
# (already in the tree through `netwatch`) reads the interface table through a
|
|
# safe wrapper, which is how the provisioner observes an adapter by name
|
|
# before deciding what to change. Creating an adapter needs the process to be
|
|
# elevated and `wintun.dll` to be reachable at run time.
|
|
[target.'cfg(target_os = "windows")'.dependencies]
|
|
smoltcp = { version = "0.12", default-features = false, features = ["medium-ip", "socket-tcp"] }
|
|
socket2 = { version = "0.6", features = ["all"] }
|
|
windows-sys = { version = "0.61", features = [
|
|
"Win32_Networking_WinSock",
|
|
"Win32_Security",
|
|
"Win32_Security_Authorization",
|
|
"Win32_Foundation",
|
|
] }
|
|
|
|
[dev-dependencies]
|
|
smoltcp = { version = "0.12", default-features = false, features = ["medium-ip", "socket-tcp"] }
|
|
socket2 = { version = "0.6", features = ["all"] }
|
|
# Its own tests use the harness it publishes.
|
|
tsunagi-core = { path = ".", features = ["testing"] }
|
|
tokio = { version = "1.53", features = ["rt", "rt-multi-thread", "sync", "time", "macros", "process", "test-util"] }
|
|
tempfile.workspace = true
|
|
tracing-subscriber.workspace = true
|
|
|
|
[lints]
|
|
workspace = true
|