Sojourn

An open protocol for messaging that leaves nothing behind: no accounts, no phone numbers, no central switchboard, and no record of who talks to whom. Like email, it's a protocol: anyone can implement it or run a mailbox.

This is an early skeleton. It shows the shape of the envelope and nothing more. It hasn't been reviewed, it has no network layer yet, and it will change. Don't use it to protect anyone yet.

Design rules

  1. Nothing on the outside. An envelope carries no sender, no recipient and no account. A mailbox stores opaque blobs, and you find yours by trying to open them.
  2. Every envelope is one of four sizes. 2, 4, 16 or 64 KiB, so length says little about what's inside.
  3. Hybrid key agreement. X25519 and ML-KEM-768 (FIPS 203) are combined, so breaking one of them isn't enough, including with a future quantum computer.
  4. Signed inside the seal. The sender's Ed25519 signature covers the recipient's keys and the envelope's one-time key, so a message can't be re-sealed to someone else.
  5. One failure mode. Wrong recipient, tampering and garbage all look the same.
  6. No telemetry, ever. No analytics, no crash reporting, no phoning home.

Envelope, version 0

version (1) | ephemeral X25519 key (32) | ML-KEM-768 ciphertext (1088) | nonce (24)
| XChaCha20-Poly1305 ciphertext of:
    sender Ed25519 key (32) | signature (64) | message length (4) | message | zero padding

The key comes from HKDF-SHA256 over both shared secrets, salted with the one-time key and the recipient's X25519 key. The header is authenticated as associated data.

The code

Try it

cargo build --release
./target/release/sojourn keygen alice
./target/release/sojourn keygen bob
./target/release/sojourn send alice.secret bob.pub ./box "meet at the harbor"
./target/release/sojourn fetch bob.secret ./box

Still to build