serverless-ircd 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/ci.yml +2 -2
- package/.github/workflows/deploy-aws.yml +1 -3
- package/.github/workflows/deploy-cf-tcp.yml +87 -0
- package/.github/workflows/deploy-cf.yml +1 -1
- package/.node-version +1 -0
- package/.nvmrc +1 -0
- package/CHANGELOG.md +258 -18
- package/README.md +72 -30
- package/apps/aws-stack/README.md +2 -2
- package/apps/aws-stack/bin/aws.ts +7 -0
- package/apps/aws-stack/package.json +4 -4
- package/apps/aws-stack/src/aws-stack.ts +118 -6
- package/apps/aws-stack/tests/stack.test.ts +98 -3
- package/apps/cf-tcp-container/Dockerfile +69 -0
- package/apps/cf-tcp-container/package.json +34 -0
- package/apps/cf-tcp-container/src/config-loader.ts +145 -0
- package/apps/cf-tcp-container/src/container-do.ts +38 -0
- package/apps/cf-tcp-container/src/container-server.ts +363 -0
- package/apps/cf-tcp-container/src/main.ts +77 -0
- package/apps/cf-tcp-container/src/persistence.ts +144 -0
- package/apps/cf-tcp-container/src/worker.ts +41 -0
- package/apps/cf-tcp-container/terraform/provider.tf +24 -0
- package/apps/cf-tcp-container/terraform/spectrum.tf +81 -0
- package/apps/cf-tcp-container/tests/config-loader.test.ts +217 -0
- package/apps/cf-tcp-container/tests/container-server.test.ts +465 -0
- package/apps/cf-tcp-container/tests/persistence.test.ts +227 -0
- package/apps/cf-tcp-container/tests/tls-e2e.test.ts +275 -0
- package/apps/cf-tcp-container/tsconfig.build.json +17 -0
- package/apps/cf-tcp-container/tsconfig.test.json +15 -0
- package/apps/cf-tcp-container/vitest.config.ts +26 -0
- package/apps/cf-tcp-container/wrangler.toml +63 -0
- package/apps/cf-worker/package.json +1 -1
- package/apps/cf-worker/scripts/smoke.mjs +0 -0
- package/apps/cf-worker/src/worker.ts +8 -2
- package/apps/cf-worker/tests/smoke.test.ts +1 -0
- package/apps/cf-worker/wrangler.test.toml +11 -1
- package/apps/cf-worker/wrangler.toml +69 -19
- package/apps/local-cli/package.json +1 -1
- package/apps/local-cli/src/config-loader.ts +11 -0
- package/apps/local-cli/src/main.ts +1 -1
- package/apps/local-cli/src/server.ts +46 -3
- package/apps/local-cli/tests/e2e.test.ts +52 -0
- package/package.json +19 -16
- package/packages/aws-adapter/package.json +3 -3
- package/packages/aws-adapter/src/account-store.ts +121 -0
- package/packages/aws-adapter/src/admission.ts +74 -0
- package/packages/aws-adapter/src/aws-runtime.ts +124 -34
- package/packages/aws-adapter/src/cdk-table-defs.ts +5 -1
- package/packages/aws-adapter/src/config-loader.ts +62 -0
- package/packages/aws-adapter/src/dynamo-account-store.ts +95 -0
- package/packages/aws-adapter/src/handlers/connect.ts +64 -8
- package/packages/aws-adapter/src/handlers/default.ts +43 -2
- package/packages/aws-adapter/src/handlers/disconnect.ts +27 -8
- package/packages/aws-adapter/src/handlers/index.ts +120 -9
- package/packages/aws-adapter/src/handlers/nlb-stream.ts +481 -0
- package/packages/aws-adapter/src/handlers/ping-checker.ts +1 -1
- package/packages/aws-adapter/src/index.ts +13 -0
- package/packages/aws-adapter/tests/account-store-dynamo.test.ts +182 -0
- package/packages/aws-adapter/tests/account-store.test.ts +279 -0
- package/packages/aws-adapter/tests/admission.test.ts +70 -0
- package/packages/aws-adapter/tests/aws-harness.ts +13 -1
- package/packages/aws-adapter/tests/config-loader.test.ts +75 -0
- package/packages/aws-adapter/tests/connect.test.ts +78 -0
- package/packages/aws-adapter/tests/disconnect-fanout.test.ts +343 -0
- package/packages/aws-adapter/tests/gone-exception.test.ts +31 -26
- package/packages/aws-adapter/tests/handlers.test.ts +194 -47
- package/packages/aws-adapter/tests/nlb-stream.test.ts +478 -0
- package/packages/aws-adapter/tests/ping-checker.test.ts +34 -29
- package/packages/aws-adapter/tests/sweeper.test.ts +25 -18
- package/packages/aws-adapter/tests/transactions.test.ts +25 -20
- package/packages/cf-adapter/package.json +1 -1
- package/packages/cf-adapter/src/cf-runtime.ts +40 -22
- package/packages/cf-adapter/src/channel-do.ts +40 -1
- package/packages/cf-adapter/src/channel-registry-do.ts +58 -0
- package/packages/cf-adapter/src/config-loader.ts +62 -0
- package/packages/cf-adapter/src/connection-do.ts +181 -31
- package/packages/cf-adapter/src/d1-account-store.ts +198 -0
- package/packages/cf-adapter/src/env.ts +58 -8
- package/packages/cf-adapter/src/index.ts +11 -9
- package/packages/cf-adapter/tests/cf-harness.ts +11 -1
- package/packages/cf-adapter/tests/cf-integration.test.ts +2 -1
- package/packages/cf-adapter/tests/cf-runtime.test.ts +91 -0
- package/packages/cf-adapter/tests/config-loader.test.ts +22 -0
- package/packages/cf-adapter/tests/connection-do-channel-registration.test.ts +37 -0
- package/packages/cf-adapter/tests/connection-do-no-batching-reservation.test.ts +52 -0
- package/packages/cf-adapter/tests/connection-do-sasl-d1.test.ts +166 -0
- package/packages/cf-adapter/tests/connection-do.test.ts +40 -0
- package/packages/cf-adapter/tests/d1-account-store.test.ts +226 -0
- package/packages/cf-adapter/tests/raw-modules.d.ts +11 -0
- package/packages/cf-adapter/tests/worker/main.ts +9 -1
- package/packages/cf-adapter/tests/worker/stubs/channel-stub.ts +7 -1
- package/packages/cf-adapter/wrangler.test.toml +18 -1
- package/packages/in-memory-runtime/package.json +1 -1
- package/packages/in-memory-runtime/src/in-memory-runtime.ts +14 -28
- package/packages/in-memory-runtime/tests/in-memory-runtime.test.ts +19 -0
- package/packages/irc-core/package.json +8 -2
- package/packages/irc-core/scripts/generate-build-info.mjs +31 -0
- package/packages/irc-core/src/caps/capabilities.ts +23 -2
- package/packages/irc-core/src/case-fold.ts +64 -0
- package/packages/irc-core/src/cloak.ts +1 -1
- package/packages/irc-core/src/commands/cap.ts +8 -1
- package/packages/irc-core/src/commands/index.ts +11 -0
- package/packages/irc-core/src/commands/invite.ts +6 -9
- package/packages/irc-core/src/commands/ison.ts +61 -0
- package/packages/irc-core/src/commands/isupport.ts +1 -1
- package/packages/irc-core/src/commands/join.ts +4 -3
- package/packages/irc-core/src/commands/kick.ts +4 -11
- package/packages/irc-core/src/commands/list.ts +5 -4
- package/packages/irc-core/src/commands/mode.ts +5 -9
- package/packages/irc-core/src/commands/motd-lines.ts +127 -0
- package/packages/irc-core/src/commands/motd.ts +6 -110
- package/packages/irc-core/src/commands/oper.ts +151 -0
- package/packages/irc-core/src/commands/quit.ts +12 -0
- package/packages/irc-core/src/commands/registration.ts +26 -19
- package/packages/irc-core/src/commands/sasl.ts +72 -9
- package/packages/irc-core/src/commands/server-info.ts +129 -0
- package/packages/irc-core/src/commands/tagmsg.ts +205 -0
- package/packages/irc-core/src/commands/userhost.ts +84 -0
- package/packages/irc-core/src/commands/whowas.ts +113 -0
- package/packages/irc-core/src/config.ts +84 -3
- package/packages/irc-core/src/credential-hashing.ts +124 -0
- package/packages/irc-core/src/effects.ts +6 -29
- package/packages/irc-core/src/index.ts +3 -0
- package/packages/irc-core/src/ports.ts +240 -7
- package/packages/irc-core/src/protocol/numerics.ts +14 -8
- package/packages/irc-core/src/types.ts +60 -1
- package/packages/irc-core/tests/account-store.test.ts +131 -0
- package/packages/irc-core/tests/caps/capabilities.test.ts +4 -3
- package/packages/irc-core/tests/case-fold.test.ts +80 -0
- package/packages/irc-core/tests/commands/cap.test.ts +33 -1
- package/packages/irc-core/tests/commands/ison.test.ts +166 -0
- package/packages/irc-core/tests/commands/kick.test.ts +15 -0
- package/packages/irc-core/tests/commands/oper.test.ts +257 -0
- package/packages/irc-core/tests/commands/quit.test.ts +69 -2
- package/packages/irc-core/tests/commands/registration.test.ts +256 -19
- package/packages/irc-core/tests/commands/sasl.test.ts +118 -10
- package/packages/irc-core/tests/commands/server-info.test.ts +274 -0
- package/packages/irc-core/tests/commands/tagmsg.test.ts +662 -0
- package/packages/irc-core/tests/commands/userhost.test.ts +264 -0
- package/packages/irc-core/tests/commands/who.test.ts +22 -4
- package/packages/irc-core/tests/commands/whois.test.ts +8 -1
- package/packages/irc-core/tests/commands/whowas.test.ts +312 -0
- package/packages/irc-core/tests/config.test.ts +170 -1
- package/packages/irc-core/tests/credential-hashing.test.ts +170 -0
- package/packages/irc-core/tests/effects.test.ts +0 -27
- package/packages/irc-core/tests/nick-history-store.test.ts +162 -0
- package/packages/irc-core/tests/numerics.test.ts +12 -0
- package/packages/irc-core/tests/types.test.ts +35 -1
- package/packages/irc-core/tsconfig.build.json +1 -1
- package/packages/irc-core/tsconfig.test.json +1 -1
- package/packages/irc-server/package.json +1 -1
- package/packages/irc-server/src/actor.ts +182 -14
- package/packages/irc-server/src/dispatch.ts +0 -3
- package/packages/irc-server/src/index.ts +10 -2
- package/packages/irc-server/src/routing.ts +21 -0
- package/packages/irc-server/src/transport.ts +101 -0
- package/packages/irc-server/tests/actor.test.ts +617 -1
- package/packages/irc-server/tests/dispatch.test.ts +0 -17
- package/packages/irc-server/tests/routing.test.ts +7 -0
- package/packages/irc-server/tests/transport.test.ts +230 -0
- package/packages/irc-test-support/package.json +1 -1
- package/packages/irc-test-support/src/harness.ts +44 -9
- package/packages/irc-test-support/src/in-memory-harness.ts +78 -13
- package/packages/irc-test-support/src/index.ts +3 -0
- package/packages/irc-test-support/src/scenarios.ts +132 -2
- package/packages/irc-test-support/tests/in-memory-harness.test.ts +2 -1
- package/packages/irc-test-support/tests/in-memory-scenarios.test.ts +23 -9
- package/pnpm-workspace.yaml +9 -0
- package/tools/ci-hardening/package.json +1 -1
- package/tools/package.json +4 -0
- package/tools/seed-aws-accounts.ts +79 -0
- package/tools/seed-cf-accounts.ts +104 -0
- package/tools/tcp-ws-forwarder/package.json +1 -1
- package/AGENTS.md +0 -5
- package/MOTD.txt +0 -3
- package/PLAN-FIXES.md +0 -358
- package/PLAN.md +0 -420
- package/dashboards/cloudwatch-irc.json +0 -139
- package/docs/AWS-Adapter-Architecture.md +0 -494
- package/docs/AWS-Deployment.md +0 -1107
- package/docs/Cloudflare-Deployment-Guide.md +0 -660
- package/docs/Home.md +0 -1
- package/docs/Observability.md +0 -87
- package/docs/PlanIRCv3Websocket.md +0 -489
- package/docs/PlanWebClient.md +0 -451
- package/docs/Release-Process.md +0 -440
- package/progress.md +0 -107
- package/tickets.md +0 -2485
- package/webircgateway/LICENSE +0 -201
- package/webircgateway/Makefile +0 -44
- package/webircgateway/README.md +0 -134
- package/webircgateway/config.conf.example +0 -135
- package/webircgateway/go.mod +0 -16
- package/webircgateway/go.sum +0 -89
- package/webircgateway/main.go +0 -118
- package/webircgateway/pkg/dnsbl/dnsbl.go +0 -121
- package/webircgateway/pkg/identd/identd.go +0 -86
- package/webircgateway/pkg/identd/rpcclient.go +0 -59
- package/webircgateway/pkg/irc/isupport.go +0 -56
- package/webircgateway/pkg/irc/message.go +0 -217
- package/webircgateway/pkg/irc/state.go +0 -79
- package/webircgateway/pkg/proxy/proxy.go +0 -129
- package/webircgateway/pkg/proxy/server.go +0 -237
- package/webircgateway/pkg/recaptcha/recaptcha.go +0 -59
- package/webircgateway/pkg/webircgateway/client.go +0 -741
- package/webircgateway/pkg/webircgateway/client_command_handlers.go +0 -495
- package/webircgateway/pkg/webircgateway/config.go +0 -385
- package/webircgateway/pkg/webircgateway/gateway.go +0 -278
- package/webircgateway/pkg/webircgateway/gateway_utils.go +0 -133
- package/webircgateway/pkg/webircgateway/hooks.go +0 -152
- package/webircgateway/pkg/webircgateway/letsencrypt.go +0 -41
- package/webircgateway/pkg/webircgateway/messagetags.go +0 -103
- package/webircgateway/pkg/webircgateway/transport_kiwiirc.go +0 -206
- package/webircgateway/pkg/webircgateway/transport_sockjs.go +0 -107
- package/webircgateway/pkg/webircgateway/transport_tcp.go +0 -113
- package/webircgateway/pkg/webircgateway/transport_websocket.go +0 -126
- package/webircgateway/pkg/webircgateway/utils.go +0 -147
- package/webircgateway/plugins/example/plugin.go +0 -11
- package/webircgateway/plugins/stats/plugin.go +0 -52
- package/webircgateway/staticcheck.conf +0 -1
- package/webircgateway/webircgateway.svg +0 -3
package/PLAN-FIXES.md
DELETED
|
@@ -1,358 +0,0 @@
|
|
|
1
|
-
# PLAN-FIXES.md
|
|
2
|
-
|
|
3
|
-
Audit of stubbed, incomplete, and not-fully-wired-up functionality in ServerlessIRCd.
|
|
4
|
-
Each item lists location, current behavior, expected behavior, and impact.
|
|
5
|
-
|
|
6
|
-
Findings are grouped by severity: **Critical** > **Partial** > **Minor / Dead scaffolding**.
|
|
7
|
-
|
|
8
|
-
---
|
|
9
|
-
|
|
10
|
-
## Critical
|
|
11
|
-
|
|
12
|
-
### 1. `MessageStore` (IRCv3 `draft/chathistory`) wired into no adapter
|
|
13
|
-
|
|
14
|
-
`ConnectionActor` accepts `messages?: MessageStore` (`packages/irc-server/src/actor.ts:105`),
|
|
15
|
-
and `irc-core` ships a complete `InMemoryMessageStore`, the `CHATHISTORY` reducer, and
|
|
16
|
-
JOIN auto-playback. None of the three adapters pass it:
|
|
17
|
-
|
|
18
|
-
- `packages/cf-adapter/src/connection-do.ts:303-312`
|
|
19
|
-
- `packages/aws-adapter/src/handlers/default.ts:103-111`
|
|
20
|
-
- `apps/local-cli/src/server.ts:480-501`
|
|
21
|
-
|
|
22
|
-
**Impact:** chathistory recording and playback are dead code outside unit tests.
|
|
23
|
-
`ctx.messages` is always `undefined` in any deployment.
|
|
24
|
-
|
|
25
|
-
**Fix:** construct and pass a `MessageStore` instance at each actor-construction site.
|
|
26
|
-
|
|
27
|
-
---
|
|
28
|
-
|
|
29
|
-
### 2. `AccountStore` (SASL) not accepted by the actor
|
|
30
|
-
|
|
31
|
-
`ConnectionActorOptions` (`packages/irc-server/src/actor.ts:89-119`) has **no `accounts`**
|
|
32
|
-
field, and `route()` -> `buildCtx()` (`actor.ts:238-245`) never supplies one, even though
|
|
33
|
-
`buildCtx` supports it (`packages/irc-core/src/types.ts:143`).
|
|
34
|
-
|
|
35
|
-
**Impact:** SASL PLAIN authentication can never succeed in any adapter. A client completing
|
|
36
|
-
`AUTHENTICATE PLAIN` always receives `904 ERR_SASLFAIL` because `ctx.accounts` is `undefined`.
|
|
37
|
-
Only unit tests (which call `buildCtx` directly) exercise the happy path.
|
|
38
|
-
|
|
39
|
-
**Fix:** add `accounts?: AccountStore` to `ConnectionActorOptions`, forward it through
|
|
40
|
-
`route()` into `buildCtx`, and supply an implementation in each adapter.
|
|
41
|
-
|
|
42
|
-
---
|
|
43
|
-
|
|
44
|
-
### 3. Cloudflare runtime stubs (`packages/cf-adapter/src/cf-runtime.ts`)
|
|
45
|
-
|
|
46
|
-
The AWS runtime fully implements all 16 `IrcRuntime` methods against DynamoDB. The CF
|
|
47
|
-
runtime has explicit stubs that break three commands for anything beyond the local connection.
|
|
48
|
-
|
|
49
|
-
| Method | Line | Stub | Impact |
|
|
50
|
-
|---|---|---|---|
|
|
51
|
-
| `getConnection()` | cf-runtime.ts:234-244 | returns `null` for remote conns | Remote WHOIS broken (only `401` + `318`) |
|
|
52
|
-
| `getChannelConnections()` | cf-runtime.ts:246-251 | returns empty `Map` | WHO broken on CF |
|
|
53
|
-
| `listChannels()` | cf-runtime.ts:253-258 | returns `[]` | LIST returns no channels on CF |
|
|
54
|
-
| `disconnect()` | cf-runtime.ts:115-126 | cross-connection disconnect is a no-op | KICK of a remote user does not close their socket |
|
|
55
|
-
|
|
56
|
-
**Fix:** add the missing ConnectionDO RPCs (`getConnState`, channel-membership enumeration,
|
|
57
|
-
channel registry) and a cross-connection `disconnect` RPC; wire `cf-runtime.ts` to call them.
|
|
58
|
-
|
|
59
|
-
---
|
|
60
|
-
|
|
61
|
-
### 4. AWS disconnect never broadcasts QUIT to peers
|
|
62
|
-
|
|
63
|
-
`packages/aws-adapter/src/aws-runtime.ts:645` -- `cleanupConnection` explicitly discards
|
|
64
|
-
`managementApi` (`void managementApi;`) and never broadcasts QUIT. Confirmed at the call
|
|
65
|
-
site: `packages/aws-adapter/src/handlers/disconnect.ts:28` hardcodes `null`.
|
|
66
|
-
|
|
67
|
-
**Impact:** when a connection tears down, peers in shared channels never receive the QUIT
|
|
68
|
-
fanout. Their local rosters go stale until a subsequent broadcast prunes the ghost member.
|
|
69
|
-
|
|
70
|
-
**Fix:** thread the `managementApi` through `handleDisconnect` and implement QUIT fanout
|
|
71
|
-
to all connections sharing channels with the disconnecting client.
|
|
72
|
-
|
|
73
|
-
---
|
|
74
|
-
|
|
75
|
-
### 5. AWS `Accounts` DynamoDB table deployed with no runtime consumer
|
|
76
|
-
|
|
77
|
-
Provisioned in CDK (`packages/aws-adapter/src/cdk-table-defs.ts:61-65`) and required by
|
|
78
|
-
`tablesConfigFromNames`, but no runtime code reads or writes it. No `AccountStore`
|
|
79
|
-
implementation is backed by it.
|
|
80
|
-
|
|
81
|
-
**Impact:** paid-for infrastructure with no consumer; also blocks SASL account persistence
|
|
82
|
-
(see #2).
|
|
83
|
-
|
|
84
|
-
**Fix:** either implement a DynamoDB-backed `AccountStore` against this table, or remove
|
|
85
|
-
the table from the CDK stack and config loader until it is needed.
|
|
86
|
-
|
|
87
|
-
---
|
|
88
|
-
|
|
89
|
-
## Absent IRC commands (scaffolded or advertised, no handler)
|
|
90
|
-
|
|
91
|
-
Implemented reducers (JOIN/PART/TOPIC/NAMES/KICK/INVITE/MOTD/PRIVMSG/NOTICE/MODE/LIST/
|
|
92
|
-
WHO/WHOIS/CAP/AUTHENTICATE/AWAY/CHATHISTORY) are genuinely complete. The gaps below either
|
|
93
|
-
fall through to `421 ERR_UNKNOWNCOMMAND` or have partial scaffolding.
|
|
94
|
-
|
|
95
|
-
### 6. `OPER` -- absent, but heavily scaffolded
|
|
96
|
-
|
|
97
|
-
No `OPER` case in `actor.ts` `route()` switch, no reducer, no entry in
|
|
98
|
-
`packages/irc-core/src/commands/index.ts`. Referenced everywhere:
|
|
99
|
-
|
|
100
|
-
- `packages/irc-core/src/commands/mode.ts:15` -- "The oper flag (`+o`) is granted via the
|
|
101
|
-
future OPER command, not via MODE"
|
|
102
|
-
- `packages/irc-core/src/commands/mode.ts:547,612-624` -- user `MODE +o` hard-rejected
|
|
103
|
-
with `481 ERR_NOPRIVILEGES`, gated on an OPER command that does not exist.
|
|
104
|
-
- `operCreds` is defined, validated, and loaded by **all three adapters**
|
|
105
|
-
(`packages/cf-adapter/src/config-loader.ts:65`,
|
|
106
|
-
`packages/aws-adapter/src/config-loader.ts:59`,
|
|
107
|
-
`apps/local-cli/src/config-loader.ts:27`) but no runtime code ever reads
|
|
108
|
-
`serverConfig.operCreds`.
|
|
109
|
-
- Reserved-but-unused numerics: `RPL_YOUREOPER: 381`, `RPL_REHASHING: 382`,
|
|
110
|
-
`ERR_NOOPERHOST: 491` (`packages/irc-core/src/numerics.ts:75-76,138`).
|
|
111
|
-
|
|
112
|
-
**Impact:** `state.userModes.oper` can never become `true` via any command flow, so the
|
|
113
|
-
`RPL_WHOISOPERATOR` (`313`) branch in `packages/irc-core/src/commands/whois.ts:132-136`
|
|
114
|
-
and the WHO `*` oper flag (`packages/irc-core/src/commands/who.ts:69`) are unreachable.
|
|
115
|
-
|
|
116
|
-
**Fix:** implement the `OPER` reducer (verify credentials against `operCreds`, set the
|
|
117
|
-
`oper` user mode, emit `381`), add it to the route switch, and wire the dependent
|
|
118
|
-
WHOIS/WHO branches.
|
|
119
|
-
|
|
120
|
-
---
|
|
121
|
-
|
|
122
|
-
### 7. `TAGMSG` -- replay path exists, no recorder
|
|
123
|
-
|
|
124
|
-
`StoredCommand = 'PRIVMSG' | 'NOTICE' | 'TAGMSG'` (`packages/irc-core/src/ports.ts:200`)
|
|
125
|
-
and `packages/irc-core/src/commands/chathistory.ts:237-238` contain real replay code for
|
|
126
|
-
a stored TAGMSG. But nothing ever records one: the only call to `ctx.messages.record(...)`
|
|
127
|
-
is `packages/irc-core/src/commands/privmsg.ts:188`, which records `PRIVMSG`/`NOTICE` only.
|
|
128
|
-
|
|
129
|
-
**Impact:** the `message-tags` cap is advertised (`packages/irc-core/src/caps/capabilities.ts:33`)
|
|
130
|
-
with no command that consumes it. The TAGMSG replay branch is dead code.
|
|
131
|
-
|
|
132
|
-
**Fix:** add a `TAGMSG` reducer + route case that records the message-tag set via
|
|
133
|
-
`ctx.messages.record({ command: 'TAGMSG', ... })`.
|
|
134
|
-
|
|
135
|
-
---
|
|
136
|
-
|
|
137
|
-
### 8. `WHOWAS` -- numerics present, no handler
|
|
138
|
-
|
|
139
|
-
`RPL_ENDOFWHOWAS: 369`, `ERR_WASNOSUCHNICK: 406` defined
|
|
140
|
-
(`packages/irc-core/src/numerics.ts:65,97`); no reducer, no route case.
|
|
141
|
-
|
|
142
|
-
**Fix:** implement a `WHOWAS` reducer against the nick history (or decide to drop the
|
|
143
|
-
numerics if the feature is not planned).
|
|
144
|
-
|
|
145
|
-
---
|
|
146
|
-
|
|
147
|
-
### 9. Other unimplemented standard verbs
|
|
148
|
-
|
|
149
|
-
Currently return `421 ERR_UNKNOWNCOMMAND` via `actor.ts:318-319` (graceful, not broken):
|
|
150
|
-
|
|
151
|
-
`VERSION`, `ADMIN`, `INFO`, `TIME`, `STATS`, `LUSERS`, `LINKS`, `USERHOST`, `ISON`,
|
|
152
|
-
`WALLOPS`, `SETNAME`, `KILL`, `REHASH`, `CONNECT`, `TRACE`, `SQUIT`, `SERVICE`,
|
|
153
|
-
`SUMMON`, `USERS`.
|
|
154
|
-
|
|
155
|
-
Several have dedicated numerics defined but unused (`RPL_USERHOST: 302`, `RPL_ISON: 303`,
|
|
156
|
-
`RPL_INFO: 371`, `RPL_LINKS: 364`, `RPL_TIME: 391`, `RPL_ADMINME: 256`).
|
|
157
|
-
|
|
158
|
-
**Fix:** implement the subset that matters for client compatibility, or remove unused
|
|
159
|
-
numerics to avoid advertising false capability.
|
|
160
|
-
|
|
161
|
-
---
|
|
162
|
-
|
|
163
|
-
## Partial
|
|
164
|
-
|
|
165
|
-
### 10. SASL `EXTERNAL` -- hardcoded to fail
|
|
166
|
-
|
|
167
|
-
`packages/irc-core/src/commands/sasl.ts:95-97` recognizes `AUTHENTICATE EXTERNAL` but
|
|
168
|
-
unconditionally returns `904 ERR_SASLFAIL`. The `sasl` cap advertises `PLAIN,EXTERNAL`
|
|
169
|
-
(`packages/irc-core/src/caps/capabilities.ts:36`,
|
|
170
|
-
`packages/irc-core/src/commands/sasl.ts:42` `SUPPORTED_MECHS = 'PLAIN,EXTERNAL'`).
|
|
171
|
-
|
|
172
|
-
**Impact:** EXTERNAL is advertised but non-functional. (PLAIN is fully implemented but
|
|
173
|
-
see #2.)
|
|
174
|
-
|
|
175
|
-
**Fix:** either implement EXTERNAL (mTLS client-cert extraction), or stop advertising it
|
|
176
|
-
in `SUPPORTED_MECHS` until it lands.
|
|
177
|
-
|
|
178
|
-
---
|
|
179
|
-
|
|
180
|
-
### 11. Welcome MOTD is a hardcoded placeholder
|
|
181
|
-
|
|
182
|
-
`packages/irc-core/src/commands/registration.ts:84-87` always emits:
|
|
183
|
-
|
|
184
|
-
```
|
|
185
|
-
375 <nick> :- <server> Message of the day -
|
|
186
|
-
372 <nick> :- MOTD placeholder
|
|
187
|
-
376 <nick> :End of MOTD command
|
|
188
|
-
```
|
|
189
|
-
|
|
190
|
-
regardless of the configured `MotdProvider`. The comment claims "filled via MotdProvider
|
|
191
|
-
elsewhere" but it is not. The standalone `MOTD` command correctly uses `ctx.motd.lines()`
|
|
192
|
-
(`packages/irc-core/src/commands/motd.ts:59`).
|
|
193
|
-
|
|
194
|
-
**Impact:** every client sees `372 <nick> :- MOTD placeholder` on connect regardless of
|
|
195
|
-
configuration.
|
|
196
|
-
|
|
197
|
-
**Fix:** call `ctx.motd.lines()` in `buildWelcomeLines` and emit the real lines.
|
|
198
|
-
|
|
199
|
-
---
|
|
200
|
-
|
|
201
|
-
### 12. Placeholder constants in registration
|
|
202
|
-
|
|
203
|
-
`packages/irc-core/src/commands/registration.ts:29,32`:
|
|
204
|
-
|
|
205
|
-
- `SERVER_VERSION = '0.1.0'` -- "Placeholder until a config-driven version lands"
|
|
206
|
-
- `CREATED_TEXT = 'Phase 1'` -- "Placeholder"
|
|
207
|
-
|
|
208
|
-
Surfaced verbatim in `002`/`003`/`004` replies.
|
|
209
|
-
|
|
210
|
-
**Fix:** drive these from `ServerConfig` (read `package.json` version at build time, or
|
|
211
|
-
add `serverVersion`/`createdAt` config fields).
|
|
212
|
-
|
|
213
|
-
---
|
|
214
|
-
|
|
215
|
-
### 13. `DEFAULT_SERVER_CONFIG` ships a placeholder server name
|
|
216
|
-
|
|
217
|
-
`packages/irc-core/src/config.ts:244-247` -- `serverName: 'irc.example.com'` as the
|
|
218
|
-
baseline. Documented as a boot/test baseline that adapters overlay, and
|
|
219
|
-
`docs/AWS-Deployment.md:414` warns "(placeholder -- override!)".
|
|
220
|
-
|
|
221
|
-
**Impact:** if a deployment forgets to override, the server advertises `irc.example.com`.
|
|
222
|
-
|
|
223
|
-
**Fix:** require `serverName` at adapter config-load time (fail fast if unset) rather
|
|
224
|
-
than relying on a placeholder default.
|
|
225
|
-
|
|
226
|
-
---
|
|
227
|
-
|
|
228
|
-
### 14. AWS `handleConnect` ignores `serverConfig`
|
|
229
|
-
|
|
230
|
-
`packages/aws-adapter/src/handlers/connect.ts:36` -- `void params.serverConfig;`
|
|
231
|
-
("reserved for max-clients gating").
|
|
232
|
-
|
|
233
|
-
**Impact:** connection-count admission gating at connect time is unimplemented.
|
|
234
|
-
|
|
235
|
-
**Fix:** implement max-clients admission using the supplied config.
|
|
236
|
-
|
|
237
|
-
---
|
|
238
|
-
|
|
239
|
-
### 15. AWS Lambda transport `disconnect` is a no-op
|
|
240
|
-
|
|
241
|
-
`packages/aws-adapter/src/handlers/default.ts:86-89` -- `AwsRuntimeHandlers.disconnect`
|
|
242
|
-
does nothing. Documented as a platform limit (a Lambda cannot close its own APIGW socket;
|
|
243
|
-
the canonical close is the `$disconnect` route).
|
|
244
|
-
|
|
245
|
-
**Impact:** effect-driven `Disconnect` on the bound connection never reaches the transport
|
|
246
|
-
from within a `$default` invocation.
|
|
247
|
-
|
|
248
|
-
**Fix:** documented platform limitation; no code fix possible without an APIGW feature.
|
|
249
|
-
Consider noting this in operator docs.
|
|
250
|
-
|
|
251
|
-
---
|
|
252
|
-
|
|
253
|
-
### 16. CF `webSocketMessage` newly-joined-channel registration is a no-op
|
|
254
|
-
|
|
255
|
-
`packages/cf-adapter/src/connection-do.ts:150-156` -- the loop body is `void chan;`.
|
|
256
|
-
|
|
257
|
-
**Impact:** no real channel-registration work happens on join beyond the
|
|
258
|
-
`ApplyChannelDelta` already emitted by the reducer.
|
|
259
|
-
|
|
260
|
-
**Fix:** wire channel-DO registration here, or remove the dead loop.
|
|
261
|
-
|
|
262
|
-
---
|
|
263
|
-
|
|
264
|
-
## Minor / Dead scaffolding
|
|
265
|
-
|
|
266
|
-
### 17. Three lookup Effect variants are dead
|
|
267
|
-
|
|
268
|
-
`LookupNick`, `GetConnectionInfo`, `GetChannelSnapshot` are defined in
|
|
269
|
-
`packages/irc-core/src/effects.ts:74-87` and `:170-178` (and included in the `Effect`
|
|
270
|
-
union at `:112-114`), but their dispatch results are discarded via `noop`
|
|
271
|
-
(`packages/irc-server/src/dispatch.ts:36-38`) and no reducer ever emits them. The
|
|
272
|
-
runtime methods they wrap (`lookupNick`/`getConnectionInfo`/`getChannelSnapshot`) are
|
|
273
|
-
used elsewhere, so only the Effect path is dead.
|
|
274
|
-
|
|
275
|
-
**Fix:** either wire these effects to real consumers, or remove the variants and their
|
|
276
|
-
dispatch arms.
|
|
277
|
-
|
|
278
|
-
---
|
|
279
|
-
|
|
280
|
-
### 18. CF outbound batching optimization reserved/disabled
|
|
281
|
-
|
|
282
|
-
`packages/cf-adapter/src/connection-do.ts:100-101` -- a field for batching outbound line
|
|
283
|
-
drains is commented out, explicitly deferred.
|
|
284
|
-
|
|
285
|
-
**Fix:** implement the batching optimization, or drop the reserved comment.
|
|
286
|
-
|
|
287
|
-
---
|
|
288
|
-
|
|
289
|
-
### 19. Stale doc-comments advertise DOs as stubbed
|
|
290
|
-
|
|
291
|
-
`packages/cf-adapter/src/env.ts:23-36` -- still describes `REGISTRY_DO` as
|
|
292
|
-
"Stubbed now (033); real impl in 034" and `CHANNEL_DO` as "Stubbed now; real in 035",
|
|
293
|
-
even though `registry-do.ts` and `channel-do.ts` now contain real implementations.
|
|
294
|
-
|
|
295
|
-
`packages/cf-adapter/src/connection-do.ts:148-153, 291-293, 337-338, 504-506, 549` contain
|
|
296
|
-
similar stale "stub" language; `:546-549` exports `applyChannelDelta` purely to keep an
|
|
297
|
-
import used by tests.
|
|
298
|
-
|
|
299
|
-
**Fix:** update comments to reflect the implemented state; drop the test-only re-export
|
|
300
|
-
or move it behind a test boundary.
|
|
301
|
-
|
|
302
|
-
---
|
|
303
|
-
|
|
304
|
-
### 20. Case-mapping mismatch vs. advertised ISUPPORT
|
|
305
|
-
|
|
306
|
-
`packages/irc-core/src/isupport.ts:43` advertises `CASEMAPPING=rfc1459`, but
|
|
307
|
-
`packages/irc-core/src/commands/kick.ts:57-60` (and the duplicated `lowerNick`/`lower`
|
|
308
|
-
helpers in `mode.ts`, `invite.ts`, `join.ts`, `packages/in-memory-runtime/src/in-memory-runtime.ts`)
|
|
309
|
-
use bare ASCII `toLowerCase()`. The advertised case-mapping and the actual folding diverge
|
|
310
|
-
for the `[]\^` special chars.
|
|
311
|
-
|
|
312
|
-
**Fix:** implement rfc1459 case folding in a single shared helper and use it everywhere.
|
|
313
|
-
|
|
314
|
-
---
|
|
315
|
-
|
|
316
|
-
### 21. `_disabledRecordId()` generates IDs never consulted
|
|
317
|
-
|
|
318
|
-
`packages/in-memory-runtime/src/in-memory-runtime.ts:61-69` -- mints admission record ids
|
|
319
|
-
whose own doc comment states "The id is never consulted (no `AdmissionStats` exists)."
|
|
320
|
-
Called at `:116` when admission is disabled; the returned `recordId` flows nowhere.
|
|
321
|
-
|
|
322
|
-
**Fix:** remove the helper and its call site, or implement the `AdmissionStats` consumer.
|
|
323
|
-
|
|
324
|
-
---
|
|
325
|
-
|
|
326
|
-
### 22. Stale CLI doc comment
|
|
327
|
-
|
|
328
|
-
`apps/local-cli/src/main.ts:17` -- "a fuller config-loader lands in a later ticket."
|
|
329
|
-
`apps/local-cli/src/config-loader.ts` already exists and fully validates via
|
|
330
|
-
`ServerConfigSchema`.
|
|
331
|
-
|
|
332
|
-
**Fix:** update the comment.
|
|
333
|
-
|
|
334
|
-
---
|
|
335
|
-
|
|
336
|
-
### 23. Stale release-process doc
|
|
337
|
-
|
|
338
|
-
`docs/Release-Process.md:114` -- "the 90% coverage gate (TICKET-048) is not yet wired in CI."
|
|
339
|
-
`.github/workflows/ci.yml:57-60` shows the gate **is** wired and enforced per package
|
|
340
|
-
(100% on irc-core/irc-server/in-memory-runtime, >=90% elsewhere).
|
|
341
|
-
|
|
342
|
-
**Fix:** update the doc to reflect the enforced gate.
|
|
343
|
-
|
|
344
|
-
---
|
|
345
|
-
|
|
346
|
-
## Summary
|
|
347
|
-
|
|
348
|
-
| Severity | Count | Items |
|
|
349
|
-
|---|---|---|
|
|
350
|
-
| Critical | 5 | #1 MessageStore unwired; #2 AccountStore unwired; #3 CF runtime stubs; #4 AWS no QUIT fanout; #5 AWS Accounts table unused |
|
|
351
|
-
| Absent commands | 4 | #6 OPER; #7 TAGMSG; #8 WHOWAS; #9 misc standard verbs |
|
|
352
|
-
| Partial | 7 | #10 SASL EXTERNAL; #11 Welcome MOTD; #12 Version/Created placeholders; #13 DEFAULT_SERVER_CONFIG; #14 AWS connect ignores config; #15 AWS Lambda disconnect; #16 CF channel-register no-op |
|
|
353
|
-
| Minor / Dead scaffolding | 7 | #17 dead lookup Effects; #18 CF batching reserved; #19 stale DO doc-comments; #20 case-mapping mismatch; #21 unused recordId; #22 stale CLI comment; #23 stale release doc |
|
|
354
|
-
|
|
355
|
-
**Bottom line:** Implemented command reducers are solid. The real gaps are (1) two whole
|
|
356
|
-
feature ports (`MessageStore`, `AccountStore`) shipped with no adapter wiring, (2) the CF
|
|
357
|
-
runtime's four stubbed methods that break WHO/WHOIS/LIST/remote-disconnect, (3) AWS never
|
|
358
|
-
broadcasts QUIT on disconnect, and (4) `OPER` is the largest scaffolded-but-absent command.
|