diff --git a/CHANGELOG.md b/CHANGELOG.md index edf7a560..3fd1be72 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to Rust's notion of ## [0.8.0] - 2024-03-25 ### Added +- `orchard::keys::IncomingViewingKey::prepare` - `orchard::note::Rho` - `orchard::action::Action::rho` - `orchard::note_encryption::CompactAction::rho` diff --git a/src/keys.rs b/src/keys.rs index 8b85bdce..f5bae6cb 100644 --- a/src/keys.rs +++ b/src/keys.rs @@ -663,6 +663,11 @@ impl IncomingViewingKey { pub fn address(&self, d: Diversifier) -> Address { self.ivk.address(d) } + + /// Returns the [`PreparedIncomingViewingKey`] for this [`IncomingViewingKey`]. + pub fn prepare(&self) -> PreparedIncomingViewingKey { + PreparedIncomingViewingKey::new(self) + } } /// An Orchard incoming viewing key that has been precomputed for trial decryption.