remove password param from get_cache_file_buffer()

This commit is contained in:
woodser
2023-07-24 17:46:42 -04:00
parent a60c2752bb
commit 6fedf2d076
2 changed files with 5 additions and 5 deletions
+4 -4
View File
@@ -3440,9 +3440,9 @@ namespace monero {
void monero_wallet_full::change_password(const std::string& old_password, const std::string& new_password) {
MTRACE("change_password(" << "***" << ", ***)");
#if !defined(__EMSCRIPTEN__) // TODO: wallet2 verify_password loads from disk so password is verified in js for wasm
if (!get_path().empty()) { // TODO: skipping password verification of in-memory wallet
if (!m_w2->verify_password(old_password)) throw std::runtime_error("Invalid original password.");
#endif
}
m_w2->change_password(m_w2->get_wallet_file(), old_password, new_password);
}
@@ -3463,8 +3463,8 @@ namespace monero {
return buf;
}
std::string monero_wallet_full::get_cache_file_buffer(const epee::wipeable_string& password) const {
boost::optional<wallet2::cache_file_data> cache_file_data = m_w2->get_cache_file_data(password);
std::string monero_wallet_full::get_cache_file_buffer() const {
boost::optional<wallet2::cache_file_data> cache_file_data = m_w2->get_cache_file_data();
std::string buf;
::serialization::dump_binary(cache_file_data.get(), buf);
return buf;
+1 -1
View File
@@ -298,7 +298,7 @@ namespace monero {
* Wallet import and export using buffers and not the file system.
*/
std::string get_keys_file_buffer(const epee::wipeable_string& password, bool view_only) const;
std::string get_cache_file_buffer(const epee::wipeable_string& password) const;
std::string get_cache_file_buffer() const;
// ---------------------------------- PRIVATE ---------------------------------