Protocol
DSTP/1The end-to-end encryption protocol behind every Drop2p transfer. We document it so you can verify what we do — and, in time, so anyone could build a compatible peer.
A transfer code is channel-secret. The client sends only the channel half to the signalling server to find its peer; the secret half never leaves the two endpoints.
Peers connect over a WebRTC data channel, which is already encrypted with DTLS. Everything below runs inside that channel.
Both sides run SPAKE2 (a PAKE, RFC 9382) keyed on the secret half of the code. They arrive at a shared secret only if the codes match — and a compromised signalling server can't substitute its own.
The PAKE output is expanded with HKDF-SHA-256 into an AES-256-GCM session key. Distinct labels keep purposes separated.
Every frame is sealed with AES-256-GCM under a monotonic counter used as the nonce and bound as additional data, so frames can't be reordered, dropped or replayed. A type byte distinguishes metadata, chunk and completion frames.
The filename and size travel in an encrypted metadata frame — never in the clear, never to the server. For protected transfers it also carries an Argon2id salt and a verifier.
With a passphrase, Argon2id derives a second key and each chunk gets an independent AES-256-GCM seal inside the code-derived one. The receiver verifies the passphrase locally before any bytes flow.
Per-frame tags authenticate every byte; a final size check rejects truncation; and the sender ships a SHA-256 of the whole file in the (encrypted) completion frame, which the receiver recomputes and compares end-to-end. The receiver gets exactly what was sent, or the transfer aborts.
Exactly what the deployed protocol does today. We'd rather under-promise than imply.
This page describes the deployed protocol. For the plain-English overview see Security; to try a real DSTP/1 peer in your terminal, see the developer docs.