[PATCHv2 01/12] Separate station grouping and uplink configuration
Jouni Malinen
j at w1.fi
Wed Feb 17 06:25:53 PST 2016
On Thu, Jan 07, 2016 at 02:22:33PM +0100, M. Braun wrote:
> >> diff --git a/src/ap/sta_info.h b/src/ap/sta_info.h
> >> struct sta_info {
> >> + struct hostapd_data *bss; /* required for set vlan in preauth */
> >
> > Cannot say that I'm exactly fond of adding sta->bss pointer,
>
> alternative approach: move get/set vlan for station out of pmksa2eapol
> and eapol2pmksa. That is struct eapol_state_machine would hold a struct
> *vlan_description instead of void *sta (to be filled during creation and
> updated by ap_sta_set_vlan, just referencing the struct sta_info
> member), so pmksa2eapol and eapol2pmksa can just copy the
> vlan_description data. ieee802_1x_new_station would then call
> ap_sta_set_vlan (using the eapol_state_machine member) in addition to
> the existing ap_sta_bind_vlan call afer pmksa2eapol, and
> ieee802_1x_new_station already has a hapd pointer available.
For now, I ended up removing this sta->bss pointer and passing the hapd
pointer to pmksa_cache_to_eapol_data(). pmksa_cache_auth.c is not really
supposed to use struct hapd_data, but at least this is now only for the
purpose of forwarding the pointer to ap_sta_set_vlan(). In fact, event
he use of struct sta_info in that function is not exactly in line with
the goal of keeping pmksa_cache_auth.c independent of the core hostapd
data structures. Anyway, that was not something added by this patch set.
--
Jouni Malinen PGP id EFC895FA
More information about the Hostap
mailing list