Skip to content

Commit

Permalink
Merge pull request #1288 from multiversx/cargo-libraries-update
Browse files Browse the repository at this point in the history
updated libraries: sha2, sha3, itertools, hmac, pem, pbkdf2
  • Loading branch information
andrei-marinica authored Nov 28, 2023
2 parents e689c17 + eca2d89 commit c985410
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 101 deletions.
113 changes: 24 additions & 89 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion framework/scenario/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ sha2 = "0.10.6"
serde = "1.0"
serde_json = "1.0"
pathdiff = "0.2.1"
itertools = "0.11"
itertools = "0.12.0"
colored = "2.0"
clap = { version = "4.4.7", features = ["derive"] }
tokio = { version = "1.24", features = ["full"] }
Expand Down
12 changes: 6 additions & 6 deletions sdk/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ serde_repr = "0.1.8"
anyhow = "1.0.44"
rand = "0.8.5"
bip39 = { version = "2.0.0", features = ["rand"] }
sha2 = "0.9.8"
sha3 = "0.9.1"
hmac = { version = "0.11.0", features = ["std"] }
sha2 = "0.10.8"
sha3 = "0.10.8"
hmac = { version = "0.12.1", features = ["std"] }
hex = "0.4.3"
base64 = "0.13.0"
pbkdf2 = { version = "0.9.0", default-features = false }
pbkdf2 = { version = "0.12.2", default-features = false }
zeroize = "1.4.2"
bech32 = "0.9"
itertools = "0.11"
pem = "1.0.1"
itertools = "0.12.0"
pem = "3.0.2"
6 changes: 3 additions & 3 deletions sdk/core/src/wallet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ extern crate rand;

use anyhow::Result;
use bip39::{Language, Mnemonic};
use hmac::{Hmac, Mac, NewMac};
use hmac::{Hmac, Mac};
use pbkdf2::pbkdf2;
use serde_json::json;
use sha2::{Digest, Sha512};
Expand Down Expand Up @@ -40,7 +40,7 @@ impl Wallet {

let mut seed = [0u8; 64];

pbkdf2::<Hmac<Sha512>>(
let _ = pbkdf2::<Hmac<Sha512>>(
mnemonic.to_string().as_bytes(),
salt.as_bytes(),
2048,
Expand Down Expand Up @@ -105,7 +105,7 @@ impl Wallet {

pub fn from_pem_file_contents(contents: String) -> Result<Self> {
let x = pem::parse(contents)?;
let x = x.contents[..PRIVATE_KEY_LENGTH].to_vec();
let x = x.contents()[..PRIVATE_KEY_LENGTH].to_vec();
let priv_key_str = std::str::from_utf8(x.as_slice())?;
let pri_key = PrivateKey::from_hex_str(priv_key_str)?;
Ok(Self { priv_key: pri_key })
Expand Down
2 changes: 1 addition & 1 deletion sdk/scenario-format/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ serde_json = "1.0"
num-bigint = "0.4"
num-traits = "0.2"
hex = "0.4"
sha3 = "0.9"
sha3 = "0.10.8"
bech32 = "0.9.0"
2 changes: 1 addition & 1 deletion vm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ sha3 = "0.10.6"
rand = "0.8.5"
rand_seeder = "0.2.2"
ed25519-dalek = "2.0.0"
itertools = "0.11"
itertools = "0.12.0"
hex-literal = "0.4.1"
bitflags = "1.3.2"

Expand Down

0 comments on commit c985410

Please sign in to comment.