From 8968547981f823734c93537764d59c0732636b52 Mon Sep 17 00:00:00 2001 From: therealyingtong Date: Thu, 6 Aug 2020 13:13:49 +0800 Subject: [PATCH] Document pub enum Rseed with link to ZIP 212 --- zcash_primitives/src/primitives.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/zcash_primitives/src/primitives.rs b/zcash_primitives/src/primitives.rs index 4f635a867..1c81fc03b 100644 --- a/zcash_primitives/src/primitives.rs +++ b/zcash_primitives/src/primitives.rs @@ -223,6 +223,11 @@ impl PaymentAddress { } } +/// Enum for note randomness before and after [ZIP 212](https://zips.z.cash/zip-0212). +/// +/// Before ZIP 212, the note commitment trapdoor `rcm` must be a scalar value. +/// After ZIP 212, the note randomness `rseed` is a 32-byte sequence, used to derive +/// both the note commitment trapdoor `rcm` and the ephemeral private key `esk`. #[derive(Copy, Clone, Debug)] pub enum Rseed { BeforeZip212(Fs),