profanity icon indicating copy to clipboard operation
profanity copied to clipboard

Are there mnemonic words to generate?

Open 1kxbt opened this issue 3 years ago • 2 comments

I would like to know if there are mnemonics generated and if so, how should I get them?

1kxbt avatar Jun 07 '22 06:06 1kxbt

no way

ef1m0ff avatar Jun 15 '22 05:06 ef1m0ff

Short answer

No, that would be a security risk.

Detailed answer

Fortunately, that's not how BIP-39 hierarchical deterministic [HD] wallets work. This is the process in a nutshell:

  1. generate entropy
  2. generate a mnemonic from the entropy and its checksum, using a wordlist
  3. generate a seed from the mnemonic and an optional passphrase
  4. generate a master key from the seed
  5. generate one or more private keys from the master key
  6. generate a public key from each private key
  7. generate an address from each public key

As everything else in public-key cryptography, all derivations go in one direction only:

entropy > mnemonic > seed > master key > private key > public key > address

The same reason why you can't generate a private key from an address, is the reason why you can't generate a mnemonic from a private key.

Think of it from security standpoint, if you could generate a seed and a mnemonic from your private key, and that seed is used to derive the master key and all your private keys... Then someone who steals your private key could generate your seed, and then generate all the private keys for all the addresses which correspond to that private key.

Having said all that, it should be absolutely possible to create a program which brute forces different MNEMONICS instead of PRIVATE KEYS as input, searching for an address which fits the given pattern 🤔

To study the topic in more depth, this article nicely explains the ins and outs:

https://medium.com/mycrypto/the-journey-from-mnemonic-phrase-to-address-6c5e86e11e14

bobanm avatar Jun 25 '22 11:06 bobanm