akegaviar / ton-foo

MIT License
0 stars 0 forks source link

Account derivation #504

Open akegaviar opened 4 months ago

akegaviar commented 4 months ago

Since there are no derivation paths, I was thinking about using the same 12 word mnemonic, with a password that would be just a string of numbers incrementing... Is this correct logic?

Also I found it a bit confusing that it has a function

/**
 * Convert mnemonics to HD seed
 * @param mnemonicArray mnemonic array
 * @param password mnemonic password
 * @returns 64 byte seed
 */
async function mnemonicToHDSeed(mnemonicArray, password) {
    mnemonicArray = normalizeMnemonic(mnemonicArray);
    return (await mnemonicToSeed(mnemonicArray, 'TON HD Keys seed', password));
}
exports.mnemonicToHDSeed = mnemonicToHDSeed;

But I don't quite understand the purpose of it... in the documentation, it uses mnemonicToPrivateKey which has TON default seed, then in mnemonicToHDSeed it uses TON HD Keys seed. I'm a bit lost, please help.

Answer

No answer found


Original