Ridge-Lab/moonmls/key_schedule does not have a README file

    EpochSecrets

    pub(all) struct EpochSecrets {
    suite :
    CipherSuite

    joiner_secret : Bytes
    welcome_secret : Bytes
    epoch_secret : Bytes
    sender_data_secret : Bytes
    encryption_secret : Bytes
    exporter_secret : Bytes
    epoch_authenticator : Bytes
    external_secret : Bytes
    confirmation_key : Bytes
    membership_key : Bytes
    resumption_psk : Bytes
    init_secret : Bytes
    } derive(Eq,
    Debug
    )

    All secrets derived for a single MLS epoch.

    EpochSecrets::advance

    fn EpochSecrets::advance(suite :
    CipherSuite
    , init_secret_prev : Bytes, commit_secret : Bytes, psk_secret : Bytes, group_context_bytes : Bytes) -> EpochSecrets raise
    MlsError

    RFC 9420 §8 Advance the key schedule by one epoch from init_secret_prev, commit_secret, psk_secret, and the serialized new GroupContext.

    EpochSecrets::export_secret

    fn EpochSecrets::export_secret(self : EpochSecrets, label : String, context : Bytes, length : Int) -> Bytes raise
    MlsError

    RFC 9420 §8.5 MLS-Exporter(label, context, length).

    EpochSecrets::external_key_pair

    fn EpochSecrets::external_key_pair(self : EpochSecrets) -> (Bytes, Bytes)

    Derive the external HPKE key pair (external_priv, external_pub) for External Commits.

    EpochSecrets::from_joiner_secret

    fn EpochSecrets::from_joiner_secret(suite :
    CipherSuite
    , joiner_secret : Bytes, psk_secret : Bytes, group_context_bytes : Bytes) -> EpochSecrets raise
    MlsError

    Derive epoch secrets from an existing joiner_secret (used by Welcome joiners and by advance_epoch).

    compute_confirmation_tag

    fn compute_confirmation_tag(suite :
    CipherSuite
    , confirmation_key : Bytes, confirmed_transcript_hash : Bytes) -> Bytes

    RFC 9420 §8.1 Compute confirmation_tag = MAC(confirmation_key, confirmed_transcript_hash).

    compute_confirmed_transcript_hash

    fn compute_confirmed_transcript_hash(suite :
    CipherSuite
    , interim_transcript_hash_before : Bytes, wire_format :
    WireFormat
    , content :
    FramedContent
    , signature : Bytes) -> Bytes raise
    MlsError

    RFC 9420 §8.2 Compute confirmed_transcript_hash from the prior interim_transcript_hash and the authenticated Commit content.

    compute_interim_transcript_hash

    fn compute_interim_transcript_hash(suite :
    CipherSuite
    , confirmed_transcript_hash : Bytes, confirmation_tag : Bytes) -> Bytes raise
    MlsError

    RFC 9420 §8.2 Compute interim_transcript_hash from confirmed_transcript_hash and confirmation_tag.

    compute_psk_secret

    RFC 9420 §8.4 Compute psk_secret from an ordered list of (PreSharedKeyID, psk_bytes).

    welcome_key_nonce

    fn welcome_key_nonce(suite :
    CipherSuite
    , welcome_secret : Bytes) -> (Bytes, Bytes) raise
    MlsError

    RFC 9420 §8.3 Derive (welcome_key, welcome_nonce) from welcome_secret.

    Source Files