Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/keys.rs
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,12 @@ impl FullViewingKey {
}
}

/// Returns the scalar form of the incoming viewing key for `scope`.
#[cfg_attr(feature = "unstable-voting-circuits", visibility::make(pub))]
pub(crate) fn ivk_scalar(&self, scope: Scope) -> pallas::Scalar {
*self.to_ivk(scope).ivk.0
}

/// Derives an `OutgoingViewingKey` for this full viewing key.
pub fn to_ovk(&self, scope: Scope) -> OutgoingViewingKey {
match scope {
Expand Down
3 changes: 2 additions & 1 deletion src/note/commitment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ impl NoteCommitment {
/// Defined in [Zcash Protocol Spec § 5.4.8.4: Sinsemilla commitments][concretesinsemillacommit].
///
/// [concretesinsemillacommit]: https://zips.z.cash/protocol/nu5.pdf#concretesinsemillacommit
pub(super) fn derive(
#[cfg_attr(feature = "unstable-voting-circuits", visibility::make(pub))]
pub(crate) fn derive(
g_d: [u8; 32],
pk_d: [u8; 32],
v: NoteValue,
Expand Down
3 changes: 2 additions & 1 deletion src/note/nullifier.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ impl Nullifier {
/// Defined in [Zcash Protocol Spec § 4.16: Note Commitments and Nullifiers][commitmentsandnullifiers].
///
/// [commitmentsandnullifiers]: https://zips.z.cash/protocol/nu5.pdf#commitmentsandnullifiers
pub(super) fn derive(
#[cfg_attr(feature = "unstable-voting-circuits", visibility::make(pub))]
pub(crate) fn derive(
nk: &NullifierDerivingKey,
rho: pallas::Base,
psi: pallas::Base,
Expand Down
Loading