Implement native IRC gateway
All checks were successful
Native Rust workspace compile / compile (push) Successful in 21m47s
All checks were successful
Native Rust workspace compile / compile (push) Successful in 21m47s
This commit is contained in:
@@ -12,7 +12,7 @@ here so a source entry is never mistaken for a completed port.
|
||||
| `packet-dump` | PacketDump | Implemented with live and deterministic fake-grid capture |
|
||||
| `prim-inspector` | PrimInspector | Implemented with live and deterministic fake-grid discovery |
|
||||
| `inventory-explorer` | InventoryExplorer | Implemented with live inventory and deterministic AIS fixtures |
|
||||
| `irc-gateway` | IRCGateway | Pending milestone 11 issue #90 |
|
||||
| `irc-gateway` | IRCGateway | Implemented with live IRC/grid transports and deterministic offline scripts |
|
||||
| `test-client` | TestClient | Pending milestone 11 issues #91–#94 |
|
||||
| `vivox-test` | VivoxTest | Pending milestone 11 issue #95 |
|
||||
| `webrtc-test` | WebRtcTest | Pending milestone 11 issue #96 |
|
||||
@@ -101,6 +101,56 @@ cargo test -p libremetaverse-programs --test simple_bot_cli --locked
|
||||
cargo test --manifest-path tests/compat/Cargo.toml --test core_runtime_shims --locked
|
||||
```
|
||||
|
||||
## IRCGateway
|
||||
|
||||
`irc-gateway` preserves the upstream seven-position live interface and bridges
|
||||
fully audible normal local chat to one IRC channel in both directions:
|
||||
|
||||
```text
|
||||
irc-gateway FIRSTNAME LASTNAME PASSWORD MASTER_UUID IRC_HOST IRC_PORT '#channel'
|
||||
```
|
||||
|
||||
The positional values can instead come from `GRID_FIRST_NAME`,
|
||||
`GRID_LAST_NAME`, `GRID_PASSWORD`, `GRID_MASTER_UUID`, `IRC_HOST`, `IRC_PORT`,
|
||||
and `IRC_CHANNEL`. `GRID_LOGIN_URL` or `--login-uri` selects a grid endpoint.
|
||||
`--nickname` defaults to the upstream `SLGateway` name. Login is bounded by
|
||||
`--login-timeout-seconds`; `--messages-per-second` and `--burst` control the
|
||||
per-direction token buckets.
|
||||
|
||||
The native IRC transport registers with `NICK`/`USER`, responds to `PING`,
|
||||
joins after numeric `001`, handles fragmented UTF-8 input, caps inbound and
|
||||
outbound lines, and reconnects with exponential backoff. The bridge uses
|
||||
bounded queues, sanitizes names and line breaks, suppresses self messages,
|
||||
short-window duplicates, and reflected cross-transport messages, and accepts
|
||||
teleport lures only from `MASTER_UUID`. Login messages and console output
|
||||
redact credentials, tokens, capability URLs, and other URLs. Ctrl-C cancels
|
||||
login and reconnect waits, closes the IRC socket, joins workers, unsubscribes
|
||||
grid callbacks, logs out, and disposes the native client.
|
||||
|
||||
Offline tests use the same routing and rate-limit engine without credentials or
|
||||
network access:
|
||||
|
||||
```text
|
||||
irc-connect
|
||||
irc-disconnect
|
||||
irc<TAB>target<TAB>nickname<TAB>message
|
||||
grid-chat<TAB>source-uuid<TAB>name<TAB>normal|other<TAB>full|other<TAB>message
|
||||
grid-login<TAB>message
|
||||
teleport<TAB>source-uuid<TAB>session-uuid
|
||||
advance<TAB>milliseconds
|
||||
shutdown
|
||||
```
|
||||
|
||||
Scripts are limited to 1 MiB and 4,096 events; names, messages, transport
|
||||
queues, and loop histories are also bounded. Run the issue-focused suite and
|
||||
the related native social-message compatibility cases with:
|
||||
|
||||
```sh
|
||||
cargo test -p libremetaverse-programs --test irc_gateway_cli --locked
|
||||
cargo test -p libremetaverse-programs irc_gateway::tests --locked
|
||||
cargo test --manifest-path tests/compat/Cargo.toml --test social_message_semantics --locked
|
||||
```
|
||||
|
||||
## PacketDump
|
||||
|
||||
`packet-dump` preserves the upstream live arguments and its 20-second login
|
||||
|
||||
Reference in New Issue
Block a user