Skip to content

Commit

Permalink
SFT-4441: Update Rust dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
jeandudey committed Nov 20, 2024
1 parent cfac5d6 commit 4b4a5ce
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 17 deletions.
20 changes: 10 additions & 10 deletions extmod/foundation-rust/Cargo.lock

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

8 changes: 4 additions & 4 deletions extmod/foundation-rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ name = "sizes"
required-features = ["std"]

[dependencies.bitcoin_hashes]
version = "0.14"
version = "0.15"
features = ["small-hash"]
default-features = false

Expand Down Expand Up @@ -50,11 +50,11 @@ version = "1"
default-features = false

[dependencies.foundation-firmware]
version = "0.1.2"
version = "0.2"
default-features = false

[dependencies.foundation-ur]
version = "0.3"
version = "0.4"
default-features = false

[dependencies.foundation-urtypes]
Expand All @@ -74,7 +74,7 @@ default-features = false
features = ["critical-section"]

[dependencies.secp256k1]
version = "0.29"
version = "0.30"
default-features = false
features = ["lowmemory", "rand"]

Expand Down
2 changes: 1 addition & 1 deletion extmod/foundation-rust/src/firmware.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// SPDX-License-Identifier: GPL-3.0-or-later

use crate::secp256k1::PRE_ALLOCATED_CTX;
use bitcoin_hashes::{sha256d, Hash};
use bitcoin_hashes::sha256d;
use core::{ffi::c_char, slice};
use foundation_firmware::{VerifyHeaderError, VerifySignatureError};
use secp256k1::PublicKey;
Expand Down
3 changes: 1 addition & 2 deletions extmod/foundation-rust/src/secp256k1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,8 @@ pub extern "C" fn secp256k1_sign_schnorr(
Err(_) => return false,
};

let msg = Message::from_digest_slice(data).unwrap();
let sig =
PRE_ALLOCATED_CTX.sign_schnorr_with_rng(&msg, &keypair, &mut rng());
PRE_ALLOCATED_CTX.sign_schnorr_with_rng(data, &keypair, &mut rng());
signature.copy_from_slice(sig.as_ref());

true
Expand Down

0 comments on commit 4b4a5ce

Please sign in to comment.