Ping-Pong Wake Protocol

Secure Legion's stateless, serverless delivery handshake that ensures messages are only delivered when you are physically present and have unlocked your device.

1

Purpose

The Ping-Pong Wake Protocol is Secure Legion's stateless, serverless delivery handshake. It solves one brutal requirement:

"Do not deliver a message to my device unless I am physically present and have unlocked it."

This guarantees:

No centralized queue
No metadata about communication partners
No auto-delivery to seized/compromised devices

Ping-Pong is the high-security mode of Secure Legion. Other users can still use the asynchronous encrypted relay mode for convenience.

2

Roles

Sender (S)

Creates and encrypts the message.

Receiver (R)

Authenticates and retrieves the message.

No permanent servers or relays are required. Relays can act only as ephemeral transport layers for wake tokens, never as message custodians.

3

Cryptographic Material

Each Secure Legion identity includes:

Identity Key (Ed25519)

Long-term signing key for authenticity.

Wake Key (X25519/Kyber768)

Used for ping/pong wake encryption.

Session/Chat Keys

Ephemeral keys for message encryption (Double Ratchet-style).

Onion Encryption Key

Protects locally queued messages.

All private keys are stored in hardware security modules (SecureEnclaves / Secure Elements).

4

Lifecycle Overview

1

Sender creates message M.

2

M is encrypted → ciphertext C.

3

C stored locally (encrypted queue).

4

Sender sends encrypted Ping Token to Receiver.

5

Receiver wakes, authenticates, sends Pong.

6

Sender transmits ciphertext C → Receiver.

7

Receiver decrypts and displays. C is deleted.

5

Sender Behavior

Message Preparation

  • Encrypt plaintext M → ciphertext C.
  • Store C locally (per-contact encrypted queue).

Ping Creation

  • Create Wake Token: {nonce, metadata_hash = hash(nonce)}
  • Encrypt with Receiver's Wake Key → Ping.
  • Sign with Identity Key.

Ping Transport

  • Direct (online peer)
  • Tor onion route
  • Encrypted Push/Notification / UDP channel

Relays only move opaque encrypted tokens, not messages.

6

Receiver Behavior

Wake & Authentication

  • Receiver decrypts Ping(s) via Wake Key.
  • User authentication (PIN, biometric) required before generating Pong.
  • Prevents message delivery to seized/locked device.

Pong Response

  • Receiver constructs Pong.
  • Includes original nonce, signature, ephemeral address.
  • Sends encrypted Pong back to Sender.
7

Secure Transfer After Pong

1

Sender verifies Pong and matches to queued message ID.

2

Sender transmits ciphertext C over secure channel.

3

Sender deletes C.

4

Receiver decrypts in memory.

5

For view-once messages, keys and plaintext are erased instantly.

8

Key Advantages

Device-Gated Delivery

Messages can't arrive without verified user presence.

Zero Metadata Exposure

Relays only see opaque, fixed-length tokens.

Configurable Privacy Profiles

Users can choose Ping-Pong (real-time, max security) or asynchronous mode with encrypted time-limited storage.

9

Storage Model

ComponentStored WhereNotes
CiphertextSender DeviceEncrypted, TTL-based
Wake TokensTransportOpaque, fixed-size
Private KeysHardware EnclaveNon-exportable
10

Failures & Timeouts

Each queued message has:

TTL: 7 days (example)
Retry Limit: 5–10 attempts
Stale challenge: Senders request updated tokens/relays
11

Duress PIN Integration

When a duress PIN is entered:

Device wipes local private keys.

Broadcasts signed revocation event.

Senders delete queued messages for that identity.

12

Patentable Novelty

Two-phase authenticated wake handshake (Ping + Pong)
Biometric/PIN-gated message release
Serverless metadata-free wake transport
Duress-triggered cryptographic revocation

Summary

The Ping-Pong Wake Protocol gives users control over when and how their encrypted messages are delivered.

No central servers, no metadata leaks, and complete receiver autonomy — fulfilling Secure Legion's promise:

No servers. No metadata. No compromises.