sparrowwallet / sparrow

Desktop Bitcoin Wallet focused on security and privacy. Free and open source.
https://sparrowwallet.com/
Apache License 2.0
1.21k stars 173 forks source link

Whirlpool Accounts are unavailable with Master Private Key #682

Open jaonoctus opened 1 year ago

jaonoctus commented 1 year ago

Description

It is only possible to add Whirlpool Accounts if Mnmemonic Words were imported. But from my understanding, it should be also possible when importing the Master Private Key, right?

Steps to reproduce

  1. File > Preferences > Server > Connect to a Public Server (without TOR) > Close
  2. File > New Wallet > type anything > New or Imported Software Wallet > Enter Private Key > Import > Import Keystore
  3. Settings > Add Account

https://user-images.githubusercontent.com/7918067/189744251-58e7c8e5-0732-44d9-9baf-1d5441468198.mp4

Wallet info

Description Value
BIP 39 Mnemonic desert twist cousin expand allow index avocado summer patient discover vehicle vocal
BIP32 Root Key vprv9DMUxX4ShgxMMuW3ogJoqKvYvqKw4iWtPC9sFeEStnoU17J2Yay1ocvnbpMGjqWbpKQPA9GchJ8BFZHQ1fkSZTx65aRNVYc9KtsRNDFnYRc
Master fingerprint b0484587
Derivation m/84'/1'/0'
craigraw commented 1 year ago

Indeed, you are correct. This is purely because the Whirlpool client doesn't currently support master private keys. It could certainly be extended to do so, but is there a particular use case to motivate this?

jaonoctus commented 1 year ago

Just checked the code now, I see what you're saying.

image

It could certainly be extended to do so, but is there a particular use case to motivate this?

For the most of the users, using the BIP39 seed works just fine. I was considering an old-timer user that import BIP 32 instead of 39 into the wallet. So basically any person/company that have access to the Master Private Key, not the Mnemonic Words.