Files
hash-wallet/cw_bitcoin/lib/bitcoin_wallet_keys.dart
T
Seth For PrivacyandGitHub b60b5a59f7 feat: show Bitcoin master fingerprint in wallet keys (#3489)
* feat: show Bitcoin master fingerprint in wallet keys

Add the BIP-32 master fingerprint (XFP) to the Bitcoin wallet keys shown
under Settings > Seed & Keys > Keys, labeled "Master fingerprint".

* fix: keep xPub in Keys tab by splitting silent payment keys into a dedicated list

The Keys tab / Silent Payments tab split relied on a hardcoded item index
(`items.sublist(0, 4)` / `sublist(4)`) that assumed the first four items
were always WIF/private key/public key/xPub. Adding the master fingerprint
as the first item pushed xPub into the Silent Payments tab.

Route Bitcoin silent payment keys into their own `silentPaymentItems` list
instead, and render each tab from its list.
2026-08-07 21:47:24 +02:00

24 lines
532 B
Dart

class BitcoinWalletKeys {
const BitcoinWalletKeys({
required this.wif,
required this.privateKey,
required this.publicKey,
required this.xpub,
this.masterFingerprint = '',
});
final String wif;
final String privateKey;
final String publicKey;
final String xpub;
final String masterFingerprint;
Map<String, String> toJson() => {
'wif': wif,
'privateKey': privateKey,
'publicKey': publicKey,
'xpub': xpub,
'masterFingerprint': masterFingerprint,
};
}