diff options
author | luigi1111 <luigi1111w@gmail.com> | 2020-04-04 12:41:32 -0500 |
---|---|---|
committer | luigi1111 <luigi1111w@gmail.com> | 2020-04-04 12:41:32 -0500 |
commit | 60110646939b055f81939a6d6d4cbc43f90ea707 (patch) | |
tree | ec374baa6789575d92ddc366fd8ebf4a03cfb700 /src/wallet/api/wallet.cpp | |
parent | Merge pull request #6328 (diff) | |
parent | wallet2_api: wallet recovery - seed offset passphrase support (diff) | |
download | monero-60110646939b055f81939a6d6d4cbc43f90ea707.tar.xz |
Merge pull request #6334
cc18926 wallet2_api: wallet recovery - seed offset passphrase support (xiphon)
Diffstat (limited to 'src/wallet/api/wallet.cpp')
-rw-r--r-- | src/wallet/api/wallet.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/wallet/api/wallet.cpp b/src/wallet/api/wallet.cpp index 33047f703..4612b0397 100644 --- a/src/wallet/api/wallet.cpp +++ b/src/wallet/api/wallet.cpp @@ -725,7 +725,7 @@ bool WalletImpl::recover(const std::string &path, const std::string &seed) return recover(path, "", seed); } -bool WalletImpl::recover(const std::string &path, const std::string &password, const std::string &seed) +bool WalletImpl::recover(const std::string &path, const std::string &password, const std::string &seed, const std::string &seed_offset/* = {}*/) { clearStatus(); m_errorString.clear(); @@ -743,6 +743,10 @@ bool WalletImpl::recover(const std::string &path, const std::string &password, c setStatusError(tr("Electrum-style word list failed verification")); return false; } + if (!seed_offset.empty()) + { + recovery_key = cryptonote::decrypt_key(recovery_key, seed_offset); + } if (old_language == crypto::ElectrumWords::old_language_name) old_language = Language::English().get_language_name(); |