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)
for (std::vector<ListenSocket*>::const_iterator iter = ServerInstance->ports.begin(); iter != ServerInstance->ports.end(); ++iter)
{
ListenSocket* ls = *iter;
-
+
// Is this listener on the right port?
unsigned int saport = ls->bind_sa.port();
if (saport != port)