| Internet-Draft | Y-Wing | December 2026 |
| Morrison | Expires 6 June 2027 | [Page] |
- Workgroup:
- Network Working Group
- Internet-Draft:
- draft-morrison-ywing-00
- Published:
- Intended Status:
- Informational
- Expires:
Y-Wing: A Three-Family Hybrid Sealed Box
Abstract
Data encrypted today can be recorded today and decrypted once any algorithm protecting it is broken. Some data must stay secret for longer than anyone can vouch for a single family of mathematics.¶
This document specifies Y-Wing, a sealed box that encrypts one message to one recipient under three key encapsulations from three unrelated families at once: X25519 (elliptic curves), ML-KEM-1024 (module lattices) and Classic McEliece mceliece6688128 (binary Goppa codes). The three shared secrets, every ciphertext and every public key, the two post-quantum keys by their digests, are hashed with SHA3-256, under a fixed label, into one content key. That key seals the message with XChaCha20-Poly1305. With SHA3-256 modelled as a random oracle, the content key stays secret while any one of the three shared secrets stays unknown. The document describes the construction exactly as a running implementation builds it, byte for byte, and states what its security argument covers and what it does not.¶
Status of This Memo
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 6 June 2027.¶
Copyright Notice
Copyright (c) 2026 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
1. Introduction
A hybrid key encapsulation mechanism combines a post-quantum component with a traditional one, and stays secure while either holds. X-Wing [I-D.connolly-cfrg-xwing-kem] is the best-known design of that kind. It joins ML-KEM-768 and X25519 with one SHA3-256 call, and [I-D.irtf-cfrg-hybrid-kems] generalises the pattern into four frameworks for one post-quantum and one traditional component.¶
Two components answer one question: what if the post-quantum algorithm is broken before quantum computers arrive, or the traditional one after? They do not answer a second. ML-KEM rests on module lattices, a structured problem with a far shorter record of study than the data some systems must protect will need. A break of that family would leave a two-component hybrid with only its quantum-vulnerable leg. Data recorded now and kept for decades has to survive that case too.¶
Y-Wing adds a third leg from a third family. Classic McEliece [MCELIECE] rests on the hardness of decoding binary Goppa codes. That problem has been studied since 1978 and shares no structure with module lattices. Its public key is large, a little over a megabyte at the parameter set used here, and this document carries that key by digest (Section 7).¶
The name follows X-Wing. X-Wing combines two families, and Y-Wing combines three, one for each stroke of the Y. The construction owes its shape to X-Wing, to the UniversalCombiner of [I-D.irtf-cfrg-hybrid-kems], and to the KEM-combiner analysis of [GHP18] on which that document draws. Section 8 sets out where it departs from X-Wing and from that document, and why.¶
This document is written from running code. Every length, byte order and input to the combiner below matches what the implementation in Section 9 produces, and the test vectors of Appendix A come from it.¶
1.1. Scope
Y-Wing is a public key encryption scheme for one recipient. It gives confidentiality and integrity of the sealed message against an adversary who does not hold the recipient's private key. It does not authenticate the sender, it does not give forward secrecy against later compromise of the recipient's key, and it is not an interactive key agreement. It takes no application context and no associated data, and it gives no separation between purposes that share one key bundle (Section 10.6). It defines no new primitive. It does not define a generic three-component combiner for arbitrary KEMs.¶
2. Conventions and Terminology
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
- Leg:
- One of the three key encapsulations in a box. The X25519 leg, the ML-KEM leg and the McEliece leg.¶
- Family:
- The mathematical problem a leg rests on. Elliptic-curve discrete logarithms, module lattices and binary Goppa codes.¶
- Key bundle:
- The recipient's public key, the concatenation of the three public keys of Section 4.¶
- Box:
- The output of sealing, laid out as in Section 5.1.¶
|| denotes concatenation of octet strings.
SHA3-256(x) denotes the 32-octet output of SHA3-256 over the
whole of x. All lengths are in octets.¶
3. Cryptographic Dependencies
- X25519:
- The function of [RFC7748] Section 5. Public and private keys are 32 octets, and the shared secret is the 32-octet output.¶
- ML-KEM-1024:
- The parameter set of [FIPS203] at NIST security
category 5. Encapsulation key 1,568 octets, ciphertext 1,568 octets,
shared secret 32 octets. The decapsulation key is kept in its 64-octet
seed form,
d || z, from which ML-KEM.KeyGen_internal derives both halves of the key pair.¶ - mceliece6688128:
- The Classic McEliece parameter set with m = 13, n = 6688 and t = 128, at NIST security category 5, from the round-4 specification [MCELIECE], as also specified in [I-D.josefsson-mceliece]. Public key 1,044,992 octets, private key 13,932 octets, ciphertext 208 octets, shared secret 32 octets.¶
- SHA3-256:
- The hash function of [FIPS202], with 32 octets of output.¶
- XChaCha20-Poly1305:
- The AEAD of [I-D.irtf-cfrg-xchacha], built on [RFC8439]. Key 32 octets, nonce 24 octets, tag 16 octets.¶
4. Keys
4.1. Public Key Bundle
The recipient's public key is the three component public keys in a fixed order, 1,046,592 octets in all:¶
offset length field 0 32 x25519_pk X25519 public key 32 1568 mlkem_ek ML-KEM-1024 encapsulation key 1600 1044992 mce_pk mceliece6688128 public key¶
Each field is the encoding that its own specification gives the
key. A sealer MUST refuse a bundle of any other length. It
MUST also refuse a bundle whose mlkem_ek fails the
encapsulation key check of [FIPS203] Section 7.2. The implementation relies on its runtime for that check. The runtime refuses such a key before any encapsulation.¶
4.2. Private Key
The recipient holds four values:¶
field length content x25519_sk 32 X25519 private key mlkem_seed 64 ML-KEM-1024 seed d || z mce_sk 13932 mceliece6688128 private key mce_pk_hash 32 SHA3-256(mce_pk)¶
The opener recomputes x25519_pk from
x25519_sk and mlkem_ek from mlkem_seed. It
cannot cheaply recompute mce_pk, which costs a full McEliece
key generation, and it keeps that key's digest. The private
key carries no lead byte or length prefix of its own. How it is
stored is a local matter.¶
4.3. Key Generation
The three component key pairs are generated independently, each by
its own algorithm with its own randomness: an X25519 key pair, an
ML-KEM-1024 key pair from a fresh 64-octet seed, and an
mceliece6688128 key pair. The key bundle is assembled as in
Section 4.1, and mce_pk_hash is computed at the
same time. A component key pair MUST NOT be used
outside Y-Wing. A key pair generated for another purpose
MUST NOT be used as a Y-Wing component. The
implementation of Section 9 does not enforce either
rule itself.¶
Y-Wing does not derive the three key pairs from one shared seed,
and its private key is the expanded form above.
[I-D.irtf-cfrg-hybrid-kems] makes one shared seed the
default decapsulation key. It allows separate key generation where
that cannot be instantiated, and says it should be used only where
component implementations do not allow decapsulation keys to be
imported or exported, with further measures against key reuse where
they do. The implementation of Section 9 allows
both, and a shared seed could be instantiated there. Y-Wing keeps the
expanded form because of the McEliece leg. From a seed, the
mceliece6688128 private key is known only after a full key
generation, since the seed that succeeds is found only by the matrix
reduction that also yields the public key
([I-D.josefsson-mceliece], Section 8.3). The opener
needs both mce_sk and SHA3-256(mce_pk). A
decapsulation key held as one seed would therefore cost a full McEliece
key generation, measured at 6.5 to 8.5 seconds
(Section 9), each time the key is loaded, and on
every open for an opener that does not keep the expanded key in
memory, against 70 to 85 milliseconds for the decapsulation itself.
The two reuse rules above are those that
[I-D.irtf-cfrg-hybrid-kems] sets for separate key
generation. This document adds no further measure, and
Section 10.3 states what the choice costs.¶
5. Sealing
5.1. Wire Format
A box is the following, with no other framing:¶
offset length field 0 1 version the octet 0x03 1 32 epk ephemeral X25519 public key 33 1568 ct_k ML-KEM-1024 ciphertext 1601 208 ct_m mceliece6688128 ciphertext 1809 24 nonce XChaCha20-Poly1305 nonce 1833 L ciphertext encrypted message, L = len(plaintext) 1833+L 16 tag Poly1305 tag¶
The fixed overhead is 1,849 octets, and a box is always 1,849 octets longer than the message it seals. The lead octet 0x03 names the whole construction: the three algorithms, their parameter sets, the combiner and the AEAD. A different choice of any of them is a different construction and takes a different lead octet. No registry of lead octets exists. The lead octet is not an input to the combiner, and the label of Section 5.2 separates the construction.¶
5.2. Content Key
The 32-octet content key is:¶
K = SHA3-256( ss_k || ss_m || ss_x
|| ct_k || ct_m || epk
|| SHA3-256(mlkem_ek) || mce_pk_hash || x25519_pk
|| label )
¶
where ss_k, ss_m and ss_x are the
three 32-octet shared secrets, mce_pk_hash is
SHA3-256(mce_pk), and label is the 32 ASCII octets
MLKEM1024-MCELIECE6688128-X25519, with no length prefix and
no terminator. Every input has a fixed length, and the transcript is
always 2,032 octets. An implementation MUST refuse to
compute K over a transcript of any other length.¶
This is the field order of the UniversalCombiner of
[I-D.irtf-cfrg-hybrid-kems]: shared secrets, then
ciphertexts, then public keys, then the label, with the post-quantum
component before the traditional one. Here the post-quantum component
is the pair of ML-KEM-1024 and mceliece6688128, in wire order, and
X25519 is the traditional component, a nominal group whose ciphertext
is epk. The X25519 public key goes in whole. The two
post-quantum public keys go in as their SHA3-256 digests
(Section 8.2).¶
The label names the three algorithms, post-quantum first. [I-D.irtf-cfrg-hybrid-kems] separates constructions that share a hash by asking that their labels form a suffix-free set. The Y-Wing label is not a suffix of the X-Wing label, and the X-Wing label is not a suffix of it.¶
5.3. Seal Procedure
To seal plaintext P to a key bundle:¶
- Split the bundle as in Section 4.1, refusing a bundle of the wrong length.¶
- Generate an ephemeral X25519 key pair
(esk, epk). Computess_x = X25519(esk, x25519_pk).¶ - Compute
(ss_k, ct_k) = ML-KEM.Encaps(mlkem_ek)per [FIPS203], refusing an encapsulation key that fails the check of Section 4.1.¶ - Compute
(ss_m, ct_m)by mceliece6688128 encapsulation tomce_pk.¶ - Draw a 24-octet
nonceuniformly at random.¶ - Compute
Kas in Section 5.2, hashingmlkem_ekandmce_pkto their digests.¶ - Compute
C || tag = XChaCha20-Poly1305-Encrypt(K, nonce, P, ""), with empty associated data.¶ - Output
0x03 || epk || ct_k || ct_m || nonce || C || tag.¶ - Erase
esk,Kand the three shared secrets.¶
A sealer that seals the same message to the same key bundle twice
produces two unrelated boxes, since epk, both post-quantum
ciphertexts and the nonce are all fresh.¶
6. Opening
To open a box with a private key:¶
- If the box is shorter than 1,849 octets, or its first octet is not 0x03, fail.¶
- Parse
epk,ct_k,ct_m,nonceand the remainder by the offsets of Section 5.1.¶ - Compute
ss_x = X25519(x25519_sk, epk). If that computation fails, including when its output is all zero, mark the box failed and setss_xto 32 random octets.¶ - Compute
ss_k = ML-KEM.Decaps(mlkem_seed, ct_k)per [FIPS203]. If it fails, mark the box failed and setss_kto 32 random octets.¶ - Compute
ss_mby mceliece6688128 decapsulation ofct_mwithmce_sk. If it fails, mark the box failed and setss_mto 32 random octets.¶ - Compute
Kas in Section 5.2, withx25519_pkandmlkem_ekrecomputed from the private key andmce_pk_hashtaken from it.¶ - Decrypt the remainder with XChaCha20-Poly1305 under
Kandnoncewith empty associated data.¶ - If decryption fails, or the box was marked failed, erase any plaintext and fail. Otherwise return the plaintext.¶
- Erase
Kand the three shared secrets.¶
All three legs run on every box, whatever happened to the leg before. An opener MUST report every failure that the box can cause, from any step, as one and the same error, and MUST NOT say which leg or step failed. A malformed private key or a runtime without one of the algorithms is a local fault, independent of the box, and MAY be reported separately. ML-KEM and Classic McEliece both decapsulate with implicit rejection. A well-formed but corrupted ciphertext therefore yields a pseudorandom secret with no error. The box then fails at the tag. The explicit failure branches catch malformed input and runtime errors.¶
The opener does not verify that the box was sealed to its own key bundle by any means other than the tag. A box sealed to another bundle, or with any octet altered, fails the tag check and is reported by the same error.¶
7. Key Carriage
A Y-Wing key bundle is 1,046,592 octets, and its base64url encoding is 1,395,456 characters. That is more than twenty-one times the 65,535 octets a DNS message over TCP can hold ([RFC1035] Section 4.2.2). A bundle is therefore never carried in line in a DNS record. It is carried by digest, as [I-D.morrison-mcp-dns-discovery] carries post-quantum keys in its Section 7.7 (Post-Quantum Key Carriage).¶
- The record carries the SHA-256 digest of the whole 1,046,592-octet bundle, in base64url without padding [RFC4648]. It is 43 characters long.¶
- The bundle is served at
https://<zone>/.well-known/alter-pk/<digest>[RFC8615] as the raw octets with media typeapplication/octet-stream.¶ - A sender MUST fetch the bundle only from a record that has passed DNSSEC validation, MUST accept only a body of exactly 1,046,592 octets, MUST stop reading at one octet past that length, and MUST compare the SHA-256 digest of the body with the record over all 32 octets before sealing anything to it.¶
- The resource is named by its own digest and never changes. A sender SHOULD fetch it once and cache it, and MAY seal to a cached bundle whose digest it has already checked for as long as the record still names that digest.¶
Every other retrieval rule of that section applies unchanged, including its refusal of a redirect to another host, and so do the rules of its Section 7.7.1 (Size Budget) on records split across character-strings and the retry over TCP when a UDP response is truncated. [I-D.morrison-mcp-dns-discovery] defines its key field for signature verification keys, and defines no record field or registry entry under which a zone names a Y-Wing encryption key. A revision of that document MAY define them. This document fixes only the octets that the digest covers.¶
A sender that seals many boxes to one recipient fetches the bundle once. After that, each box costs 1,849 octets of overhead.¶
8. Design Rationale
8.1. Why Three Families
A two-component hybrid survives the loss of one family. For data whose secrecy must outlast the confidence anyone can place in a single post-quantum family, that is one family too few. SIKE was a NIST fourth-round candidate when a classical key-recovery attack broke it in 2022. A hybrid that paired SIKE with X25519 would then have stood on X25519 alone. A quantum adversary holding recorded traffic breaks that leg later. Y-Wing keeps two post-quantum families so that the loss of either leaves a post-quantum leg standing.¶
The two post-quantum legs are both at NIST category 5. ML-KEM-1024 is the standardised lattice KEM. mceliece6688128 is the most studied code-based KEM, and its cost sits almost entirely in key size. Section 7 moves that cost off the per-message path.¶
8.2. Why Not an Existing Combiner
A reader who knows [I-D.irtf-cfrg-hybrid-kems] and X-Wing will ask why Y-Wing does not use one of their combiners. It uses the hash, the field order and the label convention of the first. It departs from both in two places, and only the first is a necessity.¶
First, neither applies as written. [I-D.irtf-cfrg-hybrid-kems] restricts itself to one post-quantum and one traditional component, and lists more than two components as out of scope. X-Wing fixes its components to ML-KEM-768 and X25519. Its combiner also leaves the ML-KEM ciphertext out of the hash, which rests on the ciphertext second-preimage resistance (C2PRI) of ML-KEM. Y-Wing makes no such assumption about Classic McEliece, and hashes every ciphertext as the UniversalCombiner of [I-D.irtf-cfrg-hybrid-kems] does. The Y-Wing combiner is, in structure, that UniversalCombiner with a second post-quantum leg joined to the first, and with the post-quantum public keys replaced by their digests. It uses SHA3-256, the KDF for which that document cites indifferentiability results against classical and quantum adversaries, and a fixed label placed last.¶
[I-D.josefsson-chempat] already pairs mceliece6688128 with X25519. It has two components and no lattice leg, and the case of Section 8.1 is outside it. It hashes the concatenated public keys to a digest before combining. That is the precedent for the digest step of Y-Wing.¶
Second, the digests. The UniversalCombiner hashes each
encapsulation key whole. For the McEliece leg that is a megabyte of
hashing on every seal and every open. The opener does not hold the
McEliece public key at all, since recomputing it costs a key
generation (Section 4.3). Y-Wing hashes a digest of each
post-quantum key, computed once, and the opener keeps
mce_pk_hash in its private key. With the hash modelled as a
random oracle the digest binds the key as firmly as the key itself.
The analysis of [I-D.irtf-cfrg-hybrid-kems] does not
cover this step, and Section 10.2 says so.¶
The digest is not optional for the McEliece leg.
[I-D.irtf-cfrg-hybrid-kems] records, after
[CDM23], that Classic McEliece provides MAL-BIND-K-CT but
no assurance at all of binding to its public key. With the digest in
the transcript, a change of McEliece key changes K. X-Wing
warns that leaving a post-quantum ciphertext out of the combiner is not
known to be safe in general, and Y-Wing leaves none out.¶
Moving Y-Wing the rest of the way onto [I-D.irtf-cfrg-hybrid-kems] would take two more changes: the post-quantum keys hashed whole, and key pairs derived from one shared seed, which both ML-KEM and Classic McEliece key generation permit, since each is driven by a short seed. Section 4.3 sets out why Y-Wing does not take the second. Either change would make a new construction under a new lead octet.¶
9. Implementation Status
This section is to be removed before publishing as an RFC.¶
This section records the status of known implementations of the protocol defined by this specification at the time of posting of this Internet-Draft, and is based on a proposal described in [RFC7942]. The description of implementations in this section is intended to assist the IETF in its decision processes in progressing drafts to RFCs. Please note that the listing of any individual implementation here does not imply endorsement by the IETF. No effort has been spent to verify the information presented here that was supplied by IETF contributors. This is not intended as, and must not be construed to be, a catalog of available implementations or their features. Readers are advised to note that other implementations may exist.¶
According to [RFC7942], "this will allow reviewers and working groups to assign due consideration to documents that have the benefit of running code, which may serve as evidence of valuable experimentation and feedback that have made the implemented protocols more mature. It is up to the individual working groups to use this information as they see fit".¶
~alter, the identity infrastructure operated by Alter Meridian Pty Ltd, deploys Y-Wing. An implementation in TypeScript on Node.js performs key generation, sealing and opening as this document describes them. X25519, ML-KEM-1024 and SHA3-256 come from the runtime's own cryptographic library. ML-KEM there needs Node.js 24.7 or later. The mceliece6688128 leg is the reference implementation from PQClean (SUPERCOP-20221025), compiled to WebAssembly from unedited sources.¶
The WebAssembly build reproduces the NIST known-answer test digest that PQClean records for mceliece6688128, and the implementation's tests repeat that check on every run. The test vectors of Appendix A were checked independently against Python's SHA3-256, libsodium's XChaCha20-Poly1305, a separate X25519 implementation and a separate ML-KEM implementation, and the tests replay them byte for byte in both directions. The McEliece ciphertext and shared secret have not been checked against a second McEliece implementation.¶
Measured in WebAssembly under Node.js on a desktop machine, an mceliece6688128 key generation takes about 6.5 to 8.5 seconds, encapsulation about 2 to 5 milliseconds and decapsulation about 70 to 85 milliseconds. A Y-Wing key pair is therefore generated once per device and kept.¶
The implementation is a library with tests. Keys are not yet published under Section 7. Contact: Blake Morrison, blake@truealter.com.¶
10. Security Considerations
10.1. The Claim
Model SHA3-256 as a random oracle. Then the content key
K of a box is indistinguishable from random to any adversary
for whom at least one of ss_k, ss_m and ss_x
of that box stays unknown. This holds while any one of the following
holds: the strong Diffie-Hellman problem in the X25519 group, in the
sense of [I-D.irtf-cfrg-hybrid-kems] Section 6.1.3; the
IND-CCA security of ML-KEM-1024; the IND-CCA security of
mceliece6688128. With K pseudorandom and used once, the
AEAD makes the box confidential against an adversary who may open
other boxes (IND-CCA), and any alteration of a box makes it fail to
open. Anyone holding the key bundle can seal a new, valid box.
Y-Wing does not show who sealed one (Section 1.1).¶
The argument is the KEM-combiner argument of [GHP18]
for n components, with the X25519 leg treated as a nominal group, as in
the UG framework of [I-D.irtf-cfrg-hybrid-kems], whose
IND-CCA analysis is [CG26].
The adversary learns nothing about K unless it queries the
oracle on the exact transcript, and the transcript contains the
unknown secret. Each ciphertext is in the transcript. An open
query on any box that differs in epk, ct_k or
ct_m hashes a different input and yields an independent key.
This is why no leg needs ciphertext second-preimage resistance. The
strong Diffie-Hellman reductions of X-Wing and of [CG26]
need the X25519 public key and the ephemeral key in the transcript, and
both are there. The label, fixed and last, separates the transcript
from that of any other construction whose label forms a suffix-free
set with it (Section 5.2). The digests
of the two post-quantum public keys bind the box to one key bundle: a
leg lifted out of one box and placed into a box for another bundle
changes the transcript and fails.¶
A box therefore stays closed until X25519, ML-KEM-1024 and mceliece6688128 have all fallen, provided the hash holds.¶
10.2. What Is Not Proved
- No published proof covers this exact transcript. The argument above adapts published proofs for two components and for n generic KEMs. It has not been written out as a full reduction or checked by machine. [I-D.irtf-cfrg-hybrid-kems] warns that any change to its algorithms is not guaranteed to produce secure results, and the third leg and the public key digests are such changes.¶
- The argument needs SHA3-256 to behave as a random oracle. [I-D.irtf-cfrg-hybrid-kems] cites indifferentiability results for SHA-3 against classical and quantum adversaries. The argument above is in the classical random-oracle model, and no quantum-random-oracle analysis of this construction exists.¶
- Binding against an adversary who chooses the recipient's keys is not claimed (Section 10.3).¶
- Constant-time behaviour of the WebAssembly McEliece code is inherited from the reference sources and has not been measured after compilation and just-in-time translation.¶
10.3. Binding and Key Generation
The three component key pairs are generated independently and the
opener trusts the mce_pk_hash it holds.
[I-D.irtf-cfrg-hybrid-kems] states that independent key
generation reduces its binding guarantees from an adversary who can
craft the decapsulation key to one who can only read it. The same
holds here. Y-Wing claims that the content key binds the ciphertexts
and the public keys against an adversary who learns the private key
(the LEAK binding notions of that document), and claims nothing
against one who chooses it. Every ciphertext and every public key,
the two post-quantum keys by their digests, is in the transcript, and
in that model binding of K to them reduces to the collision
resistance of SHA3-256, 128 bits against a classical adversary. A
private key whose mce_pk_hash does not match its
mce_sk opens nothing, and fails as every other failure does.
Section 4.3 gives the reason Y-Wing accepts the weaker
notion.¶
10.4. Nonce and Key Reuse
Every box has a fresh content key, because epk and both
post-quantum ciphertexts are fresh. The random 24-octet nonce is a
second safeguard against a sealer whose ephemeral randomness repeats.
A sealer that repeats all of its randomness repeats its box, and
nothing in Y-Wing defends against that.¶
10.5. Failure Reporting
All three legs run on every open and all failures share one error. An opener that reported which leg failed, or that stopped at the first failed leg, would hand an adversary an oracle on each leg separately and weaken the claim of Section 10.1 toward the weakest leg. Implementations MUST follow Section 6 in both respects.¶
10.6. One Key Bundle, One Purpose
The transcript carries one fixed label and no input from the application, and the AEAD has empty associated data. A box sealed for one purpose therefore opens for any other purpose that uses the same key bundle, and nothing in the box tells the opener which purpose it was sealed for. An application that seals for more than one purpose SHOULD give each purpose its own key bundle, or carry the purpose inside the sealed message and check it after opening.¶
10.7. Key Retrieval
A sender fetches a megabyte from a host it reaches through a record. The size bound and early stop of Section 7 limit what a hostile host can make it read. The digest check means a host can withhold a key and cannot substitute one. A sender that cannot retrieve and check a bundle does not seal to it.¶
11. IANA Considerations
This document has no IANA actions. The lead octet 0x03 is defined by this document alone. A record field and registry entry for carrying a Y-Wing key by digest would belong to [I-D.morrison-mcp-dns-discovery] (Section 7).¶
12. Normative References
- [RFC2119]
- Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, , <https://www.rfc-editor.org/info/rfc2119>.
- [RFC8174]
- Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, , <https://www.rfc-editor.org/info/rfc8174>.
- [RFC7748]
- Langley, A., Hamburg, M., and S. Turner, "Elliptic Curves for Security", RFC 7748, DOI 10.17487/RFC7748, , <https://www.rfc-editor.org/info/rfc7748>.
- [RFC8439]
- Nir, Y. and A. Langley, "ChaCha20 and Poly1305 for IETF Protocols", RFC 8439, DOI 10.17487/RFC8439, , <https://www.rfc-editor.org/info/rfc8439>.
- [RFC4648]
- Josefsson, S., "The Base16, Base32, and Base64 Data Encodings", RFC 4648, DOI 10.17487/RFC4648, , <https://www.rfc-editor.org/info/rfc4648>.
- [RFC8615]
- Nottingham, M., "Well-Known Uniform Resource Identifiers (URIs)", RFC 8615, DOI 10.17487/RFC8615, , <https://www.rfc-editor.org/info/rfc8615>.
- [FIPS203]
- National Institute of Standards and Technology, "Module-Lattice-Based Key-Encapsulation Mechanism Standard", FIPS 203, DOI 10.6028/NIST.FIPS.203, , <https://csrc.nist.gov/pubs/fips/203/final>.
- [MCELIECE]
- Albrecht, M. R., Bernstein, D. J., Chou, T., Cid, C., Gilcher, J., Lange, T., Maram, V., von Maurich, I., Misoczki, R., Niederhagen, R., Paterson, K. G., Persichetti, E., Peters, C., Schwabe, P., Sendrier, N., Szefer, J., Tjhai, C. J., Tomlinson, M., and W. Wang, "Classic McEliece: conservative code-based cryptography: cryptosystem specification", NIST Post-Quantum Cryptography Standardization, round 4 submission, , <https://classic.mceliece.org/mceliece-spec-20221023.pdf>.
- [FIPS202]
- National Institute of Standards and Technology, "SHA-3 Standard: Permutation-Based Hash and Extendable-Output Functions", FIPS 202, DOI 10.6028/NIST.FIPS.202, , <https://csrc.nist.gov/pubs/fips/202/final>.
- [I-D.irtf-cfrg-hybrid-kems]
- Connolly, D., Barnes, R., and P. Grubbs, "Hybrid PQ/T Key Encapsulation Mechanisms", Work in Progress, Internet-Draft, draft-irtf-cfrg-hybrid-kems-12, , <https://datatracker.ietf.org/doc/html/draft-irtf-cfrg-hybrid-kems-12>.
- [I-D.irtf-cfrg-xchacha]
- Arciszewski, S., "XChaCha: eXtended-nonce ChaCha and AEAD_XChaCha20_Poly1305", Work in Progress, Internet-Draft, draft-irtf-cfrg-xchacha-03, , <https://datatracker.ietf.org/doc/html/draft-irtf-cfrg-xchacha-03>.
- [I-D.morrison-mcp-dns-discovery]
- Morrison, B., "Discovery of Model Context Protocol Servers via DNS", Work in Progress, Internet-Draft, draft-morrison-mcp-dns-discovery-11, , <https://datatracker.ietf.org/doc/html/draft-morrison-mcp-dns-discovery-11>.
13. Informative References
- [I-D.connolly-cfrg-xwing-kem]
- Connolly, D., Schwabe, P., and B. E. Westerbaan, "X-Wing: general-purpose hybrid post-quantum KEM", Work in Progress, Internet-Draft, draft-connolly-cfrg-xwing-kem-11, , <https://datatracker.ietf.org/doc/html/draft-connolly-cfrg-xwing-kem-11>.
- [I-D.josefsson-mceliece]
- Josefsson, S., "Classic McEliece", Work in Progress, Internet-Draft, draft-josefsson-mceliece-05, , <https://datatracker.ietf.org/doc/html/draft-josefsson-mceliece-05>.
- [I-D.josefsson-chempat]
- Josefsson, S., "Chempat: Generic Instantiated PQ/T Hybrid Key Encapsulation Mechanisms", Work in Progress, Internet-Draft, draft-josefsson-chempat-05, , <https://datatracker.ietf.org/doc/html/draft-josefsson-chempat-05>.
- [CDM23]
- Cremers, C., Dax, A., and N. Medinger, "Keeping Up with the KEMs: Stronger Security Notions for KEMs and automated analysis of KEM-based protocols", Cryptology ePrint Archive, Paper 2023/1933, , <https://eprint.iacr.org/2023/1933>.
- [CG26]
- Connolly, D. and P. Grubbs, "StarFortress: Hybrid KEMs with Diffie-Hellman Inlining", IACR Communications in Cryptology, vol. 3, no. 1, DOI 10.62056/ahmp-49p1, , <https://doi.org/10.62056/ahmp-49p1>.
- [GHP18]
- Giacon, F., Heuer, F., and B. Poettering, "KEM Combiners", Public-Key Cryptography - PKC 2018, LNCS 10769, pp. 190-218, DOI 10.1007/978-3-319-76578-5_7, , <https://doi.org/10.1007/978-3-319-76578-5_7>.
- [RFC7942]
- Sheffer, Y. and A. Farrel, "Improving Awareness of Running Code: The Implementation Status Section", BCP 205, RFC 7942, DOI 10.17487/RFC7942, , <https://www.rfc-editor.org/info/rfc7942>.
- [RFC1035]
- Mockapetris, P., "Domain names - implementation and specification", STD 13, RFC 1035, DOI 10.17487/RFC1035, , <https://www.rfc-editor.org/info/rfc1035>.
Appendix A. Test Vector
One vector from the implementation's set, sealing the empty
message. Every random input is fixed, and an independent
implementation can reproduce every value from them. The McEliece key generation
seed is the first 32 octets of SHAKE256 of the recipient's stream seed.
The ML-KEM encapsulation is ML-KEM.Encaps_internal of
[FIPS203] with the stated m. The McEliece
encapsulation reads its randomness from SHAKE256 of the stated stream
seed, 512 octets in the order of the reference implementation's calls.
A second McEliece implementation that samples in another order will
produce another ct_m, and it can still check ss_m by
decapsulating the stated ct_m. The McEliece public key, the
key bundle and the box are given by their SHA-256 digests. The full
set, three boxes with every intermediate value, is available from the
author.¶
recipient x25519_sk 90629e551c07cdb6d190b03789826b891742ac823be4187ea65c9258b21af665 recipient x25519_pk 520b74bd2b347c452d791a0202160bd8c971771d75c2dc288b2253bce2946a7b recipient mlkem_seed (d || z) b249b03e463eeff01dc37c26aa37f06c3dc70536596015954a2a00329084b404 8ae31537de82c6ecfb77e5b1cfceb3b6b851ec753d6fffad4f6d6d675ad8ad92 recipient McEliece stream seed 69e73abc8bfe76fff35b5b7ddc074725267c3d6ce834c7a2bbb42f504c816174 McEliece key generation seed, SHAKE256(stream seed) first 32 octets e0127db4c631ea1d3c79fb5b2c8be599dfdcfaea6315eafb054112ff614c61f2 SHA3-256(mlkem_ek) fbf7e68057b4852633bbd05594272c76c2006fc24bcd8df094b793621345e86a SHA3-256(mce_pk), mce_pk_hash e7e5c21c9d0e385e88008da51c47c42f7c8216f5f3532abc3e506d02d3a7b0a4 SHA-256(mce_pk) a967afe4531e81c317e98611e565c196343f91fb26daa87346090cfc83ecb93e SHA-256(key bundle), the digest a record carries 90e57875bdf229817e49d74f48787a75071492568e8c2443bc00b96a3bd1160f¶
ephemeral esk c1e0d66727a3dd3a07cf111a25ac303bc91a4c1b740a1f31e6209970efaef46d epk e047c836ea2d0fe9f9b39f0c50b75e2010a5245f45189b69a90911ee05c27f03 ss_x 10f12450594d4aac770b1251265f8294b7113222df89e8e2628bee0081fefb0a ML-KEM encapsulation m 9d8973478a254257662130104c9681577de3cdb404ddf71aa3112d3000899105 ct_k (1,568 octets), octets 0 to 799 f1a4c3b92c805017f94f6ba99e66fb1693c93f951d5a080a6580306eb4452ec9 f8aec3f1968adc3bfac53db933950015d9a614e1b85211786dd6ed87025e53ca 5f6af1001d0a2a1857540a9eee1802f4b1c4853644833003b0387d00e38fff0e 20a7dce7123fbf3cdfef4b68a12e9ef1238a2b20ffd614abb55e4041a4236d00 1bbc6b49e954aa08f02233078f0187e74c0b4fa6f4b02924a36201f9b429b68a 38e3b98eb51a583bba04a29680667292902ac2e7ca662821103c978e7b177aac 76bf4117f12840c50157c56a50d439cb8ee06e7da9fc1212281ccba0c0a102c7 a03716528983c3ec169f61fba2ed4a62770e287b7717014e2dee53fb5b62121b d1e30d4f10531a423345061f50b230f278d388dd31d06655a149da8086d5cdfc c1ee9ac407ec816bd68dd8964612ff1afca8eef3fbf5b38f12b9a777fbb735d5 22d884fba99b41abb711488b46d4bfbe7ce907535e7c4e869fdb54c18270b682 04697557265f1e981194020e746e2be6f676ef3ab91af28a63828135dd32e1b1 60011963b9a7ced4860220c8627862239c0d00fcc742400111eccac1ef6c7856 c2d2ccf2e92c38a7649e2843447a72fb9fa66c5b0bb66a24a5c847b7eb5199bc ef6a49d35a72c4cf720b533dd886ab924013ba68dcb1274002c6f8eb44094bea afca83c4322ce4483d1e959e46211b90d9fe765d1e5166cc2b5348e2b735148e 420162c5ce9bb56d0cccbc0d566d37cb0a8b69815af51dfce95048930b97c172 407672be51262191c25b8afb5a1627c68acaa3c1a47be7013c0bd88635c22694 694ee8f990914fa3e14265fe72334cc3b595f28f72b8eef60ddbdde8da0c00a9 a72175f401e2f2ebf25b8bf979cc68bacb7365a908b28df7ee12405ae8b1c0dc ce47f7a5b37cf183e97c11de3a1be051db33445e097d5ba3abaf042d501e366c 024396d0bd6fdff6aa1d18cc2d8dbe71b0499859141221f799bc95d12640f537 102d4beec20deafba033a45da71d7922eb2a4131240633627bd4e75ae39b87d1 868274c3b33a0732c5f82eadea0df02a3ab4222122212b72a26d0b0baa61d1c0 b3c16383b25c139d313ff47d1905cd07642ba26562da767122a2a9d86cfbb5ea¶
ct_k, octets 800 to 1,567 63ef9b56d7ace3b5a3e8075d3d531cd3961915be25196dd6e313b6fdb4f0cf51 368820ed59169637aad18e4f958a02326387a2ba89f0c87746e3b38e01c0ee6d 60fbc030e78edd20175c05d44143ceeb485ebb46689c393ee3e9080d639fefd5 ef9a7f14da725849c731bebfbdab30c02c490de5f785f8adcc35eb9e2377bcfd 3c4c11ff41ae3b250db4bd6b58980cfdfd9b747790a9899fcc139838ebfc4939 0945d5cd2487535d457e9f0e95d66703253be8684093f3054b72a63124d033f2 330ff78e427599c1874a7174330b63fe3a8313affe7b99adc2108d536d5601d2 d82c21c2264c24e931b802ee485910a87be82870cee21eddc94e5c53f983997a 228ac8b8194406a8317a707e72c042b2a233ced10383a1e579c3725319b59812 178222769b00994ce88d3f1231a5342d8ff049a1781d4df651da3037fb71e99c e9fbac65757c2fc67f2d91341ff8a7f3bd5a6f6c5f28c7b03bbef548bc19dfd6 e2a7f3cf3c9b72e179d7c83ee74f005a203eb35fb8e15f005d5a918e5bf50154 0d2653f2c0e6137130867a9bb37b4eb4bfbb10cdc391851a44272cbe36dfbb9a 14d3d7422de33d55ceb09ee1befbb660e64414ad1928a97e0e369d316d0b53c2 14526b0a6311b4e0eecb8f3a2840461c70b0c0ee7906ca10095d22e9240d8503 30d6b44016e9209237f5fee420aa9a4eb16955a4a5c69ccaf08eb2dfbc501f88 646d2b6c43a9f6c7b75dfb0617cddd37e1ccb739d097f803557ea8be1d7406f3 311af935af55176be69fcafc08c8031d86ec3da3eeade99f552f17a1b6ae8a7d 89ab16025c3f28cf9e678f29c580395a4b0e280b62b4eb25d35fad2a5ac0b646 4406f2481f389adefe425830c16da0f5ab53ae0a0f644d2c20c4435c338cf823 94e714dc083b0b5b9f6aa1b06c651a049994e59f178bb019c989af320c0ebe6f 8162d3a1b23565666d49baa5f796c64ec3bdf5c2758b3ba238ad054209759803 ee35f5529e1c4066c3ef08e8cdbb5c7a7232bc9adf8217b4251da646b2c53a66 94649d8d99aec92bcd27556586efd43087b48ed35a57fe6da1144610bd2b0acc¶
ss_k e159b588076f6b4fda4baa811138956c23fd484f69234176ab40eea08810c416 McEliece encapsulation stream seed 0ccee39016f89c5168d1874eeb983c8d0db0ff500c5b4253c803ed8ea6496f50 ct_m (208 octets) d71b9f9ec0c44a2ddbda3c16608e750ee66033f96828bf14e128e907faccb7d6 26dc64e0b50fa12f3427303adcc4b5e394745481ebdcf7be8de4c7db2f9c96b7 bd1ae6d705176f7ef4acdb35da19ffb0648c49419b0ec815ef0569f93e0997b5 7fbd8e4631aa465790ed36ab50edafef602627d693af1f986b14779cd2dbebc3 754ad4687239bbb6fb877c13d176801fc6fee4ad5bc0a47a12b16a3bee47c3e8 10c6617932f86eff969dbcdbf5f3866a2025d7b45ab8214d071ca45aefc65833 abd1e746a82fb00d6bea91dd4c6d7367 ss_m 02a66b135d0a6e699f68df77783f310d32b458c57c6ee93cecc9bd00ada64978 nonce 2397a42d1e2adc39db7993b284cf4c8a4d6064fc29f0184d label (32 octets, ASCII MLKEM1024-MCELIECE6688128-X25519) 4d4c4b454d313032342d4d43454c49454345363638383132382d583235353139 K (transcript of 2,032 octets) f0df5cc891ff1e02500a44c6f404a34e9ad4d15abfe90bffc0aa7340f585dba8 box length 1849 SHA-256(box) 86e8eeeec565fac48f80f6bf66e97f71cc8a4bd203d522357a2483839c5b78ef¶
Document History
-00: First version.¶