Merge pull request #5924 from steven-ecc/5893-enforce-recovery-phrase-backup
Require wallet recovery phrase to be backed up for z_getnewaccount an…
This commit is contained in:
commit
b7d6120b20
|
@ -3268,6 +3268,7 @@ UniValue z_getnewaccount(const UniValue& params, bool fHelp)
|
||||||
LOCK(pwalletMain->cs_wallet);
|
LOCK(pwalletMain->cs_wallet);
|
||||||
|
|
||||||
EnsureWalletIsUnlocked();
|
EnsureWalletIsUnlocked();
|
||||||
|
EnsureWalletIsBackedUp(Params());
|
||||||
|
|
||||||
// Generate the new account.
|
// Generate the new account.
|
||||||
auto ufvkNew = pwalletMain->GenerateNewUnifiedSpendingKey();
|
auto ufvkNew = pwalletMain->GenerateNewUnifiedSpendingKey();
|
||||||
|
@ -3363,6 +3364,7 @@ UniValue z_getaddressforaccount(const UniValue& params, bool fHelp)
|
||||||
}
|
}
|
||||||
|
|
||||||
EnsureWalletIsUnlocked();
|
EnsureWalletIsUnlocked();
|
||||||
|
EnsureWalletIsBackedUp(Params());
|
||||||
|
|
||||||
auto res = pwalletMain->GenerateUnifiedAddress(account, receiverTypes, j);
|
auto res = pwalletMain->GenerateUnifiedAddress(account, receiverTypes, j);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue