π Wave-32: welcome_encrypted_group_info_aead + proposal_ref_collision#773
Open
gHashTag wants to merge 1 commit into
Open
π Wave-32: welcome_encrypted_group_info_aead + proposal_ref_collision#773gHashTag wants to merge 1 commit into
gHashTag wants to merge 1 commit into
Conversation
β¦sal-ref-collision
Anchor: ΟΒ² + Οβ»Β² = 3
Two fresh threat-model lanes following the W7..W31 canonical cadence.
Lane A β L-CHAT-1-wegi (R-CHAT-1 / CR-CHAT-01):
crates/trios-chat/rings/CR-CHAT-01/src/welcome_encrypted_group_info_aead.rs
(268 lines) shipping validate_welcome_aead_envelope(envelope, view).
Consts WELCOME_GROUP_INFO_AEAD_NONCE_LEN = 12,
WELCOME_GROUP_INFO_MIN_CT_LEN = 16. Six rules in fixed order from
RFC 9420 Β§12.4.3 (Welcome / encrypted_group_info AEAD envelope β
nonce length + ciphertext bound + cross-group + epoch + replay):
1. NonCanonicalAeadNonceLength β reject any AEAD nonce whose
byte length is not 12 (HPKE / AES-GCM canonical).
2. ShortAeadCiphertext β reject ciphertext whose length is less
than 16 bytes (AEAD tag is 16 bytes minimum).
3. CrossGroupAeadEnvelope β reject envelope whose group_id !=
view.local_group_id.
4. StaleEpochAeadEnvelope β reject envelope whose epoch !=
view.current_epoch.
5. ReusedAeadNonce β reject any (group_id, epoch, nonce) triple
already present in view.used_aead_nonces (catastrophic
AEAD nonce-misuse hazard).
6. ZeroAeadNonce β reject the all-zero AEAD nonce (degenerate
AEAD encapsulation / sentinel for uninitialised state).
WEGI-01..10 unit tests (10 new tests).
Lane B β L-CHAT-3-pref (R-CHAT-11 / CR-CHAT-03):
crates/trios-chat/rings/CR-CHAT-03/src/proposal_ref_collision.rs
(265 lines) shipping validate_proposal_ref(proposal, view).
Consts PROPOSAL_REF_LEN = 32, PROPOSAL_ID_MAX_LEN = 255.
Seven rules in fixed order from RFC 9420 Β§12.1.1
(ProposalRef = MAC(membership_key, ProposalContent) β canonical
length + provenance + cross-group + epoch + replay):
1. NonCanonicalProposalRefLength β reject any proposal_ref whose
byte length is not 32 (KDF output canonical size).
2. EmptyProposalId β reject zero-length proposal_id (spec
mandates a non-empty identifier).
3. UnknownProposalRef β reject proposal_ref β
view.known_proposal_refs (provenance hazard β unsourced
commits).
4. CrossGroupProposalRef β reject proposal whose group_id !=
view.local_group_id.
5. StaleEpochProposalRef β reject proposal whose epoch !=
view.current_epoch.
6. ProposalRefReplay β reject (group_id, epoch, proposal_ref)
triple already present in view.applied_proposal_refs (replay
attack across commits).
7. ZeroProposalRef β reject the all-zero proposal_ref
(degenerate MAC output / sentinel for uninitialised state).
PREF-01..10 unit tests (10 new tests).
Falsifier corpus: 3000 β 3100 (+50/+50). New categories
welcome_encrypted_group_info_aead + proposal_ref_collision with IDs
PI-WEGI-001..050 and PI-PREF-001..050. Offline-sim 3100/3100 blocked,
0 misses, 62 categories.
DENY_PATTERNS: 5120 β 5321 (+201 W32 patterns) in
crates/trios-chat/rings/CR-CHAT-06/src/injection.rs under the
`// -- Wave-32: welcome-encrypted-group-info-aead + proposal-ref-collision --`
block. No closer patches were needed β offline-sim returned
100/100 W32 prompts blocked on the first pass.
Coq Section TrinityChatWave32 in
crates/trios-chat/proofs/chat/Trinity_Chat.v (lines 4418β4540)
closes 7 new theorems + 4 helpers:
INV-CHAT-194 inv_chat_194_wegi_non_canonical_aead_nonce_len_rejected
INV-CHAT-195 inv_chat_195_wegi_short_aead_ciphertext_rejected
INV-CHAT-196 inv_chat_196_wegi_cross_group_envelope_rejected
INV-CHAT-197 inv_chat_197_wegi_stale_epoch_envelope_rejected
INV-CHAT-198 inv_chat_198_pref_non_canonical_proposal_ref_len_rejected
INV-CHAT-199 inv_chat_199_pref_empty_proposal_id_rejected
INV-CHAT-200 inv_chat_200_pref_unknown_proposal_ref_rejected
helpers: wegi_canonical_envelope_accepted_32,
wegi_min_ciphertext_accepted_32,
pref_canonical_proposal_accepted_32,
pref_one_byte_proposal_id_accepted_32.
Cumulative Qed: 288 β 299. 0 admissions. 0 new axioms (cumulative
axioms still ss_kp_injective W9, dh_step_fresh W10,
dh_post_history_independent W10, hybrid_kem_non_degenerate W10,
sn_hash_sym W14).
falsifier_runner: added `("welcome_encrypted_group_info_aead", 0.95)`
and `("proposal_ref_collision", 0.95)` to the threshold-lane list.
G-C10 summary line now enumerates all 62 categories.
ROADMAP.md updates: status line W32, +2 anchor tokens
WELCOME-ENCRYPTED-GROUP-INFO-AEAD + PROPOSAL-REF-COLLISION,
Wave-31 row finalised with `756cf35` + PR #771, new Wave-32 bold row
+ full detail section, INV mapping row INV-CHAT-194..200 W32, axiom
summary extended through Wave-32, future-waves shifted to W33..W37,
W32 VERIFIED footer.
Stats after W32:
- ~548 tests / 0 failures (expected)
- 25/25 e2e
- 3100/3100 falsifier blocked across 62 categories
- 299 Coq Qed / 0 Admitted / 5 axioms (unchanged)
- 0 unsafe, 0 monoliths, clippy clean
Closes #772
Co-Authored-By: Trinity Grandmaster <admin@t27.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #772
π Wave-32 β welcome_encrypted_group_info_aead + proposal_ref_collision
Anchor:
ΟΒ² + Οβ»Β² = 3Two fresh threat-model lanes following the W7..W31 canonical cadence.
Lane summary
encrypted_group_infoAEAD envelope: non-canonical nonce length,short ciphertext, cross-group, stale epoch, AEAD nonce reuse, and
zero-nonce per RFC 9420 Β§12.4.3. Module
crates/trios-chat/rings/CR-CHAT-01/src/welcome_encrypted_group_info_aead.rs(268 lines) with 6 rules
NonCanonicalAeadNonceLengthβShortAeadCiphertextβCrossGroupAeadEnvelopeβStaleEpochAeadEnvelopeβReusedAeadNonceβZeroAeadNonce.WEGI-01..10 (10 unit tests).
non-canonical length, empty id, unknown ref, cross-group, stale
epoch, replay, zero-ref per RFC 9420 Β§12.1.1. Module
crates/trios-chat/rings/CR-CHAT-03/src/proposal_ref_collision.rs(265 lines) with 7 rules
NonCanonicalProposalRefLengthβEmptyProposalIdβUnknownProposalRefβCrossGroupProposalRefβStaleEpochProposalRefβProposalRefReplayβZeroProposalRef.PREF-01..10 (10 unit tests).
welcome_encrypted_group_info_aeadproposal_ref_collision, IDsPI-WEGI-001..050/PI-PREF-001..050). Offline-sim: 3100/3100 blocked, 0 misses,62 categories.
// -- Wave-32: welcome-encrypted-group-info-aead + proposal-ref-collision --block in
crates/trios-chat/rings/CR-CHAT-06/src/injection.rs.No closer patches were needed.
crates/trios-chat/proofs/chat/Trinity_Chat.vβ 7 theoremsINV-CHAT-194..200 + 4 helpers; cumulative
Qed.288 β 299;0 admissions; 0 new axioms.
("welcome_encrypted_group_info_aead", 0.95)and("proposal_ref_collision", 0.95).finalised with
756cf35+ PR π Wave-31: keypackage_init_key_reuse + external_psk_id_provenanceΒ #771, Wave-32 bold row + fulldetail section, INV mapping row INV-CHAT-194..200 W32, axiom
summary extended through W32, future-waves shifted to W33..W37,
W32 VERIFIED footer.
Theorems (proof-grade)
inv_chat_194_wegi_non_canonical_aead_nonce_len_rejectedinv_chat_195_wegi_short_aead_ciphertext_rejectedinv_chat_196_wegi_cross_group_envelope_rejectedinv_chat_197_wegi_stale_epoch_envelope_rejectedinv_chat_198_pref_non_canonical_proposal_ref_len_rejectedinv_chat_199_pref_empty_proposal_id_rejectedinv_chat_200_pref_unknown_proposal_ref_rejectedHelpers:
wegi_canonical_envelope_accepted_32,wegi_min_ciphertext_accepted_32,pref_canonical_proposal_accepted_32,pref_one_byte_proposal_id_accepted_32.Wave-32 introduces 0 new axioms (cumulative axiom list
unchanged:
ss_kp_injectiveW9,dh_step_freshW10,dh_post_history_independentW10,hybrid_kem_non_degenerateW10,sn_hash_symW14).Verification (expected after CI)
Stats after W32
References
756cf35)