Enable DNS Blocklist

This commit is contained in:
_xxfedexx_ 2023-05-01 18:10:16 +02:00
parent 085d0f1994
commit cdad11aec5
2 changed files with 6 additions and 4 deletions

View file

@ -526,12 +526,12 @@ bool load_txt_records_from_dns(std::vector<std::string> &good_records, const std
const std::string &url = dns_urls[cur_index]; const std::string &url = dns_urls[cur_index];
if (!avail[cur_index]) if (!avail[cur_index])
{ {
records[cur_index].clear(); //records[cur_index].clear(); TODO: temp skipped DNSSEC
LOG_PRINT_L2("DNSSEC not available for hostname: " << url << ", skipping."); LOG_PRINT_L2("DNSSEC not available for hostname: " << url << ", skipping.");
} }
if (!valid[cur_index]) if (!valid[cur_index])
{ {
records[cur_index].clear(); //records[cur_index].clear(); TODO: temp skipped DNSSEC
LOG_PRINT_L2("DNSSEC validation failed for hostname: " << url << ", skipping."); LOG_PRINT_L2("DNSSEC validation failed for hostname: " << url << ", skipping.");
} }

View file

@ -2012,12 +2012,14 @@ namespace nodetool
template<class t_payload_net_handler> template<class t_payload_net_handler>
bool node_server<t_payload_net_handler>::update_dns_blocklist() bool node_server<t_payload_net_handler>::update_dns_blocklist()
{ {
if (!m_enable_dns_blocklist) /*if (!m_enable_dns_blocklist) // TODO: temp forced DNS blocklist
return true; return true;*/
if (m_nettype != cryptonote::MAINNET) if (m_nettype != cryptonote::MAINNET)
return true; return true;
static const std::vector<std::string> dns_urls = { static const std::vector<std::string> dns_urls = {
"blocklist.wownero.com",
"blocklist2.wownero.com",
}; };
std::vector<std::string> records; std::vector<std::string> records;