open the device signing dialog for a card keystore in a multisig wallet that also holds seed and watch only keystores
What changed, and why it matters
This commit fixes a UI workflow bug in Sparrow Wallet. Previously, when signing a transaction with a multisig wallet that mixed a hardware card keystore, a software seed keystore, and a watch-only keystore, the device signing dialog would not open. The change ensures the dialog opens so the user can sign with the card device. It is a functional bug fix rather than a security vulnerability.
Treat as a normal bug fix. No urgent security action required. Reviewers may verify that the new condition correctly covers all intended card keystore models and does not introduce unintended dialog behavior.
Security signals we found
No memory safety, cryptographic, or authorization issues visible in diff
Change is a guard-condition refinement in UI controller logic
No input validation, parsing, or secret-handling changes observed
Evidence from the diff
In HeadersController.signDeviceKeystores(), the early-return guard that decides whether to skip opening the device signing dialog was too broad. It returned early whenever the wallet contained both SW_SEED and SW_WATCH keystores, even if a card-based hardware keystore was also present and needed signing. The patch adds an additional condition: the early return only applies if no keystore has a card wallet model. This allows the device signing dialog to open for card keystores in mixed multisig wallets.
Changed components
src/main/java/com/sparrowwallet/sparrow/transaction/HeadersController.javasignDeviceKeystores() methodMultisig wallet transaction signing flow involving card keystoresInspect captured patch +2 / −1
### src/main/java/com/sparrowwallet/sparrow/transaction/HeadersController.java
@@ -1330,7 +1330,8 @@ private void signDeviceKeystores() {
List<Device> signingDevices = AppServices.getDevices().stream().filter(device -> fingerprints.contains(device.getFingerprint())).collect(Collectors.toList());
if(signingDevices.isEmpty() &&
(headersForm.getSigningWallet().getKeystores().stream().noneMatch(keystore -> keystore.getSource().equals(KeystoreSource.HW_USB) || keystore.getSource().equals(KeystoreSource.SW_WATCH) || keystore.getWalletModel().isCard()) ||
- (headersForm.getSigningWallet().getKeystores().stream().anyMatch(keystore -> keystore.getSource().equals(KeystoreSource.SW_SEED)) && headersForm.getSigningWallet().getKeystores().stream().anyMatch(keystore -> keystore.getSource().equals(KeystoreSource.SW_WATCH))))) {
+ (headersForm.getSigningWallet().getKeystores().stream().anyMatch(keystore -> keystore.getSource().equals(KeystoreSource.SW_SEED)) && headersForm.getSigningWallet().getKeystores().stream().anyMatch(keystore -> keystore.getSource().equals(KeystoreSource.SW_WATCH))
+ && headersForm.getSigningWallet().getKeystores().stream().noneMatch(keystore -> keystore.getWalletModel().isCard())))) {
return;
}
Why this scored 19/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.