mirror of
https://github.com/monero-project/monero.git
synced 2025-08-06 12:54:20 -04:00
wallet: wipe seed from memory where appropriate
This commit is contained in:
parent
b780cf4db1
commit
ea37614efe
19 changed files with 653 additions and 144 deletions
|
@ -1574,11 +1574,13 @@ namespace tools
|
|||
|
||||
if (req.key_type.compare("mnemonic") == 0)
|
||||
{
|
||||
if (!m_wallet->get_seed(res.key))
|
||||
epee::wipeable_string seed;
|
||||
if (!m_wallet->get_seed(seed))
|
||||
{
|
||||
er.message = "The wallet is non-deterministic. Cannot display seed.";
|
||||
return false;
|
||||
}
|
||||
res.key = std::string(seed.data(), seed.size()); // send to the network, then wipe RAM :D
|
||||
}
|
||||
else if(req.key_type.compare("view_key") == 0)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue