kyokan / bob-wallet

Bob Wallet is a GUI for DNS Record Management and Name Auctions on Handshake. It includes an integrated full node: hsd
https://www.bobwallet.io/
GNU General Public License v3.0
381 stars 91 forks source link

Feature Request: Multiple accounts #558

Open CorpulentBrony opened 2 years ago

CorpulentBrony commented 2 years ago

It would be useful to have the ability to create multiple "wallets" off the same Ledger wallet. I believe the terminology in HSD for this are "accounts." @rithvikvibhu mentioned on Discord this was technically possible, wanted to make an official feature request here. This feature would allow me to separate transactions and domains that I use for personal use from ones that I may use for project use all while keeping everything secure on the same Ledger hardware.

xnf0k — 09/12/2022
hsd has "accounts" like MetaMask, but Bob currently only uses 1 account per wallet (seed phrase).
twifag/ — 09/12/2022
ahhh, got it, that would be the difference I think yes, making multiple accounts
thanks
xnf0k — 09/12/2022
Adding accounts to Bob will need non-trivial work, but technically possible. Maybe someday ™️
Nathanwoodburn commented 1 year ago

FYI, if you want to have nearly the same affect before this has been added you can use ledger passphrase

CorpulentBrony commented 1 year ago

FYI, if you want to have nearly the same affect before this has been added you can use ledger passphrase

Thanks, I'm aware and already use passphrase, but it's not really a substitute. I have need for more than just 2 wallets.

skironDotNet commented 1 year ago

@CorpulentBrony the terminology is BIP39 and I think HNS does it wrong use this to play https://iancoleman.io/bip39/ So basically when you import 24 seed words your xpub key will be Account 0 key, but if you import Account 0 xpriv you are getting different set of addresses image

It's ok to take 24 seed and gen 0 Account, but it's a bug to take xpriv key and expect Bip32 ROOT key! it should take Account xpriv key, and display corresponding xpub key.

To answer your question, yes it's possible to have multiple account and should be done using bip32, 39, and 44 specification.

rithvikvibhu commented 1 year ago

HNS does it wrong

Hey @skironDotNet can you elaborate on how? Both hsd and Bob follow BIP44 with wallets and accounts. Bob currently only uses the first account and this feature request is to allow using the other accounts of the wallet (which is, like you said, possible to implement).

In Bob's UI, the main method to backup the wallet is with the seed phrase - by importing it and viewing it in Settings -> Wallet.

but it's a bug to take xpriv key and expect Bip32 ROOT key! it

Correct, and that's why we don't have any UI that shows the account private key at all. Backups happen only with seed phrase, which covers the entire wallet.

As for the "account key" visible in Settings, that's only the extended public key - yes, of the account, not wallet - which has uses with services like https://sinpapeles.xyz/ 's payment gateway and for things like https://github.com/pinheadmz/hip2-server.

To note here, is that Bob does not have any UI element to export the account extended private key at all. It is not meant to be used as a backup method.

If/When Bob does get multiple accounts, then the "account xpub" component will feature all accounts' keys. There's just no need to show the wallet-level xpub as of now, and if anyone needs it, is always possible with hsd's cli.

Falci commented 1 year ago

How to you imagine the UI of this feature?