diff --git a/common/Cargo.toml b/common/Cargo.toml index d235246..d0d145f 100644 --- a/common/Cargo.toml +++ b/common/Cargo.toml @@ -19,5 +19,9 @@ hex.workspace = true nssa-core = { path = "../nssa/core", features = ["host"] } borsh.workspace = true +[dependencies.generic-array] +version = "1.3.3" +features = ["zeroize"] + [dependencies.nssa] path = "../nssa" diff --git a/common/src/transaction.rs b/common/src/transaction.rs index 3a2bda1..7790ea0 100644 --- a/common/src/transaction.rs +++ b/common/src/transaction.rs @@ -3,13 +3,10 @@ use k256::ecdsa::{Signature, SigningKey, VerifyingKey}; use log::info; use serde::{Deserialize, Serialize}; -use sha2::{Digest, digest::FixedOutput}; - -use elliptic_curve::{ - consts::{B0, B1}, - generic_array::GenericArray, -}; +use generic_array::GenericArray; +use sha2::digest::typenum::{B0, B1}; use sha2::digest::typenum::{UInt, UTerm}; +use sha2::{Digest, digest::FixedOutput}; #[derive(Debug, Clone, PartialEq, Eq)] pub enum NSSATransaction { diff --git a/wallet/src/lib.rs b/wallet/src/lib.rs index 8e3086d..b874ff9 100644 --- a/wallet/src/lib.rs +++ b/wallet/src/lib.rs @@ -213,7 +213,7 @@ impl WalletCore { let res_acc = nssa_core::EncryptionScheme::decrypt( &acc_ead.ciphertext, - &secret, + secret, &acc_comm, output_index as u32, )