Electroneum
cryptonote_basic_impl.cpp File Reference
#include "include_base_utils.h"
#include "cryptonote_basic_impl.h"
#include "string_tools.h"
#include "serialization/binary_utils.h"
#include "serialization/container.h"
#include "cryptonote_format_utils.h"
#include "cryptonote_config.h"
#include "misc_language.h"
#include "common/base58.h"
#include "crypto/hash.h"
#include "int-util.h"
#include "common/dns_utils.h"
#include <math.h>
Include dependency graph for cryptonote_basic_impl.cpp:

Go to the source code of this file.

Classes

struct  cryptonote::integrated_address
 

Namespaces

 cryptonote
 Holds cryptonote related classes and helpers.
 

Macros

#define ELECTRONEUM_DEFAULT_LOG_CATEGORY   "cn"
 

Functions

size_t cryptonote::get_min_block_weight (uint8_t version)
 
size_t cryptonote::get_max_tx_size ()
 
bool cryptonote::get_block_reward (size_t median_weight, size_t current_block_weight, uint64_t already_generated_coins, uint64_t &reward, uint8_t version, uint64_t current_block_height, network_type nettype)
 
uint8_t cryptonote::get_account_address_checksum (const public_address_outer_blob &bl)
 
uint8_t cryptonote::get_account_integrated_address_checksum (const public_integrated_address_outer_blob &bl)
 
std::string cryptonote::get_account_address_as_str (network_type nettype, bool subaddress, account_public_address const &adr)
 
std::string cryptonote::get_account_integrated_address_as_str (network_type nettype, account_public_address const &adr, crypto::hash8 const &payment_id)
 
bool cryptonote::is_coinbase (const transaction &tx)
 
bool cryptonote::get_account_address_from_str (address_parse_info &info, network_type nettype, std::string const &str)
 
bool cryptonote::get_account_address_from_str_or_url (address_parse_info &info, network_type nettype, const std::string &str_or_url, std::function< std::string(const std::string &, const std::vector< std::string > &, bool)> dns_confirm)
 
bool cryptonote::operator== (const cryptonote::transaction &a, const cryptonote::transaction &b)
 
bool cryptonote::operator== (const cryptonote::block &a, const cryptonote::block &b)
 
bool parse_hash256 (const std::string &str_hash, crypto::hash &hash)
 

Macro Definition Documentation

◆ ELECTRONEUM_DEFAULT_LOG_CATEGORY

#define ELECTRONEUM_DEFAULT_LOG_CATEGORY   "cn"

Definition at line 50 of file cryptonote_basic_impl.cpp.

Function Documentation

◆ parse_hash256()

bool parse_hash256 ( const std::string &  str_hash,
crypto::hash hash 
)

Definition at line 373 of file cryptonote_basic_impl.cpp.

374 {
377  if (!res || buf.size() != sizeof(crypto::hash))
378  {
379  MERROR("invalid hash format: " << str_hash);
380  return false;
381  }
382  else
383  {
384  buf.copy(reinterpret_cast<char *>(&hash), sizeof(crypto::hash));
385  return true;
386  }
387 }
const char * res
Definition: hmac_keccak.cpp:41
#define MERROR(x)
Definition: misc_log_ex.h:73
::std::string string
Definition: gtest-port.h:1097
const char * buf
Definition: slow_memmem.cpp:74
POD_CLASS hash
Definition: hash.h:50
bool parse_hexstr_to_binbuff(const epee::span< const char > s, epee::span< char > &res)
Definition: string_tools.h:92
Here is the call graph for this function:
Here is the caller graph for this function: