A Rust implementation of the Moblin remote control assistant server. This server allows Moblin streamers to connect via WebSocket and provides remote control functionality.
- WebSocket server for Moblin remote control protocol
- Connection setup with challenge-response authentication (SHA256-based)
- Identification using password hashing with salt and challenge
- Ping/pong keep-alive mechanism
- Twitch chat ingestion and forwarding to Moblin
- YouTube live chat ingestion and forwarding to Moblin
cargo build --releaseStart the server with a password:
cargo run -- --password my-secure-passwordOr specify a custom port:
cargo run -- --password my-secure-password --port 2345For release builds:
./target/release/moblin-assistant --password my-secure-passwordThe server uses env_logger for logging. You can control the log level using the RUST_LOG environment variable:
# Show only important events (info level)
RUST_LOG=info cargo run -- --password my-secure-password
# Show all debug information
RUST_LOG=debug cargo run -- --password my-secure-password
# Show everything including trace
RUST_LOG=trace cargo run -- --password my-secure-passwordBy default (without RUST_LOG set), the server runs silently. The logging levels used are:
- info: Major events like server startup, connections, authentication success, and Twitch channel joins
- debug: Detailed operational information like message exchanges and protocol details
- error: Error conditions like authentication failures and connection issues
The server implements the Moblin remote control protocol:
- Hello: Server sends authentication challenge and salt
- Identify: Client sends hashed password for authentication
- Identified: Server confirms authentication status
- Ping/Pong: Keep-alive mechanism
- TwitchStart/YouTubeStart: Streamer requests external chat bridge setup
- Chat Messages: Assistant forwards Twitch/YouTube messages to the streamer
-
Start the server:
cargo run -- --password test123
-
Connect your Moblin app to the server using the IP address and password
-
Start Twitch and/or YouTube chat from the app and incoming messages are forwarded to Moblin
This implementation is based on: