Expand description
Matter session-establishment protocols.
Milestones 3 (PASE / SPAKE2+) and 4 (CASE / SIGMA) of the matter-rust
roadmap.
§Scope
pase: Password Authenticated Session Establishment (SPAKE2+). M3.1 (current): math + KDF primitives. M3.2: state machines. M3.3: matter.js byte-parity verification.case: Certificate Authenticated Session Establishment (SIGMA-I). Placeholder; M4 territory.aead: AES-128-CCM-128 AEAD helpers. PreferSessionAeadover the free functions on any path that encrypts/decrypts more than once per key, to avoid repeating AES key expansion per call.error: the crate error type.
§Cryptographic discipline
This crate never implements primitives. AES, ECDH, ECDSA, SHA, HKDF, and
HMAC come from ring. EC scalar/point arithmetic (which ring deliberately
doesn’t expose) comes from p256. We implement only the Matter-defined
protocols on top of those primitives.
Re-exports§
pub use aead::SessionAead;pub use case::CaseCredentials;pub use case::CaseMessageKind;pub use case::CaseSessionKeys;pub use case::CaseSessionOutput;pub use case::LocalInfo;pub use case::PeerInfo;pub use case::ResumptionId;pub use case::ResumptionRecord;pub use case::Sigma1Outcome;pub use error::Error;pub use error::Result;pub use operational::derive_compressed_fabric_id;pub use operational::derive_group_privacy_key;pub use operational::derive_group_session_id;pub use operational::derive_operational_ipk;pub use operational::group_multicast_ipv6;pub use pase::pake_passcode_verifier;pub use pase::PaseMessageKind;pub use pase::PasePbkdfParams;pub use pase::PaseProver;pub use pase::PaseSessionKeys;pub use pase::PaseVerifier;
Modules§
- aead
- AES-128-CCM-128 (16-byte key, 13-byte nonce, 16-byte tag) AEAD helpers.
- case
- Matter CASE (Certificate Authenticated Session Establishment) via SIGMA-I.
- checkin
- Matter Check-In message codec (Matter Core §4.18.2) — the payload an ICD
sends unsolicited to a registered client when it briefly wakes. Reuses the
crate’s AES-128-CCM AEAD and
ringHMAC-SHA256; never implements primitives. - error
- Error type for
matter-crypto. - operational
- Operational identity derivations (Matter Core Spec §4.3).
- pase
- Matter PASE (Password Authenticated Session Establishment).
Structs§
- Case
Initiator - Initiator-side CASE state machine (new-session and resumption paths).
- Case
Responder - Responder-side CASE state machine (new-session path).
- Ring
Signer CaseSignerbacked by thep256crate’s RFC 6979 deterministic ECDSA.
Enums§
- Signer
Error - Errors returned by a
CaseSignerimplementation.
Traits§
- Case
Signer - Pluggable ECDSA-P256-SHA256 signer for CASE.
- Signer
- Canonical name for the ECDSA-P256-SHA256 signer trait outside CASE.
Functions§
- random_
bytes - Fill
bufwith cryptographically secure random bytes (ringSystemRandom).