jacogr / substrate-ledger-ed25519

Extract Substrate and Polkadot compatible ed25519 keys from Ledger mnemonic phrases
145 stars 15 forks source link

From ed25519 seed to Polkadot.js #8

Closed ironoa closed 2 years ago

ironoa commented 2 years ago

Hi Jaco, thanks for the tool.

Having ed25519 seed, is there a way to import it to the Polkadot.js extension and therefore gain the complete control over the account via the https://polkadot.js.org/apps/ ?

FYI Importing the seed in the extension using "Import account from pre-existing seed" leads to an address mismatch ( whether you insert the derive path or not, i.e. m/44'/354'/0'/0'/0' )

Thanks

jacogr commented 2 years ago

The extension doesn't support Ethereum/Bitcoin/Other-style derivation paths. Only Polkadot/substrate derivation paths are supported since that is the standard in the ecosystem.

With this cli tool, once you have generated the raw seed, you can just add it to the extension where the mnemonic is supposed to go, i.e. past 0x... into the seed box. (The extension supports both mnemonics and hex-seeds there)

ironoa commented 2 years ago

pasting the 0x... seed (ed25519 seed from this tool) into the seed box of polkadotjs extension leads to an address that doesn't match the expectations (address (DOT) from this tool)... No derivation path inserted.

Doing the same in polkadot js web app kind of work instead, but only if you tune the advanced creation options from the default Shnorkell to Edwards

image

Is this expected ? wdyt ?

jacogr commented 2 years ago

Dangit, my bad. It is indeed expected, I should have explained above, guess I need more coffee.

So the extension only does sr25519, no ed25519 when creating from seed.

So if you wish to import into the extension, it is a bit of work-around.

So basically on import the extension allows anything, ed25519, sr25519 or edcsa.

ironoa commented 2 years ago

Very nice, thanks. I think we can close it.

Have a good one

adambz19 commented 4 months ago

Hi, can you explain how to import account with JSON file using the extension as import through web app is no longer possible ? How can I get that JSON file ? This file is generated by the tool or I need to generate it myself using seed generated by the tool ? Thank you