generate_random_blinding

Function generate_random_blinding 

Source
pub fn generate_random_blinding() -> Result<Vec<u8>, JsValue>
Expand description

Generate a cryptographically random blinding factor for a note.

Each note requires a unique blinding factor to ensure commitments are unique even when amount and recipient are the same.

§Returns

32 bytes: Random BN254 scalar (little-endian), reduced to field modulus

§Note

Unlike the private keys above, blinding factors are NOT derived deterministically. They are random per-note and must be stored for later use.