Author: Isomer <isomer@coders.net>
[ircu2.10.12-pk.git] / doc / example.conf
1 # ircd.conf  configuration file for ircd version ircu2.9.mu and ircu2.10
2 #
3 # Written by Niels <niels@undernet.org>, based on the original example.conf,
4 # server code and some real-life (ahem) experience.
5 #
6 # Thanks and credits to: Run, Trillian, Cym, Morrissey, Chaos, Flynn,
7 #                        Xorath, WildThang, Mmmm, SeKs, Ghostwolf and
8 #                        all other Undernet IRC Admins and Operators,
9 #                        and programmers working on the Undernet ircd.
10
11 # This is an example of the configuration file used by the Undernet ircd.
12 #
13 # This document is based on a (fictious) server in Europe with a
14 # connection to the Undernet IRC network. It is primarily a leaf server,
15 # but if all the other hubs in Europe aren't in service, it can connect
16 # to one in the US by itself.
17 #
18 # All configuration options start with a letter identifying the option,
19 # and a colon separated list of options. An asterisk indicates an
20 # unused field.
21 #
22 # Please note that when ircd puts the configuration lines into practice,
23 # it parses them exactly the other way round than they are listed here.
24 # This means that you should start your I: lines with the "fall through",
25 # most vanilla one and end with the most detailed.
26 #
27 # There is a difference between the ``hostname'' and the ``server name''
28 # of the machine that the server is run on. For example, the host can
29 # have ``veer.cs.vu.nl'' as FQDN, and ``Amsterdam.NL.EU.undernet.org'' as
30 # server name.
31 # A ``server mask'' is something like '*.EU.UnderNet.org'', which is
32 # matched by 'Amsterdam.NL.EU.undernet.org' but not by
33 # 'Manhattan.KS.US.undernet.org'.
34
35 #
36 # First some information about the server.
37 # M:<server name>:<virtual host>:<description>:<server port>:<server numeric>
38 #
39 # <virtual host> must contain either a * or a valid IPv4 address in
40 # dotted quad notation. (127.0.0.1) The address MUST be the address
41 # of a physical interface on the host. This address is used for outgoing
42 # connections only, see P:lines for listener virtual hosting.
43 # If in doubt put a * or the IP of your primary interface here.
44 # The server must be compiled with virtual hosting turned on to get this
45 # to work correctly.
46 #
47 # The <server port> is no longer used.
48 # Ports need to be specified with a P: line, see below.
49 # At some point in the future we may want to use the port value for
50 # server capacity. --Bleep
51 #
52 # Note that <server numeric> has to be unique on the network your server
53 # is running on, must be between 1 and 64, and is not updated on a rehash.
54
55 M:London.UK.Eu.UnderNet.org:*:University of London, England:0:1
56
57 #
58 # This sets information that can be retrieved with the /ADMIN command.
59 # It should contain at least an admin Email contact address.
60 # A:<line 1>:<line 2>:<line 3>
61
62 A:The University of London:Undernet IRC server:IRC Admins <irc@london.ac.uk>
63
64 #
65 # All connections to the server are associated with a certain ``connection
66 # class'', be they incoming or outgoing (initiated by the server), be they
67 # clients, servers or Martians. (Note that ircd doesn't have direct support
68 # for Martians (yet?); they will have to register as normal users. ;-)
69 # Take the following Y: lines only as a guide.
70 # Y:<class>:<ping freq>:<connect freq>:<maximum links>:<sendq size>
71
72 # Server classes: 90 = all your uplinks for who you do not wish to hub;
73 # else in classes 80 and/or 70.
74 # 50 = leaf servers (only used if your server is a hub)
75
76 Y:90:90:300:1:1700000
77 Y:80:90:300:1:1700000
78 Y:70:90:300:1:1700000
79 Y:50:90:300:10:1700000
80
81 # Client classes. 10 = locals; 2 = for all .net and .com that are not
82 # in Europe; 1 = for everybody.
83
84 Y:10:90:0:100:160000
85 Y:2:90:0:5:80000
86 Y:1:90:0:400:160000
87
88 #
89 # To allow clients to connect, they need authorization. This can be
90 # done based on hostmask, address mask, and/or with a password.
91 # With intelligent use of classes and the maxconnections field in the
92 # Y: lines, you can let in a specific domain, but get rid of all other
93 # domains in the same toplevel, thus setting up some sort of 'reverse
94 # K: line'.
95 # I:<IP mask or crap to force resolving>:<opt passwd>:<hostmask>::<class>
96
97 # Technical description (for examples, see below):
98 # For every connecting client, the IP-number is know.  A reverse lookup
99 # on this IP-number is done to get the (/all) hostname(s).
100 # Each hostname that belongs to this IP-number is matched to <hostmask>,
101 # and the I: line is used when any matches; the client will then show
102 # with this particular hostname.  If none of the hostnames matches, then
103 # the IP-number is matched against the <IP mask ...> field, if this matches
104 # then the I: line is used nevertheless and the client will show with the
105 # first (main) hostname if any; if the IP-number did not resolve then the
106 # client will show with the dot notation of the IP-number.
107 # There is a special case for the UNIX domain sockets and localhost connections
108 # though; in this case the <IP mask ...> field is compared with the
109 # name of the server (thus not with any IP-number representation). The name
110 # of the server is the one returned in the numeric 002 reply, for example:
111 # 002 Your host is 2.undernet.org[jolan.ppro], running version ...
112 # Then the "jolan.ppro" is the name used for matching.
113 # Therefore, unix domain sockets, and connections to localhost would
114 # match this I: line:
115 # I:jolan.ppro::foobar::1
116 # Finally, I: lines with empty <IP mask ..> or <hostmask> fields are skipped.
117
118 # This is the 'fallback' entry. All .uk, .nl, and all unresolved are
119 # in these two lines.
120 # By using two different lines, multiple connections from a single IP
121 # are only allowed from hostnames which have both valid forward and
122 # reverse DNS mappings.
123
124 I:*@*:1:Unresolved::1
125 I:Resolved::*@*::1
126
127 # If you don't want unresolved dudes to be able to connect to your
128 # server, use just:
129 # I:NotMatchingCrap::*@*::1
130
131 # Here, take care of all American ISPs.
132 I:Resolved::*@*.com::2
133 I:Resolved::*@*.net::2
134
135 # Now list all the .com / .net domains that you wish to have access...
136 # actually it's less work to do it this way than to do it the other
137 # way around - K: lining every single ISP in the US.
138 # I wish people in Holland just got a .nl domain, and not try to be
139 # cool and use .com...
140 I:Resolved::*@*.wirehub.net::1
141 I:Resolved::*@*.planete.net::1
142 I:Resolved::*@*.ivg.com::1
143 I:Resolved::*@*.ib.com::1
144 I:Resolved::*@*.ibm.net::1
145 I:Resolved::*@*.hydro.com::1
146 I:Resolved::*@*.NL.net::1
147
148 # You can request a more complete listing, including the "list of standard
149 # K-lines" from the Routing Committee; it will also be sent to you if
150 # you apply for a server and get accepted.
151
152 # Ourselves - this makes sure that we can get in, no matter how full
153 # the server is (hopefully).
154 I:*@193.37.*::*@*.london.ac.uk::10
155
156 # You can put a digit (0..9) in the password field, which will make ircd
157 # only accept a client when the total number of connections to the network
158 # from the same IP number doesn't exceed this number.
159 # The following example would accept at most one connection per IP number
160 # from "*.swipnet.se" and at most two connections from dial up accounts
161 # that have "dial??.*" as host mask:
162 # I:Resolved:1:*@*.swipnet.se::1
163 # I:Resolved:2:*@dial??.*::1
164
165 #
166 # It is possible to show a different Message of the Day to a connecting
167 # client depending on its origin.
168 # T:<hostmask>:<path to motd file>
169
170 # DPATH/net_com.motd contains a special MOTD where users are encouraged
171 # to register their domains and get their own I: lines if they're in
172 # Europe, or move to US.UnderNet.org if they're in the USA.
173 T:*.net:net_com.motd
174 T:*.com:net_com.motd
175
176 # A different MOTD for ourselves, where we point out that the helpdesk
177 # better not be bothered with questions regarding irc...
178 T:*.london.ac.uk:london.motd
179
180 #
181 # One of the many nice features of Undernet is ``Uworld'', a program
182 # connected to the net as a server. This allows it to broadcast any mode
183 # change, thus allowing opers to, for example, 'unlock' a channel that
184 # has been taken over.
185 # There is only one slight problem: the TimeStamp protocol prevents this.
186 # So there is a configuration option to allow them anyway from a certain
187 # server.
188 # Note: (1) These lines are agreed on by every server admin on Undernet;
189 # (2) These lines must be the same on every single server, or results
190 # will be disasterous; (3) This is a useful feature, not something that
191 # is a liability and abused regularly (well... :-)
192 # If you're on Undernet, you MUST have these lines. I cannnot stress
193 # this enough.
194 # As of ircu2.10.05 is it possible to Jupe nicks. Juped nicks need to be
195 # added to U: lines.  As per CFV-0095, the following nicks must be juped,
196 # it is not allowed to jupe others as well.
197
198 U:Uworld.EU.undernet.org:EuWorld,E,protocol,StatServ,NoteServ,Undernet:*
199 U:Uworld2.undernet.org:UWorld2,ChanSvr,ChanSaver,ChanServ,COM1,COM2,COM3,COM4:*
200 U:Uworld.undernet.org:Uworld,X,W,NickSvr,NickSaver,NickServ,LPT1,LPT2,AUX:*
201
202 #
203 # While running your server, you will most probably encounter individuals
204 # or groups of persons that you do not wish to have access to your server.
205 #
206 # For this purpose, the ircd understands "kill lines".
207 # K:<host/IP mask>:"<opt reason>":<username mask>
208 #
209 # It is possible to use a file as comment for the ban.
210 # K:<host/IP mask>:!<path to file>:<usermask>
211 #
212 # The default reason is: "You are banned from this server"
213 # Note that K: lines are local to the server; if you ban a person or a
214 # whole domain from your server, they can get on IRC via any other server
215 # that doesn't have them K: lined (yet).
216
217 # With a simple comment, using quotes:
218 K:*.au:"Please use a nearer server":*
219 K:*.edu:"Please use a nearer server":*
220
221 # With a file, prepending a '!' before the filename.
222 # The file can contain for example, a reason, a link to the
223 # server rules and a contact address.
224 K:unixbox.flooder.co.uk:!kline/youflooded.txt:*luser
225
226 #
227 # IP-based kill lines are designated with a lowercase 'k'.  These lines
228 # use the same format as normal K: lines, except they apply to all hosts,
229 # even if an IP address has a properly resolving host name.
230 k:192.168.*:!klines/martians:*
231
232 #
233 # You probably want your server connected to other servers, so your users
234 # have other users to chat with.
235 # IRC servers connect to other servers forming a network with a star or
236 # tree topology. Loops are not allowed.
237 # In this network, two servers can be distinguished: "hub" and "leaf"
238 # servers. Leaf servers connect to hubs; hubs connect to each other.
239 # Of course, many servers can't be directly classified in one of these
240 # categories. Both a fixed and a rule-based decision making system for
241 # server links is provided for ircd to decide what links to allow, what
242 # to let humans do themselves, and what links to (forcefully) disallow.
243 #
244 # The Connection lines (also known as C lines)
245 # define what servers the server connect to, and which servers are
246 # allowed to connect.
247 # C:<remote hostname or IP>:<password>:<remote server name>:<port>:<class>
248 #
249 # If the "port" field is omitted, the server will not attempt to
250 # establish a link with that server ("not autoconnecting").
251
252 # Our primary uplink.
253 C:1.2.3.4:passwd:Amsterdam.NL.Eu.UnderNet.org:4400:90
254
255 #
256 # If your server starts on a bit larger network, you'll probably get
257 # assigned one or two uplinks to which your server can connect.
258 # If your uplink(s) also connect to other servers than yours (which is
259 # probable), you need to define your uplink as being allowed to "hub".
260 # H:<allowed hostmask>::<server name>
261 H:*.*::Amsterdam.NL.Eu.UnderNet.org
262
263 #
264 # Of course, the opposite is also possible: forcing a server to be
265 # a leaf. L: lines follow Murphy's Law: if you use them, there's a big
266 # chance that routing will be screwed up afterwards.
267 # L:<opt disallowed hostmask>::<server mask>:<opt max depth>
268
269 #
270 # For an advanced, real-time rule-based routing decision making system
271 # you can use Disallow lines. For more information, see doc/readme.crules.
272 # D:<server mask that ircd will refuse to connect to>::<rule>
273 # d:<server mask that ircd will not autoconnect to>::<rule>
274 # D:*.US.UnderNet.org::connected(*.US.UnderNet.org)
275 # d:*.EU.UnderNet.org::connected(Amsterdam.NL.EU.*)
276
277 # The following line is recommended for leaf servers:
278 # d:*::directcon(*)
279
280 #
281 # Inevitably, you have reached the part about "IRC Operators". Oper status
282 # grants some special privileges to a user, like the power to make the
283 # server break or (try to) establish a connection with another server,
284 # and to "kill" users off IRC.
285 # I can write many pages about this; I will restrict myself to saying that
286 # if you want to appoint somebody as IRC Operator on your server, that
287 # person should be aware of his/her responsibilities, and that you, being
288 # the admin, will be held accountable for their actions.
289 #
290 # There are two sorts of IRC Operators: "local" and "global". Local opers
291 # can squit, connect and kill - but only locally: their +o user mode
292 # is not not passed along to other servers. On Undernet, this prevents
293 # them from using Uworld as well.
294 # Depending on some defines in include/config.h, local operators are also
295 # not allowed to /DIE and /RESTART the server.
296 # Local operators are designated with a lowercase 'o'
297 # O:<host/IP mask>:<encrypted password>:<Nick>::<connection class>
298 # o:<host/IP mask>:<encrypted password>:<Nick>::<connection class>
299
300 O:*@*.cs.vu.nl:VRKLKuGKn0jLs:Niels::10
301
302 # Note that the <connection class> is optional, but leaving it away
303 # puts the O: lines in class 0, which usually only accepts one connection
304 # at a time.  If you want users to Oper up more then once per O: line,
305 # then use a connection class that allows more then one connection,
306 # for example (using class 10 as in the example above):
307 # Y:10:90:0:100:160000
308
309 # [P:lines]
310 # When your server gets fuller, you will notice delays when trying to
311 # connect to your server's primary listening port. Via the Port lines
312 # it is possible to specify additional ports for ircd to listen to.
313 # De facto ports are: 6667 - standard; 6660-6669 - additional client
314 # ports;
315 # Undernet uses 4400 for server listener ports.
316 # These are just hints, they are in no way official IANA or IETF policies.
317 #
318 # The interface setting allows multiply homed hosts to specify which
319 # interface to use on a port by port basis, if an interface is not specified
320 # the default interface will be used. The interface MUST be the complete
321 # IP address for a real hardware interface on the machine running ircd.
322 #
323 # The [CS][H] field is an optional field to specify that a port is a
324 # server port or a client port and whether it's hidden or not.
325 # If used the first character MUST be either a C or S.
326 # If you want to hide a port from /stats p from non-opers follow the C
327 # or S with an H
328 #
329 # P:<hostmask>:<interface>:<[CS][H]>:<client port number>
330 #
331 # This is a normal server port, you need to have at least one server
332 # port defined if you want to connect your server to other servers.
333 P:::S:4400
334 # This is a Server port that is Hidden
335 #P:::SH:4401
336
337 # The following are normal client ports
338 P:::C:6667
339 P::::6668
340 P:*.nl:::6666
341
342 # This is a hidden client port, listening on the interface associated
343 # with the IP address 168.8.21.107
344 #P:*:168.8.21.107:CH:7000
345
346 #
347 # Well, you have now reached the end of this sample configuration file
348 # If you have any questions, feel free to mail <doco-com@undernet.org>
349 # or <coder-com@undernet.org>.
350 # If you are interested in linking your server to the Undernet IRC network
351 # visit http://www.routing-com.undernet.org/, and if there are any problems
352 # then contact <routing-com@undernet.org> asking for information.
353 # Upgrades of the Undernet ircd can be found on http://coder-com.undernet.org/.
354 #
355 # For the rest:  Good Luck!
356 #
357 #       -- Niels.