rev 1.19 fixed wpa supplicant but broke wpa authenticator; when operating

as an authenticator need to always check for the unicast key in the node
(as was the case before)

Submitted by:	Divy Le Ray
This commit is contained in:
sam 2005-02-10 17:00:48 +00:00
parent be46f93f56
commit bfba17efd6

View File

@ -563,7 +563,8 @@ ieee80211_encap(struct ieee80211com *ic, struct mbuf *m,
*/
if (eh.ether_type != htons(ETHERTYPE_PAE) ||
((ic->ic_flags & IEEE80211_F_WPA) &&
!KEY_UNDEFINED(*key))) {
(ic->ic_opmode == IEEE80211_M_STA ?
!KEY_UNDEFINED(*key) : !KEY_UNDEFINED(ni->ni_ucastkey)))) {
wh->i_fc[1] |= IEEE80211_FC1_WEP;
/* XXX do fragmentation */
if (!ieee80211_crypto_enmic(ic, key, m)) {