]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Fix VLAN ID validation check to use the new VLAN ID
authorBlaž Bačnik <bacnik@gmail.com>
Wed, 30 Sep 2009 17:44:04 +0000 (20:44 +0300)
committerJouni Malinen <j@w1.fi>
Wed, 30 Sep 2009 17:44:04 +0000 (20:44 +0300)
When checking the validity of VLAN ID based on RADIUS-based ACL or
accept_mac_file, the assigned vlan_id, not the old sta->vlan_id
(likely zero) needs to be used.

hostapd/ieee802_11.c

index 394dfab747d672c94864f5b9a170b23a7cdeb3c6..f2e793c903beccb7c869d8a33c7dddca852a578d 100644 (file)
@@ -585,7 +585,7 @@ static void handle_auth(struct hostapd_data *hapd, struct ieee80211_mgmt *mgmt,
 
        if (vlan_id > 0) {
                if (hostapd_get_vlan_id_ifname(hapd->conf->vlan,
-                                              sta->vlan_id) == NULL) {
+                                              vlan_id) == NULL) {
                        hostapd_logger(hapd, sta->addr, HOSTAPD_MODULE_RADIUS,
                                       HOSTAPD_LEVEL_INFO, "Invalid VLAN ID "
                                       "%d received from RADIUS server",