aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet.cpp
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2019-12-05 18:01:30 -0500
committerAndrew Chow <achow101-github@achow101.com>2019-12-06 15:05:08 -0500
commitfd9d6eebc1eabb4675a118d19d38283da2dead39 (patch)
tree94b31da8c4ac4ee1cd54250ed4417d294446c961 /src/wallet/wallet.cpp
parent4ee8a58ce77a1e013af98ceff1cf96bd0e4fd436 (diff)
Add GetEncryptionKey() and HasEncryptionKeys() to WalletStorage
Adds functions in WalletStorage that allow ScriptPubKeyMans to check and get encryption keys from the wallet.
Diffstat (limited to 'src/wallet/wallet.cpp')
-rw-r--r--src/wallet/wallet.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp
index abee497c1d..af3b7cf613 100644
--- a/src/wallet/wallet.cpp
+++ b/src/wallet/wallet.cpp
@@ -4056,3 +4056,13 @@ LegacyScriptPubKeyMan* CWallet::GetLegacyScriptPubKeyMan() const
{
return m_spk_man.get();
}
+
+const CKeyingMaterial& CWallet::GetEncryptionKey() const
+{
+ return vMasterKey;
+}
+
+bool CWallet::HasEncryptionKeys() const
+{
+ return !mapMasterKeys.empty();
+}