5 #ifndef BITCOIN_NETGROUP_H 6 #define BITCOIN_NETGROUP_H 96 explicit NetGroupManager(std::span<const std::byte> embedded_asmap, std::vector<std::byte>&& loaded_asmap)
104 #endif // BITCOIN_NETGROUP_H std::vector< unsigned char > GetGroup(const CNetAddr &address) const
Get the canonical identifier of the network group for address.
NetGroupManager & operator=(const NetGroupManager &)=delete
void ASMapHealthCheck(const std::vector< CNetAddr > &clearnet_addrs) const
Analyze and log current health of ASMap based buckets.
std::vector< std::byte > m_loaded_asmap
uint256 GetAsmapVersion() const
Get the asmap version, a checksum identifying the asmap being used.
bool UsingASMap() const
Indicates whether ASMap is being used for clearnet bucketing.
static NetGroupManager NoAsmap()
static NetGroupManager WithEmbeddedAsmap(std::span< const std::byte > asmap)
static NetGroupManager WithLoadedAsmap(std::vector< std::byte > &&asmap)
uint32_t GetMappedAS(const CNetAddr &address) const
Get the autonomous system on the BGP path to address.
const std::span< const std::byte > m_asmap
Compressed IP->ASN mapping.
NetGroupManager(const NetGroupManager &)=delete
NetGroupManager(std::span< const std::byte > embedded_asmap, std::vector< std::byte > &&loaded_asmap)