mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-12-25 08:02:38 +01:00
wiphy: Don't connect to networks we don't support
This commit is contained in:
parent
d77238d5fd
commit
97a92a9d02
@ -207,6 +207,14 @@ static struct l_dbus_message *network_connect(struct l_dbus *dbus,
|
|||||||
if (netdev->connect_pending)
|
if (netdev->connect_pending)
|
||||||
return dbus_error_busy(message);
|
return dbus_error_busy(message);
|
||||||
|
|
||||||
|
switch (network->ssid_security) {
|
||||||
|
case SCAN_SSID_SECURITY_NONE:
|
||||||
|
case SCAN_SSID_SECURITY_PSK:
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
return dbus_error_not_supported(message);
|
||||||
|
}
|
||||||
|
|
||||||
msg = l_genl_msg_new_sized(NL80211_CMD_AUTHENTICATE, 512);
|
msg = l_genl_msg_new_sized(NL80211_CMD_AUTHENTICATE, 512);
|
||||||
msg_append_attr(msg, NL80211_ATTR_IFINDEX, 4, &netdev->index);
|
msg_append_attr(msg, NL80211_ATTR_IFINDEX, 4, &netdev->index);
|
||||||
msg_append_attr(msg, NL80211_ATTR_WIPHY_FREQ, 4, &bss->frequency);
|
msg_append_attr(msg, NL80211_ATTR_WIPHY_FREQ, 4, &bss->frequency);
|
||||||
|
Loading…
Reference in New Issue
Block a user