1
0
Fork 0
forked from lthn/blockchain

added error handling for custom seed generator

This commit is contained in:
cryptozoidberg 2025-05-21 20:15:49 +04:00
parent dd9fb6c8a7
commit 0b7a8a89bd
No known key found for this signature in database
GPG key ID: 2E10CC61CAC8F36D

View file

@ -2934,6 +2934,11 @@ int custom_seed_builder()
acc.generate();
std::string pass_protected_or_not = "";
std::vector<unsigned char> binary_from_seed = tools::mnemonic_encoding::text2binary(seed_24);
if (!binary_from_seed.size())
{
success_msg_writer() << "The seed phrase you have provided is not correct. (Please keep in mind that seed words is not compatible with bip39 dictionary)";
return EXIT_FAILURE;
}
std::vector<unsigned char> processed_binary_from_seed = binary_from_seed;
if (!passphrase.empty())
{