Skip to content

Commit

Permalink
mac80211: tell SME about real auth state
Browse files Browse the repository at this point in the history
When the auth algorithm is rejected, but we don't have
another one to try, we will eventually retry but that
isn't useful -- we'll then do it again and again until
we eventually give up. Instead, we should let the SME
know and go into disabled state. The same applies for
situations where the AP rejects with any other status
code.

Additionally, when trying the next auth algorithm, we
should reset the auth_tries so that just a single lost
frame doesn't lead to us giving up on the third auth
algorithm.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Johannes Berg authored and John W. Linville committed Jul 10, 2009
1 parent 7ebbe6b commit 0575606
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion net/mac80211/mlme.c
Original file line number Diff line number Diff line change
Expand Up @@ -1511,9 +1511,15 @@ static void ieee80211_rx_mgmt_auth(struct ieee80211_sub_if_data *sdata,
!ieee80211_sta_wep_configured(sdata))
continue;
ifmgd->auth_alg = algs[pos];
break;
ifmgd->auth_tries = 0;
return;
}
}
/* nothing else to try -- give up */
cfg80211_send_rx_auth(sdata->dev, (u8 *) mgmt, len,
GFP_KERNEL);
ifmgd->state = IEEE80211_STA_MLME_DISABLED;
ieee80211_recalc_idle(sdata->local);
return;
}

Expand Down

0 comments on commit 0575606

Please sign in to comment.