]>
jfr.im git - irc/quakenet/newserv.git/blob - glines/glines.c
1 #include "../irc/irc.h"
2 #include "../trusts/trusts.h"
5 void glinesetbynick(nick
*np
, int duration
, char *reason
, char *creator
, int flags
) {
6 irc_send("%s GL * +%s@%s %d %jd :%s", mynumeric
->content
, istrusted(np
)?np
->ident
:"*", IPtostr(np
->p_ipaddr
), duration
, (intmax_t)getnettime(), reason
);
9 void glinesetbynode( patricia_node_t
*node
, int duration
, char *reason
, char *creator
) {
10 irc_send("%s GL * +*@%s %d %jd :%s", mynumeric
->content
, IPtostr(node
->prefix
->sin
), duration
, (intmax_t)getnettime(), reason
);
15 * This should be avoided (where possible) and gline on Nick/IPs instead
17 void glinesetbyhost(char *ident
, char *hostname
, int duration
, char *reason
, char *creator
) {
18 irc_send("%s GL * +%s@%s %d %jd :%s", mynumeric
->content
, ident
, hostname
, duration
, (intmax_t)getnettime(), reason
);
21 void unglinebyhost(char *ident
, char *hostname
, int duration
, char *reason
) {
22 irc_send("%s GL * -%s@%s %d %jd :%s", mynumeric
->content
, ident
, hostname
, duration
, (intmax_t)getnettime(), reason
);