Anope IRC Services  Version 1.8
Go to the documentation of this file.
1 /* Unreal IRCD 3.2.x functions
2  *
3  * (C) 2003-2014 Anope Team
4  * Contact us at
5  *
6  * Please read COPYING and README for further details.
7  *
8  * Based on the original code of Epona by Lara.
9  * Based on the original code of Services by Andy Church.
10  *
11  *
12  */
14 /*************************************************************************/
16 /* User Modes */
17 #define UMODE_a 0x00000001 /* a Services Admin */
18 #define UMODE_h 0x00000002 /* h Available for help (HelpOp) */
19 #define UMODE_i 0x00000004 /* i Invisible (not shown in /who) */
20 #define UMODE_o 0x00000008 /* o Global IRC Operator */
21 #define UMODE_r 0x00000010 /* r Identifies the nick as being registered */
22 #define UMODE_w 0x00000020 /* w Can listen to wallop messages */
23 #define UMODE_A 0x00000040 /* A Server Admin */
24 #define UMODE_N 0x00000080 /* N Network Administrator */
25 #define UMODE_O 0x00000100 /* O Local IRC Operator */
26 #define UMODE_C 0x00000200 /* C Co-Admin */
27 #define UMODE_d 0x00000400 /* d Makes it so you can not receive channel PRIVMSGs */
28 #define UMODE_p 0x00000800 /* Hides the channels you are in in a /whois reply */
29 #define UMODE_q 0x00001000 /* q Only U:Lines can kick you (Services Admins Only) */
30 #define UMODE_s 0x00002000 /* s Can listen to server notices */
31 #define UMODE_t 0x00004000 /* t Says you are using a /vhost */
32 #define UMODE_v 0x00008000 /* v Receives infected DCC Send Rejection notices */
33 #define UMODE_z 0x00010000 /* z Indicates that you are an SSL client */
34 #define UMODE_B 0x00020000 /* B Marks you as being a Bot */
35 #define UMODE_G 0x00040000 /* G Filters out all the bad words per configuration */
36 #define UMODE_H 0x00080000 /* H Hide IRCop Status (IRCop Only) */
37 #define UMODE_S 0x00100000 /* S services client */
38 #define UMODE_V 0x00200000 /* V Marks you as a WebTV user */
39 #define UMODE_W 0x00400000 /* W Lets you see when people do a /whois on you */
40 #define UMODE_T 0x00800000 /* T Prevents you from receiving CTCPs */
41 #define UMODE_g 0x20000000 /* g Can send & read globops and locops */
42 #define UMODE_x 0x40000000 /* x Gives user a hidden hostname */
43 #define UMODE_R 0x80000000 /* Allows you to only receive PRIVMSGs/NOTICEs from registered (+r) users */
46 /*************************************************************************/
48 /* Channel Modes */
50 #define CMODE_i 0x00000001
51 #define CMODE_m 0x00000002
52 #define CMODE_n 0x00000004
53 #define CMODE_p 0x00000008
54 #define CMODE_s 0x00000010
55 #define CMODE_t 0x00000020
56 #define CMODE_k 0x00000040 /* These two used only by ChanServ */
57 #define CMODE_l 0x00000080
58 #define CMODE_R 0x00000100 /* Only identified users can join */
59 #define CMODE_r 0x00000200 /* Set for all registered channels */
60 #define CMODE_c 0x00000400
61 #define CMODE_A 0x00000800
62 /* #define CMODE_H 0x00001000 Was now +I may not join, but Unreal Removed it and it will not set in 3.2 */
63 #define CMODE_K 0x00002000
64 #define CMODE_L 0x00004000
65 #define CMODE_O 0x00008000
66 #define CMODE_Q 0x00010000
67 #define CMODE_S 0x00020000
68 #define CMODE_V 0x00040000
69 #define CMODE_f 0x00080000
70 #define CMODE_G 0x00100000
71 #define CMODE_C 0x00200000
72 #define CMODE_u 0x00400000
73 #define CMODE_z 0x00800000
74 #define CMODE_N 0x01000000
75 #define CMODE_T 0x02000000
76 #define CMODE_M 0x04000000
77 #define CMODE_j 0x08000000
80 /* Default Modes with MLOCK */
84 void unreal_set_umode(User * user, int ac, char **av);
85 void unreal_cmd_svsnoop(char *server, int set);
86 void unreal_cmd_remove_akill(char *user, char *host);
87 void unreal_cmd_topic(char *whosets, char *chan, char *whosetit, char *topic, time_t when);
88 void unreal_cmd_vhost_off(User * u);
89 void unreal_cmd_akill(char *user, char *host, char *who, time_t when,time_t expires, char *reason);
90 void unreal_cmd_svskill(char *source, char *user, char *buf);
91 void unreal_cmd_svsmode(User * u, int ac, char **av);
92 void unreal_cmd_372(char *source, char *msg);
93 void unreal_cmd_372_error(char *source);
94 void unreal_cmd_375(char *source);
95 void unreal_cmd_376(char *source);
96 void unreal_cmd_nick(char *nick, char *name, char *modes);
97 void unreal_cmd_guest_nick(char *nick, char *user, char *host, char *real, char *modes);
98 void unreal_cmd_mode(char *source, char *dest, char *buf);
99 void unreal_cmd_bot_nick(char *nick, char *user, char *host, char *real, char *modes);
100 void unreal_cmd_kick(char *source, char *chan, char *user, char *buf);
101 void unreal_cmd_notice_ops(char *source, char *dest, char *buf);
102 void unreal_cmd_notice(char *source, char *dest, char *buf);
103 void unreal_cmd_notice2(char *source, char *dest, char *msg);
104 void unreal_cmd_privmsg(char *source, char *dest, char *buf);
105 void unreal_cmd_privmsg2(char *source, char *dest, char *msg);
106 void unreal_cmd_serv_notice(char *source, char *dest, char *msg);
107 void unreal_cmd_serv_privmsg(char *source, char *dest, char *msg);
108 void unreal_cmd_bot_chan_mode(char *nick, char *chan);
109 void unreal_cmd_351(char *source);
110 void unreal_cmd_quit(char *source, char *buf);
111 void unreal_cmd_pong(char *servname, char *who);
112 void unreal_cmd_join(char *user, char *channel, time_t chantime);
113 void unreal_cmd_unsqline(char *user);
114 void unreal_cmd_invite(char *source, char *chan, char *nick);
115 void unreal_cmd_part(char *nick, char *chan, char *buf);
116 void unreal_cmd_391(char *source, char *timestr);
117 void unreal_cmd_250(char *buf);
118 void unreal_cmd_307(char *buf);
119 void unreal_cmd_311(char *buf);
120 void unreal_cmd_312(char *buf);
121 void unreal_cmd_317(char *buf);
122 void unreal_cmd_219(char *source, char *letter);
123 void unreal_cmd_401(char *source, char *who);
124 void unreal_cmd_318(char *source, char *who);
125 void unreal_cmd_242(char *buf);
126 void unreal_cmd_243(char *buf);
127 void unreal_cmd_211(char *buf);
128 void unreal_cmd_global(char *source, char *buf);
129 void unreal_cmd_global_legacy(char *source, char *fmt);
130 void unreal_cmd_sqline(char *mask, char *reason);
131 void unreal_cmd_squit(char *servname, char *message);
132 void unreal_cmd_svso(char *source, char *nick, char *flag);
133 void unreal_cmd_chg_nick(char *oldnick, char *newnick);
134 void unreal_cmd_svsnick(char *source, char *guest, time_t when);
135 void unreal_cmd_vhost_on(char *nick, char *vIdent, char *vhost);
136 void unreal_cmd_connect(int servernum);
137 void unreal_cmd_bob();
138 void unreal_cmd_svshold(char *nick);
139 void unreal_cmd_release_svshold(char *nick);
140 void unreal_cmd_unsgline(char *mask);
141 void unreal_cmd_unszline(char *mask);
142 void unreal_cmd_szline(char *mask, char *reason, char *whom);
143 void unreal_cmd_sgline(char *mask, char *reason);
144 void unreal_cmd_unban(char *name, char *nick);
145 void unreal_cmd_svsmode_chan(char *name, char *mode, char *nick);
146 void unreal_cmd_svid_umode(char *nick, time_t ts);
147 void unreal_cmd_nc_change(User * u);
148 void unreal_cmd_svid_umode2(User * u, char *ts);
149 void unreal_cmd_svid_umode3(User * u, char *ts);
150 void unreal_cmd_eob();
151 int unreal_flood_mode_check(char *value);
152 void unreal_cmd_jupe(char *jserver, char *who, char *reason);
153 int unreal_valid_nick(char *nick);
154 void unreal_cmd_ctcp(char *source, char *dest, char *buf);
155 int unreal_jointhrottle_mode_check(char *value);
void unreal_cmd_372_error(char *source)
Definition: unreal31.c:565
void unreal_cmd_szline(char *mask, char *reason, char *whom)
Definition: unreal31.c:1314
void unreal_cmd_242(char *buf)
Definition: unreal31.c:882
void unreal_cmd_global_legacy(char *source, char *fmt)
Definition: unreal31.c:1448
void unreal_cmd_ctcp(char *source, char *dest, char *buf)
Definition: unreal31.c:1476
void unreal_cmd_global(char *source, char *buf)
Definition: unreal31.c:912
void unreal_cmd_svsnoop(char *server, int set)
Definition: unreal31.c:504
void unreal_cmd_317(char *buf)
Definition: unreal31.c:838
void unreal_cmd_bot_nick(char *nick, char *user, char *host, char *real, char *modes)
Definition: unreal31.c:607
void unreal_cmd_privmsg(char *source, char *dest, char *buf)
Definition: unreal31.c:653
void unreal_cmd_nick(char *nick, char *name, char *modes)
Definition: unreal31.c:582
void unreal_cmd_squit(char *servname, char *message)
Definition: unreal31.c:932
void unreal_cmd_svid_umode3(User *u, char *ts)
Definition: unreal31.c:1364
void unreal_cmd_bob()
Definition: unreal31.c:1001
void unreal_cmd_318(char *source, char *who)
Definition: unreal31.c:872
void unreal_cmd_svid_umode(char *nick, time_t ts)
Definition: unreal31.c:1342
void unreal_cmd_pong(char *servname, char *who)
Definition: unreal31.c:724
void unreal_cmd_219(char *source, char *letter)
Definition: unreal31.c:848
void unreal_cmd_311(char *buf)
Definition: unreal31.c:818
void unreal_cmd_sgline(char *mask, char *reason)
Definition: unreal31.c:1322
void unreal_cmd_jupe(char *jserver, char *who, char *reason)
Definition: unreal31.c:1434
void unreal_cmd_401(char *source, char *who)
Definition: unreal31.c:863
void unreal_cmd_351(char *source)
Definition: unreal31.c:683
void unreal_cmd_unszline(char *mask)
Definition: unreal31.c:1307
void unreal_cmd_312(char *buf)
Definition: unreal31.c:828
void unreal_cmd_remove_akill(char *user, char *host)
Definition: unreal31.c:514
void unreal_cmd_connect(int servernum)
Definition: unreal31.c:983
void unreal_cmd_307(char *buf)
Definition: unreal31.c:808
void unreal_cmd_svsnick(char *source, char *guest, time_t when)
Definition: unreal31.c:962
void unreal_cmd_nc_change(User *u)
Definition: unreal31.c:1349
void unreal_cmd_privmsg2(char *source, char *dest, char *msg)
Definition: unreal31.c:662
int unreal_valid_nick(char *nick)
Definition: unreal31.c:1458
void unreal_cmd_372(char *source, char *msg)
Definition: unreal31.c:560
void unreal_set_umode(User *user, int ac, char **av)
Definition: unreal31.c:372
void unreal_cmd_akill(char *user, char *host, char *who, time_t when, time_t expires, char *reason)
Definition: unreal31.c:533
void unreal_cmd_serv_privmsg(char *source, char *dest, char *msg)
Definition: unreal31.c:672
void unreal_cmd_243(char *buf)
Definition: unreal31.c:892
void unreal_cmd_mode(char *source, char *dest, char *buf)
Definition: unreal31.c:598
void unreal_cmd_join(char *user, char *channel, time_t chantime)
Definition: unreal31.c:732
void unreal_cmd_release_svshold(char *nick)
Definition: unreal31.c:1295
void unreal_cmd_vhost_on(char *nick, char *vIdent, char *vhost)
Definition: unreal31.c:972
void unreal_cmd_topic(char *whosets, char *chan, char *whosetit, char *topic, time_t when)
Definition: unreal31.c:519
void unreal_cmd_250(char *buf)
Definition: unreal31.c:798
void unreal_cmd_kick(char *source, char *chan, char *user, char *buf)
Definition: unreal31.c:616
E int servernum
Definition: extern.h:615
void unreal_cmd_211(char *buf)
Definition: unreal31.c:902
void unreal_cmd_serv_notice(char *source, char *dest, char *msg)
Definition: unreal31.c:667
void unreal_cmd_376(char *source)
Definition: unreal31.c:577
void unreal_cmd_vhost_off(User *u)
Definition: unreal31.c:526
int unreal_jointhrottle_mode_check(char *value)
Definition: unreal32.c:1876
void unreal_cmd_375(char *source)
Definition: unreal31.c:571
void unreal_cmd_svsmode_chan(char *name, char *mode, char *nick)
Definition: unreal31.c:1334
void unreal_cmd_svsmode(User *u, int ac, char **av)
Definition: unreal31.c:553
void unreal_cmd_unsqline(char *user)
Definition: unreal31.c:738
void unreal_cmd_sqline(char *mask, char *reason)
Definition: unreal31.c:922
void unreal_cmd_unsgline(char *mask)
Definition: unreal31.c:1301
void unreal_cmd_svskill(char *source, char *user, char *buf)
Definition: unreal31.c:540
void unreal_cmd_eob()
Definition: unreal31.c:1399
void unreal_cmd_svshold(char *nick)
Definition: unreal31.c:1289
void unreal_cmd_svso(char *source, char *nick, char *flag)
Definition: unreal31.c:942
int unreal_flood_mode_check(char *value)
Definition: unreal31.c:1420
void unreal_cmd_part(char *nick, char *chan, char *buf)
Definition: unreal31.c:775
void unreal_cmd_svid_umode2(User *u, char *ts)
Definition: unreal31.c:1355
void unreal_cmd_chg_nick(char *oldnick, char *newnick)
Definition: unreal31.c:952
void unreal_cmd_notice(char *source, char *dest, char *buf)
Definition: unreal31.c:635
void unreal_cmd_notice_ops(char *source, char *dest, char *buf)
Definition: unreal31.c:625
void unreal_cmd_notice2(char *source, char *dest, char *msg)
Definition: unreal31.c:648
void unreal_cmd_391(char *source, char *timestr)
Definition: unreal31.c:789
void unreal_cmd_invite(char *source, char *chan, char *nick)
Definition: unreal31.c:765
void unreal_cmd_unban(char *name, char *nick)
Definition: unreal31.c:1327
void unreal_cmd_quit(char *source, char *buf)
Definition: unreal31.c:691
void unreal_cmd_guest_nick(char *nick, char *user, char *host, char *real, char *modes)
Definition: unreal31.c:591
void unreal_cmd_bot_chan_mode(char *nick, char *chan)
Definition: unreal31.c:678