PERFORCE change 134525 for review
Sam Leffler
sam at FreeBSD.org
Wed Jan 30 22:18:32 PST 2008
http://perforce.freebsd.org/chv.cgi?CH=134525
Change 134525 by sam at sam_ebb on 2008/01/31 06:18:26
sanity-check the country ie before parsing
Affected files ...
.. //depot/projects/vap/sys/net80211/ieee80211_scan.c#14 edit
Differences ...
==== //depot/projects/vap/sys/net80211/ieee80211_scan.c#14 (text+ko) ====
@@ -1020,6 +1020,10 @@
(const struct ieee80211_country_ie *) ie;
int i, nbands, schan, nchan;
+ if (cie->len < 3) {
+ printf(" <bogus country ie, len %d>", cie->len);
+ return;
+ }
printf(" country [%c%c%c", cie->cc[0], cie->cc[1], cie->cc[2]);
nbands = (cie->len - 3) / sizeof(cie->band[0]);
for (i = 0; i < nbands; i++) {
More information about the p4-projects
mailing list