pakery-crypto 0.2.1

Concrete cryptographic implementations for PAKE protocols
Documentation
//! Pre-computed SPAKE2 constants for Ristretto255.
//!
//! Each constant is derived as `compress(from_uniform_bytes(SHA-512(label)))`.

/// M point for SPAKE2 with Ristretto255.
///
/// Derived from `SHA-512(b"M SPAKE2 ristretto255")`.
pub const SPAKE2_M_COMPRESSED: [u8; 32] = [
    0x30, 0x8d, 0x1f, 0x6c, 0x2a, 0xe5, 0xfe, 0x3b, 0x53, 0x83, 0x32, 0x32, 0xda, 0x21, 0x72, 0x13,
    0x3c, 0x34, 0xd5, 0xea, 0x7e, 0x28, 0xa3, 0x72, 0xb0, 0x42, 0x02, 0x92, 0x3e, 0xc3, 0x7b, 0x31,
];

/// N point for SPAKE2 with Ristretto255.
///
/// Derived from `SHA-512(b"N SPAKE2 ristretto255")`.
pub const SPAKE2_N_COMPRESSED: [u8; 32] = [
    0xdc, 0x64, 0xb1, 0x1f, 0xd2, 0x14, 0x11, 0xba, 0xc1, 0xef, 0xaf, 0x6b, 0x5e, 0x69, 0xd4, 0x3c,
    0xbc, 0xb6, 0x71, 0xe1, 0x2b, 0x1a, 0x5a, 0xd8, 0xbf, 0x32, 0xab, 0x40, 0xde, 0xb0, 0xfa, 0x2d,
];

/// S point for symmetric SPAKE2 with Ristretto255.
///
/// Derived from `SHA-512(b"symmetric SPAKE2 ristretto255")`.
pub const SPAKE2_S_COMPRESSED: [u8; 32] = [
    0xc8, 0xc7, 0x86, 0xd3, 0x54, 0x57, 0x75, 0xd0, 0x2f, 0x76, 0xa7, 0xd7, 0x58, 0x95, 0xaf, 0x1b,
    0x08, 0x8f, 0xb0, 0xbf, 0x12, 0x09, 0xcc, 0x5b, 0xca, 0x2b, 0xd0, 0xf8, 0x4d, 0xeb, 0x27, 0x7d,
];