30 #include "serialization/keyvalue_serialization.h" 34 #include "net/http_server_impl_base.h" 35 #include "net/http_client.h" 36 #include "net/abstract_http_client.h" 38 #include "wipeable_string.h" 62 BEGIN_KV_SERIALIZE_MAP()
67 KV_SERIALIZE_VAL_POD_AS_BLOB(
iv)
73 KV_SERIALIZE_VAL_POD_AS_BLOB(
hash)
78 END_KV_SERIALIZE_MAP()
85 message_transporter(std::unique_ptr<epee::net_utils::http::abstract_http_client> http_client);
86 void set_options(
const std::string &bitmessage_address,
const epee::wipeable_string &bitmessage_login);
88 bool receive_messages(
const std::vector<std::string> &destination_transport_addresses,
89 std::vector<transport_message> &messages);
91 void stop() { m_run.store(
false, std::memory_order_relaxed); }
92 std::string derive_transport_address(
const std::string &seed);
93 bool delete_transport_address(
const std::string &transport_address);
96 const std::unique_ptr<epee::net_utils::http::abstract_http_client>
m_http_client;
101 bool post_request(
const std::string &request, std::string &answer);
102 static std::string get_str_between_tags(
const std::string &
s,
const std::string &start_delim,
const std::string &stop_delim);
104 static void start_xml_rpc_cmd(std::string &xml,
const std::string &method_name);
105 static void add_xml_rpc_string_param(std::string &xml,
const std::string ¶m);
106 static void add_xml_rpc_base64_param(std::string &xml,
const std::string ¶m);
107 static void add_xml_rpc_integer_param(std::string &xml,
const int32_t ¶m);
108 static void end_xml_rpc_cmd(std::string &xml);
const std::unique_ptr< epee::net_utils::http::abstract_http_client > m_http_client
Definition: message_transporter.h:96
std::string destination_transport_address
Definition: message_transporter.h:49
std::string content
Definition: message_transporter.h:55
Definition: message_transporter.h:82
uint32_t type
Definition: message_transporter.h:53
uint32_t signature_count
Definition: message_transporter.h:59
epee::wipeable_string m_bitmessage_login
Definition: message_transporter.h:98
std::string source_transport_address
Definition: message_transporter.h:47
crypto::signature signature
Definition: message_transporter.h:57
uint32_t round
Definition: message_transporter.h:58
std::string m_bitmessage_url
Definition: message_transporter.h:97
void stop()
Definition: message_transporter.h:91
crypto::chacha_iv iv
Definition: message_transporter.h:50
Definition: message_transporter.h:44
crypto::public_key encryption_public_key
Definition: message_transporter.h:51
std::string subject
Definition: message_transporter.h:54
Definition: message_store.h:102
std::string transport_id
Definition: message_transporter.h:60
crypto::hash hash
Definition: message_transporter.h:56
uint64_t timestamp
Definition: message_transporter.h:52
Definition: message_store.cpp:48
std::atomic< bool > m_run
Definition: message_transporter.h:99
cryptonote::account_public_address destination_monero_address
Definition: message_transporter.h:48
POD_CLASS public_key
Definition: crypto.h:61
Definition: cryptonote_format_utils.h:43
POD_CLASS signature
Definition: crypto.h:93
Definition: cryptonote_basic.h:500
epee::misc_utils::struct_init< transport_message_t > transport_message
Definition: message_transporter.h:80
POD_CLASS hash
Definition: hash.h:48
cryptonote::account_public_address source_monero_address
Definition: message_transporter.h:46
#define s(x, c)
Definition: aesb.c:47