mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-01-03 13:53:12 +00:00
fix: fmt
This commit is contained in:
parent
4837413989
commit
23e79d3e17
@ -1,4 +1,4 @@
|
||||
use aes_gcm::{aead::Aead, Aes256Gcm, KeyInit};
|
||||
use aes_gcm::{Aes256Gcm, KeyInit, aead::Aead};
|
||||
use common::merkle_tree_public::TreeHashType;
|
||||
use elliptic_curve::group::GroupEncoding;
|
||||
use elliptic_curve::point::AffineCoordinates;
|
||||
@ -6,7 +6,7 @@ use k256::AffinePoint;
|
||||
use log::info;
|
||||
use secret_holders::{PrivateKeyHolder, SeedHolder, TopSecretKeyHolder};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use sha2::{digest::FixedOutput, Digest};
|
||||
use sha2::{Digest, digest::FixedOutput};
|
||||
use types::{CipherText, Nonce};
|
||||
|
||||
use crate::key_protocol_core::PublicKey;
|
||||
|
||||
@ -2,7 +2,7 @@ use bip39::Mnemonic;
|
||||
use common::merkle_tree_public::TreeHashType;
|
||||
use elliptic_curve::PrimeField;
|
||||
use k256::{AffinePoint, Scalar};
|
||||
use rand::{rngs::OsRng, RngCore};
|
||||
use rand::{RngCore, rngs::OsRng};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use sha2::{Digest, digest::FixedOutput};
|
||||
|
||||
|
||||
@ -46,11 +46,15 @@ impl NSSAUserData {
|
||||
accounts_key_chains: HashMap<nssa::Address, KeyChain>,
|
||||
) -> Result<Self> {
|
||||
if !Self::valid_public_key_transaction_pairing_check(&accounts_keys) {
|
||||
anyhow::bail!("Key transaction pairing check not satisfied, there is addresses, which is not derived from keys");
|
||||
anyhow::bail!(
|
||||
"Key transaction pairing check not satisfied, there is addresses, which is not derived from keys"
|
||||
);
|
||||
}
|
||||
|
||||
if !Self::valid_private_key_transaction_pairing_check(&accounts_key_chains) {
|
||||
anyhow::bail!("Key transaction pairing check not satisfied, there is addresses, which is not derived from keys");
|
||||
anyhow::bail!(
|
||||
"Key transaction pairing check not satisfied, there is addresses, which is not derived from keys"
|
||||
);
|
||||
}
|
||||
|
||||
Ok(Self {
|
||||
|
||||
@ -228,7 +228,10 @@ pub async fn execute_subcommand(command: Command) -> Result<()> {
|
||||
Command::RegisterAccount {} => {
|
||||
let addr = wallet_core.create_new_account();
|
||||
|
||||
let key = wallet_core.storage.user_data.get_pub_account_signing_key(&addr);
|
||||
let key = wallet_core
|
||||
.storage
|
||||
.user_data
|
||||
.get_pub_account_signing_key(&addr);
|
||||
|
||||
info!("Generated new account with addr {addr:#?}");
|
||||
info!("With key {key:#?}");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user