Expand description
Common cryptographic utility functions.
This module provides implementations of various cryptographic operations used throughout the VRF schemes, including challenge generation, nonce derivation, and delinearization.
Structs§
- Exact
Chain - Wrapper around
Chainthat implementsExactSizeIterator.
Constants§
- CHALLENGE_
LEN - Challenge encoding length in bytes (128-bit security).
Functions§
- challenge
- Challenge generation inspired by RFC-9381 section 5.4.3.
- challenge_
scalar - expanded_
scalar_ len - Number of bytes to squeeze for an unbiased scalar via
from_le_bytes_mod_order. - nonce
- Deterministic nonce generation inspired by RFC-8032 section 5.1.6.
- nonce_
scalar - point_
to_ hash - Point-to-hash inspired by RFC-9381 section 5.2.