33#include <boost/serialization/vector.hpp>
34#include <boost/serialization/utility.hpp>
112 return a.original ==
b.original
113 &&
a.amount ==
b.amount
115 &&
a.is_subaddress ==
b.is_subaddress
116 &&
a.is_integrated ==
b.is_integrated;
138 const std::unordered_map<crypto::public_key, cryptonote::subaddress_index>& subaddresses,
141 void classify_addresses(
const std::vector<tx_destination_entry> &destinations,
const boost::optional<cryptonote::account_public_address>& change_addr,
size_t &num_stdaddresses,
size_t &num_subaddresses,
account_public_address &single_dest_subaddress);
143 bool construct_tx(
const account_keys& sender_account_keys, std::vector<tx_source_entry> &sources,
const std::vector<tx_destination_entry>& destinations,
const boost::optional<cryptonote::account_public_address>& change_addr,
const std::vector<uint8_t> &extra,
transaction&
tx);
144 bool construct_tx_with_tx_key(
const account_keys& sender_account_keys,
const std::unordered_map<crypto::public_key, subaddress_index>& subaddresses, std::vector<tx_source_entry>& sources, std::vector<tx_destination_entry>& destinations,
const boost::optional<cryptonote::account_public_address>& change_addr,
const std::vector<uint8_t> &extra,
transaction&
tx,
const crypto::secret_key &tx_key,
const std::vector<crypto::secret_key> &additional_tx_keys,
bool rct =
false,
const rct::RCTConfig &rct_config = {
rct::RangeProofBorromean, 0 },
bool shuffle_outs =
true,
bool use_view_tags =
false);
145 bool construct_tx_and_get_tx_key(
const account_keys& sender_account_keys,
const std::unordered_map<crypto::public_key, subaddress_index>& subaddresses, std::vector<tx_source_entry>& sources, std::vector<tx_destination_entry>& destinations,
const boost::optional<cryptonote::account_public_address>& change_addr,
const std::vector<uint8_t> &extra,
transaction&
tx,
crypto::secret_key &tx_key, std::vector<crypto::secret_key> &additional_tx_keys,
bool rct =
false,
const rct::RCTConfig &rct_config = {
rct::RangeProofBorromean, 0 },
bool use_view_tags =
false);
148 const bool &need_additional_txkeys,
const std::vector<crypto::secret_key> &additional_tx_keys,
149 std::vector<crypto::public_key> &additional_tx_public_keys,
150 std::vector<rct::key> &amount_keys,
156 const bool &need_additional_txkeys,
const std::vector<crypto::secret_key> &additional_tx_keys,
157 std::vector<crypto::public_key> &additional_tx_public_keys,
158 std::vector<rct::key> &amount_keys,
164 , std::string
const & genesis_tx
183 template <
class Archive>
199 template <
class Archive>
cryptonote::block b
Definition block.cpp:40
Definition blockchain.h:103
Definition cryptonote_basic.h:307
std::tuple< uint64_t, uint64_t, std::vector< tools::wallet2::transfer_details > > outputs
Definition cold-outputs.cpp:53
#define BEGIN_SERIALIZE_OBJECT()
#define inline
Definition inline_c.h:34
#define AUTO_VAL_INIT(v)
Definition misc_language.h:36
void serialize(Archive &a, std::unordered_map< h_key, hval > &x, const boost::serialization::version_type ver)
Definition unordered_containers_boost_serialization.h:126
Definition portable_binary_archive.hpp:29
epee::mlocked< tools::scrubbed< ec_scalar > > secret_key
Definition crypto.h:72
POD_CLASS hash8
Definition hash.h:52
POD_CLASS view_tag
Definition crypto.h:103
POD_CLASS public_key
Definition crypto.h:64
POD_CLASS hash
Definition hash.h:49
Holds cryptonote related classes and helpers.
Definition blockchain_db.cpp:45
void classify_addresses(const std::vector< tx_destination_entry > &destinations, const boost::optional< cryptonote::account_public_address > &change_addr, size_t &num_stdaddresses, size_t &num_subaddresses, account_public_address &single_dest_subaddress)
Definition cryptonote_tx_utils.cpp:76
network_type
Definition cryptonote_config.h:302
crypto::public_key get_destination_view_key_pub(const std::vector< tx_destination_entry > &destinations, const boost::optional< cryptonote::account_public_address > &change_addr)
Definition cryptonote_tx_utils.cpp:208
bool construct_tx(const account_keys &sender_account_keys, std::vector< tx_source_entry > &sources, const std::vector< tx_destination_entry > &destinations, const boost::optional< cryptonote::account_public_address > &change_addr, const std::vector< uint8_t > &extra, transaction &tx)
Definition cryptonote_tx_utils.cpp:676
void get_altblock_longhash(const block &b, crypto::hash &res, const crypto::hash &seed_hash)
Definition cryptonote_tx_utils.cpp:711
std::string get_account_address_as_str(network_type nettype, bool subaddress, account_public_address const &adr)
Definition cryptonote_basic_impl.cpp:151
boost::optional< cryptonote::subaddress_index > sanity_check_change_address(const cryptonote::account_public_address &change_addr, const std::unordered_map< crypto::public_key, cryptonote::subaddress_index > &subaddresses, const cryptonote::account_keys &keys)
check if can re-derive change address from device / keys
Definition cryptonote_tx_utils.cpp:55
bool construct_tx_and_get_tx_key(const account_keys &sender_account_keys, const std::unordered_map< crypto::public_key, subaddress_index > &subaddresses, std::vector< tx_source_entry > &sources, std::vector< tx_destination_entry > &destinations, const boost::optional< cryptonote::account_public_address > &change_addr, const std::vector< uint8_t > &extra, transaction &tx, crypto::secret_key &tx_key, std::vector< crypto::secret_key > &additional_tx_keys, bool rct, const rct::RCTConfig &rct_config, bool use_view_tags)
Definition cryptonote_tx_utils.cpp:646
std::string blobdata
Definition blobdatatype.h:39
bool get_block_longhash(const Blockchain *pbc, const blobdata &bd, crypto::hash &res, const uint64_t height, const int major_version, const crypto::hash *seed_hash, const int miners)
Definition cryptonote_tx_utils.cpp:717
bool construct_tx_with_tx_key(const account_keys &sender_account_keys, const std::unordered_map< crypto::public_key, subaddress_index > &subaddresses, std::vector< tx_source_entry > &sources, std::vector< tx_destination_entry > &destinations, const boost::optional< cryptonote::account_public_address > &change_addr, const std::vector< uint8_t > &extra, transaction &tx, const crypto::secret_key &tx_key, const std::vector< crypto::secret_key > &additional_tx_keys, bool rct, const rct::RCTConfig &rct_config, bool shuffle_outs, bool use_view_tags)
Definition cryptonote_tx_utils.cpp:230
bool construct_miner_tx(size_t height, size_t median_weight, uint64_t already_generated_coins, size_t current_block_weight, uint64_t fee, const account_public_address &miner_address, transaction &tx, const blobdata &extra_nonce, size_t max_outs, uint8_t hard_fork_version)
Definition cryptonote_tx_utils.cpp:102
bool generate_genesis_block(block &bl, std::string const &genesis_tx, uint32_t nonce)
Definition cryptonote_tx_utils.cpp:686
std::string get_account_integrated_address_as_str(network_type nettype, account_public_address const &adr, crypto::hash8 const &payment_id)
Definition cryptonote_basic_impl.cpp:162
bool generate_output_ephemeral_keys(const size_t tx_version, const cryptonote::account_keys &sender_account_keys, const crypto::public_key &txkey_pub, const crypto::secret_key &tx_key, const cryptonote::tx_destination_entry &dst_entr, const boost::optional< cryptonote::account_public_address > &change_addr, const size_t output_index, const bool &need_additional_txkeys, const std::vector< crypto::secret_key > &additional_tx_keys, std::vector< crypto::public_key > &additional_tx_public_keys, std::vector< rct::key > &amount_keys, crypto::public_key &out_eph_public_key, const bool use_view_tags, crypto::view_tag &view_tag)
Definition bulletproofs.cc:64
key zeroCommit(xmr_amount amount)
Definition rctOps.cpp:322
@ RangeProofBorromean
Definition rctTypes.h:307
Definition binary_utils.h:36
BOOST_CLASS_VERSION(nodetool::peerlist_types, nodetool::CURRENT_PEERLIST_STORAGE_ARCHIVE_VER)
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition pointer.h:1124
unsigned int uint32_t
Definition stdint.h:126
unsigned char uint8_t
Definition stdint.h:124
unsigned __int64 uint64_t
Definition stdint.h:136
Definition cryptonote_basic.h:614
Definition cryptonote_basic.h:577
Definition cryptonote_tx_utils.h:122
uint64_t fee
Definition cryptonote_tx_utils.h:125
uint64_t weight
Definition cryptonote_tx_utils.h:124
crypto::hash id
Definition cryptonote_tx_utils.h:123
Definition cryptonote_tx_utils.h:75
bool is_subaddress
Definition cryptonote_tx_utils.h:79
std::string address(network_type nettype, const crypto::hash &payment_id) const
Definition cryptonote_tx_utils.h:86
tx_destination_entry()
Definition cryptonote_tx_utils.h:82
bool is_integrated
Definition cryptonote_tx_utils.h:80
tx_destination_entry(uint64_t a, const account_public_address &ad, bool is_subaddress)
Definition cryptonote_tx_utils.h:83
std::string original
Definition cryptonote_tx_utils.h:76
uint64_t amount
Definition cryptonote_tx_utils.h:77
tx_destination_entry(const std::string &o, uint64_t a, const account_public_address &ad, bool is_subaddress)
Definition cryptonote_tx_utils.h:84
account_public_address addr
Definition cryptonote_tx_utils.h:78
Definition cryptonote_tx_utils.h:43
std::vector< crypto::public_key > real_out_additional_tx_keys
Definition cryptonote_tx_utils.h:49
crypto::public_key real_out_tx_key
Definition cryptonote_tx_utils.h:48
uint64_t amount
Definition cryptonote_tx_utils.h:51
rct::multisig_kLRki multisig_kLRki
Definition cryptonote_tx_utils.h:54
bool rct
Definition cryptonote_tx_utils.h:52
uint64_t real_output
Definition cryptonote_tx_utils.h:47
uint64_t real_output_in_tx_index
Definition cryptonote_tx_utils.h:50
std::vector< output_entry > outputs
Definition cryptonote_tx_utils.h:46
rct::key mask
Definition cryptonote_tx_utils.h:53
void push_output(uint64_t idx, const crypto::public_key &k, uint64_t amount)
Definition cryptonote_tx_utils.h:56
std::pair< uint64_t, rct::ctkey > output_entry
Definition cryptonote_tx_utils.h:44
if(real_output >=outputs.size()) return false
Definition chaingen.h:294
Definition rctTypes.h:308
Definition rctTypes.h:113
cryptonote::transaction tx
Definition transaction.cpp:40