summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-06-16 10:58:28 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-06-16 10:58:28 +0000
commitef672ecfcc78b21f04143c6f21c5450c972cdffc (patch)
treeadce27fed3509a83aeabb97233b74f7290c3d300 /modules
parent6ba883ff9d3934eacf35d4dc6844052d9f1301ad (diff)
- Add usermode 'S' (client is connecte via SSL/TLS).
Allows services to keep track of what users are connected via SSL, and allows to see ssl-status of remote clients in a /whois git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@2247 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'modules')
-rw-r--r--modules/m_svsmode.c3
-rw-r--r--modules/m_whois.c9
2 files changed, 7 insertions, 5 deletions
diff --git a/modules/m_svsmode.c b/modules/m_svsmode.c
index d54f664..77cfad6 100644
--- a/modules/m_svsmode.c
+++ b/modules/m_svsmode.c
@@ -146,6 +146,9 @@ ms_svsmode(struct Client *client_p, struct Client *source_p,
break;
+ case 'S': /* Only servers may set +S in a burst */
+ break;
+
default:
if ((flag = user_modes[(unsigned char)*m]))
{
diff --git a/modules/m_whois.c b/modules/m_whois.c
index 85531a2..764e458 100644
--- a/modules/m_whois.c
+++ b/modules/m_whois.c
@@ -136,6 +136,10 @@ whois_person(struct Client *source_p, struct Client *target_p)
show_ip ? target_p->sockhost : "255.255.255.255");
}
+ if (HasUMode(target_p, UMODE_SSL))
+ sendto_one(source_p, form_str(RPL_WHOISSECURE), me.name,
+ source_p->name, target_p->name);
+
if (!EmptyString(target_p->certfp))
if (target_p == source_p || HasUMode(source_p, UMODE_OPER))
sendto_one(source_p, form_str(RPL_WHOISCERTFP), me.name,
@@ -143,11 +147,6 @@ whois_person(struct Client *source_p, struct Client *target_p)
if (MyConnect(target_p))
{
-#ifdef HAVE_LIBCRYPTO
- if (target_p->localClient->fd.ssl)
- sendto_one(source_p, form_str(RPL_WHOISSECURE),
- me.name, source_p->name, target_p->name);
-#endif
sendto_one(source_p, form_str(RPL_WHOISIDLE),
me.name, source_p->name, target_p->name,
idle_time_get(source_p, target_p),