client-class-init #9
17
tasks.md
17
tasks.md
@@ -7,6 +7,23 @@ You can try connect IRC server with
|
||||
```bash
|
||||
nc localhost <port>
|
||||
```
|
||||
---
|
||||
|
||||
### User
|
||||
|
||||
Represents a connected IRC client.
|
||||
|
||||
| Attribute | Type | Description |
|
||||
|-----------------|----------|------------------------------------------------|
|
||||
| `fd` | `int` | TCP s-ocket file descriptor |
|
||||
| `nick` | `string` | IRC nickname |
|
||||
| `username` | `string` | Username |
|
||||
| `realname` | `string` | Real name |
|
||||
| `buffer` | `string` | Incoming data buffer, accumulates until `\r\n` |
|
||||
| `authenticated` | `bool` | `true` after correct `PASS` |
|
||||
| `registered` | `bool` | `true` after `NICK` + `USER` received |
|
||||
|
||||
**Registration flow:** `PASS` → authenticated → `NICK` + `USER` → registered → client ready
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user