Function substrate_bip39::mini_secret_from_entropy
source · pub fn mini_secret_from_entropy(
entropy: &[u8],
password: &str
) -> Result<MiniSecretKey, Error>
Expand description
entropy
should be a byte array from a correctly recovered and checksumed BIP39.
This function accepts slices of different length for different word lengths:
- 16 bytes for 12 words.
- 20 bytes for 15 words.
- 24 bytes for 18 words.
- 28 bytes for 21 words.
- 32 bytes for 24 words.
Any other length will return an error.
password
is analog to BIP39 seed generation itself, with an empty string being defalt.