This commit is contained in:
Rostyslav Tyshko 2025-04-18 11:45:01 -04:00
parent 92b9fe252a
commit 257044b210
2 changed files with 13 additions and 7 deletions

View File

@ -2,12 +2,20 @@ use elliptic_curve::{
consts::{B0, B1},
generic_array::GenericArray,
};
use sha2::digest::typenum::{UInt, UTerm};
use lazy_static::lazy_static;
use sha2::digest::typenum::{UInt, UTerm};
lazy_static! {
pub static ref NULLIFIER_SECRET_CONST: [u8; 32] = hex::decode(std::env::var("NULLIFIER_SECRET_CONST").unwrap()).unwrap().try_into().unwrap();
pub static ref VIEWING_SECRET_CONST: [u8; 32] = hex::decode(std::env::var("VIEWING_SECRET_CONST").unwrap()).unwrap().try_into().unwrap();
pub static ref NULLIFIER_SECRET_CONST: [u8; 32] =
hex::decode(std::env::var("NULLIFIER_SECRET_CONST").unwrap())
.unwrap()
.try_into()
.unwrap();
pub static ref VIEWING_SECRET_CONST: [u8; 32] =
hex::decode(std::env::var("VIEWING_SECRET_CONST").unwrap())
.unwrap()
.try_into()
.unwrap();
}
pub type CipherText = Vec<u8>;

View File

@ -50,7 +50,7 @@ pub const WRITE_SEND_UTXO_SHIELDED: &str = "write_send_utxo_shielded";
pub const WRITE_SEND_UTXO_DESHIELDED: &str = "write_send_utxo_deshielded";
pub const WRITE_SPLIT_UTXO: &str = "write_split_utxo";
pub const SUCCESS: &str = "success";
pub const SUCCESS: &str = "success";
pub const ACCOUNT_NOT_FOUND: &str = "Account not found";
pub const TRANSACTION_NOT_FOUND: &str = "Transaction not found";
@ -791,9 +791,7 @@ impl JsonHandler {
self.process_request_execute_scenario_multiple_send(request)
.await
}
SHOW_ACCOUNT_PUBLIC_BALANCE => {
self.process_show_account_public_balance(request).await
}
SHOW_ACCOUNT_PUBLIC_BALANCE => self.process_show_account_public_balance(request).await,
SHOW_ACCOUNT_UTXO => self.process_show_account_utxo_request(request).await,
SHOW_TRANSACTION => self.process_show_transaction(request).await,
WRITE_DEPOSIT_PUBLIC_BALANCE => {