simulator-graphical: simulate Nova, same as the old simulator
What changed, and why it matters
This commit updates the graphical simulator for the BitBox02 hardware wallet so it behaves like the 'Nova' product variant and fixes a wallet-creation problem that had already been fixed in the older simulator. The changes only affect test/simulator code paths, not the real device firmware, so they do not create a security vulnerability in shipped products.
No security action required. Treat as normal test/simulator maintenance. If reviewing the referenced prior commit 5a6fea4d053ff7150e8423bbcbd4a826f80b868f, verify that the wallet-creation fix it contains is also appropriate for the graphical simulator context.
Security signals we found
No production firmware code changed
Changes confined to simulator/test build configuration
Commit message references a prior fix for the same wallet-creation issue in another simulator
Addition of 'zeroize' dependency in simulator lockfile (defensive memory-clearing crate, not a vulnerability signal)
Evidence from the diff
The patch adds a new C function ‘fake_memory_nova’ to the Rust FFI allowlist, exposes it through bitbox02::memory::fake_nova() under the simulator-graphical feature, and calls it during graphical simulator initialization. It also adds the ‘zeroize’ crate to the simulator’s Cargo.lock. The commit message explicitly states this makes the graphical simulator match the older simulator and fixes wallet creation the same way as commit 5a6fea4d053ff7150e8423bbcbd4a826f80b868f. No production firmware code is modified.
Changed components
test/simulator-graphical/src/main.rssrc/rust/bitbox02/src/memory.rs (simulator-graphical feature only)src/rust/bitbox02-sys/build.rs (FFI allowlist only)test/simulator-graphical/Cargo.lockInspect captured patch +8 / −0
diff --git a/src/rust/bitbox02-sys/build.rs b/src/rust/bitbox02-sys/build.rs
index 8ca923d..e33a9b2 100644
--- a/src/rust/bitbox02-sys/build.rs
+++ b/src/rust/bitbox02-sys/build.rs
@@ -72,6 +72,7 @@ const ALLOWLIST_FNS: &[&str] = &[
"emit_event",
"empty_create",
"fake_memory_factoryreset",
+ "fake_memory_nova",
"gmtime",
"hww_setup",
"keystore_bip39_mnemonic_to_seed",
diff --git a/src/rust/bitbox02/src/memory.rs b/src/rust/bitbox02/src/memory.rs
index 9ef7be6..ceee314 100644
--- a/src/rust/bitbox02/src/memory.rs
+++ b/src/rust/bitbox02/src/memory.rs
@@ -294,6 +294,11 @@ fn fake_memory_factoryreset() {
unsafe { bitbox02_sys::fake_memory_factoryreset() }
}
+#[cfg(feature = "simulator-graphical")]
+pub fn fake_nova() -> bool {
+ unsafe { bitbox02_sys::fake_memory_nova() }
+}
+
#[cfg(test)]
fn memory_bootloader_hash() -> [u8; 32] {
let mut out = [0u8; 32];
diff --git a/test/simulator-graphical/Cargo.lock b/test/simulator-graphical/Cargo.lock
index 492cf0a..31b89f1 100644
--- a/test/simulator-graphical/Cargo.lock
+++ b/test/simulator-graphical/Cargo.lock
@@ -3110,6 +3110,7 @@ dependencies = [
"hex",
"num-bigint",
"sha2",
+ "zeroize",
]
[[package]]
diff --git a/test/simulator-graphical/src/main.rs b/test/simulator-graphical/src/main.rs
index 31bacbe..24e28bb 100644
--- a/test/simulator-graphical/src/main.rs
+++ b/test/simulator-graphical/src/main.rs
@@ -153,6 +153,7 @@ fn init_hww(preseed: bool) -> bool {
info!("Sd card setup: success");
bitbox02::testing::mock_memory();
+ bitbox02::memory::fake_nova();
info!("Memory setup: success");
if preseed {
Why this scored 17/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.