Compare commits

...

6 Commits

Author SHA1 Message Date
str4d 1db974141b
Merge pull request #420 from zcash/release-0.7.1
Release 0.7.1
2024-02-29 22:38:17 +00:00
Jack Grigg 79d739f197 orchard 0.7.1 2024-02-29 22:26:40 +00:00
str4d 2a312c0cf1
Merge pull request #419 from nuttycom/nullifier_ct_eq
Additions needed for Orchard batch scanning
2024-02-29 22:24:02 +00:00
Kris Nuttycombe 9729cd8d26 Add note_encryption::CompactAction::cmx 2024-02-26 10:03:16 -07:00
Kris Nuttycombe 8cc96b5420 Add `impl Clone for note_encryption::CompactAction` 2024-02-26 09:44:02 -07:00
Kris Nuttycombe ff7287e392 Add `impl subtle::ConstantTimeEq for note::Nullifier` 2024-02-23 22:06:10 -07:00
5 changed files with 23 additions and 4 deletions

View File

@ -7,6 +7,13 @@ and this project adheres to Rust's notion of
## [Unreleased]
## [0.7.1] - 2024-02-29
### Added
- `impl subtle::ConstantTimeEq for orchard::note::Nullifier`
- `orchard::note_encryption`:
- `CompactAction::cmx`
- `impl Clone for CompactAction`
## [0.7.0] - 2024-01-26
### Licensing
- The license for this crate is now "MIT OR Apache-2.0". The license

2
Cargo.lock generated
View File

@ -1412,7 +1412,7 @@ checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5"
[[package]]
name = "orchard"
version = "0.7.0"
version = "0.7.1"
dependencies = [
"aes",
"bitvec",

View File

@ -1,6 +1,6 @@
[package]
name = "orchard"
version = "0.7.0"
version = "0.7.1"
authors = [
"Sean Bowe <sean@electriccoin.co>",
"Jack Grigg <jack@electriccoin.co>",

View File

@ -3,7 +3,7 @@ use halo2_proofs::arithmetic::CurveExt;
use memuse::DynamicUsage;
use pasta_curves::pallas;
use rand::RngCore;
use subtle::CtOption;
use subtle::{ConstantTimeEq, CtOption};
use super::NoteCommitment;
use crate::{
@ -62,6 +62,12 @@ impl Nullifier {
}
}
impl ConstantTimeEq for Nullifier {
fn ct_eq(&self, other: &Self) -> subtle::Choice {
self.0.ct_eq(&other.0)
}
}
/// Generators for property testing.
#[cfg(any(test, feature = "test-dependencies"))]
#[cfg_attr(docsrs, doc(cfg(feature = "test-dependencies")))]

View File

@ -269,6 +269,7 @@ impl<T> ShieldedOutput<OrchardDomain, ENC_CIPHERTEXT_SIZE> for Action<T> {
}
/// A compact Action for light clients.
#[derive(Clone)]
pub struct CompactAction {
nullifier: Nullifier,
cmx: ExtractedNoteCommitment,
@ -325,10 +326,15 @@ impl CompactAction {
}
}
///Returns the nullifier of the note being spent.
/// Returns the nullifier of the note being spent.
pub fn nullifier(&self) -> Nullifier {
self.nullifier
}
/// Returns the commitment to the new note being created.
pub fn cmx(&self) -> ExtractedNoteCommitment {
self.cmx
}
}
#[cfg(test)]