Elysium profile, draft 1

The rules, end to end.

How the X25519MLKEM768 group of RFC 10024 is used on Elysium, where there is no TLS handshake: reader keys, the transcript, sealed envelopes, the contract and the limits we know of.

DocumentElysium Profile of RFC 10024, draft 1 StatusExperimental. Not an IETF document. Updated2026-12-03 GroupX25519MLKEM768, TLS Supported Groups value 4588 (0x11EC) ChainElysium, chain id 99901 ContractRfc10024, not deployed yet

1.Introduction

RFC 10024 defines three hybrid key agreement groups for TLS 1.3 that join ML-KEM, the module-lattice key encapsulation mechanism of NIST FIPS 203, with elliptic curve Diffie-Hellman. A shared secret from such a group stays safe as long as either component does.

A public blockchain keeps every byte it is given, forever, in the open. Anything encrypted on it with classical key agreement alone can be opened by whoever later holds a cryptographically relevant quantum computer. This profile brings RFC 10024's X25519MLKEM768 group to that setting. A reader publishes a client share on Elysium. A sender encapsulates to it, seals a short note under the resulting secret, and posts the envelope. Only the reader's secret key opens it.

RFC 10024 is written for TLS 1.3, and its security considerations warn that its analysis relies on the TLS transcript and does not carry over to other protocols unchanged. Section 5 therefore builds an explicit transcript for every envelope and binds the key derivation to it.

2.Conventions

The key words MUST, MUST NOT, SHOULD and MAY are to be read as in BCP 14 (RFC 2119 and RFC 8174) when, and only when, they appear in capitals. a || b is concatenation. Integers are big endian. HKDF-Extract and HKDF-Expand are those of RFC 5869 with SHA-256. Lengths are in bytes.

3.The hybrid group

This profile uses X25519MLKEM768 only. Its layout is that of RFC 10024 Section 4, with the ML-KEM part first. The RFC's other two groups put the elliptic curve part first.

                     ML-KEM-768 part      X25519 part     total
client share         encapsulation key    public share
                     1184                 32              1216
server share         ciphertext           public share
                     1088                 32              1120
shared secret        ML-KEM secret        X25519 secret
                     32                   32                64

Implementations MUST run the encapsulation key check of FIPS 203 Section 7.2 before encapsulating, MUST check the server share length before decapsulating, and MUST refuse an all-zero X25519 shared secret, as RFC 10024 Sections 4.2 and 4.3 require. The other two groups of the RFC (SecP256r1MLKEM768 and SecP384r1MLKEM1024) are checked by the handshake board but are not used for envelopes.

4.Reader keys

4.1Master secret

A reader holds one 32-byte master secret drawn from a cryptographically secure random generator. It MUST NOT be derived from a wallet key or a wallet signature. Elysium wallets use secp256k1, and an attacker who later recovers a wallet's private key from its public key could then rebuild any key derived from it, which would defeat the purpose of the ML-KEM half.

4.2Per wallet, per version

prk  = HKDF-Extract(salt = "RFC10024-ELYSIUM-KEY-V1", IKM = master)
seed = HKDF-Expand(prk, "x25519mlkem768 " || lowercase hex address || " v" || decimal version, 96)

The wallet address is part of the label, so two wallets that share one master secret publish unrelated shares and cannot be linked through them. Each published version gets a new key.

4.3Key pair

The ML-KEM-768 key pair is ML-KEM.KeyGen_internal(d, z) with d || z = seed[0..64]. The X25519 private key is seed[64..96], clamped as RFC 7748 specifies. The client share is the encapsulation key followed by the X25519 public key, 1216 bytes.

4.4Recovery code

The master secret is shown once as a recovery code: the prefix R10K, then the 32 bytes in Crockford base32 (52 characters), then 4 check characters taken from the base32 of the first three bytes of SHA-256 of the master secret, grouped in fours. Readers type it back to restore the key elsewhere. It is deliberately unlike a wallet seed phrase: it cannot move funds and no wallet will accept it.

4.5At rest

The reference page keeps the master secret in the browser's local storage, encrypted with AES-256-GCM under a key from PBKDF2-SHA-256 with 600,000 iterations of a passphrase of at least 8 characters. Unlocked, it lives only in the memory of the open tab.

5.Sealed envelopes

5.1Context

Every envelope is bound to a context: the chain id, the contract address, the recipient address, the sender address (the account that posts the envelope) and the version of the recipient's reader key.

5.2Transcript

th = SHA-256( "RFC10024-ELYSIUM-SEAL-V1"
            || chainId (8) || contract (20) || to (20) || from (20)
            || keyVersion (4) || client share (1216) || server share (1120) )

Hashing both shares into the transcript ties the key to the exact public key and ciphertext used, in the spirit of the TLS 1.3 key schedule, which binds every secret to the handshake transcript.

5.3Key derivation

prk = HKDF-Extract(salt = th, IKM = ML-KEM secret (32) || X25519 secret (32))
key = HKDF-Expand(prk, "rfc10024 elysium aead key", 32)

The input keying material is the 64-byte shared secret exactly as RFC 10024 Section 4.3 lays it out.

5.4Body

The note is UTF-8 text of 1 to 2000 bytes. The body is a 2-byte length, the text, then zero bytes up to the next multiple of 64, which hides the exact length. A reader MUST refuse a body whose padding is not all zero or whose length runs past the end.

5.5Envelope

envelope = 0x01 || server share (1120) || AES-256-GCM(key, nonce = 0 (12), aad = th).seal(body)

sizes:     1    +  1120               +  64 to 2048 (body)  +  16 (tag)
           smallest 1201, largest the contract accepts 5233

Every envelope comes from a fresh ML-KEM encapsulation and a fresh X25519 scalar, so every AEAD key is used exactly once and the fixed nonce is safe. A sender MUST NOT reuse an encapsulation for two envelopes.

5.6Opening

  1. Check the version byte and the sizes.
  2. Rebuild the reader key for the envelope's key version (Section 4.2).
  3. Decapsulate the server share; ML-KEM's implicit rejection turns a damaged ciphertext into an unrelated secret, so the failure surfaces at the next step.
  4. Rebuild the transcript from the on-chain context (the event's recipient, sender and key version) and both shares, derive the key, and open the AEAD.
  5. An envelope that fails to open MUST be reported as unreadable and nothing of it shown.

6.The contract

Rfc10024 is one small contract with no owner, no fee, no pause and no upgrade path. It checks sizes and key versions, stores a hash of each live share, and emits shares and envelopes as events. It never holds HYPE: value sent with an envelope is forwarded to the recipient in the same transaction.

function publish(bytes share) returns (uint32 version)          share: exactly 1216 bytes
function revoke()
function seal(address to, uint32 keyVersion, bytes envelope) payable returns (uint256 id)
function keyOf(address reader) view returns (bytes32 shareHash, uint32 version,
                                              uint64 publishedAt, uint64 publishedBlock)
function stats() view returns (uint256 keysPublished, uint256 readers, uint256 envelopes)

event KeyPublished(address indexed reader, uint32 indexed version, uint16 group, bytes share)
event KeyRevoked(address indexed reader, uint32 indexed version)
event Sealed(address indexed to, address indexed from, uint256 indexed id,
             uint32 keyVersion, uint256 value, bytes envelope)

error BadShareLength(uint256)     error BadEnvelopeLength(uint256)   error NoKey(address)
error StaleKey(uint32 live, uint32 given)                            error ValueNotDelivered(address)

Versions only grow: a revoke keeps the version counter, so a later publish never reuses a number. seal reverts with StaleKey when the recipient has moved to a newer version, so a sender never seals to a key the reader has replaced. publishedBlock lets a client fetch the share's event from one block. The contract does not check that a share is a valid ML-KEM key; senders MUST run the FIPS 203 check (Section 3) before sealing, and the reference page does.

7.The handshake checker

The board runs a small TLS 1.3 client written for this site. For each host it opens four connections: one offering X25519MLKEM768, x25519 and secp256r1 with key shares for the first two (the shape browsers send), then one for each RFC 10024 group alone. It reads the ServerHello, checks the selected group and the server share length, computes the hybrid secret, runs the TLS 1.3 key schedule, opens the encrypted handshake records and compares the server Finished MAC. Only a matching Finished MAC counts as a pass. It then closes the connection without sending application data. It does not judge certificate chains. The X25519MLKEM768 path calls the same module the Seal page uses to make and open envelopes.

8.Security considerations

8.1Harvest now, decrypt later

Envelopes are designed so that a recording of the chain does not become readable when large quantum computers arrive, provided ML-KEM-768 holds. Against attackers without one, they stay shut if either ML-KEM-768 or X25519 holds.

8.2What stays classical or public

  • Every Elysium transaction is authorised by a secp256k1 signature. This profile protects the content of envelopes, not control of accounts or funds.
  • The sender, the recipient, the time, the HYPE amount and the padded size of every envelope are public.
  • The sender cannot reopen an envelope after sending it: only the recipient's reader key can.

8.3Hybrid outside TLS

RFC 10024 warns that its hybrid's security analysis relies on the TLS 1.3 transcript. This profile mirrors that binding with the transcript of Section 5.2, which covers both public shares and the full context, and feeds it to HKDF as the salt over the concatenated secret. That follows the combiner guidance NIST SP 800-227 gives for hybrid constructions. It has not been through a separate formal analysis, and readers should weigh it accordingly.

8.4Key loss and theft

Losing both the saved key and the recovery code makes every envelope sealed to that key unreadable for good. Anyone who learns the recovery code can read all of them. A reader who suspects exposure SHOULD publish a new version; notes sealed to older versions stay readable to whoever holds the code.

8.5Randomness

Master secrets, encapsulation randomness and X25519 scalars come from the browser's crypto.getRandomValues. RFC 10024 points out that ML-KEM encapsulation reveals its randomness to the holder of the decapsulation key, so a weak generator leaks more than in classical Diffie-Hellman alone.

8.6Implementation

The reference implementation is JavaScript in the browser, built on the open source noble libraries for ML-KEM, X25519, SHA-2, HKDF and AES-GCM. JavaScript engines give no constant-time guarantee. Decapsulation runs only in the reader's own tab, which limits who can time it. The code is served as plain modules and can be read on this site: /js/pq/hybrid.js, /js/pq/seal.js and /js/pq/keystore.js.

9.Test results

  • Interop against OpenSSL 4.1.0: X25519MLKEM768, SecP256r1MLKEM768, SecP384r1MLKEM1024, x25519, secp256r1 and secp384r1, each under TLS_AES_128_GCM_SHA256, TLS_AES_256_GCM_SHA384 and TLS_CHACHA20_POLY1305_SHA256, every one ending in a matching server Finished MAC, plus a negotiation check and a refusal check: 20 of 20.
  • Live: every host on the board, rerun at most every ten minutes.
  • Unit checks: key sizes and layout, encapsulation and decapsulation, the FIPS 203 key check, the all-zero X25519 check, implicit rejection, envelope round trips, binding to each context field and to the recipient share, tampering at several offsets, padding rules, recovery code round trip and typo detection, passphrase storage: 51 of 51.
  • Contract: 16 tests including fuzzing of share and envelope sizes and value forwarding.

10.References

RFC 10024
Kwiatkowski, K., Kampanakis, P., Westerbaan, B. E., Stebila, D., "Post-Quantum Traditional (PQ/T) Hybrid Key Agreement Mechanisms for TLS 1.3", August 2026. rfc-editor.org/info/rfc10024
RFC 9954
Stebila, D., Fluhrer, S., Gueron, S., "Hybrid Key Exchange in TLS 1.3", July 2026.
RFC 9846
Rescorla, E., "The Transport Layer Security (TLS) Protocol Version 1.3", July 2026.
FIPS 203
NIST, "Module-Lattice-Based Key-Encapsulation Mechanism Standard", August 2024. doi.org/10.6028/NIST.FIPS.203
RFC 7748
Langley, A., Hamburg, M., Turner, S., "Elliptic Curves for Security", January 2016.
RFC 5869
Krawczyk, H., Eronen, P., "HMAC-based Extract-and-Expand Key Derivation Function (HKDF)", May 2010.
NIST SP 800-227
NIST, "Recommendations for Key-Encapsulation Mechanisms", September 2025.
RFC 2119, RFC 8174
Key words for use in RFCs to indicate requirement levels (BCP 14).

This profile is not an IETF document and is not endorsed by the IETF, the RFC Editor or the authors of RFC 10024.