Changeset View
Changeset View
Standalone View
Standalone View
src/interfaces/node.cpp
Show First 20 Lines • Show All 154 Lines • ▼ Show 20 Lines | public: | ||||
} | } | ||||
bool getBanned(banmap_t &banmap) override { | bool getBanned(banmap_t &banmap) override { | ||||
if (m_context.banman) { | if (m_context.banman) { | ||||
m_context.banman->GetBanned(banmap); | m_context.banman->GetBanned(banmap); | ||||
return true; | return true; | ||||
} | } | ||||
return false; | return false; | ||||
} | } | ||||
bool ban(const CNetAddr &net_addr, BanReason reason, | bool ban(const CNetAddr &net_addr, int64_t ban_time_offset) override { | ||||
int64_t ban_time_offset) override { | |||||
if (m_context.banman) { | if (m_context.banman) { | ||||
m_context.banman->Ban(net_addr, reason, ban_time_offset); | m_context.banman->Ban(net_addr, ban_time_offset); | ||||
return true; | return true; | ||||
} | } | ||||
return false; | return false; | ||||
} | } | ||||
bool unban(const CSubNet &ip) override { | bool unban(const CSubNet &ip) override { | ||||
if (m_context.banman) { | if (m_context.banman) { | ||||
m_context.banman->Unban(ip); | m_context.banman->Unban(ip); | ||||
return true; | return true; | ||||
▲ Show 20 Lines • Show All 190 Lines • Show Last 20 Lines |