bugfix: premature wipe while exporting secret material via NFC - only first export loop (0th) was actually sending data

This commit is contained in:
scgbckbone 2025-06-24 10:23:30 +02:00 committed by doc-hex
parent 98420f8ac3
commit bbac20b453
2 changed files with 4 additions and 2 deletions

View File

@ -12,6 +12,7 @@ This lists the new changes that have not yet been published in a normal release.
- Bugfix: Disallow negative input/output amounts in PSBT.
- Bugfix: Fix filesystem initialization after Wife LFS or Destroy Seed.
- Bugfix: Fix MicroSD selftest
- Bugfix: NFC loop exporting secrets pre-mature wipe
## Spending Policy Feature

View File

@ -402,7 +402,7 @@ class NFCHandler:
# Run the pretty animation, and detect both when we are written, and/or key to exit/abort.
# - similar when "read" and then removed from field
# - return T if aborted by user
from glob import dis, numpad
from glob import dis
await self.wait_ready()
self.set_rf_disable(0)
@ -471,7 +471,8 @@ class NFCHandler:
break
self.set_rf_disable(1)
if not write_mode:
# do not wipe if we are not aborted
if not write_mode and aborted:
# function argument secret decides whether to do full wipe after writing to chip
await self.wipe(is_secret)