mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-19 07:06:30 +00:00
parent
9264d437b1
commit
7aceb21123
@ -85,7 +85,7 @@
|
|||||||
},
|
},
|
||||||
'802-11-wireless-security':
|
'802-11-wireless-security':
|
||||||
{
|
{
|
||||||
{% if interface.wifi.auth == "web" %}
|
{% if interface.wifi.auth == "wep" %}
|
||||||
'auth-alg': <'none'>,
|
'auth-alg': <'none'>,
|
||||||
'key-mgmt': <'none'>
|
'key-mgmt': <'none'>
|
||||||
{% elif interface.wifi.auth == "wpa-psk" %}
|
{% elif interface.wifi.auth == "wpa-psk" %}
|
||||||
|
@ -22,7 +22,7 @@ class AuthMethod(str, Enum):
|
|||||||
"""Authentication method."""
|
"""Authentication method."""
|
||||||
|
|
||||||
OPEN = "open"
|
OPEN = "open"
|
||||||
WEB = "web"
|
WEP = "wep"
|
||||||
WPA_PSK = "wpa-psk"
|
WPA_PSK = "wpa-psk"
|
||||||
|
|
||||||
|
|
||||||
|
@ -287,8 +287,8 @@ class Interface:
|
|||||||
return None
|
return None
|
||||||
|
|
||||||
# Authentication
|
# Authentication
|
||||||
if inet.settings.wireless_security.key_mgmt == "none":
|
if inet.settings.wireless_security.auth_alg == "none":
|
||||||
auth = AuthMethod.WEB
|
auth = AuthMethod.WEP
|
||||||
elif inet.settings.wireless_security.key_mgmt == "wpa-psk":
|
elif inet.settings.wireless_security.key_mgmt == "wpa-psk":
|
||||||
auth = AuthMethod.WPA_PSK
|
auth = AuthMethod.WPA_PSK
|
||||||
else:
|
else:
|
||||||
|
@ -124,7 +124,7 @@ async def test_interface_update_payload_wireless_web(coresys):
|
|||||||
|
|
||||||
interface.type = InterfaceType.WIRELESS
|
interface.type = InterfaceType.WIRELESS
|
||||||
interface.wifi = WifiConfig(
|
interface.wifi = WifiConfig(
|
||||||
WifiMode.INFRASTRUCTURE, "Test", AuthMethod.WEB, "password", 0
|
WifiMode.INFRASTRUCTURE, "Test", AuthMethod.WEP, "password", 0
|
||||||
)
|
)
|
||||||
|
|
||||||
data = interface_update_payload(interface)
|
data = interface_update_payload(interface)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user