mirror of https://github.com/zcash/orchard.git
Compare commits
6 Commits
f8857e8292
...
1db974141b
Author | SHA1 | Date |
---|---|---|
str4d | 1db974141b | |
Jack Grigg | 79d739f197 | |
str4d | 2a312c0cf1 | |
Kris Nuttycombe | 9729cd8d26 | |
Kris Nuttycombe | 8cc96b5420 | |
Kris Nuttycombe | ff7287e392 |
|
@ -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
|
||||
|
|
|
@ -1412,7 +1412,7 @@ checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5"
|
|||
|
||||
[[package]]
|
||||
name = "orchard"
|
||||
version = "0.7.0"
|
||||
version = "0.7.1"
|
||||
dependencies = [
|
||||
"aes",
|
||||
"bitvec",
|
||||
|
|
|
@ -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>",
|
||||
|
|
|
@ -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")))]
|
||||
|
|
|
@ -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)]
|
||||
|
|
Loading…
Reference in New Issue