aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/m_dnsbl.cpp
diff options
context:
space:
mode:
authorGravatar Peter Powell2018-07-13 10:28:28 +0100
committerGravatar Peter Powell2018-07-18 19:22:17 +0100
commitb7716ed57704b2b2bcc665a590aecc8f02de631d (patch)
tree43f1c62613f3aee5074009a3b8e4582dc65c3638 /src/modules/m_dnsbl.cpp
parentAdd the family() member to the sockaddrs union. (diff)
downloadinspircd++-b7716ed57704b2b2bcc665a590aecc8f02de631d.tar.gz
inspircd++-b7716ed57704b2b2bcc665a590aecc8f02de631d.tar.bz2
inspircd++-b7716ed57704b2b2bcc665a590aecc8f02de631d.zip
Initial support for listening on UNIX socket endpoints.
Diffstat (limited to 'src/modules/m_dnsbl.cpp')
-rw-r--r--src/modules/m_dnsbl.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/modules/m_dnsbl.cpp b/src/modules/m_dnsbl.cpp
index 95913c235..10b0e2728 100644
--- a/src/modules/m_dnsbl.cpp
+++ b/src/modules/m_dnsbl.cpp
@@ -339,6 +339,10 @@ class ModuleDNSBL : public Module, public Stats::EventListener
if ((user->exempt) || !DNS)
return;
+ // Clients can't be in a DNSBL if they aren't connected via IPv4 or IPv6.
+ if (user->client_sa.family() != AF_INET && user->client_sa.family() != AF_INET6)
+ return;
+
if (user->MyClass)
{
if (!user->MyClass->config->getBool("usednsbl", true))