]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_ircv3_sts.cpp
Allow disabling a STS policy for users in specific connect classes.
[user/henk/code/inspircd.git] / src / modules / m_ircv3_sts.cpp
index a8738b2ac0d718d0d2774bf423840c34b685053d..68f4c46c6d3a5621fe685613cfdd68dda9fe108b 100644 (file)
@@ -35,6 +35,10 @@ class STSCap : public Cap::Capability
                if (GetProtocol(user) == Cap::CAP_LEGACY)
                        return false;
 
+               // Don't send the cap to clients in a class which has STS disabled.
+               if (user->GetClass()->config->getBool("usests", true))
+                       return false;
+
                // Plaintext listeners have their own policy.
                SSLIOHook* sslhook = SSLIOHook::IsSSL(&user->eh);
                if (!sslhook)