Move redjubjub to sapling module.
This commit is contained in:
parent
de1345a1c2
commit
bf97b21632
|
@ -18,7 +18,6 @@ pub mod note_encryption;
|
|||
pub mod pedersen_hash;
|
||||
pub mod primitives;
|
||||
pub mod prover;
|
||||
pub mod redjubjub;
|
||||
pub mod sapling;
|
||||
pub mod serialize;
|
||||
pub mod transaction;
|
||||
|
|
|
@ -4,8 +4,10 @@ use crate::primitives::{Diversifier, PaymentAddress, ProofGenerationKey, Rseed};
|
|||
|
||||
use crate::{
|
||||
merkle_tree::MerklePath,
|
||||
redjubjub::{PublicKey, Signature},
|
||||
sapling::Node,
|
||||
sapling::{
|
||||
redjubjub::{PublicKey, Signature},
|
||||
Node,
|
||||
},
|
||||
transaction::components::{Amount, GROTH_PROOF_SIZE},
|
||||
};
|
||||
|
||||
|
@ -72,8 +74,10 @@ pub mod mock {
|
|||
|
||||
use crate::{
|
||||
merkle_tree::MerklePath,
|
||||
redjubjub::{PublicKey, Signature},
|
||||
sapling::Node,
|
||||
sapling::{
|
||||
redjubjub::{PublicKey, Signature},
|
||||
Node,
|
||||
},
|
||||
transaction::components::{Amount, GROTH_PROOF_SIZE},
|
||||
};
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//! Structs and constants specific to the Sapling shielded pool.
|
||||
|
||||
pub mod group_hash;
|
||||
pub mod redjubjub;
|
||||
|
||||
use crate::{
|
||||
constants::SPENDING_KEY_GENERATOR,
|
||||
|
@ -14,8 +15,8 @@ use lazy_static::lazy_static;
|
|||
use rand_core::{CryptoRng, RngCore};
|
||||
use std::io::{self, Read, Write};
|
||||
|
||||
use self::redjubjub::{PrivateKey, PublicKey, Signature};
|
||||
use crate::merkle_tree::Hashable;
|
||||
use crate::redjubjub::{PrivateKey, PublicKey, Signature};
|
||||
|
||||
pub const SAPLING_COMMITMENT_TREE_DEPTH: usize = 32;
|
||||
|
||||
|
|
|
@ -19,8 +19,7 @@ use crate::{
|
|||
note_encryption::SaplingNoteEncryption,
|
||||
primitives::{Diversifier, Note, PaymentAddress},
|
||||
prover::TxProver,
|
||||
redjubjub::PrivateKey,
|
||||
sapling::{spend_sig_internal, Node},
|
||||
sapling::{redjubjub::PrivateKey, spend_sig_internal, Node},
|
||||
transaction::{
|
||||
components::{
|
||||
amount::Amount, amount::DEFAULT_FEE, OutputDescription, SpendDescription, TxOut,
|
||||
|
|
|
@ -5,7 +5,7 @@ use std::io::{self, Read, Write};
|
|||
|
||||
use crate::{
|
||||
primitives::Nullifier,
|
||||
redjubjub::{PublicKey, Signature},
|
||||
sapling::redjubjub::{PublicKey, Signature},
|
||||
};
|
||||
|
||||
use super::GROTH_PROOF_SIZE;
|
||||
|
|
|
@ -7,7 +7,7 @@ use std::ops::Deref;
|
|||
|
||||
use crate::{
|
||||
consensus::BlockHeight,
|
||||
redjubjub::Signature,
|
||||
sapling::redjubjub::Signature,
|
||||
serialize::Vector,
|
||||
util::sha256d::{HashReader, HashWriter},
|
||||
};
|
||||
|
|
|
@ -3,7 +3,7 @@ use rand_core::OsRng;
|
|||
|
||||
use proptest::prelude::*;
|
||||
|
||||
use crate::{constants::SPENDING_KEY_GENERATOR, redjubjub::PrivateKey};
|
||||
use crate::{constants::SPENDING_KEY_GENERATOR, sapling::redjubjub::PrivateKey};
|
||||
|
||||
use super::{
|
||||
components::Amount,
|
||||
|
|
|
@ -7,8 +7,10 @@ use zcash_primitives::{
|
|||
merkle_tree::MerklePath,
|
||||
primitives::{Diversifier, PaymentAddress, ProofGenerationKey, Rseed},
|
||||
prover::TxProver,
|
||||
redjubjub::{PublicKey, Signature},
|
||||
sapling::Node,
|
||||
sapling::{
|
||||
redjubjub::{PublicKey, Signature},
|
||||
Node,
|
||||
},
|
||||
transaction::components::{Amount, GROTH_PROOF_SIZE},
|
||||
};
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ use zcash_primitives::{
|
|||
constants::{SPENDING_KEY_GENERATOR, VALUE_COMMITMENT_RANDOMNESS_GENERATOR},
|
||||
merkle_tree::MerklePath,
|
||||
primitives::{Diversifier, Note, PaymentAddress, ProofGenerationKey, Rseed, ValueCommitment},
|
||||
redjubjub::{PrivateKey, PublicKey, Signature},
|
||||
sapling::redjubjub::{PrivateKey, PublicKey, Signature},
|
||||
sapling::Node,
|
||||
transaction::components::Amount,
|
||||
};
|
||||
|
|
|
@ -6,7 +6,7 @@ use bls12_381::Bls12;
|
|||
use group::{Curve, GroupEncoding};
|
||||
use zcash_primitives::{
|
||||
constants::{SPENDING_KEY_GENERATOR, VALUE_COMMITMENT_RANDOMNESS_GENERATOR},
|
||||
redjubjub::{PublicKey, Signature},
|
||||
sapling::redjubjub::{PublicKey, Signature},
|
||||
transaction::components::Amount,
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue