Bitcoin ABC 0.26.3
P2P Digital Currency
|
#include <banman.h>
Public Member Functions | |
~BanMan () | |
BanMan (fs::path ban_file, const CChainParams &chainparams, CClientUIInterface *client_interface, int64_t default_ban_time) | |
void | Ban (const CNetAddr &net_addr, int64_t ban_time_offset=0, bool since_unix_epoch=false) |
void | Ban (const CSubNet &sub_net, int64_t ban_time_offset=0, bool since_unix_epoch=false) |
void | Discourage (const CNetAddr &net_addr) |
void | ClearBanned () |
bool | IsBanned (const CNetAddr &net_addr) |
Return whether net_addr is banned. | |
bool | IsBanned (const CSubNet &sub_net) |
Return whether sub_net is exactly banned. | |
bool | IsDiscouraged (const CNetAddr &net_addr) |
Return whether net_addr is discouraged. | |
bool | Unban (const CNetAddr &net_addr) |
bool | Unban (const CSubNet &sub_net) |
void | GetBanned (banmap_t &banmap) |
void | DumpBanlist () |
Private Member Functions | |
void | SetBanned (const banmap_t &banmap) |
bool | BannedSetIsDirty () |
void | SetBannedSetDirty (bool dirty=true) |
set the "dirty" flag for the banlist | |
void | SweepBanned () |
clean unused entries (if bantime has expired) | |
banmap_t m_banned | GUARDED_BY (m_cs_banned) |
bool m_is_dirty | GUARDED_BY (m_cs_banned) |
CRollingBloomFilter m_discouraged | GUARDED_BY (m_cs_banned) |
Private Attributes | |
RecursiveMutex | m_cs_banned |
CClientUIInterface * | m_client_interface = nullptr |
CBanDB | m_ban_db |
const int64_t | m_default_ban_time |
BanMan::~BanMan | ( | ) |
BanMan::BanMan | ( | fs::path | ban_file, |
const CChainParams & | chainparams, | ||
CClientUIInterface * | client_interface, | ||
int64_t | default_ban_time | ||
) |
void BanMan::Ban | ( | const CNetAddr & | net_addr, |
int64_t | ban_time_offset = 0 , |
||
bool | since_unix_epoch = false |
||
) |
Definition at line 116 of file banman.cpp.
|
private |
Definition at line 221 of file banman.cpp.
void BanMan::ClearBanned | ( | ) |
void BanMan::DumpBanlist | ( | ) |
Definition at line 49 of file banman.cpp.
Definition at line 179 of file banman.cpp.
|
private |
|
private |
|
inlineprivate |
Return whether net_addr is banned.
Definition at line 89 of file banman.cpp.
Return whether sub_net is exactly banned.
Definition at line 103 of file banman.cpp.
Return whether net_addr is discouraged.
Definition at line 84 of file banman.cpp.
Definition at line 187 of file banman.cpp.
set the "dirty" flag for the banlist
Definition at line 226 of file banman.cpp.
|
private |
clean unused entries (if bantime has expired)
Definition at line 193 of file banman.cpp.
Definition at line 157 of file banman.cpp.
|
private |
|
private |