refactor!: rebrand wraith to alknet
Rename all crates, CLI commands, constants, type names, doc comments, and documentation from wraith to alknet. Includes wire-protocol changes: ALPN wraith-ssh -> alknet-ssh, reserved destination prefix wraith- -> alknet-, SSH auth username wraith -> alknet.
This commit is contained in:
@@ -13,15 +13,15 @@ level: implementation
|
||||
|
||||
## Description
|
||||
|
||||
Implement the NAPI `serve()` function per ADR-016. Returns a `WraithServer` object with a `close()` method and `onConnection` event emitter. Each incoming SSH connection produces a `Duplex` stream.
|
||||
Implement the NAPI `serve()` function per ADR-016. Returns a `AlknetServer` object with a `close()` method and `onConnection` event emitter. Each incoming SSH connection produces a `Duplex` stream.
|
||||
|
||||
The function accepts `WraithServeOptions` and returns `Promise<WraithServer>`. The NAPI layer handles transport binding, SSH server setup, and connection handling.
|
||||
The function accepts `AlknetServeOptions` and returns `Promise<AlknetServer>`. The NAPI layer handles transport binding, SSH server setup, and connection handling.
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [x] `#[napi]` function `serve(options: WraithServeOptions) -> Result<WraithServer>` in `crates/wraith-napi/src/serve.rs`
|
||||
- [x] `WraithServeOptions` struct with napi fields: `transport`, `hostKey`, `authorizedKeys`, `certAuthority`, `tlsCert`, `tlsKey`, `acmeDomain`, `listen`, `irohRelay`
|
||||
- [x] `WraithServer` napi class with `close() -> Promise<void>` and `onConnection(callback)` event registration
|
||||
- [x] `#[napi]` function `serve(options: AlknetServeOptions) -> Result<AlknetServer>` in `crates/alknet-napi/src/serve.rs`
|
||||
- [x] `AlknetServeOptions` struct with napi fields: `transport`, `hostKey`, `authorizedKeys`, `certAuthority`, `tlsCert`, `tlsKey`, `acmeDomain`, `listen`, `irohRelay`
|
||||
- [x] `AlknetServer` napi class with `close() -> Promise<void>` and `onConnection(callback)` event registration
|
||||
- [x] Each incoming connection produces a `Duplex` stream via the `onConnection` callback
|
||||
- [x] `ConnectionInfo` struct passed with each connection: `remoteAddr`, `transportKind`
|
||||
- [x] Key material: `hostKey`, `authorizedKeys` accept file path (string) or `Buffer` (in-memory)
|
||||
@@ -32,14 +32,14 @@ The function accepts `WraithServeOptions` and returns `Promise<WraithServer>`. T
|
||||
|
||||
## References
|
||||
|
||||
- docs/architecture/napi-and-pubsub.md — NAPI serve() spec, WraithServer interface
|
||||
- docs/architecture/napi-and-pubsub.md — NAPI serve() spec, AlknetServer interface
|
||||
- docs/architecture/decisions/016-napi-expose-connect-and-serve.md — both connect() and serve()
|
||||
- docs/architecture/server.md — server configuration
|
||||
|
||||
## Notes
|
||||
|
||||
TCP transport fully implemented. TLS/iroh transports return helpful "not yet supported" errors. WraithServerStream provides read/write/close. ConnectionInfo includes remoteAddr and transportKind.
|
||||
TCP transport fully implemented. TLS/iroh transports return helpful "not yet supported" errors. AlknetServerStream provides read/write/close. ConnectionInfo includes remoteAddr and transportKind.
|
||||
|
||||
## Summary
|
||||
|
||||
Implemented NAPI serve() in crates/wraith-napi/src/serve.rs: WraithServeOptions, WraithServer with close()/onConnection(), WraithServerStream (Duplex read/write/close), ConnectionInfo. TCP transport works end-to-end. 241 tests pass, clippy clean.
|
||||
Implemented NAPI serve() in crates/alknet-napi/src/serve.rs: AlknetServeOptions, AlknetServer with close()/onConnection(), AlknetServerStream (Duplex read/write/close), ConnectionInfo. TCP transport works end-to-end. 241 tests pass, clippy clean.
|
||||
Reference in New Issue
Block a user