Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Wallet->Information should show HD path #4700

Closed
Talkless opened this issue Sep 9, 2018 · 14 comments
Closed

Feature request: Wallet->Information should show HD path #4700

Talkless opened this issue Sep 9, 2018 · 14 comments
Labels
topic-wallet 👛 related to wallet.py, or maybe address_synchronizer.py/coinchooser.py user-interface 🔲
Milestone

Comments

@Talkless
Copy link

Talkless commented Sep 9, 2018

Currently (3.1.3 in Debian Sid), Wallet->Information does not display BIP32 HD derivation path.

User might have multiple Electrum wallets (HD accounts) using same master seed generated in hardware device (like Ledger Nano S), named BIP84_short_term_spending for m/84'/0'/0', or legacy_hodl for m/44'/0'/3, etc, etc, but there's now way to know which path was used for previously created Electrum wallet, so re-creating that wallet in another computer (or application) is difficult (if HW wallet device is available, but Electrum wallet files are not), as user has to guess, manually document, or remember these paths used for creating that HW-based wallet.

If BIP32 derivation path would be available in Electrum GUI, and if user would know in advance that it will need to "recreate" wallet in another computer (or another application), he could just check HD path in Wallet->Information before proceeding.

@Talkless
Copy link
Author

Talkless commented Sep 9, 2018

I guess I could have named wallet files accordingly to paths, but, well, now it's too late :) . Again, this is manual documentation which maybe could be avoided.

@ecdsa
Copy link
Member

ecdsa commented Sep 18, 2018

this is a design choice; electrum does not know about your wallet derivation path, it does not keep that information.

@Talkless
Copy link
Author

I see. I guess I'll try to recall paths and rename wallet files accordingly.

@Talkless
Copy link
Author

Talkless commented Sep 18, 2018

@ecdsa maybe possibility for the user to add arbitrary note inside a wallet file would be reasonable?

@Talkless
Copy link
Author

@ecdsa Sorry for off-topic, but how does then HW wallet knows which private key to use for signing, if software wallet cannot provide derivation path?

@SomberNight
Copy link
Member

It's stored in the keystore, and persisted in the wallet file for hw wallets.

d = {
'type': 'hardware',
'hw_type': name,
'derivation': derivation,
'xpub': xpub,
'label': device_info.label,
}
k = hardware_keystore(d)

We might as well do it for generic bip39 seeds too.

@Talkless
Copy link
Author

and persisted in the wallet file

I am lost now. @ecdsa said Electrum does not keep that.

@SomberNight
Copy link
Member

Yes, and I just said it does for hardware wallets. I had to check myself to be sure :P
It's hard to keep track..
For software bip39 seeds, it is not kept. We might as well keep it for those too I think.

@Talkless
Copy link
Author

OK so my feature requests still holds, at least for HW wallets :) .

@SomberNight
Copy link
Member

Note: in Qt console:
for non-multisig, or first cosigner in case of multisig:

wallet.keystore.derivation

multisig:

[k.derivation for k in wallet.get_keystores()]

(these will raise AttributeError for non-hw wallet keystores)

@SomberNight SomberNight added topic-wallet 👛 related to wallet.py, or maybe address_synchronizer.py/coinchooser.py user-interface 🔲 and removed wontfix ❌ labels Feb 29, 2020
@SomberNight
Copy link
Member

Looks like to fully cover PSBT usecases we will optionally have full bip32 paths for any kind of bip32-based wallet, in which case we might as well (and will probably need to) show it in the UI.

related:
#5715
#5955

@SomberNight
Copy link
Member

For newly created wallets (and exisiting hw-keystore wallets), the derivation path is stored but is not atm exposed to the user. In console: wallet.keystore.get_derivation_prefix()

@fresheneesz
Copy link

I want to just add my opinion here that since derivation paths are kind of really important to be able to correctly restore from your seed, the derivation path should be shown alongside your seed and users should be instructed to record it as well. That is, unless we are aiming to have some mechanism to automatically search numerous standard derivation paths so users don't have to write it down.

@Stadicus
Copy link

+1 to show derivation path in Wallet Information dialog. When creating a multisig wallet with hardware wallets, I need to record the derivation path as crucial information during setup for a proper backup of the overall multisig setup. Otherwise the derivation path is no longer accessible using regular UI options (not counting #4700 (comment))

@SomberNight SomberNight added this to the backlog milestone Aug 20, 2020
@SomberNight SomberNight modified the milestones: backlog, 4.0.next, 4.0.3 Sep 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic-wallet 👛 related to wallet.py, or maybe address_synchronizer.py/coinchooser.py user-interface 🔲
Projects
None yet
Development

No branches or pull requests

5 participants