What changed, and why it matters
This update fixes a bug in the COLDCARD MK4 hardware wallet where sensitive temporary data stored in extra memory (PSRAM) was not fully erased when the device performed a 'fast wipe' or self-destruct sequence. After wiping the seed, leftover application data could remain in that memory through a reset, potentially allowing someone with physical access to recover secrets. The patch now explicitly clears that memory during both wipe paths.
Treat this as a security fix and include it in the next firmware release. Users who rely on fast-wipe or duress-pin features should update when available. No immediate user action is required beyond normal patching.
Security signals we found
Clearing of sensitive memory (PSRAM/SRAM) during wipe/reset paths
Fast wipe is a security-critical, seed-destruction code path
Potential data remanence in volatile memory across warm reset
ChangeLog explicitly frames the fix as a security-relevant bugfix
Evidence from the diff
The commit adds calls to psram_wipe() (and wipe_all_sram() in the bootloader’s firewall wipe path) during fast_wipe() in the MK4 bootloader. Previously, the fast-wipe routines cleared the MCU key and reset/locked the device, but did not explicitly clear PSRAM, which is external volatile memory used by the application. Because PSRAM contents can survive a warm reset, seed-related or other sensitive application data could persist after a wipe. The change ensures volatile application data is zeroized before reset or lockup.
Changed components
stm32/mk4-bootloader/storage.c:fast_wipe()stm32/mk4-bootloader/dispatch.c:firewall_dispatch() wipe handlerPSRAM volatile storage on COLDCARD Mk4Inspect captured patch +8 / −0
### releases/Next-ChangeLog.md
@@ -77,6 +77,7 @@ This lists the new changes that have not yet been published in a normal release.
- Bugfix: Reject backup files that request excessive password-derivation work.
- Bugfix: Separate the SE1 check nonce from the PIN digest. Thanks to
[@instagibbs](https://github.com/instagibbs) for reporting this issue.
+- Bugfix: Clear volatile application data when the seed is wiped.
- Enhancement: Clone Coldcard now shows the restored seed's master fingerprint on the receiving
Coldcard and asks for confirmation before installing it.
- Bugfix: CCC velocity policies created by older firmware now enforce the
### stm32/mk4-bootloader/dispatch.c
@@ -563,6 +563,9 @@ firewall_dispatch(int method_num, uint8_t *buf_io, int len_in,
mcu_key_clear(NULL);
oled_show(screen_wiped);
+ psram_wipe();
+ wipe_all_sram();
+
LOCKUP_FOREVER();
}
rv = EPERM;
### stm32/mk4-bootloader/storage.c
@@ -23,6 +23,7 @@
#include "stm32l4xx_hal.h"
#include "constant_time.h"
#include "storage.h"
+#include "psram.h"
// Number of flash pages to write-protect (ie. our size in flash pages)
// - written into FLASH->WRP1AR
@@ -826,6 +827,9 @@ fast_wipe(void)
// - and the check value on main seed will be garbage now
mcu_key_clear(NULL);
+ // clear volatile application data that would survive the warm reset
+ psram_wipe();
+
NVIC_SystemReset();
// not reached.Why this scored 59/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.