Add 'sethdseed' RPC to initialize or replace HD seed

This commit is contained in:
Chris Moore
2017-09-12 14:01:12 -07:00
committed by Andrew Chow
parent dd3c07acce
commit b5ba01a187
5 changed files with 80 additions and 0 deletions
+4
View File
@@ -1452,7 +1452,11 @@ CPubKey CWallet::GenerateNewHDMasterKey()
{
CKey key;
key.MakeNewKey(true);
return DeriveNewMasterHDKey(key);
}
CPubKey CWallet::DeriveNewMasterHDKey(const CKey& key)
{
int64_t nCreationTime = GetTime();
CKeyMetadata metadata(nCreationTime);