From e0fa7fa38488784efd1cbb87922b3079370e0b55 Mon Sep 17 00:00:00 2001 From: Riccardo Spagni Date: Tue, 2 Oct 2018 22:39:56 +0200 Subject: Merge pull request #4482 25e5890d wallet: fix --generate-from-json using wrong password (moneromooo-monero) --- src/common/password.cpp | 4 ++++ src/common/password.h | 1 + 2 files changed, 5 insertions(+) (limited to 'src/common') diff --git a/src/common/password.cpp b/src/common/password.cpp index 5671c4a4e..b32bedae2 100644 --- a/src/common/password.cpp +++ b/src/common/password.cpp @@ -221,6 +221,10 @@ namespace tools : m_password(std::move(password)) { } + password_container::password_container(const epee::wipeable_string& password) noexcept + : m_password(password) + { + } password_container::~password_container() noexcept { diff --git a/src/common/password.h b/src/common/password.h index 529881e40..beb98283b 100644 --- a/src/common/password.h +++ b/src/common/password.h @@ -47,6 +47,7 @@ namespace tools //! `password` is used as password password_container(std::string&& password) noexcept; + password_container(const epee::wipeable_string& password) noexcept; //! \return A password from stdin TTY prompt or `std::cin` pipe. static boost::optional prompt(bool verify, const char *mesage = "Password", bool hide_input = true); -- cgit v1.2.3