1 TS6 protocol description
2 Written by Jilles Tjoelker
4 General format: much like rfc1459
5 Maximum parameters for a command: 15 (this does not include the prefix
8 SID: a server's unique ID. It is configured in each server and consists of
9 a digit and two alphanumerics. Sending SIDs with lowercase letters is
12 UID: a client's unique ID. It consists of the server's SID and six
13 alphanumerics (so it is nine characters long). The first of the alphanumerics
14 should be a letter, numbers are legal but reserved for future use.
16 hunted: a parameter type used for various remote requests. From local users,
17 nicknames and server names are accepted, possibly with wildcards; from servers,
18 UIDs/SIDs (sending names or even wildcards is deprecated). This is done with
19 the function hunt_server(). Any rate limiting should be done locally.
21 duration: a parameter type used for ban durations. It is a duration in seconds.
22 A value of 0 means a permanent ban.
24 propagation: to which other servers the command is sent. For all commands
25 with a hunted parameter, the propagation is determined by that, and not
26 otherwise specified. Propagation broadcast means the command is sent to all
27 servers. Propagation one-to-one means the command is only sent to the target
28 or the server the target is on. Propagation none means the command is never
29 sent to another server if it is received. For some other commands, the
30 propagation depends on the parameters and is described in text.
32 services server: server mentioned in a service{} block. There are no services
35 service: client with umode +S. This implies that it is on a services server.
38 The initiator sends the PASS, CAPAB and SERVER messages. Upon receiving the
39 SERVER, the listener will check the information, and if it is valid, it will
40 send its own PASS, CAPAB and SERVER messages, followed by SVINFO and the burst.
41 Upon receiving the SERVER, the initiator will send SVINFO and the burst. If
42 ziplinks are used, SVINFO is the first compressed message.
44 The burst consists of SID and SERVER messages for all known servers, UID or
45 EUID messages for all known users (possibly followed by ENCAP REALHOST, ENCAP
46 LOGIN and/or AWAY) and SJOIN messages for all known channels (possibly followed
51 +D (deaf: does not receive channel messages)
52 +S (network service) (only settable on burst from a services server)
53 +a (appears as server administrator)
54 +i (invisible, see rfc1459)
55 +o (IRC operator, see rfc1459)
56 +w (wallops, see rfc1459) (always propagated for historical reasons)
58 +Q/+R/+g/+l/+s/+z (only locally effective)
59 +Z (ssl user) (only settable on burst)
60 possibly more added by modules
72 +k (key: password required to join, <= 23 ascii chars, no : or , or whitespace)
74 +l (limit: maximum number of members before further joins are disallowed)
77 +n (no external messages)
78 +p (private: does not appear in /whois to non-members, no /knock allowed)
79 +r (only registered users may join) (only if a services server exists)
81 +t (only chanops may change topic)
86 +f (forward: channel name <= 30 chars)
87 +j (join throttle: N:T with integer N and T)
89 +F (free target for +f)
91 +P (permanent: does not disappear when empty)
92 +Q (ignore forwards to this)
94 +g (allow any member to /invite)
95 +z (send messages blocked by +m to chanops)
101 Remote ADMIN request.
105 propagation: broadcast
106 parameters: opt. away reason
108 If the away reason is empty or not present, mark the user as not away.
109 Otherwise, mark the user as away.
111 Changing away reason from one non-empty string to another non-empty string
112 may not be propagated.
116 propagation: broadcast
117 parameters: channelTS, channel, type, space separated masks
119 If the channelTS in the message is greater (newer) than the current TS of
120 the channel, drop the message and do not propagate it.
122 Type is the mode letter of a ban-like mode. In efnet TS6 this is 'b', 'e' or
123 'I'. In charybdis TS6 additionally 'q' is possible.
125 Add all the masks to the given list of the channel.
127 All ban-like modes must be bursted using this command, not using MODE or TMODE.
130 source: unregistered server
132 parameters: space separated capability list
134 Sends capabilities of the server. This must include QS and ENCAP. It is also
135 strongly recommended to include EX, CHW, IE and KNOCK, and for charybdis TS6
136 also SAVE and EUID. For use with services, SERVICES and RSFNC are strongly
139 The capabilities may depend on the configuration for the server they are sent
145 propagation: broadcast
146 parameters: client, new hostname
148 Changes the visible hostname of a client.
150 Opers are notified unless the source is a server or a service.
154 parameters: server to connect to, port, hunted
156 Remote connect request. A server WALLOPS should be sent by the receiving
159 The port can be 0 for the default port.
165 parameters: duration, mask, reason
167 Sets a D:line (IP ban checked directly after accepting connection).
169 The mask must be an IP address or CIDR mask.
173 parameters: target server mask, subcommand, opt. parameters...
175 Sends a command to all servers with names matching the given mask (for example
176 '*', '*.example.com', 'irc.example.com'). Those servers do not have to be
177 directly connected. Targets cannot be SIDs.
179 Propagation is independent of understanding the subcommand.
182 source: server or unregistered server
184 parameters: error message
186 Reports a (usually fatal) error with the connection.
188 Error messages may contain IP addresses and have a negative effect on server
193 encap target: single server
197 Remote ETRACE information request.
203 parameters: nickname, hopcount, nickTS, umodes, username, visible hostname, IP address, UID, real hostname, account name, gecos
204 propagation: broadcast
206 Introduces a client. The client is on the source server of this command.
208 The account name is '0' if the user is not logged in with services.
212 EUID is similar to UID but includes the ENCAP REALHOST and ENCAP LOGIN
219 parameters: space separated capability list
221 Capability list of remote server.
231 parameters: target user, channel, opt. channelTS
232 propagation: one-to-one
234 Invites a user to a channel.
236 If the channelTS is greater (newer) than the current TS of the channel, drop
239 Not sending the channelTS parameter is deprecated.
244 parameters: '0' (one ASCII zero)
245 propagation: broadcast
247 Parts the source user from all channels.
251 parameters: channelTS, channel, '+' (a plus sign)
252 propagation: broadcast
254 Joins the source user to the given channel. If the channel does not exist yet,
255 it is created with the given channelTS and no modes. If the channel already
256 exists and has a greater (newer) TS, wipe all simple modes and statuses and
257 change the TS, notifying local users of this but not servers (note that
258 ban-like modes remain intact; invites may or may not be cleared).
262 parameters: channel, target user, opt. reason
263 propagation: broadcast
265 Kicks the target user from the given channel.
267 Unless the channel's TS is 0, no check is done whether the source user has ops.
269 Not sending the reason parameter is questionable.
273 parameters: target user, path
274 propagation: broadcast
276 Removes the user from the network.
278 The format of the path parameter is some sort of description of the source of
279 the kill followed by a space and a parenthesized reason. To avoid overflow,
280 it is recommended not to add anything to the path.
286 parameters: duration, user mask, host mask, reason
288 Sets a K:line (ban on user@host).
293 parameters: target server mask, duration, user mask, host mask, reason
295 As form 1, deprecated.
300 propagation: broadcast
302 Requests an invite to a channel that is locked somehow (+ikl). Notifies all
303 operators of the channel. (In charybdis, on +g channels all members are
306 This is broadcast so that each server can store when KNOCK was used last on
311 parameters: hunted, server mask
313 Remote LINKS request. The server mask limits which servers are listed.
321 Sends a message to operators (with umode +l set). This is intended to be
322 used for strict subsets of the network.
327 parameters: target server mask, text
329 As form 1, deprecated.
334 parameters: account name
336 In a burst, states that the source user is logged in as the account.
340 parameters: server mask, hunted
342 Remote LUSERS request. Most servers ignore the server mask, treating it as '*'.
347 parameters: client, umode changes
348 propagation: broadcast
350 Propagates a user mode change. The client parameter must refer to the same user
353 Not all umodes are propagated to other servers.
357 parameters: channel, cmode changes, opt. cmode parameters...
359 Propagates a channel mode change.
361 This is deprecated because the channelTS is not included. If it is received,
362 it should be propagated as TMODE.
373 parameters: new nickname, new nickTS
374 propagation: broadcast
376 Propagates a nick change.
380 parameters: nickname, hopcount, nickTS, umodes, username, hostname, server, gecos
382 Historic TS5 user introduction. The user is on the server indicated by the
383 server parameter; the source server is meaningless (local link).
389 source: services server
390 parameters: duration, nickname
392 If duration is greater than 0, makes the given nickname unavailable for that
395 If duration is 0, removes a nick delay entry for the given nickname.
397 There may or may not be a client with the given nickname; this does not affect
402 parameters: msgtarget, message
404 As PRIVMSG, except NOTICE messages are sent out, server sources are permitted
405 and most error messages are suppressed.
411 parameters: command name, parameters
413 Reports operspy usage.
418 propagation: broadcast
420 Sends a message to operators (with umode +z set).
424 parameters: comma separated channel list, message
426 Parts the source user from the given channels.
429 source: unregistered server
430 parameters: password, 'TS', TS version, SID
432 Sends the server link password, TS version and SID.
436 parameters: origin, opt. destination server
438 Sends a PING to the destination server, which will reply with a PONG. If the
439 destination server parameter is not present, the server receiving the message
442 The origin field is not used in the server protocol. It is sent as the name
443 (not UID/SID) of the source.
445 Remote PINGs are used for end-of-burst detection, therefore all servers must
450 parameters: origin, destination
452 Routes a PONG back to the destination that originally sent the PING.
456 parameters: msgtarget, message
458 Sends a normal message (PRIVMSG) to the given target.
462 propagation: one-to-one
464 propagation: all servers with -D users on the channel
465 (cmode +m/+n should be checked everywhere, bans should not be checked
467 - a status character ('@'/'+') followed by a channel name, to send to users
468 with that status or higher only.
469 propagation: all servers with -D users with appropriate status
470 - a user@server message, to send to users on a specific server. The exact
471 meaning of the part before the '@' is not prescribed, except that "opers"
472 allows IRC operators to send to all IRC operators on the server in an
474 propagation: one-to-one
475 - a message to all users on server names matching a mask ('$$' followed by mask)
476 propagation: broadcast
477 - a message to all users with hostnames matching a mask ('$#' followed by mask).
478 Note that this is often implemented poorly.
479 propagation: broadcast
484 encap target: single server
488 Remote PRIVS information request.
494 Propagates quitting of a client. No QUIT should be sent for a client that
495 has been removed as result of a KILL message.
502 parameters: real hostname
504 In a burst, propagates the real host of a dynamically-spoofed user.
510 parameters: opt. rehash type
512 Remote REHASH request. If the rehash type is omitted, it is equivalent to
513 a regular /rehash, otherwise it is equivalent to /rehash <rehash type>.
519 parameters: duration, mask, reason
521 Sets a RESV, making a nickname mask or exact channel unavailable.
526 parameters: target server mask, duration, mask, reason
528 As form 1, deprecated.
533 encap target: single server
534 source: services server
535 parameters: target user, new nickname, old nickTS, new nickTS
537 Forces a nickname change and propagates it.
539 The command is ignored if the nick TS of the user is not equal to the old
540 nickTS parameter. If the new nickname already exists (and is not the target
541 user), it is killed first.
549 parameters: source uid, '*', 'S', sasl mechanism name
551 Requests that a SASL agent (a service) initiate the authentication process.
552 The source uid is that of an unregistered client. This is why it is not sent
556 encap target: single server
558 parameters: source uid, target uid, mode, data
560 Part of a SASL authentication exchange. The mode is 'C' to send some data
561 (base64 encoded), or 'S' to end the exchange (data indicates type of
562 termination: 'A' for abort, 'F' for authentication failure, 'S' for
563 authentication success).
568 propagation: broadcast
569 parameters: target uid, TS
571 Resolve a nick collision by changing a nickname to the UID.
573 The server should verify that the UID belongs to a registered user, the user
574 does not already have their UID as their nick and the TS matches the user's
575 nickTS. If not, drop the message.
577 SAVE should be propagated as a regular NICK change to links without SAVE capab.
582 source: unregistered server
583 parameters: server name, hopcount, server description
585 Registers the connection as a server. PASS and CAPAB must have been sent
586 before, SVINFO should be sent afterwards.
588 If there is no such server configured or authentication failed, the connection
591 This is propagated as a SID message.
595 propagation: broadcast
596 parameters: server name, hopcount, server description
598 Introduces a new TS5 server, directly connected to the source of this command.
599 This is only used for jupes as TS5 servers may do little else than existing.
603 propagation: broadcast
604 parameters: server name, hopcount, sid, server description
606 Introduces a new server, directly connected to the source of this command.
610 propagation: broadcast
611 parameters: new nickname, new username, new visible hostname, new nickTS, new login name
613 Broadcasts a change of several user parameters at once.
615 Currently only sent after an SVSLOGIN.
619 propagation: broadcast
620 parameters: channelTS, simple modes, opt. mode parameters..., nicklist
622 Broadcasts a channel creation or bursts a channel.
624 The nicklist consists of users joining the channel, with status prefixes for
625 their status ('@+', '@', '+' or ''), for example:
626 '@+1JJAAAAAB +2JJAAAA4C 1JJAAAADS'. All users must be behind the source server
627 so it is not possible to use this message to force users to join a channel.
629 The interpretation depends on the channelTS and the current TS of the channel.
630 If either is 0, set the channel's TS to 0 and accept all modes. Otherwise, if
631 the incoming channelTS is greater (newer), ignore the incoming simple modes
632 and statuses and join and propagate just the users. If the incoming channelTS
633 is lower (older), wipe all modes and change the TS, notifying local users of
634 this but not servers (invites may be cleared). In the latter case, kick on
635 split riding may happen: if the key (+k) differs or the incoming simple modes
636 include +i, kick all local users, sending KICK messages to servers.
638 SJOIN must be used to propagate channel creation and in netbursts. For regular
639 users joining channels, JOIN must be used. Pseudoservers may use SJOIN to join
646 parameters: snomask letter, text
648 Sends the text as a server notice from the source server to opers with the
652 parameters: target server, comment
654 Removes the target server and all servers and users behind it from the network.
656 If the target server is the receiving server or the local link this came from,
657 this is an announcement that the link is being closed.
659 Otherwise, if the target server is locally connected, the server should send
660 a WALLOPS announcing the SQUIT.
664 parameters: stats letter, hunted
666 Remote STATS request. Privileges are checked on the server executing the
672 source: services server
673 parameters: target user, new login name (optional)
675 If the new login name is not present or empty, mark the target user as not
676 logged in, otherwise mark the target user as logged in as the given account.
681 parameters: current TS version, minimum TS version, '0', current time
683 Verifies TS protocol compatibility and clock. If anything is not in order,
686 The current TS version is the highest version supported by the source server
687 and the minimum TS version is the lowest version supported.
689 The current time is sent as a TS in the usual way.
694 encap target: single server
695 source: services server
696 parameters: target, new nick, new username, new visible hostname, new login name
698 Sent after successful SASL authentication.
700 The target is a UID, typically an unregistered one.
702 Any of the "new" parameters can be '*' to leave the corresponding field
703 unchanged. The new login name can be '0' to log the user out.
705 If the UID is registered on the network, a SIGNON with the changes will be
706 broadcast, otherwise the changes will be stored, to be used when registration
711 propagation: broadcast
722 parameters: channelTS, channel, cmode changes, opt. cmode parameters...
724 Propagates a channel mode change.
726 If the channelTS is greater (newer) than the current TS of the channel, drop
729 On input, only the limit on parameters per line restricts how many cmode
730 parameters can be present. Apart from this, arbitrary modes shall be
731 processed. Redundant modes may be dropped. For example, +n-n may be applied and
732 propagated as +n-n, -n or (if the channel was already -n) nothing, but not as
735 The parameter for mode -k (removing a key) shall be ignored.
737 On output, at most ten cmode parameters should be sent; if there are more,
738 multiple TMODE messages should be sent.
742 propagation: broadcast
744 Propagates a channel topic change. The server may verify that the source has
752 Performs a trace to the target, sending 200 numerics from each server passing
753 the message on. The target server sends a description of the target followed
756 TRACE, STATS l and STATS L are the only commands using hunt_server that use the
757 hunted parameter for more than just determining which server the command
758 should be executed on.
761 parameters: target name, hunted
763 Executes a trace command on the target server. No 200 numerics are sent.
764 The target name is a name, not a UID, and should be on the target server.
768 propagation: broadcast
769 parameters: nickname, hopcount, nickTS, umodes, username, visible hostname, IP address, UID, gecos
770 propagation: broadcast
772 Introduces a client. The client is on the source server of this command.
782 Removes a D:line (IP ban checked directly after accepting connection).
784 The mask must be an IP address or CIDR mask.
790 parameters: user mask, host mask
792 Removes a K:line (ban on user@host).
797 parameters: target server mask, user mask, host mask
799 As form 1, deprecated.
812 parameters: target server mask, mask
814 As form 1, deprecated.
822 Removes an X:line (ban on realname).
827 parameters: target server mask, mask
829 As form 1, deprecated.
835 Remote USERS request.
841 Remote VERSION request.
847 propagation: broadcast
849 In efnet TS6, sends a message to operators (with umode +z set). This is a
850 deprecated equivalent to OPERWALL.
852 In charybdis TS6, sends a message to local users with umode +w set (or possibly
853 another indication that WALLOPS messages should be sent), including non-opers.
858 propagation: broadcast
860 Sends a message to local users with umode +w set (or possibly another
861 indication that WALLOPS messages should be sent).
863 In efnet TS6 this may include non-opers, in charybdis TS6 this may only be
868 parameters: hunted, target nick
870 Remote WHOIS request.
876 parameters: duration, mask, reason
878 Sets an X:line (ban on realname).
883 parameters: target server mask, duration, mask, reason
885 As form 1, deprecated.
887 Local only commands (charybdis 3.1):