From eecfb57df9aa4a78fb7c1b3c8072b1368654b433 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Sat, 31 Mar 2018 14:20:48 +0100 Subject: wallet: warn if not using the default ring size --- src/simplewallet/simplewallet.cpp | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'src/simplewallet') diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp index 97dadb126..61c6e6422 100644 --- a/src/simplewallet/simplewallet.cpp +++ b/src/simplewallet/simplewallet.cpp @@ -1650,6 +1650,9 @@ bool simple_wallet::set_default_ring_size(const std::vector &args/* return true; } + if (ring_size != 0 && ring_size != DEFAULT_MIX+1) + message_writer() << tr("WARNING: this is a non default ring size, which may harm your privacy. Default is recommended."); + const auto pwd_container = get_and_verify_password(); if (pwd_container) { @@ -4581,6 +4584,23 @@ bool simple_wallet::transfer_main(int transfer_type, const std::vector(vin); + if (in_to_key.key_offsets.size() != DEFAULT_MIX + 1) + default_ring_size = false; + } + } + } + if (m_wallet->confirm_non_default_ring_size() && !default_ring_size) + { + prompt << tr("WARNING: this is a non default ring size, which may harm your privacy. Default is recommended."); + } prompt << ENDL << tr("Is this okay? (Y/Yes/N/No): "); std::string accepted = input_line(prompt.str()); -- cgit v1.2.3