Skip to content

Commit

Permalink
feat(chore): updated readme for telnet options
Browse files Browse the repository at this point in the history
  • Loading branch information
mystiker committed Nov 4, 2024
1 parent e44ab63 commit 07101d0
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Please note: most of these features have been tested against [UNItopia](https://

Provides a flexible and customizable socket interface that can establish a Telnet connection to any MUD server. Telnet Options are negotiated as necessary.

There is [work in progress](https://github.com/unitopia-de/webmud3/milestone/9).
To see the full list of supported options and their negotiation status see the [Telnet Feature](./backend/src/features/telnet/README.md) page.

- ANSI support

Expand Down
32 changes: 22 additions & 10 deletions backend/src/features/telnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,27 @@ The TelnetClient class handles these negotiation commands, regardless of their o

## Supported Options

| Telnet Option | Client Support | Client Negotiation | Remarks | Discussion |
| ---------------------------------- | ------------------------- | ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------- |
| NAWS (Negotiate About Window Size) | Partial | WILL (+ Sub) | We support this option to subnegotiate the window size. However, we send static values <br>for the window size (80x25) and it does look like Unitopia is ignoring these values. | https://github.com/unitopia-de/webmud3/issues/108 |
| CHARSET | Partial | WILL (+ Sub) | We support this option to subnegotiate the character set with the server. <br>However, we only accept UTF-8. If the server does not subnogitiate <br>for UTF-8, an error will be thrown and the connection will be closed. | https://github.com/unitopia-de/webmud3/issues/111 |
| ECHO | Full | Dynamic | Is used in the telnet login flow to hide user input (password) | |
| SGA (Suppress Go Ahead) | Todo | | | https://github.com/unitopia-de/webmud3/issues/115 |
| LINEMODE | Todo | | | https://github.com/unitopia-de/webmud3/issues/114 |
| STARTTLS | Intentionally Unsupported | WONT | This option allows to upgrade any existing connection to a secure one. However, we <br>don't support this intentionally and recommend you to initialize a secure <br>connection from the beginning. | https://github.com/unitopia-de/webmud3/issues/113 |
| EOR (End of Record) | Todo | | | |
| Telnet Option | Client Support | Client Negotiation | Server Negotiation | Remarks | Discussion |
| ----------------------------------------- | -------------- | ------------------ | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------- |
| ECHO | Full | Dynamic | Dynamic | Is used in the telnet login flow to hide user input (password). This option is negotiated on the fly and can be enabled or disabled whenever needed. | |
| NAWS (Negotiate About Window Size) | Partial | WILL (+ Sub) | DO | We support this option to subnegotiate the window size. However, we send static values for the window size (80x25) and it does look like Unitopia is ignoring these values. | https://github.com/unitopia-de/webmud3/issues/108 |
| CHARSET | Partial | DO / WILL (+ Sub) | WILL (+ Sub) / DO | We support this option to subnegotiate the character set with the server. However, we only accept UTF-8. If the server does not subnogitiate for UTF-8, an error will be thrown and the connection will be closed. | https://github.com/unitopia-de/webmud3/issues/111 |
| SGA (Suppress Go Ahead) | Todo | Not negotiated | Not negotiated | The Telnet Suppress Go Ahead (SGA) option disables the need for "Go Ahead" signals, allowing continuous, uninterrupted data flow in both directions, ideal for interactive applications like remote shells. | https://github.com/unitopia-de/webmud3/issues/115 |
| LINEMODE | Todo | WILL | DO | The Telnet LINEMODE option allows the client to send input line-by-line instead of character-by-character, optimizing bandwidth and reducing network load for text-based applications. | https://github.com/unitopia-de/webmud3/issues/114 |
| EOR (End of Record) | Todo | DONT | WILL | Allows for the server to signal the end of a record which is not needed for our client. | https://github.com/unitopia-de/webmud3/issues/112 |
| MSSP (Mud Server Status Protocol) | Todo | DO | WILL | Allows our client to retrieve basic information about the mud, like the current player count or the server name. | |
| TTYPE | Todo | WILL | DO | Allows the client to send its name to the server. | |
| STARTTLS | Unsupported | WONT | DO | This option allows to upgrade any existing connection to a secure one. However, we don't support this intentionally and recommend you to initialize a secure connection from the beginning. | https://github.com/unitopia-de/webmud3/issues/113 |
| XDISPLOC | Unsupported | WONT | DO | Crazy option to redirect graphical output directly to a X display. Probably not used by Unitopia. | |
| TSPEED (Terminal Speed) | Unsupported | WONT | DO | Allows the client to report its connection speed (in baud) to the server, which can adjust data transmission rates accordingly. Although we do not support this option now, it could be valuable, especially for managing data flow over unstable or mobile connections. | |
| ENVIRON | Unsupported | WONT | DO | Allows the client to send environment variables to the server. However, we don't support this option now. | |
| NEWENV | Unsupported | WONT | DO | Never version of ENVIRON. Still unsupported. | |
| COMPRESS | Unsupported | WONT | DO | LZW based compression. We dont need nor support this option now. | |
| COMPRESS 2 | Unsupported | WONT | DO | Compression based on zlib - which is better, but still not supported. | |
| STATUS | Unsupported | DONT | WILL | Allows for comparisson of the status of the server and the client. Matches negotiated options. We dont support this option now. | |
| AUTH | Unsupported | WONT | DO | We dont support any authentication options for now. | |
| MXP (Mud Extention Protocol) | Unsupported | WONT | DO | We dont support the MXP option for now, but we want to support this option in the future. | |
| GMCP (Generic Mud Communication Protocol) | Unsupported | WONT | DO | We dont support the GMCP option for now, but we want to support this option in the future. | |

## How to handle a new option

Expand All @@ -41,7 +53,7 @@ const newOptionHandler: TelnetOptionHandler = {
negotiate: () => {
// In this handler you can send a negotiation yourself uppon initialization.
// Use this if you want the server to enable/disable the option.
}
},
handleDo: () => {
// Handle the DO command for the new option
// Return a TelnetNegotiationResult object with the appropriate control sequence and subnegotiation result
Expand Down

0 comments on commit 07101d0

Please sign in to comment.