Add HTML fallback for SB8200 with broken HNAP firmware#312
Merged
Conversation
Move HTML table parsing logic into a reusable module for both CM8200A and SB8200 HTML fallback. Refs: #309
No behavior change. Inline HTML table parsing replaced by the shared parse_arris_channel_tables() function from arris_html module. Refs: #309
When HNAP login exhausts all retries (legacy TLS, fresh sessions,
HTTP fallback), the driver now tries the browser HTML login path
(GET /cmconnectionstatus.html?login_{base64}) before giving up.
If HTML works, the driver switches to HTML mode permanently for
subsequent polls.
This allows SB8200 units on old ISP firmware where HNAP POST body
reads consistently fail to still function via HTML table scraping.
Existing HNAP users (S33/S34/newer SB8200) are unaffected - the
HTML fallback only activates after HNAP is completely exhausted.
Refs: #309
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
arris_html.py(reused by CM8200A and SB8200)How it works
The SB8200 on old ISP firmware (e.g.
AB01.02.053.05) has a broken HNAP implementation that resets the TCP connection during POST body reads. The browser login path (GET /cmconnectionstatus.html?login_{base64}) works fine because it uses GET requests instead of POST.When the driver detects that HNAP is completely non-functional (3+ transport failures), it attempts a single HTML login. If the response contains valid channel tables, the driver switches to HTML mode for subsequent polls. If not, the original HNAP error is raised.
Test plan
Refs: #309