home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.65k stars 30.41k forks source link

Non-existing networks discovered and made available #65921

Closed kongo09 closed 2 years ago

kongo09 commented 2 years ago

The problem

The AVM FRITZ!Box Tools integration discovers a total of three WiFi networks on my Fritz!Box 6660 Cable (retail version) and marks one of these as active. The box actually has WiFi disabled and only shows one network on the interface:

image

vs

image

Interestingly, the mira network is my inactive guest network of the Fritz!Box. When I disable WiFi, the guest network is also disabled. However, internally the SSID seems to be saved along with the theoretical state of being enabled once the main network is enabled. It looks like the integration is picking this up but interpreting it incorrectly.

When I enable my main WiFi and then go to the guest section of the interface, I can see mira being enabled as well. If I disable it explicitely there and then disable my main WiFi again, the integration also shows it as disabled:

image

Conclusion is: the guest network should always be unavailable if the main network is off.

In addition, what is inconsistent is the separate switch for WiFi 6. I'm not aware of such a switch in the Fritz!Box interface and having this switch in HA suggest that there are two different networks while there are not.

What version of Home Assistant Core has the issue?

core-2022.2.2

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Supervised

Integration causing the issue

AVM FRITZ!Box Tools

Link to integration documentation on our website

https://www.home-assistant.io/integrations/fritz/

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

probot-home-assistant[bot] commented 2 years ago

fritz documentation fritz source (message by IssueLinks)

probot-home-assistant[bot] commented 2 years ago

Hey there @mammuth, @aarondavidschneider, @chemelli74, @mib1185, mind taking a look at this issue as it has been labeled with an integration (fritz) you are listed as a code owner for? Thanks! (message by CodeOwnersMention)

kongo09 commented 2 years ago

Playing with the switches, I come to realize that WiFi motoko is my 2.4 GHz network and WiFi motoko WiFi6 is my 5 GHz network. I suggest to name the switches consistently WiFi motoko 2.4 GHz and WiFi motoko 5 GHz inline with the Fritz!Box interface to avoid confusion.

chemelli74 commented 2 years ago

@kongo09, please add the following to configuration.yaml , restart HA, and post the log:

logger:
  default: warning
  logs:
    homeassistant.components.fritz: debug
    fritzconnection: info

Note: it is better to drag the log into the comment (which will add it as an attachment) and not copy paste as it is hard to read logs in GitHub.

And add diagnostics (menu configuration -> integration -> fritz tools -> download diagnostics )

kongo09 commented 2 years ago

Sorry, dragging just adds it as plain text for me. Here it comes "quoted"

2022-02-07 04:44:36 DEBUG (MainThread) [homeassistant.components.fritz] Setting up FRITZ!Box Tools component
2022-02-07 04:44:38 DEBUG (SyncWorker_4) [homeassistant.components.fritz.common] detected services on 192.168.0.1 ['any1', 'WANCommonIFC1', 'WANDSLLinkC1', 'WANIPConn1', 'WANIPv6Firewall1', 'DeviceInfo1', 'DeviceConfig1', 'Layer3Forwarding1', 'LANConfigSecurity1', 'ManagementServer1', 'Time1', 'UserInterface1', 'X_AVM-DE_Storage1', 'X_AVM-DE_WebDAVClient1', 'X_AVM-DE_UPnP1', 'X_AVM-DE_Speedtest1', 'X_AVM-DE_RemoteAccess1', 'X_AVM-DE_MyFritz1', 'X_VoIP1', 'X_AVM-DE_OnTel1', 'X_AVM-DE_Dect1', 'X_AVM-DE_TAM1', 'X_AVM-DE_AppSetup1', 'X_AVM-DE_Homeauto1', 'X_AVM-DE_Homeplug1', 'X_AVM-DE_Filelinks1', 'X_AVM-DE_Auth1', 'X_AVM-DE_HostFilter1', 'WLANConfiguration1', 'WLANConfiguration2', 'WLANConfiguration3', 'Hosts1', 'LANEthernetInterfaceConfig1', 'LANHostConfigManagement1', 'WANCommonInterfaceConfig1', 'WANDSLInterfaceConfig1', 'WANDSLLinkConfig1', 'WANEthernetLinkConfig1', 'WANPPPConnection1', 'WANIPConnection1']
2022-02-07 04:44:38 DEBUG (SyncWorker_4) [homeassistant.components.fritz.common] gathered device info of 192.168.0.1 {'NewManufacturerName': 'AVM', 'NewManufacturerOUI': '00040E', 'NewModelName': 'FRITZ!Box 6660 Cable', 'NewDescription': 'FRITZ!Box 6660 Cable 252.07.29', 'NewProductClass': 'FRITZ!Box', 'NewSerialNumber': '***omitted***', 'NewSoftwareVersion': '252.07.29', 'NewHardwareVersion': 'FRITZ!Box 6660 Cable', 'NewSpecVersion': '1.0', 'NewProvisioningCode': '', 'NewUpTime': 146639, 'NewDeviceLog': '***omitted***'}
2022-02-07 04:44:39 DEBUG (SyncWorker_2) [homeassistant.components.fritz.common] Checking host info for FRITZ!Box device 192.168.0.1
2022-02-07 04:44:41 DEBUG (SyncWorker_2) [homeassistant.components.fritz.common] Checking devices for FRITZ!Box device 192.168.0.1

Then come some logs of devices that are detected. I only post one example as this all contains personal information:

2022-02-07 04:44:45 DEBUG (SyncWorker_2) [homeassistant.components.fritz.common] Client dev_info: Device(connected=True, connected_to='fritz.box', connection_type='LAN', ip_address='***redacted***', name='shellyplug-s-***redacted***', ssid='', wan_access=True)

This list matches with the devices shown in HA. But as already noted, it is not complete. Then it goes on with:

2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.common] Finished fetching fritz-192.168.0.1-coordinator data in 8.840 seconds (success: True)
2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.button] Setting up buttons
2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.binary_sensor] Setting up FRITZ!Box binary sensors
2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.sensor] Setting up FRITZ!Box sensors
2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.switch] Setting up switches
2022-02-07 04:44:47 DEBUG (MainThread) [homeassistant.components.fritz.switch] Fritzbox services: {'any1': <fritzconnection.core.processor.Service object at 0xec9a37f0>, 'WANCommonIFC1': <fritzconnection.core.processor.Service object at 0xec9a38f8>, 'WANDSLLinkC1': <fritzconnection.core.processor.Service object at 0xec9dc2e0>, 'WANIPConn1': <fritzconnection.core.processor.Service object at 0xec9dc3a0>, 'WANIPv6Firewall1': <fritzconnection.core.processor.Service object at 0xec9dc3b8>, 'DeviceInfo1': <fritzconnection.core.processor.Service object at 0xec9dc400>, 'DeviceConfig1': <fritzconnection.core.processor.Service object at 0xec9dc040>, 'Layer3Forwarding1': <fritzconnection.core.processor.Service object at 0xec9dc4c0>, 'LANConfigSecurity1': <fritzconnection.core.processor.Service object at 0xec9dc340>, 'ManagementServer1': <fritzconnection.core.processor.Service object at 0xec9dc478>, 'Time1': <fritzconnection.core.processor.Service object at 0xec9dc448>, 'UserInterface1': <fritzconnection.core.processor.Service object at 0xec9dc070>, 'X_AVM-DE_Storage1': <fritzconnection.core.processor.Service object at 0xec9dc550>, 'X_AVM-DE_WebDAVClient1': <fritzconnection.core.processor.Service object at 0xec9dc508>, 'X_AVM-DE_UPnP1': <fritzconnection.core.processor.Service object at 0xec9dc088>, 'X_AVM-DE_Speedtest1': <fritzconnection.core.processor.Service object at 0xec9dc430>, 'X_AVM-DE_RemoteAccess1': <fritzconnection.core.processor.Service object at 0xec9dc118>, 'X_AVM-DE_MyFritz1': <fritzconnection.core.processor.Service object at 0xec9dc4a8>, 'X_VoIP1': <fritzconnection.core.processor.Service object at 0xec9dc808>, 'X_AVM-DE_OnTel1': <fritzconnection.core.processor.Service object at 0xec9dc460>, 'X_AVM-DE_Dect1': <fritzconnection.core.processor.Service object at 0xec9dc028>, 'X_AVM-DE_TAM1': <fritzconnection.core.processor.Service object at 0xec9dc358>, 'X_AVM-DE_AppSetup1': <fritzconnection.core.processor.Service object at 0xec9dc838>, 'X_AVM-DE_Homeauto1': <fritzconnection.core.processor.Service object at 0xec9dc0e8>, 'X_AVM-DE_Homeplug1': <fritzconnection.core.processor.Service object at 0xec9dc868>, 'X_AVM-DE_Filelinks1': <fritzconnection.core.processor.Service object at 0xec9dc418>, 'X_AVM-DE_Auth1': <fritzconnection.core.processor.Service object at 0xec9dc568>, 'X_AVM-DE_HostFilter1': <fritzconnection.core.processor.Service object at 0xec9dc148>, 'WLANConfiguration1': <fritzconnection.core.processor.Service object at 0xec9dc8f8>, 'WLANConfiguration2': <fritzconnection.core.processor.Service object at 0xec9dc910>, 'WLANConfiguration3': <fritzconnection.core.processor.Service object at 0xec9dc940>, 'Hosts1': <fritzconnection.core.processor.Service object at 0xec9dc958>, 'LANEthernetInterfaceConfig1': <fritzconnection.core.processor.Service object at 0xec9dc970>, 'LANHostConfigManagement1': <fritzconnection.core.processor.Service object at 0xec9dc988>, 'WANCommonInterfaceConfig1': <fritzconnection.core.processor.Service object at 0xec9dca18>, 'WANDSLInterfaceConfig1': <fritzconnection.core.processor.Service object at 0xec9dca30>, 'WANDSLLinkConfig1': <fritzconnection.core.processor.Service object at 0xec9dcb08>, 'WANEthernetLinkConfig1': <fritzconnection.core.processor.Service object at 0xec9dcb20>, 'WANPPPConnection1': <fritzconnection.core.processor.Service object at 0xec9dcb50>, 'WANIPConnection1': <fritzconnection.core.processor.Service object at 0xec9dcb68>}
2022-02-07 04:44:47 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] Setting up CallDeflection switches
2022-02-07 04:44:48 DEBUG (MainThread) [homeassistant.components.fritz.sensor] WANAccessType of FritzBox 192.168.0.1 is 'X_AVM-DE_Cable'
2022-02-07 04:44:48 DEBUG (SyncWorker_3) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_6) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (MainThread) [homeassistant.components.fritz.device_tracker] Starting FRITZ!Box device tracker
2022-02-07 04:44:48 DEBUG (SyncWorker_0) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] Specific CallDeflection response: GetNumberOfDeflections={'NewNumberOfDeflections': 0}
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] The FRITZ!Box has no CallDeflection options
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] Setting up PortForward switches
2022-02-07 04:44:48 DEBUG (SyncWorker_9) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_6) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_3) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] Specific PortForward response: GetPortMappingNumberOfEntries=0
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] IP source for 192.168.0.1 is 192.168.0.33
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] Setting up WiFiNetwork switches
2022-02-07 04:44:48 DEBUG (SyncWorker_7) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID duplicated, adding suffix
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <motoko Wifi6>
2022-02-07 04:44:48 DEBUG (SyncWorker_9) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 WARNING (MainThread) [homeassistant.components.sensor] Setup of sensor platform adguard is taking over 10 seconds.
2022-02-07 04:44:48 DEBUG (SyncWorker_1) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <mira>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <mira>
2022-02-07 04:45:18 DEBUG (SyncWorker_10) [homeassistant.components.fritz.common] Checking host info for FRITZ!Box device 192.168.0.1
2022-02-07 04:45:18 DEBUG (SyncWorker_3) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:18 DEBUG (SyncWorker_5) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:18 DEBUG (SyncWorker_1) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko' (WiFiNetwork) switch state
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko Wifi6' (WiFiNetwork) switch state
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi mira' (WiFiNetwork) switch state
2022-02-07 04:45:18 DEBUG (SyncWorker_8) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:18 DEBUG (SyncWorker_5) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'mira', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3,OWETrans', 'NewMACAddressControlEnabled': False, 'NewStandard': '', 'NewBSSID': '2E:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:86', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:18 DEBUG (SyncWorker_1) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:18 DEBUG (SyncWorker_7) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:18 DEBUG (SyncWorker_8) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:18 DEBUG (SyncWorker_4) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:19 DEBUG (SyncWorker_5) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:19 DEBUG (SyncWorker_1) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:19 DEBUG (SyncWorker_7) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:20 DEBUG (SyncWorker_10) [homeassistant.components.fritz.common] 
Checking devices for FRITZ!Box device 192.168.0.1
2022-02-07 04:45:23 DEBUG (SyncWorker_10) [homeassistant.components.fritz.common] Client dev_info: Device(connected=True, connected_to='fritz.box', connection_type='LAN', ip_address='***redacted***', name='shellyplug-s-***redacted***', ssid='', wan_access=True)

this continues for all the discovered (but not all existing) devices. Then:

2022-02-07 04:45:48 DEBUG (SyncWorker_3) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_9) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_0) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko' (WiFiNetwork) switch state
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko Wifi6' (WiFiNetwork) switch state
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi mira' (WiFiNetwork) switch state
2022-02-07 04:45:48 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_8) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:86', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:48 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'mira', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3,OWETrans', 'NewMACAddressControlEnabled': False, 'NewStandard': '', 'NewBSSID': '2E:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:45:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_3) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_10) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_6) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:48 DEBUG (SyncWorker_1) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:49 DEBUG (SyncWorker_9) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:45:55 DEBUG (SyncWorker_9) [homeassistant.components.fritz.common] Checking host info for FRITZ!Box device 192.168.0.1
2022-02-07 04:45:57 DEBUG (SyncWorker_9) [homeassistant.components.fritz.common] Checking devices for FRITZ!Box device 192.168.0.1
2022-02-07 04:46:00 DEBUG (SyncWorker_9) [homeassistant.components.fritz.common] Client dev_info: Device(connected=True, connected_to='fritz.box', connection_type='LAN', ip_address='***redacted***', name='shellyplug-s-***redacted***', ssid='', wan_access=True)

This seems to repeat itself now:

2022-02-07 04:46:18 DEBUG (SyncWorker_6) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_1) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_0) [homeassistant.components.fritz.binary_sensor] Updating FRITZ!Box binary sensors
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko' (WiFiNetwork) switch state
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi motoko Wifi6' (WiFiNetwork) switch state
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Updating 'FRITZ!Box 6660 Cable Wi-Fi mira' (WiFiNetwork) switch state
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:46:18 DEBUG (SyncWorker_8) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'motoko', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3', 'NewMACAddressControlEnabled': False, 'NewStandard': 'ax', 'NewBSSID': '2C:91:AB:86:A9:86', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:46:18 DEBUG (MainThread) [homeassistant.components.fritz.switch] Specific WiFiNetwork response: GetInfo={'NewEnable': False, 'NewStatus': 'Disabled', 'NewMaxBitRate': 'Auto', 'NewChannel': 1, 'NewSSID': 'mira', 'NewBeaconType': '11i', 'NewX_AVM-DE_PossibleBeaconTypes': 'None,11i,11iandWPA3,OWETrans', 'NewMACAddressControlEnabled': False, 'NewStandard': '', 'NewBSSID': '2E:91:AB:86:A9:85', 'NewBasicEncryptionModes': 'None', 'NewBasicAuthenticationMode': 'None', 'NewMaxCharsSSID': 32, 'NewMinCharsSSID': 1, 'NewAllowedCharsSSID': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz !"#$%&\'()*+,-./:;<=>?@[\\]^_`{|}~', 'NewMinCharsPSK': 64, 'NewMaxCharsPSK': 64, 'NewAllowedCharsPSK': '0123456789ABCDEFabcdef'}
2022-02-07 04:46:18 DEBUG (SyncWorker_0) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_0) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_4) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_5) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_9) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_10) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_2) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:18 DEBUG (SyncWorker_6) [homeassistant.components.fritz.sensor] Updating FRITZ!Box sensors
2022-02-07 04:46:32 DEBUG (SyncWorker_3) [homeassistant.components.fritz.common] Checking host info for FRITZ!Box device 192.168.0.1
2022-02-07 04:46:34 DEBUG (SyncWorker_3) [homeassistant.components.fritz.common] Checking devices for FRITZ!Box device 192.168.0.1
2022-02-07 04:46:37 DEBUG (SyncWorker_3) [homeassistant.components.fritz.common] Client dev_info: Device(connected=True, connected_to='fritz.box', connection_type='LAN', ip_address='***redacted***', name='shellyplug-s-***redacted***', ssid='', wan_access=True)

It goes on like this with the same stuff over and over.

chemelli74 commented 2 years ago

The interesting stuff is this:

2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <motoko>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID duplicated, adding suffix
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <motoko Wifi6>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID from device: <mira>
2022-02-07 04:44:48 DEBUG (SyncWorker_4) [homeassistant.components.fritz.switch] SSID normalized: <mira>

I will prepare a script to get some more info about your scenario.

Simone

chemelli74 commented 2 years ago

@kongo09, here you are: https://pastebin.com/raw/4iRHsekx

Simone

kongo09 commented 2 years ago

Here you are:

SSID:     motoko
Enabled:  False
Standard: ax
********************************************************************************
SSID:     motoko
Enabled:  False
Standard: ax
********************************************************************************
SSID:     mira
Enabled:  False
Standard:
********************************************************************************
chemelli74 commented 2 years ago
SSID:     motoko
Enabled:  False
Standard: ax
********************************************************************************
SSID:     motoko
Enabled:  False
Standard: ax
********************************************************************************
SSID:     mira
Enabled:  False
Standard:
********************************************************************************

As far as I can see, 6660 has WiFi6: https://en.avm.de/products/fritzbox/fritzbox-6660-cable/technical-specifications So:

Seems basically ok to me. Maybe we should avoid adding the second switch if the the tuple SSID/Standard is the same.

Simone

kongo09 commented 2 years ago

The device does have WiFi 6, but that's just a property of the 2.4 GHz and the 5 GHz networks. Nothing you can enable or disable or name separately in the interface.

kongo09 commented 2 years ago

In addition, the guest network can also not be enabled or disabled separately. It is unavailable, if the main network is off. And it can be on or off, when the main network is on.

kongo09 commented 2 years ago

I did some more research in the Fritz!Box interface. If the networks are enabled, on the Channel settings, there is a hidden advanced setting. There you can set WiFi 6 down to WiFi 5 or even WiFi 4.

image

The setting is available for both, 2.4 GHz and 5 GHz and can be set independently. It cannot be set or accessed if the WiFi network is off.

kongo09 commented 2 years ago

Thinking about it, the logic is still confusing. In the interface - and that might be different from the API you are using - things are presented as follows:

So that would translate to me as follows:

The thing is, the band switches do more than switching the main network on or off. The switch the whole radio on or off for both networks.

That leaves out the complexity with WiFi 6. If you want to include that, in my view, the proper way would be:

Again, these dropdowns would be unavailable if the respective radios are switched off

kongo09 commented 2 years ago

@chemelli74 and I had a discussion on Discord and looked at some more interface screens. We concluded the following:

This means: