aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet_rpc_server.cpp
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-06-18 09:28:27 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-10-14 11:43:47 +0000
commit19c0506e14e6f1649048b15917d15af55f79f116 (patch)
tree868963c7a65e16e036d6b6857afafca3cea331a0 /src/wallet/wallet_rpc_server.cpp
parentwallet2: ignore received unencrypted payment IDs (but warn hard) (diff)
downloadmonero-19c0506e14e6f1649048b15917d15af55f79f116.tar.xz
wallet: remove long payment ID sending support
Diffstat (limited to 'src/wallet/wallet_rpc_server.cpp')
-rw-r--r--src/wallet/wallet_rpc_server.cpp27
1 files changed, 3 insertions, 24 deletions
diff --git a/src/wallet/wallet_rpc_server.cpp b/src/wallet/wallet_rpc_server.cpp
index 0e0221c03..b52c63d2b 100644
--- a/src/wallet/wallet_rpc_server.cpp
+++ b/src/wallet/wallet_rpc_server.cpp
@@ -793,30 +793,9 @@ namespace tools
if (!payment_id.empty())
{
-
- /* Just to clarify */
- const std::string& payment_id_str = payment_id;
-
- crypto::hash long_payment_id;
- crypto::hash8 short_payment_id;
-
- /* Parse payment ID */
- if (wallet2::parse_long_payment_id(payment_id_str, long_payment_id)) {
- cryptonote::set_payment_id_to_tx_extra_nonce(extra_nonce, long_payment_id);
- }
- else {
- er.code = WALLET_RPC_ERROR_CODE_WRONG_PAYMENT_ID;
- er.message = "Payment id has invalid format: \"" + payment_id_str + "\", expected 64 character string";
- return false;
- }
-
- /* Append Payment ID data into extra */
- if (!cryptonote::add_extra_nonce_to_tx_extra(extra, extra_nonce)) {
- er.code = WALLET_RPC_ERROR_CODE_WRONG_PAYMENT_ID;
- er.message = "Something went wrong with payment_id. Please check its format: \"" + payment_id_str + "\", expected 64-character string";
- return false;
- }
-
+ er.code = WALLET_RPC_ERROR_CODE_WRONG_PAYMENT_ID;
+ er.message = "Standalone payment IDs are obsolete. Use subaddresses or integrated addresses instead";
+ return false;
}
return true;
}