#include "keystore.h"
-#include "crypter.h"
#include "key.h"
-#include "script/script.h"
-#include "script/standard.h"
#include "util.h"
#include <boost/foreach.hpp>
LOCK(cs_KeyStore);
return (!setWatchOnly.empty());
}
+
+bool CBasicKeyStore::AddSpendingKey(const libzcash::SpendingKey &sk)
+{
+ LOCK(cs_SpendingKeyStore);
+ auto address = sk.address();
+ mapSpendingKeys[address] = sk;
+ mapNoteDecryptors.insert(std::make_pair(address, ZCNoteDecryption(sk.viewing_key())));
+ return true;
+}