Implement control channel routing for wraith-* reserved destinations (ADR-018)

- Add control_channel.rs with WRAITH_CONTROL_DESTINATION, WRAITH_PREFIX constants
- Add ControlChannelHandler trait and ControlChannelRouter for routing logic
- Add DuplexStream supertrait for Box<dyn> compatibility
- Server handler rejects wraith-* destinations when no handler configured
- Add ForwardError type to fix pre-existing compilation error
- Unit tests: reserved detection, non-reserved pass-through, prefix matching
This commit is contained in:
2026-06-02 11:01:54 +00:00
parent 992d478630
commit f963898a05
4 changed files with 248 additions and 8 deletions

View File

@@ -1,3 +1,8 @@
pub mod control_channel;
pub mod handler;
pub use control_channel::{
ControlChannelHandler, ControlChannelRouter, DuplexStream, WRAITH_CONTROL_DESTINATION,
WRAITH_PREFIX, is_reserved_destination,
};
pub use handler::{ProxyConfig, ProxyMode, ServerHandler};