From d0d6d2c1ab141d503725d0691e9f4318797558f6 Mon Sep 17 00:00:00 2001 From: Francisco Gindre Date: Mon, 5 Aug 2024 16:40:59 -0300 Subject: [PATCH] PR Suggestions Fix compile error on non-randomized flavor --- src/keys.rs | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/keys.rs b/src/keys.rs index c792f3db0..5c99f466b 100644 --- a/src/keys.rs +++ b/src/keys.rs @@ -290,8 +290,8 @@ impl CommitIvkRandomness { <[u8; 32]>::from(self.0) } - #[cfg_attr(feature = "unstable-frost", visibility::make(pub))] /// Converts this [`CommitIvkRandomness`] from its serialized form. + #[cfg_attr(feature = "unstable-frost", visibility::make(pub))] pub(crate) fn from_bytes(bytes: &[u8]) -> Option { let rivk_bytes = <[u8; 32]>::try_from(bytes).ok()?; let rivk = pallas::Scalar::from_repr(rivk_bytes).map(CommitIvkRandomness); @@ -343,8 +343,6 @@ impl From for SpendValidatingKey { impl FullViewingKey { /// Creates a `FullViewingKey` from a `SpendingKey` and `SpendValidatingKey`. /// This is necessary for FROST key management. - /// - /// Note: See [FROST Book - Technical details](https://frost.zfnd.org/zcash/technical-details.html) #[cfg(feature = "unstable-frost")] pub fn from_sk_and_ak(sk: &SpendingKey, ak: SpendValidatingKey) -> FullViewingKey { FullViewingKey { @@ -356,8 +354,6 @@ impl FullViewingKey { /// Creates a `FullViewingKey` from its checked parts. This is necessary for FROST /// key management in order to avoid centralizing spend authority in a backup scheme. - /// - /// Note: See [FROST Book - Technical details - Backing Up Key Shares](https://frost.zfnd.org/zcash/technical-details.html) #[cfg(feature = "unstable-frost")] pub fn from_checked_parts( ak: SpendValidatingKey, @@ -369,14 +365,14 @@ impl FullViewingKey { /// Returns the `SpendValidatingKey` of this `FullViewingKey` /// - Note: this is intended for the "unstable-frost" feature to - /// facilitate the DKG'd key backup scheme. See [Backing Up Key Shares](https://frost.zfnd.org/zcash/technical-details.html#backing-up-key-shares) + /// facilitate the DKG'd key backup scheme. #[cfg_attr(feature = "unstable-frost", visibility::make(pub))] pub fn ak(&self) -> &SpendValidatingKey { &self.ak } /// Returns the `NullifierDerivingKey` of this `FullViewingKey` /// - Note: this is `pub` for the "unstable-frost" feature to - /// facilitate the DKG'd key backup scheme. See [Backing Up Key Shares](https://frost.zfnd.org/zcash/technical-details.html#backing-up-key-shares) + /// facilitate the DKG'd key backup scheme. #[cfg_attr(feature = "unstable-frost", visibility::make(pub))] pub(crate) fn nk(&self) -> &NullifierDerivingKey { &self.nk @@ -384,7 +380,7 @@ impl FullViewingKey { /// Returns either `rivk` or `rivk_internal` based on `scope`. /// - Note: this is `pub` for the "unstable-frost" feature to - /// facilitate the DKG'd key backup scheme. See [Backing Up Key Shares](https://frost.zfnd.org/zcash/technical-details.html#backing-up-key-shares) + /// facilitate the DKG'd key backup scheme. #[cfg_attr(feature = "unstable-frost", visibility::make(pub))] pub(crate) fn rivk(&self, scope: Scope) -> CommitIvkRandomness { match scope {