
A secure, decentralized P2P ephemeral network in C++. Features a custom DHT, encrypted transport, and autonomous NAT traversal using high-performance asynchronous relays (epoll/kqueue).
A secure P2P network with custom Relay for hostile NATs, built in C++20.
Programmable forgetting for high-assurance peer-to-peer storage.
Shardian designs infrastructure for teams that take deletion guarantees as seriously as confidentiality. EphemeralNet is our C++20 research daemon for data that must disappear: a P2P protocol that uses enforced time-to-live (TTL) semantics as a first-class constraint. Instead of mutating BitTorrent-style swarms into ad-hoc retention policies, EphemeralNet treats each manifest, chunk, and routing hint as expendable material whose lifetime is negotiated at the edge and cryptographically enforced.
Every node runs eph, a compact daemon that exposes a gRPC-inspired control socket and a remote-style CLI. The kernel pairs a TTL-aware Kademlia DHT with ChaCha20/HMAC sessions, Shamir's Secret Sharing for key pulverization, and deterministic cleanup hooks so expired state evaporates across storage tiers, routing tables, and manifests simultaneously. The outcome is a mesh that can gossip, store, and fetch like a modern CDN overlay—while guaranteeing the data falls out of existence on schedule.
Unlike archival systems, EphemeralNet optimizes for temporal correctness: it verifies that a chunk cannot outlive its deadline, even if peers go offline. That makes it ideal for incident data rooms, temporary collaborative edits, and any workload that needs Zero Trust guardrails for deletion.
flowchart LR
subgraph "Operator Workstation"
CLI["eph CLI<br/>(remote shell)"]
end
subgraph "Local Host"
Demon["eph daemon<br/>(control+data kernel)"]
end
subgraph Mesh
DHT["Kademlia DHT<br/>(TTL-indexed)"]
Relays["STUN/TURN + Relay"]
Peers["Peer Swarm"]
end
CLI -->|gRPC-style control| Demon
Demon -->|announce/store/fetch| DHT
Demon -->|NAT traversal| Relays
Demon <-->|ChaCha20 sessions| Peers
eph binary exposes both the background service and a remote control surface for automation-friendly operations.| Platform | Command |
|---|---|
| Linux & macOS | curl -sSf https://eph.shardian.com/install.sh | sh |
| Windows (PowerShell) | iwr https://eph.shardian.com/install.ps1 -useb | iex |
The install scripts download the latest release artifact from GitHub, place
ephon your PATH, and print follow-up instructions.
# Start the daemon with loopback control plane, TCP transport on 45000
PS> eph start --storage-dir C:\temp\ephemeral --control-host 127.0.0.1
# Store a file with a 15-minute TTL; PoW is negotiated automatically
PS> eph store secrets.bin --ttl 900
# Fetch via manifest; direct-only keeps traffic on explicitly advertised peers
PS> eph fetch eph://6c5f... --direct-only --out C:\downloads
# Inspect node health, DHT saturation, and relay status
PS> eph status --verbose
# Check whether a newer CLI release is available
PS> eph update-check
# Configure (creates build/ and toolchain files)
cmake -S . -B build -DCMAKE_BUILD_TYPE=RelWithDebInfo
# Compile all targets (daemon, CLI, relay, tests)
cmake --build build --parallel
# Optional: execute the full test suite
ctest --test-dir build --output-on-failure
Use -DEPHEMERALNET_BUILD_TESTS=OFF to skip test binaries or -GNinja if you prefer Ninja builds.
The full operations handbook, protocol reference, and observability guides live at eph.shardian.com. Offline copies are mirrored under docs/ for air-gapped review.
Pull requests are welcome—start with a proposal in docs/todo.md or open a GitHub Discussion so we can align on scope. New modules should include design notes, telemetry hooks, and deterministic tests under tests/.
EphemeralNet is released under the MIT License. By contributing you agree that your work will be licensed under MIT and that you have the right to do so.