|
Protocol | The Client<->Server protocol was last updated on December 31, 2001 - release v1.00 (stable) of the server.
Login |
Client: | Connects to server |
Server: | 001 HNDSHK <key=val args> |
Client: | 001 HNDSHK <key=val args> |
Server: | 002 SKEY <session key> |
Server: | 003 LOGIN |
Client: | 003 LOGIN "<encrypted user>" "<encrypted pass>" |
Server: | 004 LOGIN OK |
or | 004 LOGIN <error description> Login error returns 003 LOGIN or 000 ENDCOM after 3 failures |
Server: | 008 REG <code> <name> <description of command> |
Server: | 009 EAUTH |
Command Release |
Server: | 014 RLS <code> <name> |
Command Register |
Server: | 008 REG <code> <name> <description of command> |
>Pings |
Server: | 010 PING <id string> |
Client: | 011 GNIP <id string> |
Ping Timeout |
Server: | 012 TIMEOUT |
Server: | 000 ENDCOM |
Broadcast |
Server: | 013 BROADCAST <message> |
Disconnecting |
| 000 ENDCOM |
Error Codes |
Protocol error during auth | 005 BADPROTO |
Fatal Error | 006 FERR <reason> |
Non Fatal Error | 007 NFERR <reason> |
Commands |
Client: | ### <name> <arguments> |
Server: | ### <name> <reply> |
Additional notes on protocol
- User/Password encryption: Client prompts for username, password, and key. The key is mangled and used as a salt to
MD5-hash-encrypt the password. Then, the user and password are encrypted using the random session id key sent by the server
to prevent anyone sniffing the connection from using the encrypted password to log in.
- Disconnecting: the party that iniates the disconnect sends 000 ENDCOM. Note: some clients may send QUIT, which will in
turn force the server to send 000 ENDCOM to the client.
- Endcom: may be preceeded by other informative messages such as TIMEOUT or BROADCAST, but will not be followed by any
messages.
- Command codes: Start at 020 in protocol rev1.
- Command replies in streams: where reply with be STREAM <id> followed by infinite lines of <id>;<data> followed by the command again appended with ENDSTREAM <id>
|
|