Repository navigation
Releases
thenodes v0.4.0
Released 2026-09-07.
Summary
This pre-1.0 release unifies TLS and Noise trust decisions, adds optional UPnP
port mapping and NAT diagnostics, gives plugins isolated durable data
directories, and makes relay payload framing explicit.
Highlights
- Shared fingerprint trust semantics for TLS SPKI and Noise static keys,
including allowlists, exact pins, observe mode, and fail-closed TOFU. - Cryptographic WebPKI path and certificate-validity enforcement for TLS.
- Optional UPnP-IGD TCP mapping with lease renewal and conservative NAT
diagnostics. - Stable plugin identities and plugin-scoped data directories.
- Explicit base64 framing for opaque relay payloads, preserved through retries
and store-and-forward.
Breaking Changes and Migration
Plugin ABI 3
All plugins must be rebuilt against TheNodes 0.4.0 and provide a stable,
unique plugin ID:
fn plugin_id(&self) -> &'static str {
"my-plugin"
}Pin dynamic plugin dependencies to the host release:
thenodes = "=0.4.0"Plugin IDs may contain ASCII letters, numbers, ., -, and _. Existing
plugins that need durable state should obtain their assigned directory through
PluginContext::plugin_data_dir().
Relay Wire Format
RELAY_FWD now stores opaque application bytes in
msg_type.RELAY_FWD.opaque_payload_b64. The outer Message.payload must be
null. Upgrade all relay participants together; mixed 0.3.x and 0.4.x relay
paths are unsupported.
Compatibility
- Minimum supported Rust version: 1.83.
- Plugin ABI: 3.
- Default Cargo features remain empty.
- Noise requires the optional
noisefeature. - UPnP requires the optional
upnpfeature and explicit runtime activation
under[network.nat].
Known Limitations
- CRL and OCSP loading and enforcement are not implemented.
- UPnP support is limited to IGD; PCP and NAT-PMP are not implemented.
- NAT classifications are diagnostics, not guarantees of router behavior.
- UDP hole punching remains best-effort and some networks require relay
fallback. - Plugin code runs in process without sandboxing and must be treated as trusted.
See the full changelog,
plugin authoring guide, and
security documentation.
thenodes v0.3.0
Released 2026-09-05.
Summary
This pre-1.0 release adds UDP/Noise transport, NAT traversal and connection
policy, framework delivery semantics, and connection lifecycle monitoring.
Highlights
- Optional Noise-secured UDP sessions with config-driven capability
advertisement and NAT traversal support. - Framework-owned fire-and-forget, reliable, and ordered-reliable delivery
semantics. - Route health monitoring, heartbeat-based liveness, and automatic reconnect
policy. - Async plugin message handling and extension-kind subscriptions.
Breaking changes and migration
- Rust 1.83 or newer is required.
- Plugins must implement async
on_messageand be rebuilt for plugin ABI 2. - Construct
PluginContextwithPluginContext::new. - Manual
NetworkConfigconstruction must include the new optional transport,
connection policy, NAT traversal, and delivery fields. make_secure_channelreturns aResult; callers must handle configuration
errors.- Noise requires
--features noise. Selecting Noise without that feature now
rejects the connection instead of using plaintext. HELLOand delivery metadata have changed. Mixed-version deployments have
not been qualified; use a coordinated upgrade.
Compatibility
- Minimum supported Rust version: 1.83.
- Plugin ABI: 2. Plugins compiled against an earlier ABI must be rebuilt.
- The locked dependency graph is tested with default and all features on Rust
1.83. - UDP Noise transport requires the optional
noiseCargo feature.
Known limitations
- CA chain analysis is heuristic; complete cryptographic path validation
remains pending. - Certificate date extraction is a placeholder; validity flags do not yet
enforce certificate dates. - CRL/OCSP enforcement and Noise static-key trust policy remain pending.
- Hole punching is best-effort and some networks require relay fallback.
- Framework delivery acknowledgements are not application persistence or read
receipts. - Plugin persistence and end-to-end application encryption remain application
responsibilities.
See the full changelog and
security documentation for details.
thenodes v0.2.0
thenodes v0.2.0
Overview
TheNodes v0.2.0 is a major pre-1.0 milestone focused on closing the planned release gaps across security, persistence, and relay networking.
Compared to v0.1.0, this release includes substantial protocol and runtime updates, plus integration and reliability hardening.
Breaking Changes
- Wire message type tokens now use SCREAMING_SNAKE_CASE (e.g.
PEER_REQUEST,RELAY_BIND). Reasonenum values now serialize as snake_case (e.g.policy_denied,timeout).HELLOnow includes optionalcapabilities.connect_to_peer()now uses aConnectToPeerParamsstruct instead of positional arguments; the struct gains apeer_storefield that callers must supply.send_to_addr/send_to_node_idchanged from blocking.send().awaitto non-blockingtry_send()behavior.TrustMode::from_strandStoreNew::from_strare no longer plain associated functions; they now implementstd::str::FromStr(callers must handle theResult).
Added
- ADR-0001 complete: SecureChannel abstraction with backend selection.
- TLS backend
- Plaintext backend
- Optional Noise backend (feature-gated via
--features noise, usessnow0.9)
- ADR-0002 complete: Persistent peer store with config-driven load/save, TTL, caps, and periodic persistence.
- ADR-0003 complete: Relay node core implementation:
RELAY_BIND,RELAY_BIND_ACK,RELAY_FWD,RELAY_UNBIND,RELAY_NOTIFYACKtoken and reliable retry/ack scaffolding- Store-and-forward queueing with TTL and cap controls
- HRW/Rendezvous-based relay selection with capability gating
- New config sections (all opt-in, omitting a section keeps previous behaviour):
[network.persistence]—enabled,path,max_entries,ttl_secs,save_interval_secs[network.relay]—enabled,store_forward,queue_max_per_target,queue_max_global,selection[encryption.backend]— selectstls | noise | plaintextat runtime[encryption.noise]—pattern,curve,cipher,hash,static_key_path
- 10 new integration tests:
peer_store_cap,peer_store_persistence,peer_store_ttl,relay_notify,relay_store_forward,relay_ttl_unbind,reliable_ack,reliable_retry,qos_behavior, plusrelay_helpersshared harness.
Changed
start_listener()internal implementation replaced: inline TLS/rustls code removed; now fully delegates to the SecureChannel factory (public signature is unchanged from v0.1.0).- Runtime now consistently uses SecureChannel factory wiring for inbound/outbound handshakes.
- Startup now initializes peer persistence from merged runtime config.
- Relay queue limits are now configurable (
queue_max_per_target,queue_max_global) with safe defaults. - HELLO capability advertisement is centralized and config-driven across paths.
- Documentation and templates were aligned to v0.2.0 API surface.
Fixed
- Removed relay enqueue async lock/await hang risk in queue path.
- Discovery periodic task now sends real
PEER_REQUESTmessages. PEER_REQUESTnow returns actualPEER_LISTresponses.- Template generator now reliably materializes template files during app generation.
Quality Gates
All required release checks passed:
cargo fmt --all -- --checkcargo build --workspacecargo test --workspace --all-features -- --nocapturecargo clippy --workspace --all-targets --all-features -- -D clippy::correctness -D clippy::perf -W clippy::style -W clippy::complexity
Upgrade Notes
- Treat this as a protocol/API upgrade from v0.1.0; mixed-version interop is not expected.
- Update any integrations that depend on previous message token casing or old function signatures.
- If using templates or custom hosts, regenerate or align startup/prompt/listener wiring to v0.2.0 contracts.
thenodes v0.1.0
thenodes v0.1.0
Initial release of the thenodes crate: a modular, plugin-driven P2P node framework for Rust.
Highlights
- Core framework published as a library crate (dual-licensed Apache-2.0 OR MIT).
- Two operation modes:
- Node-Embedded Plugins (NEP): main binary can host plugins for app logic.
- Core-as-a-Library (CAL): use TheNodes as a reusable library in your own binaries.
- Async-first APIs built on Tokio; designed for non-blocking I/O and concurrency.
- Security and trust policy:
- TLS via rustls (optional, opt-in via config).
- PKI directory layout for own/trusted/issuer/rejected materials.
- Trust modes: open and allowlist; supports SPKI fingerprint and subject pinning.
- Realms to define logical network boundaries for compatible communication.
- Configuration-driven behavior (TOML).
- Examples and tests, including trust policy coverage.
Compatibility and stability
- Version 0.1.0 establishes the baseline API; pre-1.0 SemVer means breaking changes may occur in minor versions.
Getting started
cargo add thenodes@0.1.0
# or in Cargo.toml:
# thenodes = "0.1.0"Configuration (excerpt)
[encryption]
enabled = true
[encryption.paths]
own_certificate = "pki/own/cert.pem"
own_private_key = "pki/own/key.pem"
trusted_cert_dir = "pki/trusted/certs"
trusted_crl_dir = "pki/trusted/crl"
rejected_dir = "pki/rejected"
issuer_cert_dir = "pki/issuers/certs"
issuer_crl_dir = "pki/issuers/crl"Links
Notes
- TLS is enabled by default; disable it by setting
[encryption] enabled = falsein your config. - TheNodes includes a built-in tool to generate/manage PKI materials (CA and node certs/keys). Use it to create development or production certificates and place them into the configured PKI paths.
- PKI directories are required when TLS is enabled (the default).
- When TLS is disabled, all traffic is plaintext; use only in trusted/dev environments.
- Uses rustls; no OpenSSL/C interop.