Tiny safety net
This commit is contained in:
parent
a55c6de32b
commit
bf15a1c7f3
@ -34,7 +34,11 @@ defmodule Pleroma.Web.ActivityPub.MRF.DnsRblPolicy do
|
|||||||
rblzone = rblconfig[:zone] || rblhost
|
rblzone = rblconfig[:zone] || rblhost
|
||||||
|
|
||||||
# concatenate the host we're checking with the zone, e.g., "pleroma.host" <> . <> "bl.pleroma.com" <> .
|
# concatenate the host we're checking with the zone, e.g., "pleroma.host" <> . <> "bl.pleroma.com" <> .
|
||||||
query = (actor_host <> "." <> rblzone <> ".") |> String.to_charlist()
|
# trim off duplicate trailing period in case it was supplied in the config.
|
||||||
|
query =
|
||||||
|
(actor_host <> "." <> rblzone <> ".")
|
||||||
|
|> String.replace_suffix("..", ".")
|
||||||
|
|> String.to_charlist()
|
||||||
|
|
||||||
# Timeout of 1s, retry 1
|
# Timeout of 1s, retry 1
|
||||||
# We will only be using UDP for queries, so I think if the DNSRBL server is > 500ms away it won't work
|
# We will only be using UDP for queries, so I think if the DNSRBL server is > 500ms away it won't work
|
||||||
|
Loading…
Reference in New Issue
Block a user