Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hub info gives warning for settings when in Modem Mode #10

Open
InternalLoss opened this issue Oct 11, 2019 · 1 comment
Open

hub info gives warning for settings when in Modem Mode #10

InternalLoss opened this issue Oct 11, 2019 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@InternalLoss
Copy link

Now I'm in Modem Mode on my VM Router, im not too surprised there's a small bug:

billy@Billys-MBP virgin-media-hub3 % python3 hub info
modelname : TG2492LG-85
family : 852
hardware_version : 10
serial_number : [REDACTED]
bootcode_version : 4.2.0.45
firmware_version : 9.1.1802.613
name : Home
current_time_status : TODStatus.RETRIEVED
current_time : 2019-10-11 23:54:17
uptime : 16:00:49.920000
first_install_wizard_completed : True
wan_ip_prov_mode : 1
wan_current_ipaddr_ipv4 : None
wan_current_ipaddr_ipv6 : None
/Users/billy/Downloads/virgin-media-hub3/snmp.py:767: UserWarning: SNMP Walk of '1.3.6.1.4.1.4115.1.20.1.1.1.11.2.1' yielded no results
  warnings.warn("SNMP Walk of '%s' yielded no results" % table_oid)
/Users/billy/Downloads/virgin-media-hub3/snmp.py:815: UserWarning: SMTP walk of 1.3.6.1.4.1.4115.1.20.1.1.1.11.2.1 resulted in zero rows
  % table_oid)
dns_servers :
+
|
+
+

I'm going to presume this is likely due to me being in Modem Mode c:

@KarlJorgensen KarlJorgensen self-assigned this Oct 15, 2019
@KarlJorgensen KarlJorgensen added the bug Something isn't working label Oct 15, 2019
@jamesmacwhite
Copy link

jamesmacwhite commented Aug 31, 2020

I'd imagine some of the commands will return different responses when in modem mode. Perhaps, there needs to be a check for modem mode which I believe will potentially have it's own SNMP OID to query and then prevent certain methods being run when the Hub3 is in modem mode.

Looks like it's the dns_servers method that throws the error for the info command. Either gracefully handling a no results response or prevent certain commands being run when in modem mode would be potential fixes.

There's a JSON endpoint (checkConnType) which returns this:

{
	"conType": "LAN",
	"gwWan": "f",
	"remoteAddr": "192.168.100.2",
	"lang": "English",
	"provMode": "1",
	"dsLite": "0",
	"modemMode": "1",
	"firstInstall": "1"
}

And potentially an SNMP OID request: http://192.168.100.1/snmpGet?oids=1.3.6.1.4.1.4491.2.1.14.1.5.4.0 which returns "1" when on the modem mode page when logged in, potentially this is the OID for modem mode?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants