Releases: underhax/matrix-bot-openwrt
Releases · underhax/matrix-bot-openwrt
Release list
Release v2.2.3
Breaking Changes & Architecture
- Rewrote the project from Bash to native Lua 5.1
- Replaced
matrix-commander-rsdependency with a custom, self-maintainedmatrix-cli - Replaced monolithic scripts with a modular architecture using dynamic
requireloading
Performance & Security Optimizations
- Successfully ported all strict security standards from the Bash project, achieving a safer and highly optimized environment by eliminating shell forks
- Reduced CPU and memory overhead by replacing external programs with native Lua execution and OpenWrt C-bindings (
uci,ubus,iwinfo,cjson, etc.)
New Features
- Introduced a complete LuCI Web GUI application for router configuration
- Added APK package building for native OpenWrt deployment
- Added a custom OpenWrt APK repository via GitHub Pages
Full Changelog: v1.1.0...v2.2.3
Release v1.1.0
Breaking Changes & Architecture
- Refactored architecture into distinct E2EE and HTTP builds
- Split source code into common, e2ee, and http modules
- Centralized common argument parsing and cleanup logic for daemons
Security Hardening
- Enforced strict permissions (root:600/400) for SSH configurations
- Secured temporary file handling by isolating mode 0700 directories
- Mitigated symlink vulnerabilities by moving temporary files into protected BOT_RUN_DIR
- Sanitized external IP and WiFi SSID outputs to prevent XSS and HTML injection
- Implemented strict config validation using dedicated validators
Performance Optimizations
- Replaced multiple iterative uci calls with single-pass memory caching
- Optimized HTML escaping and event processing to significantly reduce process forks
- Batched jq extraction and cached dependency availability detection
- Handled zombie processes and reduced overall PID count
Resilience & New Features
- Added wget fallback for HTTP transport and connection retry logic
- Implemented HTTP 429 rate limit backoff and sleep jitter to prevent server DoS
- Added configuration toggle to mask WiFi keys in chat
- Added support for executing Wake-on-LAN across multiple broadcast interfaces
- Integrated comprehensive BATS unit testing suite for validation and handlers
Release v1.0.0
Initial Stable Release
This is the first production-ready version of the Matrix Bot for OpenWrt. It provides a secure, lightweight, and dependency-free way to manage your router remotely via the Matrix protocol.
Key Features
- Native OpenWrt Support: Written in pure POSIX shell, optimized for BusyBox
ash. No heavy runtimes (Python/Node.js) required. - Hybrid Transport System:
- Secure E2EE: Primary communication via
matrix-commander-rsover SSH. - Transparent Fallback: Direct HTTP support for non-encrypted rooms via
curlorwget.
- Secure E2EE: Primary communication via
- Comprehensive Remote Management:
- Control system services (
init.d), firewall, and network interfaces. - Manage Wi-Fi radios (On/Off/Toggle) and view real-time signal status.
- Wake-on-LAN (WOL) support for waking PCs in your local network.
- Control system services (
- Advanced Client Reporting: Dynamic listing of connected wireless and wired LAN clients with MAC/IP/Hostname resolution.
- Procd Integration: Managed as a native OpenWrt service with auto-respawn and standard logging via
logread.
Security & Reliability
- CI/CD Verified: Every line of code is automatically analyzed by GitHub Actions using ShellCheck to ensure strict POSIX compliance and prevent common shell pitfalls.
- Input Sanitization: All command arguments are strictly filtered to prevent shell injection vulnerabilities.
- Credential Protection: Matrix access tokens are handled securely using temporary private files and
curl -Kto prevent exposure in the process list. - Access Control: Built-in administrator-only restrictions with security alerts for unauthorized interaction attempts.
Compatibility & Requirements
- Tested Hardware: Xiaomi Mi Router 3G (mir3g).
- Tested OS: OpenWrt 25.12.0 (BusyBox ash).
- Dependencies:
curl,jq(orjsonfilter),openssh-client.
Installation instructions are available in the README.md.