• The forum software that supports hummy.tv has been upgraded to XenForo 2.3!

    Please bear with us as we continue to tweak things, and feel free to post any questions, issues or suggestions in the upgrade thread.

Webif Setting of LAN/WiFi Configuration

af123

Administrator
Staff member
You could always manually edit the settings.db to use a password that has characters not included in the entry screen. I've done this myself as proof of concept so I know it works.
The Wifi SSID and password are held in clear text in the 252 byte binary blob WLAN_CONNECTED_AP in table "TBL_MENUCONFIG"
The SSID is at offset 0x00 and password at offset 0x78. I think it could definitely be do-able to create a webif page to display or modify all the current network settings, not just WiFi.
Here's a couple of screenshots showing the WiFi settings blob "WLAN_CONNECTED_AP", and the IP address blob "ETHERNET_CONF_1ST_IP" which holds the 4 byte hex value of the current IP address.
Obviously, I have edited out my real network SSID and password.
View attachment 1531View attachment 1532

I've started work on a web interface screen to allow setting network parameters but won't have much time today to continue.
The settings need to be applied during boot so I'm writing a generic boot-time configuration update package. If there are other settings that would make sense to expose in the web interface then it will be fairly easy once this is in place. There may be little point since the settings are rarely adjusted and almost all available via the standard on-TV menu in any case.
 
Last edited:
What might be useful is an option to tell it to store the current settings (in a file) and on restart to check if they are the same and restore the previous if changed. Would save having to reenter it all on those occasions that it loses them (accidentally or deliberately). Obviously it would need a 'button' to tell it to store a new set when you have changed something.
 
I have successfully used the manual edit method to change a 10 character password to one containing 26 characters, including "%#<>" which are not available in the Humax character set.
I presume that the Humax 'on-screen' Wi-Fi menu will display these new ASCII characters after they have been entered via the back door, or are they replaced with asterisks for security, I don't have a Wi-Fi dongle that works on the Humax so I don't have access to this screen
 
The box itself will only display asterisks regardless of which way you have entered the previous password. ( It's a password entry page only after all, so display of existing password is matterless since you're going to replace any previously existing password anyway ) I would expect that the new webif page will display the existing password in full.
 
Last edited:
Would it be possible to use the Humax as a wifi to Ethernet bridge? If both interfaces are active, Linux ought to be able to do the routing. I have no need for this personally, I'm just thinking out loud. Obviously it would need to be switched on all the time, and come on after a power cut not go into standby.
 
Bridging would be possible with a kernel update (bridging not currently enabled). It should be possible to use the Humax as an access point with a bit of fiddling though.
 
I don't know if you could set it up from scratch though solely by editing, if you check the screenshot you will note there are also several single byte entries in the binary blob with purpose unknown. Would probably need to try several different configurations to see what effect this had on said mystery bytes. If they were to remain constant then all the better.

Would anyone with a Humax connected via wireless mind posting the output of the wifi diagnostic and details of the authentication mode they are using (e.g. WEP, WPA, WPA2)? That should enable us to work out some of the missing bytes. The data displayed by the diagnostic will already have the SSID, password and MAC address of the access point removed so should be safe to post, although feel free to PM if you prefer. Thanks!

Here's mine - I'm using WPA2-PSK(TKIP+AES)
Code:
Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:1
Quality:100/100  Signal level:-17 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:18 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00  .
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00
0070: 02 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 64 00 00 00

So far:

0 - 2f = SSID
30 - 31 = ? - channel?
32 - 37 = MAC Address of AP
64 - 67 = ?
68 - 6b = ?
6c - 6f = ?
70 - 73 = ? - channel?
74 - 77 = ?
78 - ef (or f7) = Pass phrase
f8 - fb = Unknown.
 
WPA2-PSK (AES)
Code:
Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:13
Quality:89/100  Signal level:-55 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:144 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00  .              
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00                 
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .              
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 63 00 00 00
 
WPA2-PSK
Code:
Running: wifi
Protocol:802.11b/g
Mode:Managed
Channel:6
Quality:31/100  Signal level:-77 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:54 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: ff ff 6d 6d 6d 6d 6d 6d ff ff ff ff ff ff ff ff  ..mmmmmm........
0040: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
0050: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff  ................
0060: ff ff ff ff 00 00 00 00 03 00 00 00 04 00 00 00  ....
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 00 00 00 00
 
Two boxes.
WPA2-PSK (AES)

Code:
>>> Beginning diagnostic wifi

Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:13
Quality:100/100  Signal level:-39 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:144 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00  .             
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00                 
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .             
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 64 00 00 00                             

>>> Ending diagnostic wifi

>>> Beginning diagnostic wifi

Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:13
Quality:83/100  Signal level:-57 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:144 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00  .             
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00                 
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .             
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 53 00 00 00                             

>>> Ending diagnostic wifi
 
The three bytes at offsets 0x68, 0x6c, 0x70 change depending on which encryption standard is in use:

3 4 4 - WPA2-PSK(AES)
3 4 2 - WPA2-PSK (TKIP+AES)
2 3 4 - WPA-PSK(AES)
2 3 2 - WPA-PSK(TKIP)
0 0 0 - WEP (none)
0 1 1 - WEP (64-bit hex)
 
Last edited:
Two more from me: both WPA2-PSK (AES)
Code:
Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:13
Quality:63/100  Signal level:-65 dBm  Noise level:-83 dBm
Encryption key:on
Bit Rates:144 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73  ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00  .             
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00                
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70  .             
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70  pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 3f 00 00 00            

Running: wifi
Protocol:802.11b/g/n
Mode:Managed
Channel:13
Quality:94/100 Signal level:-53 dBm Noise level:-83 dBm
Encryption key:on
Bit Rates:144 Mb/s
0000: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 ssssssssssssssss
0010: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 ssssssssssssssss
0020: 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 73 ssssssssssssssss
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00 .              
0040: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00                 
0060: 00 00 00 00 02 00 00 00 03 00 00 00 04 00 00 00                 
0070: 04 00 00 00 01 00 00 00 70 70 70 70 70 70 70 70 .              
0080: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
0090: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00A0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00B0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00C0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00D0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00E0: 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 70 pppppppppppppppp
00F0: 00 00 00 00 00 00 00 00 64 00 00 00
I think prpr is on to something wrt 00F8 and signal quality, but some don't match exactly. Presumably the hex value corresponds to a range rather than a discrete value?
 
Thanks all, I've got it working at least for WPA/WPA2. It seems that the information is a mix of configuration and statistics and it's only necessary to populate part of the data for it to bring the wireless up on boot. I'll package up what I have so far and send it out for people to test.
 
I never see the AP MAC address at offsets 32 - 37, only zeroes. And 30-31 are always 01 00 regardless of channel number. Am I missing something obvious ?
 
The channel number guess seems to be completely wrong but I always see the AP MAC address at that offset (1.03.12)
 
I see 'ff' from 0x30 to 0x63 inclusive.
Your hexdump code is broken as well. This:
Code:
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00 .
should presumably display as:
Code:
0030: 01 00 6d 6d 6d 6d 6d 6d 00 00 00 00 00 00 00 00 ..mmmmmm........
I added "A-Z" to the regsub string to get it to display upper case characters as well, but it still stops after the first 0x00 byte.
Is this a bug in jimsh?
 
Yeah - bug somewhere; hexdump routine I think. I've already added -nocase to the regexp to get the upper-case characters to show but haven't spent time working out anything further. It's the regexp that is stopping at the first null byte.
 
A quick peruse of jimsh documentation and the only vague reference it makes to null characters is "Note that Jim supports null characters in strings".
A quick peruse of the source code finds lots of references to strlen() and strdup().
Oh dear. No wonder this doesn't work. <sigh>
 
Back
Top