aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2025-02-15 16:38:50 +0000
committerMatthew Wild <mwild1@gmail.com>2025-02-15 16:38:50 +0000
commit500d0df0a4c11147eb5eca7aa60e9216b0e96624 (patch)
treea508aa5a9b02fdd91fbe7d5527f046ad987c4283
parentf585db3acf0814f52b81a01ac780aa71d3d93604 (diff)
downloadprosody-500d0df0a4c11147eb5eca7aa60e9216b0e96624.tar.gz
prosody-500d0df0a4c11147eb5eca7aa60e9216b0e96624.zip
prosodyctl: check: Skip DNS checks for known invalid domains (fixes traceback)
-rw-r--r--util/prosodyctl/check.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/util/prosodyctl/check.lua b/util/prosodyctl/check.lua
index 67762c13..b601ee8b 100644
--- a/util/prosodyctl/check.lua
+++ b/util/prosodyctl/check.lua
@@ -928,7 +928,11 @@ local function check(arg)
local unknown_addresses = set.new();
- for jid in enabled_hosts() do
+ local function is_valid_domain(domain)
+ return idna.to_ascii(domain) ~= nil;
+ end
+
+ for jid in it.filter(is_valid_domain, enabled_hosts()) do
local all_targets_ok, some_targets_ok = true, false;
local node, host = jid_split(jid);