From a7fa69c50413f52aa9758316597f71060824b1c3 Mon Sep 17 00:00:00 2001 From: Kris Nuttycombe Date: Fri, 26 May 2023 09:16:42 -0600 Subject: [PATCH] Remove `esk` and `ephemeral_key` arguments from `parse_note_plaintext_without_memo_ovk` Fixes #850 Extracted from: https://github.com/zcash/librustzcash/commit/be89e81534a9108b6ecb79fc7509b9adc32d14d6 --- CHANGELOG.md | 10 ++++++++++ src/lib.rs | 4 +--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8c3b50b..694142b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,16 @@ and this library adheres to Rust's notion of ## [Unreleased] +### Changed +- The `esk` and `ephemeral_key` arguments have been removed from + `Domain::parse_note_plaintext_without_memo_ovk`. It is therefore no longer + necessary (or possible) to ensure that `ephemeral_key` is derived from `esk` + and the diversifier within the note plaintext. We have analyzed the safety of + this change in the context of callers within `zcash_note_encryption` and + `orchard`. See https://github.com/zcash/librustzcash/pull/848 and the + associated issue https://github.com/zcash/librustzcash/issues/802 for + additional detail. + ## [0.3.0] - 2023-03-22 ### Changed - The `recipient` parameter has been removed from `Domain::note_plaintext_bytes`. diff --git a/src/lib.rs b/src/lib.rs index a6b42f8..75fcb2f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -237,8 +237,6 @@ pub trait Domain { fn parse_note_plaintext_without_memo_ovk( &self, pk_d: &Self::DiversifiedTransmissionKey, - esk: &Self::EphemeralSecretKey, - ephemeral_key: &EphemeralKeyBytes, plaintext: &NotePlaintextBytes, ) -> Option<(Self::Note, Self::Recipient)>; @@ -654,7 +652,7 @@ pub fn try_output_recovery_with_ock