]> jfr.im git - solanum.git/blame - doc/features/account-notify.txt
modules/m_challenge.c: log correct mechanism
[solanum.git] / doc / features / account-notify.txt
CommitLineData
4f943f99
AC
1account-notify client capability specification
2----------------------------------------------
3
3fc0499e 4Copyright (c) 2010 Ariadne Conill <ariadne@dereferenced.org>.
4f943f99
AC
5
6Unlimited redistribution and modification of this document is allowed
7provided that the above copyright notice and this permission notice
8remains in tact.
9
10The account-notify client capability allows a client to be notified
11when another client's accountname changes. This capability MUST be
12referred to as 'account-notify' at capability negotiation time.
13
14When enabled, clients will get the ACCOUNT message to designate the
15accountname changes for clients on common channels with them.
16
17The ACCOUNT message is one of the following:
18
19 :nick!user@host ACCOUNT accountname
20
21This message represents that the user identified by nick!user@host has
22logged into a new account. The last parameter is the display name of
23that account.
24
25 :nick!user@host ACCOUNT *
26
27This message represents that the user identified by nick!user@host has
28logged out of their account. As the last parameter is an asterisk, this
29means that an asterisk is not a valid account name (which it is not in P10
30or TS6 or ESVID).
31
32In order to take full advantage of the ACCOUNT message, WHOX must be
33supported by the ircd. In this case, the appropriate strategy to ensuring
34you always have the accountname to display is to do the following:
35
361) Enable the account-notify capability at capability negotiation time during
37 the login handshake.
38
392) When joining a channel, query the channel using WHO and ensure that you
40 include the 'a' format token in your WHOX token request. When you get
41 a reply, do appropriate caching.
42
f56b4e3c
AC
433) If the extended-join capability is available, enable it at client capability
44 negotiation time during the login handshake, and then set the accountname
45 based on what is sent in the extended JOIN command.
46
47 Otherwise, if extended-join is unavailable:
48 When new users join a channel that your client does not know the accountname
4f943f99
AC
49 for yet, do a WHO query against that client, again including the 'a' format
50 token in your WHOX token request field. When you get a reply, do appropriate
51 caching.
52
a8df2896
AC
534) In the event of a netsplit, the client should query the channel again using
54 WHO with the 'a' format token in the WHOX request field.
55
565) When the client receives an ACCOUNT message, update the accountname for the
4f943f99 57 client in question in your accountname cache.