]>
jfr.im git - solanum.git/blob - extensions/extb_ssl.c
1 /* SSL extban type: matches ssl users */
8 static const char extb_desc
[] = "SSL/TLS ($z) extban type";
10 static int _modinit(void);
11 static void _moddeinit(void);
12 static int eb_ssl(const char *data
, struct Client
*client_p
, struct Channel
*chptr
, long mode_type
);
14 DECLARE_MODULE_AV2(extb_ssl
, _modinit
, _moddeinit
, NULL
, NULL
, NULL
, NULL
, NULL
, extb_desc
);
19 extban_table
['z'] = eb_ssl
;
27 extban_table
['z'] = NULL
;
30 static int eb_ssl(const char *data
, struct Client
*client_p
,
31 struct Channel
*chptr
, long mode_type
)
37 if (! IsSSLClient(client_p
))
38 return EXTBAN_NOMATCH
;
42 if (EmptyString(client_p
->certfp
))
43 return EXTBAN_NOMATCH
;
45 if (irccmp(data
, client_p
->certfp
) != 0)
46 return EXTBAN_NOMATCH
;