Skip to content
Merged
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
2df6bd6
Initial commit of the 'setname' spec
justjanne Feb 12, 2019
e15e540
Fixed typos
justjanne Feb 12, 2019
893a7c4
Added examples showing realnames with and without spaces
justjanne Feb 12, 2019
2c258f6
Clarify command vs. message
justjanne Feb 12, 2019
328ae07
Fix typos
justjanne Feb 12, 2019
73968df
Reworded text, added examples, added FAIL
justjanne Feb 12, 2019
4395ef8
Small correction of typos
justjanne Feb 13, 2019
002aa1e
Added clarification
justjanne Feb 13, 2019
5b43f08
More clarifications along the Robustness Principle
justjanne Feb 13, 2019
9a081be
More clarifications
justjanne Feb 13, 2019
aaa42fc
Typo
justjanne Feb 13, 2019
d71259a
Updated title to render properly
justjanne Feb 13, 2019
a92c5be
Further clarifications
justjanne Feb 13, 2019
311aff9
Added clarifications for the non-negotiated use case
justjanne Feb 13, 2019
6b06077
Added RPL_ISUPPORT key
justjanne Mar 4, 2019
cc88e2b
Updated title format
justjanne Mar 4, 2019
b24f1a6
Simplified RPL_ISUPPORT section
justjanne Mar 7, 2019
f62d7fe
Remove legacy compatibility entirely
justjanne Mar 7, 2019
6f2584a
Implement suggested changes
justjanne Mar 7, 2019
4ff648b
Update extensions/setname.md
jwheare Mar 12, 2019
98b58c8
Update extensions/setname.md
jwheare Mar 29, 2019
57d390c
Update extensions/setname.md
jwheare Mar 29, 2019
6b1e350
Update extensions/setname.md
jwheare Mar 29, 2019
d14aa62
Update extensions/setname.md
jwheare Mar 29, 2019
e569307
Update extensions/setname.md
jwheare Mar 29, 2019
30aa8aa
Update extensions/setname.md
jwheare Mar 29, 2019
47123fa
Update extensions/setname.md
jwheare Mar 29, 2019
9ba42ba
Update extensions/setname.md
jwheare Mar 29, 2019
69882b1
Update extensions/setname.md
jwheare Mar 29, 2019
96dca2e
Update extensions/setname.md
jwheare Mar 29, 2019
0343fbe
Update extensions/setname.md
jwheare Mar 29, 2019
b4492f7
Update extensions/setname.md
jwheare Mar 29, 2019
03a9cac
Apply more suggestions
justjanne Mar 29, 2019
87380b4
Link standard replies extension
justjanne Mar 29, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
120 changes: 120 additions & 0 deletions extensions/setname.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
---
title: IRCv3 `setname` Extension
layout: spec
work-in-progress: true
copyrights:
-
name: "Janne Mareike Koschinski"
period: "2019"
email: "janne@kuschku.de"
---

## Notes for implementing work-in-progress version

This is a work-in-progress specification.

Software implementing this work-in-progress specification MUST NOT use the
unprefixed `setname` capability name. Instead, implementations SHOULD use
the `draft/setname` capability name to be interoperable with other software
implementing a compatible work-in-progress version.

The final version of the specification will use an unprefixed capability name.

## Motivation

Historically, a user's realname could only be set on the initial connection
handshake. However, multiple IRC servers have provided independent non-standard
commands to update the realname without reconnecting. This specification
describes a standardised behaviour based on these existing implementations.

## Description

The `draft/setname` client capability allows clients to change their realname
(GECOS) on an active connection. It also allows servers to directly inform
clients about such a change.
This avoids a client reconnect when updating this value.

This capability MUST be referred to as `draft/setname` at capability
negotiation time.

Servers advertising the `draft/setname` capability MUST support usage of the
command even while the capability is not negotiated. Clients MUST NOT prevent
users from manually using the command while the capability is not negotiated.

If a client sends a `SETNAME` command without having negotiated the capability,
the server SHOULD handle it silently (with no response), as historic
implementations did.

When enabled, servers MUST provide a `NAMELEN` token in `RPL_ISUPPORT` with the
maximum allowed length for realnames.

The client-to-server `SETNAME` command looks as follows:

SETNAME :realname goes here

This command represents the intent to change the realname. The only, trailing
parameter is the new realname. If the capability is negotiated, the client
MUST assume that no change has happened until the server confirms this
change.

Servers MUST check the realname for validity (taking length limits into
consideration). If they accept the realname change, they MUST send the
server-to-client version of the `SETNAME` message to all clients in common
channels, as well as to the client from which it originated, to confirm the
change has occurred.

The `SETNAME` message MUST NOT be sent to clients which do not have the
`draft/setname` capability negotiated.

The server-to-client `SETNAME` message looks as follows:

:nick!user@host SETNAME :realname goes here

This message represents that the user identified by nick!user@host has changed
their realname to another value. The only, trailing parameter is the new
realname.

In order to take full advantage of the `SETNAME` message, clients must be
modified to support it. The proper way to do so is this:

1) Enable the `draft/setname` capability at capability negotiation time during
the login handshake.

2) On receipt of a server-to-client `SETNAME` message, update the realname
portion of data structures and process channel users as appropriate.

## Errors

The server MUST use the [standard replies extension][1] to notify the client of
failed `SETNAME` commands.

If the server rejects the realname as a result of a validation failure, it MUST
send a `FAIL` message with the `INVALID_REALNAME` code.

FAIL SETNAME INVALID_REALNAME :Realname is not valid

If the server rejects the change for any other reason, it MUST send a `FAIL`
message with the `CANNOT_CHANGE_REALNAME` code and an appropriate description of
the reason:

FAIL SETNAME CANNOT_CHANGE_REALNAME :Slow down your realname changes
FAIL SETNAME CANNOT_CHANGE_REALNAME :Cannot change realname while banned from a channel

## Examples

Complex realname with spaces

C: SETNAME :Bruce Wayne <bruce@wayne.enterprises>
S: :batman@~batman!bat.cave SETNAME :Bruce Wayne <bruce@wayne.enterprises>

Simple realname

C: SETNAME Batman
S: :batman@~batman!bat.cave SETNAME Batman

Example with realname rejected by the server

C: SETNAME :Heute back ich, morgen brau ich, übermorgen hol ich der Königin ihr Kind; ach, wie gut, dass niemand weiß, dass ich Rumpelstilzchen heiß!
S: FAIL SETNAME INVALID_REALNAME :Realname is not valid

[1]: https://github.com/ircv3/ircv3-specifications/pull/357