feat: Add GL.iNet router support with supplementary API data#56
Open
diggerburg wants to merge 3 commits into
Open
feat: Add GL.iNet router support with supplementary API data#56diggerburg wants to merge 3 commits into
diggerburg wants to merge 3 commits into
Conversation
Screenshots will be attached via GitHub UI in the PR description.
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
GL.iNet routers run a custom firmware layer on top of OpenWrt that provides additional data not available through standard ubus/LuCI RPCs. This PR auto-detects GL.iNet routers and fetches supplementary data from their
/rpcJSON-RPC API alongside the existing LuCI data path.All changes are backward-compatible — GL.iNet-specific code only activates when the router model contains "GL-" or "GL.iNet". Non-GL.iNet routers are completely unaffected.
What's new
Dashboard:
Clients:
Interfaces:
iwinforeturns N/A through ubus)Bug fix:
(load[0] / 65536) * 100treated load average as a percentage, but load average of 2.0 on a 4-core system is ~50% utilization, not 200% clamped to 100%.Screenshots
Technical details
GlInetApiService— lightweight service for GL.iNet/rpcauth + data fetchingSha256Crypt— Unix SHA-256 crypt implementation (GL.iNet firmware ≥4.x uses$5$password hashing)HttpClientManageris injected (shared certificate acceptance with main LuCI client)formatWifiBand()utility extracted to avoid duplicationTesting
Checklist
dart formatapplied)flutter analyzepasses (0 errors, 0 warnings)flutter testpasses (41/41)