Up to [local] / src / sys / net80211
Request diff between arbitrary revisions
Default branch: MAIN
Revision 1.254 / (download) - annotate - [select for diffs], Thu May 23 11:19:13 2024 UTC (2 weeks, 5 days ago) by stsp
Branch: MAIN
CVS Tags: HEAD
Changes since 1.253: +4 -2 lines
Diff to previous 1.253 (colored)
increment CCMP decryption error counter if hw decrypt fails to get PN This case will only occur if the IV has been stripped by hardware and the driver has not cleared the protected bit in the frame header as it should. Incrementing this counter will make the problem more obvious when looking at netstat -W output. No functional change for people who do not work on wifi drivers.
Revision 1.253 / (download) - annotate - [select for diffs], Mon May 13 01:15:53 2024 UTC (4 weeks, 1 day ago) by jsg
Branch: MAIN
Changes since 1.252: +1 -2 lines
Diff to previous 1.252 (colored)
remove prototypes with no matching function ok mpi@
Revision 1.252 / (download) - annotate - [select for diffs], Sat Apr 13 23:44:11 2024 UTC (8 weeks, 2 days ago) by jsg
Branch: MAIN
Changes since 1.251: +2 -2 lines
Diff to previous 1.251 (colored)
correct indentation no functional change, found by smatch warnings ok miod@ bluhm@
Revision 1.251 / (download) - annotate - [select for diffs], Fri Mar 15 17:45:36 2024 UTC (2 months, 3 weeks ago) by stsp
Branch: MAIN
Changes since 1.250: +6 -1 lines
Diff to previous 1.250 (colored)
Ignore ADDBA requests if we are not ready to receive data frames. This prevents potential firmware errors in Intel wifi drivers when APs send an ADDBA request before the driver's state machine has settled into RUN state. The driver's addba task would race the driver's newstate task, and the hardware would see an incorrect sequence of commands. Ignoring an early ADDBA request is harmless. The AP will retry later. Reported by zxystd from the OpenIntelWireless project, thanks! ok phessler@
Revision 1.250 / (download) - annotate - [select for diffs], Mon Jan 9 00:22:47 2023 UTC (17 months ago) by daniel
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE,
OPENBSD_7_5,
OPENBSD_7_4_BASE,
OPENBSD_7_4,
OPENBSD_7_3_BASE,
OPENBSD_7_3
Changes since 1.249: +2 -1 lines
Diff to previous 1.249 (colored)
restore NetBSD RCS ID Looks like this was removed in rev 1.85 without comment (which may have been unintentional). ok stsp@
Revision 1.249 / (download) - annotate - [select for diffs], Sat Jan 7 11:09:16 2023 UTC (17 months ago) by stsp
Branch: MAIN
Changes since 1.248: +6 -1 lines
Diff to previous 1.248 (colored)
Make net80211 drop beacons received on secondary HT/VHT channels. Prevents iwm firmware panics and makes association work with 11ac APs which transmit beacons on channels other than their primary channel. We would use the wrong channel in such cases, and iwm would request a bogus channel configuration, which made the firmware unhappy. Tested by myself on iwm 8265 and florian on iwm 9260. This issue did likely affect iwx devices, too. ok mpi@
Revision 1.248 / (download) - annotate - [select for diffs], Tue Dec 27 20:13:03 2022 UTC (17 months, 2 weeks ago) by patrick
Branch: MAIN
Changes since 1.247: +3 -3 lines
Diff to previous 1.247 (colored)
Fix array bounds mismatch with clang 15 New warning -Warray-parameter is a bit overzealous. ok millert@ tb@
Revision 1.247 / (download) - annotate - [select for diffs], Sun Mar 20 12:01:58 2022 UTC (2 years, 2 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE,
OPENBSD_7_2,
OPENBSD_7_1_BASE,
OPENBSD_7_1
Changes since 1.246: +12 -8 lines
Diff to previous 1.246 (colored)
Introduce an alternative mechanism for wifi drivers to communicate the channel on which a frame was received. ieee80211_inputm() was expecting that ic->ic_bss->ni_chan would correspond to the channel which is currently being scanned. This dates back to older devices which are manually tuned to the next channel by the driver during SCAN->SCAN state transitions. However, this approach is very awkward for drivers which scan across a whole range of channels in firmware. Such drivers had an ugly workaround in place which tweaked ni_chan for each received frame. Introduce a channel number field in the Rx info struct which drivers can use to indicate the channel on which a frame was received. If this field is set, net80211 will use it instead of using the current channel of ic_bss. Use this new mechanism in all affected drivers. Tested by jmc@, sthen@, and myself on iwm(4) and iwx(4). Changes to iwn(4) and bwfm(4) are the same mechanical changes to get rid of the ni_chan tweak, and are therefore expected to work. ok sthen@ dlg@
Revision 1.246 / (download) - annotate - [select for diffs], Sun Mar 20 07:50:32 2022 UTC (2 years, 2 months ago) by stsp
Branch: MAIN
Changes since 1.245: +4 -2 lines
Diff to previous 1.245 (colored)
Make background scans pick up APs on 2GHz channels while in 11ac mode. found by landry@
Revision 1.245 / (download) - annotate - [select for diffs], Mon Mar 14 15:07:24 2022 UTC (2 years, 2 months ago) by stsp
Branch: MAIN
Changes since 1.244: +52 -9 lines
Diff to previous 1.244 (colored)
Add initial 802.11ac (VHT) support to net80211. Add VHT capability and operation IE definitions to ieee80211.h. Introduce channel flags to identify 80MHz and 160MHz capable channels. Parse VHT IEs in beacons, announce the driver's VHT capabilities in probe requests and assoc requests, and hop into 11ac mode after association to the AP if possible. Enable VHT by default if the driver announces support for it. ok claudio@
Revision 1.244 / (download) - annotate - [select for diffs], Fri Jan 28 07:11:15 2022 UTC (2 years, 4 months ago) by guenther
Branch: MAIN
Changes since 1.243: +2 -2 lines
Diff to previous 1.243 (colored)
When it's the possessive of 'it', it's spelled "its", without the apostrophe.
Revision 1.243 / (download) - annotate - [select for diffs], Fri Jan 21 15:51:03 2022 UTC (2 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.242: +20 -10 lines
Diff to previous 1.242 (colored)
Fix and re-enable active scans on iwm(4) and iwx(4). Ensure that we supply the access point's DTIM period to firmware after an active scan, as soon as the next beacon arrives. This prevents the problems which prompted us to keep active scans disabled in our drivers. Problem debugged and patch by zxystd from the OpenIntelWireless project. I made some tweaks regarding TIM parsing, which were reviewed by zxystd. Johannes Berg from Intel has confirmed to me via IRC that firmware will misbehave if running with a zero DTIM period. Tested: 8265: jca, stsp 9260: kettenis (possible fallout observed here; will keep an eye on it) 9650: stsp ax200: zxystd, kevlo, stsp ax201: stsp ok kevlo@ kettenis@
Revision 1.242 / (download) - annotate - [select for diffs], Wed Jan 12 08:29:27 2022 UTC (2 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.241: +8 -31 lines
Diff to previous 1.241 (colored)
Remove ieee80211_find_node_for_beacon(). The original purpose of ieee80211_find_node_for_beacon() was to avoid storing duplicate nodes with the same source MAC address in a hash table. Later on, our node table data structure was changed from a hash table to an RB tree. The RB tree can only store a single node per MAC address. However, find_node_for_beacon() was kept regardless, now documented to serve a different purpose. Its new purpose is to tell apart different nodes which happen to use the same MAC address and hence cannot both be stored in the RB tree. The idea is to filter such duplicate nodes out during a scan. But colliding nodes are told apart by RSSI and channel, and either may change over time. So this does not really prevent duplicate MAC addresses from causing issues. The code which decides which node is "better" can erroneously match an AP against itself, in case the AP uses a hidden SSID. This caused workarounds for hidden SSID to pile up over time. Just a bit further down, the code looks up the same node again and performs all of the intended node state updates. Simply skipping the ieee80211_find_node_for_beacon() check makes such state updates work. ok tobhe@
Revision 1.241 / (download) - annotate - [select for diffs], Wed Jan 5 05:18:25 2022 UTC (2 years, 5 months ago) by dlg
Branch: MAIN
Changes since 1.240: +4 -4 lines
Diff to previous 1.240 (colored)
rename ETHERTYPE_PAE to ETHERTYPE_EAPOL. everyone else seems to use ETHERTYPE_EAPOL, and as a bonus it also appears to be more correct. ok deraadt@ stsp@
Revision 1.240 / (download) - annotate - [select for diffs], Fri Dec 3 12:40:15 2021 UTC (2 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.239: +5 -1 lines
Diff to previous 1.239 (colored)
Ignore ADDBA requests from our AP while we are roaming away from it. Noticed while testing iwm/iwx roaming patches, where my AP would request a new Rx BA session when we had already decided to roam away. There is no need to set up a new Rx BA session with our old AP which we would have to immediately tear down again anyway.
Revision 1.239 / (download) - annotate - [select for diffs], Mon Oct 11 09:02:01 2021 UTC (2 years, 8 months ago) by stsp
Branch: MAIN
Changes since 1.238: +22 -1 lines
Diff to previous 1.238 (colored)
Monitor 20/40 MHz channel width changes in beacons sent by our access point and notify drivers when the channel width has changed.
Revision 1.238 / (download) - annotate - [select for diffs], Fri Sep 3 12:39:43 2021 UTC (2 years, 9 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE,
OPENBSD_7_0
Changes since 1.237: +3 -1 lines
Diff to previous 1.237 (colored)
Reset a net80211 node's QoS Tx sequence counter to the start of the block ack window when a new Tx block ack agreement is established. In the future this change will allow the iwx(4) driver to initialize this sequence number such that it corresponds to what the firmware expects. Note that ba->ba_winstart is set to ni->ni_qos_txseqs[tid] when a new Tx agg agreement is initiated in ieee80211_node_addba_request(). Unless the driver resets ba->ba_winstart before ieee80211_addba_resp_accept() runs, which is what iwx(4) will do, the assignment added with this patch is a no-op.
Revision 1.221.4.1 / (download) - annotate - [select for diffs], Wed May 19 22:03:35 2021 UTC (3 years ago) by bluhm
Branch: OPENBSD_6_8
Changes since 1.221: +87 -17 lines
Diff to previous 1.221 (colored) next main 1.222 (colored)
Drop fragmented 802.11 frames. Fragmented frames were never of any practical use to us anyway, given that our net80211 stack does not (yet?) re-assemble them. Counter-measure against attacks where an arbitrary packet is injected in a fragment with attacker-controlled content (via an AP which supports fragments). See https://papers.mathyvanhoef.com/usenix2021.pdf Section 6.8 "Treating fragments as full frames" ok mpi@ Prevent frame injection via forged 802.11n A-MSDUs. This mitigates an attack where a single 802.11 frame is interpreted as an A-MSDU because of a forged AMSDU-present bit in the 802.11 QoS frame header. See https://papers.mathyvanhoef.com/usenix2021.pdf section 3.2. MAC address validation is added as an additional measure to prevent hostap clients from sending A-MSDU subframes with a spoofed source address. An earlier version of this patch was reviewed by Mathy Vanhoef, who spotted a bug in my original attempt at preventing spoofed addresses. ok mpi@ Ignore trailing data in A-MSDU frame buffers if it is smaller than the Ethernet header size. Avoids spurious "input packet decapsulations failed" errors in 'netstat -W' with A-MSDU enabled (currently disabled in-tree). Problem observed and fix verified on iwm(4) 8260 by me and 7260 by tobhe. ok phessler@ tobhe@ from stsp@ this is errata/6.8/021_net80211.patch.sig
Revision 1.232.2.1 / (download) - annotate - [select for diffs], Wed May 19 21:57:31 2021 UTC (3 years ago) by bluhm
Branch: OPENBSD_6_9
Changes since 1.232: +81 -7 lines
Diff to previous 1.232 (colored) next main 1.233 (colored)
Drop fragmented 802.11 frames. Fragmented frames were never of any practical use to us anyway, given that our net80211 stack does not (yet?) re-assemble them. Counter-measure against attacks where an arbitrary packet is injected in a fragment with attacker-controlled content (via an AP which supports fragments). See https://papers.mathyvanhoef.com/usenix2021.pdf Section 6.8 "Treating fragments as full frames" ok mpi@ Prevent frame injection via forged 802.11n A-MSDUs. This mitigates an attack where a single 802.11 frame is interpreted as an A-MSDU because of a forged AMSDU-present bit in the 802.11 QoS frame header. See https://papers.mathyvanhoef.com/usenix2021.pdf section 3.2. MAC address validation is added as an additional measure to prevent hostap clients from sending A-MSDU subframes with a spoofed source address. An earlier version of this patch was reviewed by Mathy Vanhoef, who spotted a bug in my original attempt at preventing spoofed addresses. ok mpi@ from stsp@ this is errata/6.9/004_net80211.patch.sig
Revision 1.237 / (download) - annotate - [select for diffs], Tue May 18 08:10:45 2021 UTC (3 years ago) by stsp
Branch: MAIN
Changes since 1.236: +15 -1 lines
Diff to previous 1.236 (colored)
Drop fragmented 802.11 frames. Fragmented frames were never of any practical use to us anyway, given that our net80211 stack does not (yet?) re-assemble them. Counter-measure against attacks where an arbitrary packet is injected in a fragment with attacker-controlled content (via an AP which supports fragments). See https://papers.mathyvanhoef.com/usenix2021.pdf Section 6.8 "Treating fragments as full frames" ok mpi@
Revision 1.236 / (download) - annotate - [select for diffs], Mon May 17 11:44:22 2021 UTC (3 years ago) by stsp
Branch: MAIN
Changes since 1.235: +3 -1 lines
Diff to previous 1.235 (colored)
put unused 802.11 fragmentation support code under #ifdef notyet
Revision 1.235 / (download) - annotate - [select for diffs], Mon May 17 08:02:20 2021 UTC (3 years ago) by stsp
Branch: MAIN
Changes since 1.234: +67 -7 lines
Diff to previous 1.234 (colored)
Prevent frame injection via forged 802.11n A-MSDUs. This mitigates an attack where a single 802.11 frame is interpreted as an A-MSDU because of a forged AMSDU-present bit in the 802.11 QoS frame header. See https://papers.mathyvanhoef.com/usenix2021.pdf section 3.2. MAC address validation is added as an additional measure to prevent hostap clients from sending A-MSDU subframes with a spoofed source address. An earlier version of this patch was reviewed by Mathy Vanhoef, who spotted a bug in my original attempt at preventing spoofed addresses. ok mpi@
Revision 1.234 / (download) - annotate - [select for diffs], Thu Apr 29 21:43:46 2021 UTC (3 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.233: +6 -3 lines
Diff to previous 1.233 (colored)
Make iwn, iwm, and iwx keep track of beacon parameters at run-time. - HT protection settings (this was already implemented) - ERP (11g) protection setting - short slottime setting - short preamble setting - EDCA (QoS) parameters All of these parameters are communicated in beacons and hardware is now kept up-to-date with them. Prompted by a problem report from Christian Ehrhardt regarding ERP. Tested: iwn 6205: stsp, Josh Grosse iwm 7265: trondd iwm 8265: stsp, Matthias Schmidt iwm 9260: phessler iwx ax200: stsp, jmc, gnezdo
Revision 1.233 / (download) - annotate - [select for diffs], Sun Apr 25 15:32:21 2021 UTC (3 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.232: +24 -11 lines
Diff to previous 1.232 (colored)
Implement support for Rx aggregation offload in iwm(9) and iwx(4), and re-enable de-aggregation of A-MSDUs in net80211 for all drivers capable of 11n mode. This can provide improved Rx performance if the access point supports transmission of A-MSDUs nested in A-MDPUs. iwm(9) 9k and iwx(4) devices de-aggregate A-MSDUs in hardware. Neither our drivers nor the net80211 stack were prepared to handle this. Add two Rx-info flags which drivers can use to avoid having subframes which arrived in the same A-MSDU rejected as duplicates in the net80211 input layer: IEEE80211_RXI_HWDEC_SAME_PN allows the same CCMP packet number for a series of subsequent frames. IEEE80211_RXI_SAME_SEQ allows the same 802.11 frame header sequence number for a series of subsequent of frames. Handle A-MPDU reordering on iwm 9k and iwx devices, based on code from iwlwifi. Rx block ack window information is provided by firmware. So far this info was ignored by drivers and reordering of A-MPDU subframes happened twice: Once in firmware, and again in net80211. Tested: iwm 7260: bcallah, dv iwm 7265: mpi, trondd, Matthias Schmidt iwm 8260: bket, Marcus MERIGHI iwm 8265: stsp, tracey, Uwe Werler iwm 9260: phessler, matthieu iwm 9560: stsp, Uwe Werler iwx ax200: jmc, stsp iwx ax201: stsp
Revision 1.232 / (download) - annotate - [select for diffs], Fri Mar 26 10:18:55 2021 UTC (3 years, 2 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE
Branch point for: OPENBSD_6_9
Changes since 1.231: +2 -2 lines
Diff to previous 1.231 (colored)
Fix wrong sequence number wrap in ieee80211_recv_auth(). IEEE 802.11 sequence numbers wrap around at 0xfff, not 0xffff. ok phessler@ kevlo@
Revision 1.231 / (download) - annotate - [select for diffs], Tue Mar 23 12:03:44 2021 UTC (3 years, 2 months ago) by stsp
Branch: MAIN
Changes since 1.230: +5 -1 lines
Diff to previous 1.230 (colored)
Fix a corner case bug in Rx block ack window gap-wait timeout handling. If ieee80211_input_ba_flush() was called when there was nothing to flush, the (already pending) gap wait timeout was re-armed. This is only correct if we flush at least one packet. Otherwise packets that arrive at a constant rate of about 4-5 packets per second would extend the gap-wait timeout until the block ack window fills up. In extreme cases this can result in packets being queued for almost 20s. Fix this by returning immediately from ieee80211_input_ba_flush() if the first packet in the reordering buffer is missing. This prevents the timeout from being re-armed. Patch by Christian Ehrhardt. Tested by me on iwm(4) 7265.
Revision 1.230 / (download) - annotate - [select for diffs], Tue Mar 23 11:58:38 2021 UTC (3 years, 2 months ago) by stsp
Branch: MAIN
Changes since 1.229: +3 -2 lines
Diff to previous 1.229 (colored)
When moving the Rx block ack window forward do not implicitly rely on ieee80211_input_ba_flush() for updating ba->ba_winend. Required for an upcoming ieee80211_input_ba_flush() fix. Patch by Christian Ehrhardt who found one instance of this problem in ieee80211_input_ba_seq(). I spotted another in ieee80211_ba_move_window().
Revision 1.229 / (download) - annotate - [select for diffs], Wed Mar 10 10:21:48 2021 UTC (3 years, 3 months ago) by jsg
Branch: MAIN
Changes since 1.228: +3 -3 lines
Diff to previous 1.228 (colored)
spelling ok gnezdo@ semarie@ mpi@
Revision 1.228 / (download) - annotate - [select for diffs], Thu Dec 10 12:52:49 2020 UTC (3 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.227: +5 -5 lines
Diff to previous 1.227 (colored)
Fix double-free on error in ieee80211_amsdu_decap(). Bug was introduced by my previous commit to this file. ok tobhe@
Revision 1.227 / (download) - annotate - [select for diffs], Wed Dec 9 21:54:11 2020 UTC (3 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.226: +8 -12 lines
Diff to previous 1.226 (colored)
Ignore trailing data in A-MSDU frame buffers if it is smaller than the Ethernet header size. Avoids spurious "input packet decapsulations failed" errors in 'netstat -W' with A-MSDU enabled (currently disabled in-tree). Problem observed and fix verified on iwm(4) 8260 by me and 7260 by tobhe. ok phessler@ tobhe@
Revision 1.226 / (download) - annotate - [select for diffs], Wed Dec 9 15:50:58 2020 UTC (3 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.225: +4 -1 lines
Diff to previous 1.225 (colored)
Disable A-MSDU support again. iwm(4) 9k and iwx(4) need more work before AMSDU can be enabled. These devices decapsulate A-MSDU in hardware and required changes to make this work with our drivers and stack seem to be non-trivial. Problems reported by phessler@ ok phessler@
Revision 1.225 / (download) - annotate - [select for diffs], Wed Dec 9 13:24:22 2020 UTC (3 years, 6 months ago) by tobhe
Branch: MAIN
Changes since 1.224: +6 -1 lines
Diff to previous 1.224 (colored)
Flush reorder buffer after gap timeout, otherwise the frames remain in the buffer until the next frame is received. Found by and fix from Christian Ehrhardt ok stsp@
Revision 1.224 / (download) - annotate - [select for diffs], Tue Dec 8 20:17:32 2020 UTC (3 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.223: +1 -9 lines
Diff to previous 1.223 (colored)
Enable 802.11 A-MSDU support again. It was disabled some time ago but the underlying problems have since been fixed. Using A-MSDUs results in improved download speeds with APs that support them. tested by robert@
Revision 1.223 / (download) - annotate - [select for diffs], Tue Dec 8 14:40:55 2020 UTC (3 years, 6 months ago) by tobhe
Branch: MAIN
Changes since 1.222: +12 -24 lines
Diff to previous 1.222 (colored)
Fix gapwait accounting. Count all the packets in the reorder buffer. Restart the gap timeout if the buffer is not empty after we flush out some of the packets. Found by and fix from Christian Ehrhardt ok stsp@ phessler@
Revision 1.222 / (download) - annotate - [select for diffs], Tue Dec 8 10:28:22 2020 UTC (3 years, 6 months ago) by tobhe
Branch: MAIN
Changes since 1.221: +17 -2 lines
Diff to previous 1.221 (colored)
Use BA agreement immediately after it is requested by the AP. Some APs continue to send QOS packet for the same tid (with normal ack policy). Make those packets go through BA reordering to advance the sequence number counter in the BA agreement and prevent performance loss due to a gap wait later on. Found by and fix from Christian Erhardt ok stsp@ phessler@
Revision 1.221 / (download) - annotate - [select for diffs], Fri Aug 28 12:01:48 2020 UTC (3 years, 9 months ago) by mvs
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE
Branch point for: OPENBSD_6_8
Changes since 1.220: +3 -1 lines
Diff to previous 1.220 (colored)
Add missing #if's to fix build without bpf(4). ok deraadt@
Revision 1.220 / (download) - annotate - [select for diffs], Tue Jul 21 08:38:59 2020 UTC (3 years, 10 months ago) by stsp
Branch: MAIN
Changes since 1.219: +46 -19 lines
Diff to previous 1.219 (colored)
Improve processing of lost frames during 802.11 Rx aggregation. Make ieee80211_input_ba() skip one missing frame at the head of the Rx block ack (BA) window once the rest of the window has filled up with pending frames. This avoids having to wait for the BA window gap timeout handler to run in order to make progress in such situations. Simplify the BA gap timeout handler by deferring the actual flushing of the BA window buffer to the regular input path. The timeout handler now simply advances the BA window across any missing frames at the head of the window, and if_input() is no longer called from the context of this timeout handler. The window will be flushed once another frame arrives. Packet loss under streamy traffic conditions and during Rx bursts is reduced. Much less stuttering, more stable tcpbench, and easier flight in Minecraft. tested by phessler@, Martin Vahlensieck, jmc@, Uwe Werler, and myself
Revision 1.219 / (download) - annotate - [select for diffs], Mon Jul 20 07:45:44 2020 UTC (3 years, 10 months ago) by stsp
Branch: MAIN
Changes since 1.218: +2 -2 lines
Diff to previous 1.218 (colored)
The IEEE80211_F_HIDENWID flag is now part of ic_userflags, not ic_flags. Fix code which was still looking for this flag at the old location. The 'hidenwid' feature was slightly broken as a result: The SSID was leaked in probe responses to wildcard probe requests. There are other trivial ways of snooping a "hidden" SSID however so this is not a big deal. Problem reported by Mogens Jensen.
Revision 1.218 / (download) - annotate - [select for diffs], Mon Jun 1 08:51:13 2020 UTC (4 years ago) by stsp
Branch: MAIN
Changes since 1.217: +1 -6 lines
Diff to previous 1.217 (colored)
Revert "Ignore new Rxblock ack agreements until the WPA handshake is done." There are access points out there which insist on establishing a block ack agreement with the client before the WPA handshake can complete. This is sad, but we cannot operate against such APs if we require the handshake to complete first. This reverts CVS commit 4wXCjWU3qNtIX7gW. Problem reported and fix tested by Brandon Sahlin on bugs@
Revision 1.217 / (download) - annotate - [select for diffs], Tue May 26 11:45:32 2020 UTC (4 years ago) by stsp
Branch: MAIN
Changes since 1.216: +13 -7 lines
Diff to previous 1.216 (colored)
Let unencrypted 802.11 frames pass during hardware decryption post-processing. Some drivers, such as ral(4), cannot provide the IV required for a replay check because hardware strips the IV before passing the frame to the driver. Which means frames with the RXI_HWDEC flag but without the 'protected' bit set in the frame header must be passed without any further verification and without updating the last-seen packet number. All we can do is hope that these devices perform replay checking correctly. Fixes a regression where some ral(4) devices would fail to receive packets on encrypted networks. Reported and fix confirmed by Hendrik Meyburgh. ok mpi@
Revision 1.216 / (download) - annotate - [select for diffs], Fri May 15 14:21:09 2020 UTC (4 years ago) by stsp
Branch: MAIN
Changes since 1.215: +88 -2 lines
Diff to previous 1.215 (colored)
Fix CCMP replay check with 11n Rx aggregation and CCMP hardware offloading. So far, drivers using hardware CCMP decryption were expected to keep the most recently seen CCMP packet number (PN) up-to-date, and to discard frames with lower PNs as replays. A-MPDU subframes may legitimately arrive out of order, and the drivers skipped CCMP replay checking for such frames. Re-ordering happens in ieee80211_inputm(), after the driver is done with a frame. Drivers cannot tell replayed frames apart from legitimate out-of-order retransmissions. To fix this, update the PN value in ieee80211_inputm() after subframes have been reordered into their proper sequence. Drivers still perform replay checks but they no longer have to worry about updating the last seen PN value. The 802.11 spec confirms that replay checking is supposed to happen after A-MPDU re-ordering. Tested by jmc@, benno@, solene@, and myself with the following drivers: athn(4), iwn(4), iwm(4), wpi(4), urtwn(4) ok solene@
Revision 1.215 / (download) - annotate - [select for diffs], Wed Mar 11 12:39:27 2020 UTC (4 years, 3 months ago) by tobhe
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE,
OPENBSD_6_7
Changes since 1.214: +3 -2 lines
Diff to previous 1.214 (colored)
Make sure hdrlen is initialized. ok stsp@
Revision 1.214 / (download) - annotate - [select for diffs], Fri Dec 20 09:28:06 2019 UTC (4 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.213: +6 -1 lines
Diff to previous 1.213 (colored)
Ignore new Rx block ack agreements until the WPA handshake is done. Some peers will eagerly try to negotiate block ack (asking us to reserve buffer space) before they are done authenticating themselves. No thanks. Just let them try again later. ok mpi@
Revision 1.213 / (download) - annotate - [select for diffs], Fri Dec 20 09:27:00 2019 UTC (4 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.212: +4 -1 lines
Diff to previous 1.212 (colored)
Have net80211 actually update the Rx block ack sequence number window, as well as pulling frames off the Rx block ack reordering queue, when an incoming frame above the current seqnum window forces us to slide the window forward, potentially losing frames within the old window. Leaving the seqnum window out of sync with the queue would cause needlessly long stalls in traffic until the window moved again for some other reason. Problem observed on lossy wifi whenever netstat -W indicated an increasing "input block ack window slides" counter. With this fix, stalled frames can be observed only for a relatively short amount of time whenever one or more frames in the current window are lost. ok mpi@
Revision 1.212 / (download) - annotate - [select for diffs], Fri Oct 11 15:20:36 2019 UTC (4 years, 8 months ago) by patrick
Branch: MAIN
CVS Tags: OPENBSD_6_6_BASE,
OPENBSD_6_6
Changes since 1.211: +2 -2 lines
Diff to previous 1.211 (colored)
Probe responses are generally only seen after probe requests, which we only send if an SSID is already configured. Thus a scan only creates beacons. Especially on bwfm(4) only beacons frames are faked, there are no probe responses. When a node first is created, ni_rssi is 0, which is always smaller than rxi_rssi, and it wil never be set for nodes on 5 GHz. Thus we should always set ni_rssi if it is 0. Tested by jan@ tobhe@ ok stsp@ deraadt@
Revision 1.211 / (download) - annotate - [select for diffs], Sun Oct 6 16:11:17 2019 UTC (4 years, 8 months ago) by stsp
Branch: MAIN
Changes since 1.210: +2 -2 lines
Diff to previous 1.210 (colored)
Fix net80211's accounting of discarded input control frames. PS-poll and BA-req frames are in fact being processed. Do not count such frames as discarded control frames. OK phessler kn mpi
Revision 1.210 / (download) - annotate - [select for diffs], Wed Sep 25 05:51:24 2019 UTC (4 years, 8 months ago) by tobhe
Branch: MAIN
Changes since 1.209: +7 -2 lines
Diff to previous 1.209 (colored)
Update acces point channel in node list when receiving packets from same AP on a new channel. Not doing so leads to a disconnect because AP messages on the new channel are ignored.
Revision 1.209 / (download) - annotate - [select for diffs], Thu Sep 12 12:55:07 2019 UTC (4 years, 9 months ago) by stsp
Branch: MAIN
Changes since 1.208: +68 -43 lines
Diff to previous 1.208 (colored)
Make wireless drivers call if_input() only once per interrupt. This reduces drops caused by the ifq pressure drop mechanism and hence increases throughput. Such drops are visible with e.g. 'netstat -dnI iwm0'. Not all affected drivers have been tested yet but these changes are largely mechanical and should be safe. As usual, please report any regressions. With help from dlg@ and mpi@ Problem found by robert@ Tested by robert, jmc, Tracey Emer, Matthias Schmidt, florian, Björn Ketelaars ok mpi@
Revision 1.208 / (download) - annotate - [select for diffs], Thu Aug 29 09:13:56 2019 UTC (4 years, 9 months ago) by stsp
Branch: MAIN
Changes since 1.207: +3 -3 lines
Diff to previous 1.207 (colored)
Always parse RSN/WPA IEs if the driver announces support for RSN. Prevents WPA APs from appearing as non-WPA APs to the AP selection logic. The decision whether or not to parse the IE was made as a side-effect of a check for the highest mutually supported version of WPA. We can safely assume that all our drivers support WPA versions <= 2 and parse the IE regardless of whether WPA is currently active or not. ok mpi@
Revision 1.207 / (download) - annotate - [select for diffs], Mon Jul 29 10:50:08 2019 UTC (4 years, 10 months ago) by stsp
Branch: MAIN
Changes since 1.206: +71 -9 lines
Diff to previous 1.206 (colored)
Add support for 802.11n Tx aggregation to net80211 and the iwn(4) driver. In particular, add Tx block ack session management to net80211, with enough funcionality to support Tx aggregation on devices which perform A-MPDU subframe scheduling in firmware. Make use of the iwn(4) firmware Tx scheduler to build A-MPDUs. net80211's QoS support code is now enabled and used by Tx aggregation. A-MSDU frames inside A-MPDUs have been tested and work in principle. For now, this feature is disabled because unfair TCP connection sharing was observed during testing, where bursts of TCP Ack frames for a single tcpbench(1) connection arriving in A-MSDUs made other TCP connections stall. Switch off support for A-MSDUs inside A-MPDUs on the Rx side as well. Tested on iwn chipsets 1000, 4965, 5100, 5300, 2200, 6200, 6205, 6300 (committed version of tested diff has all debug printfs removed) tests/ok benno kmos mlarkin kevlo
Revision 1.206 / (download) - annotate - [select for diffs], Sun May 12 18:12:38 2019 UTC (5 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.205: +11 -4 lines
Diff to previous 1.205 (colored)
Fix 'ifconfig nwflags; These flags ended up overlapping with other flags in ieee80211com's ic_flags because we haven't been paying attention to them (they're not in the same place in the code and hence easy to miss). Move them to a dedicated variable to avoid this problem in the future. Add a new 'stayauth' nwflag which can be set to let net80211 ignore deauth frames. This can be useful when deauth frames are being persistently spoofed by an attacker. Idea from beck@ ok beck@ phessler@
Revision 1.205 / (download) - annotate - [select for diffs], Fri Mar 29 11:05:46 2019 UTC (5 years, 2 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE,
OPENBSD_6_5
Changes since 1.204: +21 -3 lines
Diff to previous 1.204 (colored)
Use stricter validation checks for A-MPDUs in the net80211 input path. Don't accept A-MPDUs if not in RUN state, and don't accept them from unassociated clients in hostap mode. ok jmatthew@ kevlo@
Revision 1.204 / (download) - annotate - [select for diffs], Fri Mar 1 08:09:00 2019 UTC (5 years, 3 months ago) by stsp
Branch: MAIN
Changes since 1.203: +4 -2 lines
Diff to previous 1.203 (colored)
Pick up the AP's 11g ERP protection setting properly in 11n client mode. ok phessler@
Revision 1.203 / (download) - annotate - [select for diffs], Tue Jan 15 10:01:46 2019 UTC (5 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.202: +8 -1 lines
Diff to previous 1.202 (colored)
Stop processing "no data" frames in ieee80211_input() before decryption. Previously such frames would be counted as decryption failures which is nonsense because they don't carry any data which could be encrypted. Problem analyzed by, and fix developed together with, Lauri Tirkkonen.
Revision 1.202 / (download) - annotate - [select for diffs], Tue Aug 7 18:13:14 2018 UTC (5 years, 10 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE,
OPENBSD_6_4
Changes since 1.201: +3 -3 lines
Diff to previous 1.201 (colored)
Ignore basic MCS set information found in association responses. Some APs (Aruba 105) send a bogus basic MCS set in assoc responses which prevents us from enabling 11n support with those APs, while these APs still behave as if were were an 11n client which renders the association unusable. The basic MSC set is already provided in beacons anyway, and the 802.11 2012 standard says the basic MSC set is reserved in frames other than beacons (see Table 8-130). ok mpi@
Revision 1.201 / (download) - annotate - [select for diffs], Sat May 5 06:58:05 2018 UTC (6 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.200: +17 -4 lines
Diff to previous 1.200 (colored)
On 5GHz channels, keep the most recent RSSI measurement from a probe response in case a lower RSSI is measured for a subsequent beacon. I have run into a 5Ghz AP which sends beacons with very low Tx power for some reason, while probe responses are transmitted with reasonable signal strength. This change ensures such 5GHz APs will be considered as a reasonable choice during access point selection. Discussed with sthen@, Patrick Dohman, and others on tech@ ok phessler@ pirofti@
Revision 1.200 / (download) - annotate - [select for diffs], Sun Apr 29 12:11:48 2018 UTC (6 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.199: +3 -2 lines
Diff to previous 1.199 (colored)
Don't bother with background scans while the desired BSSID is fixed. Patch by Jesper Wallin
Revision 1.199 / (download) - annotate - [select for diffs], Fri Apr 27 17:03:09 2018 UTC (6 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.198: +2 -2 lines
Diff to previous 1.198 (colored)
If a wifi driver does not provide an ic_bgscan_start() function there is no point in scheduling ic_bgscan_timeout() since this timeout will find that it has nothing to do. ok phessler pirofti
Revision 1.198 / (download) - annotate - [select for diffs], Tue Dec 12 15:57:11 2017 UTC (6 years, 6 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE,
OPENBSD_6_3
Changes since 1.197: +11 -9 lines
Diff to previous 1.197 (colored)
Only trigger background scans while we are in RUN state, and do not update a node's RSSI info while we are still in INIT state. ok phessler@
Revision 1.197 / (download) - annotate - [select for diffs], Fri Dec 8 21:16:01 2017 UTC (6 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.196: +29 -10 lines
Diff to previous 1.196 (colored)
Add support for background scanning to net80211 and iwm(4). The iwm(4) driver will now roam between access points which share an SSID. Use 'ifconfig iwm0 debug' and 'tail -f /var/log/messages' to watch it do so. Tested by several people in various iterations. As usual, let me know if you run into issues. ok phessler deraadt
Revision 1.196 / (download) - annotate - [select for diffs], Mon Sep 4 09:11:46 2017 UTC (6 years, 9 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_2_BASE,
OPENBSD_6_2
Changes since 1.195: +9 -1 lines
Diff to previous 1.195 (colored)
If a beacon is received in RUN state, reset the management timer. Some wifi drivers send a probe request if the hardware reports "missed beacon" events. If the AP replies with a probe response it is still servicing us and there is no need to search for a new AP. However, the management timer was not reset if a beacon was received while in RUN state. So the interface watchdog always ended up putting the driver into SCAN state after a missed beacon event, even if the AP did respond to our probe request. Under some conditions this bug would cause spurious disconnects. Problem reported and fix tested by mlarkin@ (Using the management timer in RUN state is a new convention. Before support for missed beacons was added, this timer was only used during the association sequence to handle APs which don't respond to our assoc requests and such.)
Revision 1.195 / (download) - annotate - [select for diffs], Fri Aug 4 17:31:05 2017 UTC (6 years, 10 months ago) by stsp
Branch: MAIN
Changes since 1.194: +1 -70 lines
Diff to previous 1.194 (colored)
Remove ieee80211_input_print() which printed information about received frames to dmesg, if debug mode was enabled with ifconfig. This debug output was much too verbose and not actually useful for debugging. tcpdump -y IEEE802_11_RADIO will show the same information. ok sthen@
Revision 1.194 / (download) - annotate - [select for diffs], Sun Jun 4 12:48:42 2017 UTC (7 years ago) by tb
Branch: MAIN
Changes since 1.193: +8 -5 lines
Diff to previous 1.193 (colored)
Add sizes for free for the RSN IEs. Rewrite ieee80211_save_ie() slightly to make it more readable. help, many explanations and ok stsp
Revision 1.193 / (download) - annotate - [select for diffs], Sat Jun 3 15:44:03 2017 UTC (7 years ago) by tb
Branch: MAIN
Changes since 1.192: +6 -4 lines
Diff to previous 1.192 (colored)
Add a few sizes to free(). Input, help & ok stsp
Revision 1.192 / (download) - annotate - [select for diffs], Tue May 2 11:03:48 2017 UTC (7 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.191: +19 -4 lines
Diff to previous 1.191 (colored)
Fix a problem with associating to wifi networks with a hidden SSID. If an AP is configured to hide its SSID it sends a non-zero length SSID which contains only zeroes. The AP sends its actual SSID only in probe responses after a client includes this SSID in a probe request. If we happened to receive a beacon before the probe response we stored a non-zero-length SSID of zeroes and never updated the SSID when the probe response arrived. The client was then unable to find the AP. test & ok jung@
Revision 1.191 / (download) - annotate - [select for diffs], Tue Apr 11 14:43:49 2017 UTC (7 years, 2 months ago) by dhill
Branch: MAIN
Changes since 1.190: +2 -2 lines
Diff to previous 1.190 (colored)
Partially revert previous mallocarray conversions that contain constants. The consensus is that if both operands are constant, we don't need mallocarray. Reminded by tedu@ ok deraadt@
Revision 1.190 / (download) - annotate - [select for diffs], Sun Apr 9 18:15:32 2017 UTC (7 years, 2 months ago) by dhill
Branch: MAIN
Changes since 1.189: +2 -2 lines
Diff to previous 1.189 (colored)
Convert a malloc(9) to mallocarray(9) ok deraadt@
Revision 1.189 / (download) - annotate - [select for diffs], Mon Mar 13 07:44:10 2017 UTC (7 years, 3 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE,
OPENBSD_6_1
Changes since 1.188: +49 -29 lines
Diff to previous 1.188 (colored)
Make 'ifconfig scan' show WPA information for other APs correctly while the interface operates in hostap mode. test & ok tb@
Revision 1.188 / (download) - annotate - [select for diffs], Sun Mar 12 03:13:50 2017 UTC (7 years, 3 months ago) by stsp
Branch: MAIN
Changes since 1.187: +54 -21 lines
Diff to previous 1.187 (colored)
Introduce separate fields for supported WPA protocols and AKMs in struct ieee80211_node. Pass these fields to 'ifconfig scan' instead of giving it currently configured/enabled settings. Fixes display of AP WPA capabilities in 'ifconfig scan' while the wifi interface is not configured to use WPA (my previous commit attempted to fix the same problem but didn't make it work in all cases). ok tb@
Revision 1.178.2.1 / (download) - annotate - [select for diffs], Wed Mar 1 20:57:50 2017 UTC (7 years, 3 months ago) by benno
Branch: OPENBSD_6_0
Changes since 1.178: +2 -1 lines
Diff to previous 1.178 (colored) next main 1.179 (colored)
MFC: Fix a bug allowing a man-in-the-middle attack against WPA wireless clients. A malicious AP could trick clients into connecting to the malicious AP instead of the desired AP. All frames would then be sent in the clear. This problem was found and reported by Mathy Vanhoef who also provided an initial patch which we improved together. (OpenBSD 5.9 errata 35, Mar 1, 2017) by and ok stsp@
Revision 1.168.2.1 / (download) - annotate - [select for diffs], Wed Mar 1 20:57:29 2017 UTC (7 years, 3 months ago) by benno
Branch: OPENBSD_5_9
Changes since 1.168: +2 -1 lines
Diff to previous 1.168 (colored) next main 1.169 (colored)
MFC: Fix a bug allowing a man-in-the-middle attack against WPA wireless clients. A malicious AP could trick clients into connecting to the malicious AP instead of the desired AP. All frames would then be sent in the clear. This problem was found and reported by Mathy Vanhoef who also provided an initial patch which we improved together. (OpenBSD 6.0 errata 18, Mar 1, 2017) by and ok stsp@
Revision 1.187 / (download) - annotate - [select for diffs], Wed Mar 1 19:28:48 2017 UTC (7 years, 3 months ago) by stsp
Branch: MAIN
Changes since 1.186: +2 -1 lines
Diff to previous 1.186 (colored)
Fix a bug allowing a man-in-the-middle attack against WPA wireless clients. A malicious AP could trick clients into connecting to the malicious AP instead of the desired AP. All frames would then be sent in the clear. This problem was found and reported by Mathy Vanhoef who also provided an initial patch which we improved together.
Revision 1.186 / (download) - annotate - [select for diffs], Thu Feb 2 16:47:53 2017 UTC (7 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.185: +5 -7 lines
Diff to previous 1.185 (colored)
Remove global counters from struct ieee80211com which track the number of associated nodes with particular properties: 11b-only ("non-ERP") nodes, nodes requiring long slot time, nodes using WPA, nodes not supporting 11n, nodes currently dozing in powersave state, and nodes with a pending group key update confirmation. These counters weren't properly maintained. There are bugs in the stack where these counters and actual node properties got out of sync. This is exposed by panics which are supposed to help us catch such bugs. But these panics don't provide real clues. Instead of maintaining global counters forcing us to hunt refcounting bugs, count nodes with the property in question on demand, by iterating over all nodes and checking their state. This is cheap since we'll never have more than 100 nodes cached, and none of the cases where we need such information is in a performance critical path. Prevents panics in hostap mode reported by Lauri Tirkkonen on bugs@ last year (https://marc.info/?l=openbsd-bugs&m=147513817930489&w=2) and also encountered by my 11n APs ("panic: bogus non-HT station count 0"). tested by Lauri, tb@, and myself ok mpi@ tb@
Revision 1.185 / (download) - annotate - [select for diffs], Wed Jan 25 09:23:08 2017 UTC (7 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.184: +2 -2 lines
Diff to previous 1.184 (colored)
In amsdu_decap() check the actual length of the data in the remaining mbuf chain. Else this function will sometimes signal end of AMSDU frame too early. Patch by Imre Vadasz. ok mpi@ phessler@
Revision 1.184 / (download) - annotate - [select for diffs], Mon Jan 16 09:35:06 2017 UTC (7 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.183: +14 -7 lines
Diff to previous 1.183 (colored)
Prevent wireless frame injection attack described at 33C3 in the talk titled "Predicting and Abusing WPA2/802.11 Group Keys" by Mathy Vanhoef. https://media.ccc.de/v/33c3-8195-predicting_and_abusing_wpa2_802_11_group_keys If an attacker knows the WPA group key the attacker could inject a unicast frame by sending a group-encrypted frame to the AP with addresses set as: addr1 (receiver): ff:ff:ff:ff:ff:ff addr2 (source): MAC of attacker addr3 (target): MAC of victim client The AP would forward this frame as unicast, re-encrypted with the pair-wise session key of the victim client. But an AP should not forward such frames. Guessing a WPA group key used by an OpenBSD AP is hard because our random numbers are actually random. So we are not vulnerable to this attack but we are fixing the forwarding path anyway. ok mpi@ tb@
Revision 1.183 / (download) - annotate - [select for diffs], Tue Jan 10 08:19:49 2017 UTC (7 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.182: +4 -7 lines
Diff to previous 1.182 (colored)
Make receiving A-MPDUs with an 11n-enabled athn(4) driver work by not requiring 11n wireless drivers to provide an ic_ampdu_rx_start() function. The athn(4) driver won't need this function since the hardware receives A-MPDU and sends block ack without setting up anything.
Revision 1.182 / (download) - annotate - [select for diffs], Mon Jan 9 20:18:59 2017 UTC (7 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.181: +5 -1 lines
Diff to previous 1.181 (colored)
When a HT node leaves or reassociates as a non-HT node, clear HT capabilities stored in its node cache object. A node may switch from 11n mode to 11a/b/g mode. If we don't clear HT capabilities from the cache the node will be mistaken as 11n-capable after reassociation. ok phessler@ mpi@
Revision 1.181 / (download) - annotate - [select for diffs], Mon Jan 9 12:40:00 2017 UTC (7 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.180: +3 -2 lines
Diff to previous 1.180 (colored)
Manage the HT protection setting if acting as hostap with 11n enabled. For now we flip-flop only between non-member protection and non-HT protection. Running a HT network without protection would require monitoring environmental conditions (e.g. foreign beacons) which make HT protection necessary. The ic_update_htprot driver function becomes optional because it won't be needed by all drivers. Only call it if the driver has set a function pointer. ok tb@
Revision 1.180 / (download) - annotate - [select for diffs], Wed Sep 21 12:21:27 2016 UTC (7 years, 8 months ago) by stsp
Branch: MAIN
Changes since 1.179: +60 -28 lines
Diff to previous 1.179 (colored)
When processing an ADDBA request, iwm(4) runs a task which sends a command to the firmware and waits for confirmation. This command can fail and there was no way we could recover from such an error. Allow drivers to return EBUSY from their ic_ampdu_rx_start() handler to tell the stack not to send a confirmation just yet. The stack provides functions which the driver can call to accept or refuse the request. There is no functional change yet. This just shuffles code around so drivers may insert themselves into the process. ok mpi@
Revision 1.179 / (download) - annotate - [select for diffs], Tue Sep 20 13:24:42 2016 UTC (7 years, 8 months ago) by stsp
Branch: MAIN
Changes since 1.178: +12 -2 lines
Diff to previous 1.178 (colored)
Parse the DTIM count and period advertised in beacons and store them in the node structure. This should be useful for iwm(4) in the future. ok phessler@
Revision 1.178 / (download) - annotate - [select for diffs], Wed May 18 08:15:28 2016 UTC (8 years ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE
Branch point for: OPENBSD_6_0
Changes since 1.177: +2 -2 lines
Diff to previous 1.177 (colored)
In hostap mode, don't re-use association IDs (AIDs) of nodes which are still lingering in the node cache. This could cause an AID to be assigned twice, once to a newly associated node and once to a different node in COLLECT cache state (i.e. marked for future eviction from the node cache). Drivers (e.g. rt2860) may use AIDs to keep track of nodes in firmware tables and get confused when AIDs aren't unique across the node cache. The symptom observed with rt2860 were nodes stuck at 1 Mbps Tx rate since the duplicate AID made the driver perform Tx rate (AMRR) accounting on the wrong node object. To find out if a node is associated we now check the node's cache state, rather than comparing the node's AID against zero. An AID is assigned when a node associates and it lasts until the node is eventually purged from the node cache (previously, the AID was made available for re-use when the node was placed in COLLECT state). There is no need to be stingy with AIDs since the number of possible AIDs exceeds the maximum number of nodes in the cache. Problem found by Nathanael Rensen. Fix written by Nathanael and myself. Tested by Nathanael. Comitting now to get this change tested across as many drivers as possible.
Revision 1.177 / (download) - annotate - [select for diffs], Tue May 10 06:37:15 2016 UTC (8 years, 1 month ago) by dlg
Branch: MAIN
Changes since 1.176: +7 -9 lines
Diff to previous 1.176 (colored)
make bpf_mtap callers set the M_FILDROP flag if they care about it. ok mpi@
Revision 1.176 / (download) - annotate - [select for diffs], Mon May 2 09:35:49 2016 UTC (8 years, 1 month ago) by tb
Branch: MAIN
Changes since 1.175: +2 -2 lines
Diff to previous 1.175 (colored)
Fix a corner case of 12-bit arithmetic: also increment the ba_winmiss counter if sn == 0 and ba_missedsn == 0xfff. ok stsp@
Revision 1.175 / (download) - annotate - [select for diffs], Mon May 2 08:12:42 2016 UTC (8 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.174: +2 -2 lines
Diff to previous 1.174 (colored)
IEEE 802.11 sequence numbers wrap at 12 bit. Fix a case where ieee80211_ba_input() failed to account for that. ok tb@
Revision 1.174 / (download) - annotate - [select for diffs], Thu Apr 28 15:00:27 2016 UTC (8 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.173: +47 -35 lines
Diff to previous 1.173 (colored)
Rework handling of frames which fall beyond the block ack window. tb@ discovered that we were not following the 802.11-2012 standard correctly for frames which fall within the range [winend, windend+winsize]. This could cause valid frames to be dropped because we moved the window too far ahead. with and ok tb@
Revision 1.173 / (download) - annotate - [select for diffs], Thu Apr 28 13:58:00 2016 UTC (8 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.172: +3 -1 lines
Diff to previous 1.172 (colored)
When a frame which falls into the block ack window is received, clear counters that keep track of consecutive frames falling outside the window.
Revision 1.172 / (download) - annotate - [select for diffs], Wed Apr 27 11:58:10 2016 UTC (8 years, 1 month ago) by stsp
Branch: MAIN
Changes since 1.171: +15 -4 lines
Diff to previous 1.171 (colored)
Add some stat counters for events related to 802.11n. netstat(1) needs to be recompiled to work with new kernel. ok deraadt mpi
Revision 1.171 / (download) - annotate - [select for diffs], Fri Apr 15 03:04:27 2016 UTC (8 years, 1 month ago) by dlg
Branch: MAIN
Changes since 1.170: +2 -2 lines
Diff to previous 1.170 (colored)
replace m_copym2 with m_dup_pkt tested by and ok stsp@
Revision 1.170 / (download) - annotate - [select for diffs], Tue Apr 12 14:33:27 2016 UTC (8 years, 2 months ago) by mpi
Branch: MAIN
Changes since 1.169: +3 -3 lines
Diff to previous 1.169 (colored)
Call if_enqueue() and if_start() instead of dereferencing the ifp pointers. These functions have been introduced to abstract some of the MP- safeness^Wmadness and should be use everywhere. Prodded by a comment from jsg@. ok mikeb@, stsp@
Revision 1.169 / (download) - annotate - [select for diffs], Tue Mar 22 11:37:35 2016 UTC (8 years, 2 months ago) by dlg
Branch: MAIN
Changes since 1.168: +5 -72 lines
Diff to previous 1.168 (colored)
replace ieee80211_align_mbuf with m_dup_pkt ok stsp@
Revision 1.168 / (download) - annotate - [select for diffs], Fri Feb 12 10:12:42 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE
Branch point for: OPENBSD_5_9
Changes since 1.167: +1 -4 lines
Diff to previous 1.167 (colored)
Remove superfluous assignments of 'subtype' in ieee80211_input(). Suggested by sthen@ ok tb@
Revision 1.167 / (download) - annotate - [select for diffs], Thu Feb 11 19:36:48 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.166: +2 -1 lines
Diff to previous 1.166 (colored)
In ieee80211_input(), initialize 'subtype' variable before using it. Should have been part of the QoS "no data" fix. ok tb@
Revision 1.166 / (download) - annotate - [select for diffs], Thu Feb 11 17:14:29 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.165: +4 -4 lines
Diff to previous 1.165 (colored)
Make the heuristic which catches frames with sequence numbers outside the current BlockAck window compare against the actual window size, rather than the maximum window size possible. As a result, two consecutive if-blocks now check for the same condition, so merge them.
Revision 1.165 / (download) - annotate - [select for diffs], Thu Feb 11 17:06:01 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.164: +1 -5 lines
Diff to previous 1.164 (colored)
Trim text in comment.
Revision 1.164 / (download) - annotate - [select for diffs], Thu Feb 11 16:43:40 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.163: +4 -5 lines
Diff to previous 1.163 (colored)
In ieee80211_ba_input(), compute the expression '(sn - ba->ba_winend) & 0xfff' just once, by assigning its value to the 'count' variable earlier and reusing 'count' where this expression was used. No functional change. This just results in better readability.
Revision 1.163 / (download) - annotate - [select for diffs], Thu Feb 11 16:25:15 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.162: +2 -1 lines
Diff to previous 1.162 (colored)
Don't pass QoS "no data" frames to the A-MPDU reordering logic. Such frames will cause major confusion since they don't carry a sequence number. ok mpi@ sthen@
Revision 1.162 / (download) - annotate - [select for diffs], Tue Feb 9 13:48:31 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.161: +8 -1 lines
Diff to previous 1.161 (colored)
Log frames which fall outside the BlockAack window in dmesg if the interface debug flag is set (enabled with: ifconfig iwn0 debug). Shows the frame's sequence number and the current BA window. I'm adding this for diagnosis, just in case it will be needed to make future decisions about tuning the heuristic which works around network stalls caused by such frames.
Revision 1.161 / (download) - annotate - [select for diffs], Mon Feb 8 01:00:47 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.160: +9 -9 lines
Diff to previous 1.160 (colored)
Stop requiring a BlockAck session timeout (again), and just use it if the AP is asking for it. This timeout should not be required anymore now that krw@'s hangs are fixed by working around APs which make sequence numbers jump about.
Revision 1.160 / (download) - annotate - [select for diffs], Mon Feb 8 00:54:57 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.159: +32 -1 lines
Diff to previous 1.159 (colored)
Work around buggy APs which occasionally emit sequence numbers much higher than the current 11n BlockAck window. The previous code would be fooled into moving the window forward and then drop packets until their sequence numbers catch up with the new window, which can take several minutes. Fixes traffic stalls observed with Broadcom APs. ok krw@ tb@
Revision 1.159 / (download) - annotate - [select for diffs], Sun Feb 7 23:36:43 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.158: +3 -3 lines
Diff to previous 1.158 (colored)
Hide some excessive net80211 debug printfs behind ieee80211_debug >= 2.
Revision 1.158 / (download) - annotate - [select for diffs], Fri Feb 5 19:42:04 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.157: +2 -2 lines
Diff to previous 1.157 (colored)
Count A-MPDU subframes with sequence number below the current BA window as duplicates rather than input errors. These subframes have either already been received, or the window was moved by the gap timeout which should only happen with buggy APs. Neither condition indicates a severe problem. Perhaps we will introduce a separate counter for this later.
Revision 1.157 / (download) - annotate - [select for diffs], Fri Feb 5 16:07:57 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.156: +4 -1 lines
Diff to previous 1.156 (colored)
Store ADDBA request and response parameters in the block ack record of ieee80211_node. This way, we can keep track of the ACK policy and echo it back to the AP as required by the standard. And use the correct bit flag for the policy -- this code was confused between BlockAck and ADDBA, both of which have a policy bit but in different places. Fixes apple airport APs. tested by tb@, krw@, sthen@, abieber@, and Henrik Friedrichsen
Revision 1.156 / (download) - annotate - [select for diffs], Thu Feb 4 16:23:40 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.155: +9 -9 lines
Diff to previous 1.155 (colored)
Restore the BlockAck session timer. It is still required to work around stalled BA sessions observed with iwn(4). We can revisit this later once the underlying problem in iwn(4) has been found. Prompted by report from krw@, I could reproduce the issue. ok krw@
Revision 1.155 / (download) - annotate - [select for diffs], Mon Feb 1 18:43:22 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.154: +9 -9 lines
Diff to previous 1.154 (colored)
Stop requiring a BlockAck session timeout. We still honour the timeout if the AP requests it, though I don't think I've ever seen one that does. Per the 802.11-2012 spec a value of zero disables the timeout and some APs seem to have trouble with timeouts forced onto them. Our behaviour now matches Linux in this regard. This gets Apple Airport APs somewhat working in 11n mode but there is still a remaining issue with receiving frames from them. Doesn't seem to hurt any other APs I've tried. ok sthen@ mpi@ millert@
Revision 1.154 / (download) - annotate - [select for diffs], Mon Jan 25 15:14:22 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.153: +4 -2 lines
Diff to previous 1.153 (colored)
Honour ERP protection on 2 GHz channels in 11n mode, as done for 11g. ok millert@
Revision 1.153 / (download) - annotate - [select for diffs], Mon Jan 25 15:10:37 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.152: +4 -4 lines
Diff to previous 1.152 (colored)
Don't try to interpret htprot data if the last beacon didn't contain such data. ok mpi@ millert@
Revision 1.152 / (download) - annotate - [select for diffs], Mon Jan 25 11:27:11 2016 UTC (8 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.151: +23 -7 lines
Diff to previous 1.151 (colored)
Keep track of HT protection settings in beacons and have 11n-capable drivers update hardware configuration accordingly. tested by myself, tb@, deraadt@, abieber@ ok mpi@
Revision 1.151 / (download) - annotate - [select for diffs], Thu Jan 7 23:22:31 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.150: +59 -15 lines
Diff to previous 1.150 (colored)
Make the A-MPDU reordering buffer more resilient against APs which drop some subframes or let the sequence number jump up by more than 1 (hard to tell which it is). We decrease the BA inactivity timeout for quicker recovery from stalled BA sessions, and add a new timeout which keeps track of gaps in the subframe sequence number space due to dropped frames. Gaps expire after 500 msec, the same value FreeBSD uses for their implementation of this workaround. And Linux uses this trick, too. This should fix network stalls some people have been seeing in 11n mode. ok deraadt@
Revision 1.150 / (download) - annotate - [select for diffs], Tue Jan 5 18:41:16 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.149: +1 -41 lines
Diff to previous 1.149 (colored)
Remove the IEEE80211_NO_HT macro. Reduces ifdef spaghetti, enables 11n mode in bsd.rd, and might uncover some bugs. Suggested by tedu@ and deraadt@. ok sthen@ jasper@ deraadt@
Revision 1.149 / (download) - annotate - [select for diffs], Mon Jan 4 13:29:31 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.148: +5 -3 lines
Diff to previous 1.148 (colored)
Replace magic shifts and bitmasks used for ADDBA parameters with proper names, now that we have the corresponding macros.
Revision 1.148 / (download) - annotate - [select for diffs], Mon Jan 4 12:32:06 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.147: +2 -2 lines
Diff to previous 1.147 (colored)
ADDBA frames have a parameter set which we check against our own capabilities but we were checking bits in these parameters with the wrong set of bitmasks. Negotiating A-MPDUs with some APs failed because of this bug. ok kettenis@
Revision 1.147 / (download) - annotate - [select for diffs], Mon Jan 4 12:25:46 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.146: +2 -3 lines
Diff to previous 1.146 (colored)
Don't return 11n mode from ieee80211_chan2mode() so we can switch into 11a and 11b/g mode correctly when the driver supports 11n. And make sure the result of this funtion is only used to index ic_sup_rates. Its stated purpose is to help select a legacy rate. ok sthen jasper kettenis deraadt mpi
Revision 1.146 / (download) - annotate - [select for diffs], Mon Jan 4 12:25:00 2016 UTC (8 years, 5 months ago) by stsp
Branch: MAIN
Changes since 1.145: +10 -17 lines
Diff to previous 1.145 (colored)
While configuring ERP we need to know if we're in 11a or 11g mode so only configure ERP once we are sure about our operation mode against the AP. ok sthen jasper kettenis deraadt mpi
Revision 1.145 / (download) - annotate - [select for diffs], Sat Dec 12 13:56:10 2015 UTC (8 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.144: +12 -1 lines
Diff to previous 1.144 (colored)
In the A-MSDU receive code path, add an upper bounds check on A-MSDU subframe length and a clean exit at the bottom of the subframe loop. ok mpi@
Revision 1.144 / (download) - annotate - [select for diffs], Sat Dec 12 12:22:14 2015 UTC (8 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.143: +8 -5 lines
Diff to previous 1.143 (colored)
Flag AP as QoS capable when EDCA or WME information elements occur in beacons or probe responses. Makes 11n negotiation with Linux iwlwifi AP succeed. ok mpi@
Revision 1.143 / (download) - annotate - [select for diffs], Sat Dec 12 11:25:46 2015 UTC (8 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.142: +40 -23 lines
Diff to previous 1.142 (colored)
Finish support for receiving 11n A-MPDUs. The initial implementation was added by damien@ years ago. Summary of the changes made in this commit: - In ieee80211_input(), process A-MPDUs before duplicate detection. - Don't forget to set ba->ba_ni in ieee80211_recv_addba_req() so we don't crash in ieee80211_rx_ba_timeout(). - In ieee80211_recv_addba_req(), tweak the logic to deny BlockAck requests if the driver has no callback for doing so. - Implement ieee80211_ba_del() which cleans up BlockAck state. - Increase the minimum and maximum lifetime for BlockAck agrements. ok mpi@
Revision 1.142 / (download) - annotate - [select for diffs], Sun Nov 15 11:14:17 2015 UTC (8 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.141: +27 -1 lines
Diff to previous 1.141 (colored)
Parse 11n HT capabilities and operational info from association response frames, negotiate HT with the AP, and move the interface into or out of 11n mode accordingly. If running as AP negotiate HT with nodes joining the BSS. ok deraadt mpi kettenis guenther
Revision 1.141 / (download) - annotate - [select for diffs], Sun Nov 15 10:07:03 2015 UTC (8 years, 6 months ago) by stsp
Branch: MAIN
Changes since 1.140: +15 -2 lines
Diff to previous 1.140 (colored)
Extend struct ieee80211_node with fields for 11n STA HT capabilities and HT operational information sent by 11n APs. These fields reflect the structure of elements in management frames so that IEEE80211_HTCAP* and IEEE80211_HTOP* macros designed to operate on frame elements can be used directly to read or set the fields. Populate nodes with HT information received in probe responses, probe requests, and association requests. ok deraadt mpi phessler kettenis guenther
Revision 1.132.2.1 / (download) - annotate - [select for diffs], Mon Nov 9 18:48:34 2015 UTC (8 years, 7 months ago) by stsp
Branch: OPENBSD_5_7
Changes since 1.132: +6 -2 lines
Diff to previous 1.132 (colored) next main 1.133 (colored)
Merge 'Handle additional RSN element group ciphers' fix to 5.7-stable.
Revision 1.137.4.1 / (download) - annotate - [select for diffs], Mon Nov 9 18:48:11 2015 UTC (8 years, 7 months ago) by stsp
Branch: OPENBSD_5_8
Changes since 1.137: +6 -2 lines
Diff to previous 1.137 (colored) next main 1.138 (colored)
Merge 'Handle additional RSN element group ciphers' fix to 5.8-stable.
Revision 1.140 / (download) - annotate - [select for diffs], Sun Nov 8 18:51:47 2015 UTC (8 years, 7 months ago) by stsp
Branch: MAIN
Changes since 1.139: +6 -2 lines
Diff to previous 1.139 (colored)
Handle additional RSN element group ciphers. ok mpi@
Revision 1.139 / (download) - annotate - [select for diffs], Sun Nov 8 18:48:07 2015 UTC (8 years, 7 months ago) by stsp
Branch: MAIN
Changes since 1.138: +3 -3 lines
Diff to previous 1.138 (colored)
Update section and table numbers inside comments in the RSN code to the 802.11-2012 standard. ok mpi@
Revision 1.138 / (download) - annotate - [select for diffs], Wed Nov 4 12:12:00 2015 UTC (8 years, 7 months ago) by dlg
Branch: MAIN
Changes since 1.137: +8 -8 lines
Diff to previous 1.137 (colored)
replace the ifqueues in net80211 with mbuf_queues. the specific queues are ic_mgtq, ic_pwrsaveq, and ni_savedq. rtw had its own queue for beacons. tested by mpi@ and jmc@ ok mpi@
Revision 1.137 / (download) - annotate - [select for diffs], Wed Jul 15 22:16:42 2015 UTC (8 years, 10 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE
Branch point for: OPENBSD_5_8
Changes since 1.136: +3 -5 lines
Diff to previous 1.136 (colored)
m_freem() can handle NULL, do not check for this condition beforehands. ok stsp mpi
Revision 1.136 / (download) - annotate - [select for diffs], Tue Jun 30 13:54:42 2015 UTC (8 years, 11 months ago) by mpi
Branch: MAIN
Changes since 1.135: +2 -2 lines
Diff to previous 1.135 (colored)
Rename if_output() into if_enqueue() to avoid confusion with comments talking about (*ifp->if_output)(). ok claudio@, dlg@
Revision 1.135 / (download) - annotate - [select for diffs], Wed Jun 24 09:40:54 2015 UTC (8 years, 11 months ago) by mpi
Branch: MAIN
Changes since 1.134: +2 -2 lines
Diff to previous 1.134 (colored)
Increment if_ipackets in if_input(). Note that pseudo-drivers not using if_input() are not affected by this conversion. ok mikeb@, kettenis@, claudio@, dlg@
Revision 1.134 / (download) - annotate - [select for diffs], Tue May 26 15:34:00 2015 UTC (9 years ago) by mpi
Branch: MAIN
Changes since 1.133: +3 -12 lines
Diff to previous 1.133 (colored)
Use if_output() instead of rerolling it. ok stsp@
Revision 1.133 / (download) - annotate - [select for diffs], Sat Mar 14 03:38:51 2015 UTC (9 years, 3 months ago) by jsg
Branch: MAIN
Changes since 1.132: +1 -2 lines
Diff to previous 1.132 (colored)
Remove some includes include-what-you-use claims don't have any direct symbols used. Tested for indirect use by compiling amd64/i386/sparc64 kernels. ok tedu@ deraadt@
Revision 1.132 / (download) - annotate - [select for diffs], Mon Feb 9 03:09:57 2015 UTC (9 years, 4 months ago) by dlg
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE
Branch point for: OPENBSD_5_7
Changes since 1.131: +6 -3 lines
Diff to previous 1.131 (colored)
tweak the new if_input function so it takes an mbuf_list instead of a single mbuf. this forces us to batch work between the hardware rx handlers and the stack. this includes a converstion of bge from ether_input to if_input. ok claudio@ pelikan@ mpi@
Revision 1.131 / (download) - annotate - [select for diffs], Sun Feb 8 06:03:07 2015 UTC (9 years, 4 months ago) by mpi
Branch: MAIN
Changes since 1.130: +11 -11 lines
Diff to previous 1.130 (colored)
Convert wirless devices to if_input(), tested with iwn(4) and urtwn(4). ok pelikan@, reyk@, blambert@, henning@
Revision 1.130 / (download) - annotate - [select for diffs], Tue Jan 27 03:17:36 2015 UTC (9 years, 4 months ago) by dlg
Branch: MAIN
Changes since 1.129: +4 -4 lines
Diff to previous 1.129 (colored)
remove the second void * argument on tasks. when workqs were introduced, we provided a second argument so you could pass a thing and some context to work on it in. there were very few things that took advantage of the second argument, so when i introduced pools i suggested removing it. since tasks were meant to replace workqs, it was requested that we keep the second argument to make porting from workqs to tasks easier. now that workqs are gone, i had a look at the use of the second argument again and found only one good use of it (vdsp(4) on sparc64 if you're interested) and a tiny handful of questionable uses. the vast majority of tasks only used a single argument. i have since modified all tasks that used two args to only use one, so now we can remove the second argument. so this is a mechanical change. all tasks only passed NULL as their second argument, so we can just remove it. ok krw@
Revision 1.129 / (download) - annotate - [select for diffs], Tue Jan 13 23:16:59 2015 UTC (9 years, 4 months ago) by stsp
Branch: MAIN
Changes since 1.128: +3 -12 lines
Diff to previous 1.128 (colored)
In IBSS mode, stop calling the driver's newassoc() each time a probe response is received from a node. Only call it once when the node is initially discovered, as used to be the case before r1.4 of this file. Asking the driver to set up its per-node private state once is enough. Also remove an outdated comment. ok sthen deraadt jsg
Revision 1.128 / (download) - annotate - [select for diffs], Tue Dec 23 03:24:08 2014 UTC (9 years, 5 months ago) by tedu
Branch: MAIN
Changes since 1.127: +1 -3 lines
Diff to previous 1.127 (colored)
unifdef some more INET. v4 4life.
Revision 1.127 / (download) - annotate - [select for diffs], Sun Sep 14 14:17:26 2014 UTC (9 years, 8 months ago) by jsg
Branch: MAIN
Changes since 1.126: +1 -2 lines
Diff to previous 1.126 (colored)
remove uneeded proc.h includes ok mpi@ kspillner@
Revision 1.126 / (download) - annotate - [select for diffs], Sat Jul 12 18:44:22 2014 UTC (9 years, 11 months ago) by tedu
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE,
OPENBSD_5_6
Changes since 1.125: +5 -5 lines
Diff to previous 1.125 (colored)
add a size argument to free. will be used soon, but for now default to 0. after discussions with beck deraadt kettenis.
Revision 1.125 / (download) - annotate - [select for diffs], Fri Jul 11 08:19:40 2014 UTC (9 years, 11 months ago) by blambert
Branch: MAIN
Changes since 1.124: +16 -13 lines
Diff to previous 1.124 (colored)
move ieee80211 message printing from workq to taskq testing stsp@ ok stsp@, dlg@
Revision 1.124 / (download) - annotate - [select for diffs], Thu Jul 10 14:32:28 2014 UTC (9 years, 11 months ago) by stsp
Branch: MAIN
Changes since 1.123: +5 -6 lines
Diff to previous 1.123 (colored)
Return RSN (WPA) information to userland during wireless scan, and make ifconfig show whether a wireless network uses WEP or WPA. Since struct ieee80211_nodereq grows in size old ifconfig won't be able to scan when running on a new kernel. While here, add missing ioctl constant IEEE80211_WPA_CIPHER_BIP. ok jsg@
Revision 1.123 / (download) - annotate - [select for diffs], Tue Jun 11 18:15:53 2013 UTC (11 years ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE,
OPENBSD_5_5,
OPENBSD_5_4_BASE,
OPENBSD_5_4
Changes since 1.122: +2 -2 lines
Diff to previous 1.122 (colored)
Replace all ovbcopy with memmove; swap the src and dst arguments too ok otto
Revision 1.122 / (download) - annotate - [select for diffs], Fri Oct 12 19:53:24 2012 UTC (11 years, 8 months ago) by haesbaert
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE,
OPENBSD_5_3
Changes since 1.121: +4 -1 lines
Diff to previous 1.121 (colored)
Cleanup false positives for uninitialized uses. Part of the work to remove -Wno-uninitialized. ok blambert jsg
Revision 1.121 / (download) - annotate - [select for diffs], Mon Jul 16 14:51:31 2012 UTC (11 years, 10 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE,
OPENBSD_5_2
Changes since 1.120: +10 -4 lines
Diff to previous 1.120 (colored)
Fix a couple of possible node leaks in ieee80211_input().
Revision 1.120 / (download) - annotate - [select for diffs], Fri Jul 13 11:25:04 2012 UTC (11 years, 11 months ago) by stsp
Branch: MAIN
Changes since 1.119: +69 -32 lines
Diff to previous 1.119 (colored)
Fix wireless scanning on slow systems with a high RX rate and interface in debug mode. If the interface is in debug mode ieee80211_input() will print messages about received frames to the console. On slow systems, printf() calls can take so long that the next RX interrupt will be serviced immediately, if the RX rate is sufficiently high. This effectively locks the system at IPL_NET. If a concurrent scan is running, the scan will never finish because it relies on a timeout at IPL_SOFTCLOCK to hop channels every 200msec. This timeout never runs in the above situation, leaving the wireless interface in 'scan' state forever. To give the timeout a chance to run, perform the printf() call from a work queue (idea from guenther@). This allows edd's slow soekris AP to recover from 'ifconfig ral0 debug down up' in noisy RF environments. With input from guenther, kettenis, blambert and deraadt. ok deraadt
Revision 1.119 / (download) - annotate - [select for diffs], Tue Apr 5 11:48:28 2011 UTC (13 years, 2 months ago) by blambert
Branch: MAIN
CVS Tags: OPENBSD_5_1_BASE,
OPENBSD_5_1,
OPENBSD_5_0_BASE,
OPENBSD_5_0
Changes since 1.118: +4 -2 lines
Diff to previous 1.118 (colored)
Passing M_WAITOK to mbuf functions is supposed to be a contract between the caller and the function that the function will not fail to allocate memory and return a NULL pointer. However, m_dup_pkthdr() violates this contract, making it possible for functions that pass M_WAITOK to be surprised in ways that hurt. Fix this by passing the wait flag all the way down the functions that actually do the allocation for m_dup_pkthdr() so that we won't be surprised. man page update forthcoming ok claudio@
Revision 1.118 / (download) - annotate - [select for diffs], Fri Mar 4 23:48:15 2011 UTC (13 years, 3 months ago) by fgsch
Branch: MAIN
Changes since 1.117: +1 -12 lines
Diff to previous 1.117 (colored)
kill is_rx_elem_unknown. damien@ ok. ports checked by sthen@.
Revision 1.117 / (download) - annotate - [select for diffs], Mon Feb 21 20:00:12 2011 UTC (13 years, 3 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE,
OPENBSD_4_9
Changes since 1.116: +2 -2 lines
Diff to previous 1.116 (colored)
When bridging multicast frames in hostap mode, make a deep copy of the mbuf instead of a shallow copy to avoid problems if the mbuf is modified later (e.g. if the frame is encrypted). From FreeBSD. http://marc.info/?l=freebsd-current&m=114168135819304&w=2 http://svn.freebsd.org/viewvc/base?view=revision&revision=156367 ok damien; committing with miod's permission (src is soft-locked)
Revision 1.116 / (download) - annotate - [select for diffs], Mon Jun 7 16:51:22 2010 UTC (14 years ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE,
OPENBSD_4_8
Changes since 1.115: +1 -2 lines
Diff to previous 1.115 (colored)
no need to include <sys/endian.h> twice!
Revision 1.115 / (download) - annotate - [select for diffs], Mon Jun 7 16:46:17 2010 UTC (14 years ago) by damien
Branch: MAIN
Changes since 1.114: +30 -28 lines
Diff to previous 1.114 (colored)
tweak ieee80211_decap(): instead of copying the 802.11 header on the stack and building the ethernet header directly in the mbuf, build the ethernet header on the stack directly from the 802.11 header in the mbuf and copy the ethernet header to the mbuf after stripping the 802.11 header. makes the code easier to read/understand, especially, it is now explicit what is being put in the ether_type field. diff from Matthew Dempsky (matthew at dempsky dot org) moved ieee80211_align_mbuf() under #ifdef __STRICT_ALIGNMENT while i'm here.
Revision 1.114 / (download) - annotate - [select for diffs], Sat Jun 5 13:13:43 2010 UTC (14 years ago) by damien
Branch: MAIN
Changes since 1.113: +3 -3 lines
Diff to previous 1.113 (colored)
there is no need to copy the full 802.11 header in ieee80211_decap() as we do not use any field after i_addr4. slightly modified version of a diff from Matthew Dempsky (matthew at dempsky dot org), used MIN instead of min.
Revision 1.113 / (download) - annotate - [select for diffs], Thu Feb 25 17:49:16 2010 UTC (14 years, 3 months ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE,
OPENBSD_4_7
Changes since 1.112: +7 -7 lines
Diff to previous 1.112 (colored)
fix two comments that i forgot when the SA query transaction identifier changed from 16 bytes to 2 bytes. no binary change
Revision 1.112 / (download) - annotate - [select for diffs], Sun Sep 13 14:42:52 2009 UTC (14 years, 9 months ago) by krw
Branch: MAIN
Changes since 1.111: +6 -2 lines
Diff to previous 1.111 (colored)
M_DUP_PKTHDR() define -> m_dup_pkthdr() function to properly deal with m_tag_copy_chain() failures. Use m_defrag() to eliminate hand rolled defragging of mbufs and some uses of M_DUP_PKTHDR(). Original diff from thib@, claudio@'s feedback integrated by me. Tests kevlo@ claudio@, "reads ok" blambert@ ok thib@ claudio@, "m_defrag() bits ok" kettenis@
Revision 1.111 / (download) - annotate - [select for diffs], Thu Mar 26 20:34:54 2009 UTC (15 years, 2 months ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE,
OPENBSD_4_6
Changes since 1.110: +5 -5 lines
Diff to previous 1.110 (colored)
sync with 802.11w draft 8.0. the SA Query Transaction Identifier field is now a 16-bit non-negative counter value instead of a 128-bit random value.
Revision 1.110 / (download) - annotate - [select for diffs], Fri Mar 6 18:35:02 2009 UTC (15 years, 3 months ago) by damien
Branch: MAIN
Changes since 1.109: +2 -2 lines
Diff to previous 1.109 (colored)
Fix setting of the Short Slot Time subfield of the Capability Information field in (Re)Association Requests. This fixes association with APs refusing non-short-slot-time capable STAs. This should also prevent the AP we're associating with to disable the use of short slot time in the BSS as we join. Fix debug message in recv_assoc_resp() while I'm here (s/reason/status/). Scary. Thanks to Adam Emanuel for spotting this.
Revision 1.109 / (download) - annotate - [select for diffs], Sun Feb 8 15:34:39 2009 UTC (15 years, 4 months ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE,
OPENBSD_4_5
Changes since 1.108: +94 -1 lines
Diff to previous 1.108 (colored)
initial 802.11 defragmentation bits. the code will allow the concurrent reception of fragments of three fragmented MSDUs or MMPDUs as required by the 802.11 standard.
Revision 1.108 / (download) - annotate - [select for diffs], Wed Jan 28 18:55:18 2009 UTC (15 years, 4 months ago) by damien
Branch: MAIN
Changes since 1.107: +90 -74 lines
Diff to previous 1.107 (colored)
Block Ack agreements are unidirectional. Maintain state for both originator and recipient roles separately. Do not allocate receive reordering buffer in addba_request(). Test the "initiator" bit in incoming DELBA frames and set it appropriately in outgoing DELBA frames. Separate callbacks for Tx/Rx too. no binary change since all this is #ifdef'ed out.
Revision 1.107 / (download) - annotate - [select for diffs], Mon Jan 26 19:09:41 2009 UTC (15 years, 4 months ago) by damien
Branch: MAIN
Changes since 1.106: +878 -149 lines
Diff to previous 1.106 (colored)
Add some initial HT bits (not enabled yet) based on 802.11n Draft 7.01: - implement A-MPDU frames buffering and reordering - implement A-MSDU decapsulation - process/send ADDBA Request, ADDBA Response and DELBA action frames - process Block Ack Request control frames (including MTBAR) - implement PBAC support (Protected Block Ack) - add some incomplete HT Capabilities and HT Operation IEs parsing Add more Management Frame Protection bits based on 802.11w Draft 7.0: - implement SA Query procedure (both AP and STA) - cleanup BIP Fix some bugs: - fix check for WEP key length that otherwise caused a stack smash in ieee80211_wep_encrypt (pointed out by Xavier Santolaria on macppc) - properly stop EAPOL timeout: fixes a panic that occured in HostAP mode when turning the interface down while a 4-way handshake is in progress (pointed out by Doughertys) Did some code cleanup too. The HT bits are currently not compiled in (IEEE80211_NO_HT is defined) because they won't be ready until after the next release and I didn't want to grow the kernel or to inadvertently introduce new bugs. They are here such that other people can look at the code. Notice that I had to add an extra parameter to ic_send_mgmt() for action frames, that is why there are small changes in drivers defining their own ic_send_mgmt() handler. Sorry for the not very incremental diff but this has been sitting in my tree for too long now.
Revision 1.106 / (download) - annotate - [select for diffs], Sat Sep 27 15:16:09 2008 UTC (15 years, 8 months ago) by damien
Branch: MAIN
Changes since 1.105: +27 -8 lines
Diff to previous 1.105 (colored)
Initial implementation of PMKSA caching and pre-authentication. This will be required for future WPA-Enterprise support (802.1X). Add ieee80211_needs_auth() function (not implemented yet) to notify the userland 802.1X PACP machine when an 802.1X port becomes enabled (that is after successfull 802.11 Open System authentication). Add SIOCS80211KEYRUN and SIOCS80211KEYAVAIL ioctls so that the PACP state machine can kick the 802.11 key state machine and install PMKs obtained from 802.1X (pre-)authentication. Enable SHA-256 based AKMPs by default while I'm here (TGw). This uses SHA-256 for key-derivation (instead of SHA1), AES-128-CMAC for data integrity, and AES Key Wrap for data protection of EAPOL-Key frames. An OpenBSD AP will always advertise this capability and an OpenBSD STA will always prefer SHA-256 based AKMPs over SHA1 based ones if both are supported by an AP.
Revision 1.105 / (download) - annotate - [select for diffs], Sat Sep 27 15:00:08 2008 UTC (15 years, 8 months ago) by damien
Branch: MAIN
Changes since 1.104: +15 -30 lines
Diff to previous 1.104 (colored)
Add some inline functions to test the presence of optional 802.11 header fields (Sequence Control, Address 4, QoS Control, +HTC) and use them where appropriate. Add ieee80211_get_qos() inline function to extract the QoS control field of an 802.11 header instead of duplicating the same scary code everywhere (the location of this field depends on the presence of an Address 4 field). Export ieee80211_up_to_ac() so that drivers can select the access category to use based on the TID subfield of the QoS Control field. Define more QoS-related bits for the RSN Capabilities field of RSN IE (will be used later).
Revision 1.104 / (download) - annotate - [select for diffs], Mon Sep 1 19:41:10 2008 UTC (15 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.103: +5 -5 lines
Diff to previous 1.103 (colored)
rework previously unused ieee80211_pwrsave() function, call it from ieee80211_mgmt_output() and ieee80211_encap(). use new IEEE80211_C_APPMGT capability flag where appropriate. rename ic_tim_mcast to ic_tim_mcast_pending.
Revision 1.103 / (download) - annotate - [select for diffs], Fri Aug 29 12:14:53 2008 UTC (15 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.102: +4 -27 lines
Diff to previous 1.102 (colored)
move code to support Frequency-Hopping spread spectrum (FHSS) PHYs to the Attic. nothing uses it in the tree and it is very unlikely that something will use it one day. the only driver supporting FHSS PHYs in the tree is ray(4) and it does not use net80211.
Revision 1.102 / (download) - annotate - [select for diffs], Thu Aug 28 17:56:24 2008 UTC (15 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.101: +2 -2 lines
Diff to previous 1.101 (colored)
unbreak IEEE80211_DEBUG
Revision 1.101 / (download) - annotate - [select for diffs], Wed Aug 27 09:05:04 2008 UTC (15 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.100: +53 -12 lines
Diff to previous 1.100 (colored)
introduce new IEEE80211_STA_ONLY kernel option that can be set to remove IBSS and HostAP support from net80211 and 802.11 drivers. it can be used to shrink RAMDISK kernels for instance (like what was done for wi(4)). it also has the benefit of highlighting what is specific to IBSS and HostAP modes in the code. the cost is that we now have two code paths to maintain.
Revision 1.100 / (download) - annotate - [select for diffs], Thu Aug 14 16:07:58 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.99: +84 -75 lines
Diff to previous 1.99 (colored)
move the HostAP bridge code and the delivery of data frames to ether_input to a separate ieee80211_deliver_data() function. this will later be called by the A-MSDU deaggregation routine.
Revision 1.99 / (download) - annotate - [select for diffs], Thu Aug 14 16:02:23 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.98: +2 -1 lines
Diff to previous 1.98 (colored)
in ieee80211_input(), call if_start() after enqueuing frames in if_snd when acting as an access point instead of having each driver doing the job. tested by krw@ (ral AP) and me with several drivers.
Revision 1.98 / (download) - annotate - [select for diffs], Wed Aug 13 17:44:45 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.97: +14 -14 lines
Diff to previous 1.97 (colored)
one should never use sizeof(struct llc) since 802.2 LLC headers have a variable length. use LLC_SNAPFRAMELEN instead (which happen to be equal to sizeof(struct llc)) as we only deal with LLC+SNAP headers. some indentation tweaks while i'm here. no binary change.
Revision 1.97 / (download) - annotate - [select for diffs], Tue Aug 12 20:07:13 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.96: +5 -1 lines
Diff to previous 1.96 (colored)
adopt the integrity group cipher of the AP at association time.
Revision 1.96 / (download) - annotate - [select for diffs], Tue Aug 12 19:56:59 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.95: +25 -1 lines
Diff to previous 1.95 (colored)
add the code to encrypt/decrypt management frames, retrieve key id from MMIE etc... this code can't be triggered as no drivers claim MFP capability yet.
Revision 1.95 / (download) - annotate - [select for diffs], Tue Aug 12 19:50:39 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.94: +4 -2 lines
Diff to previous 1.94 (colored)
clear Tx_Rx protection bits properly.
Revision 1.94 / (download) - annotate - [select for diffs], Tue Aug 12 19:45:22 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.93: +5 -5 lines
Diff to previous 1.93 (colored)
do not drop frames that have an invalid IE, just stop processing more IEs.
Revision 1.93 / (download) - annotate - [select for diffs], Tue Aug 12 19:42:37 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.92: +53 -2 lines
Diff to previous 1.92 (colored)
populate ieee80211_recv_action(), does nothing yet.
Revision 1.92 / (download) - annotate - [select for diffs], Tue Aug 12 19:29:07 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.91: +20 -6 lines
Diff to previous 1.91 (colored)
new SHA-256 based AKMPs.
Revision 1.91 / (download) - annotate - [select for diffs], Tue Aug 12 19:21:04 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.90: +53 -10 lines
Diff to previous 1.90 (colored)
add/process group integrity cipher suite in RSN IEs. add support for MFP negotiation during association.
Revision 1.90 / (download) - annotate - [select for diffs], Tue Aug 12 17:53:13 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.89: +4 -5 lines
Diff to previous 1.89 (colored)
Change the way we process EAPOL-Key frames. Free the mbuf in the ieee80211_eapol_key_input() function. Do not assume the frame is contiguous, call m_pullup2() if it is not. We need the frame to be contiguous to process KDEs efficiently in EAPOL-Key frames (just like we process IEs in management frames). However, there are drivers like upgt(4) that use m_devget() in the RX path. m_devget() can return fragmented mbuf chains. Notice that we should do the same m_pullup2() for management frames. This will be done later. Remove the ic_recv_eapol callback.
Revision 1.89 / (download) - annotate - [select for diffs], Sat Aug 2 08:35:48 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE,
OPENBSD_4_4
Changes since 1.88: +3 -3 lines
Diff to previous 1.88 (colored)
do not use IEEE80211_QOS_TID. its definition in ieee80211.h is wrong. hard-code 0xf for now. will be fixed post-release.
Revision 1.88 / (download) - annotate - [select for diffs], Sat Aug 2 08:20:16 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.87: +20 -10 lines
Diff to previous 1.87 (colored)
Drop frames that are received unencrypted when WEP is on or when WPA is on and RX protection for TA is on. Keep track of the TX/RX protection for each node when WPA is on. tested by djm@ (ral+wpa), ckuethe@ (ath-noenc) and krw@ (wpi<->ral+wpa). hints from bluhm@ has been in snaps for a few days. pointed out by bluhm@ something like 1 year ago but we did not have the right infrastructure to fix it properly at that time. ok deraadt@
Revision 1.87 / (download) - annotate - [select for diffs], Mon Jul 28 19:42:13 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.86: +22 -24 lines
Diff to previous 1.86 (colored)
ignore PS mode changes and PS-Poll from non-associated STAs. keep track of the number of associated STAs in PS mode.
Revision 1.86 / (download) - annotate - [select for diffs], Mon Jul 28 10:38:05 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.85: +6 -5 lines
Diff to previous 1.85 (colored)
missing "goto err". fix IEEE80211_DEBUG builds.
Revision 1.85 / (download) - annotate - [select for diffs], Sun Jul 27 18:24:01 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.84: +128 -153 lines
Diff to previous 1.84 (colored)
sanitize RX path a bit. make sure drivers pass a contiguous header, check header length earlier. fix checking of frames sequence number for frames containing an Address 4 field (required for future work). fix processing of control frames (only pspoll for now).
Revision 1.84 / (download) - annotate - [select for diffs], Sun Jul 27 14:21:15 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.83: +57 -87 lines
Diff to previous 1.83 (colored)
s/IEEE80211_DPRINTF/DPRINTF/ automatically prepend __func__ to output. deobfuscates debug messages a bit. no binary change unless compiled with IEEE80211_DEBUG.
Revision 1.83 / (download) - annotate - [select for diffs], Mon Jul 21 19:27:26 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.82: +2 -13 lines
Diff to previous 1.82 (colored)
add ieee80211_priv.h file: contains definitions private to net80211. this must not be included by drivers.
Revision 1.82 / (download) - annotate - [select for diffs], Mon Jul 21 19:05:21 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.81: +1 -881 lines
Diff to previous 1.81 (colored)
move processing of EAPOL frames away from ieee80211_{input,output}.c
Revision 1.81 / (download) - annotate - [select for diffs], Mon Jul 21 18:43:18 2008 UTC (15 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.80: +32 -34 lines
Diff to previous 1.80 (colored)
instead of passing rx tstamp and rssi to the ieee80211_input function, pass a pointer to an ieee80211_rxinfo structure containing those two fields plus an extra flags field that indicates whether the frame was decrypted by hardware or not. required for a future fix.
Revision 1.80 / (download) - annotate - [select for diffs], Mon Jun 9 07:07:16 2008 UTC (16 years ago) by djm
Branch: MAIN
Changes since 1.79: +2 -2 lines
Diff to previous 1.79 (colored)
rename arc4random_bytes => arc4random_buf to match libc's nicer name; ok deraadt@
Revision 1.79 / (download) - annotate - [select for diffs], Sat Apr 26 19:57:49 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.78: +14 -14 lines
Diff to previous 1.78 (colored)
unbreak hostap mode. do not parse RSN IE from beacons/probe responses if not scanning.
Revision 1.78 / (download) - annotate - [select for diffs], Mon Apr 21 20:16:34 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.77: +1 -104 lines
Diff to previous 1.77 (colored)
move ieee80211_ibss_merge() from ieee80211_input.c to ieee80211_node.c
Revision 1.77 / (download) - annotate - [select for diffs], Mon Apr 21 19:37:18 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.76: +1 -130 lines
Diff to previous 1.76 (colored)
move ieee80211_auth_open() to ieee80211_proto.c move ieee80211_setup_rates() to ieee80211_node.c move some prototypes from ieee80211_proto.h to ieee80211_crypto.h
Revision 1.76 / (download) - annotate - [select for diffs], Mon Apr 21 19:27:13 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.75: +4 -4 lines
Diff to previous 1.75 (colored)
refuse association requests containing a wildcard SSID.
Revision 1.75 / (download) - annotate - [select for diffs], Mon Apr 21 19:01:01 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.74: +118 -120 lines
Diff to previous 1.74 (colored)
- do not process ethernet PAE frames if RSN is not enabled - add a ieee80211_recv_action() function (will be used later) - some cleanup, remove unused prototypes, get rid of the IEEE80211_VERIFY_* macros
Revision 1.74 / (download) - annotate - [select for diffs], Mon Apr 21 16:14:25 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.73: +15 -5 lines
Diff to previous 1.73 (colored)
Some WPA1+WPA2 APs include both a WPA and an RSN IE in message 3 of the 4-way handshake, regardless of what protocol the supplicant is using. Ignore the IEs we don't care about instead of deauthenticating with a reason code of 'RSN_DIFFERENT_IE'.
Revision 1.73 / (download) - annotate - [select for diffs], Wed Apr 16 18:32:15 2008 UTC (16 years, 1 month ago) by damien
Branch: MAIN
Changes since 1.72: +659 -410 lines
Diff to previous 1.72 (colored)
Kernel implementation of the 4-way handshake and group-key handshake protocols (both supplicant and authenticator state machines) as defined in the IEEE 802.11i standard. Software implementation of the TKIP (Temporal Key Integrity Protocol) and CCMP (CTR with CBC-MAC Protocol) protocols. This diff doesn't implement any of the 802.1X authentication protocols and thus only PSK authentication (using pre-shared keys) is currently supported. In concrete terms, this adds support for WPA-PSK and WPA2-PSK protocols, both in station and hostap modes. The following drivers are marked as WPA-capable and should work: bwi(4), malo(4), ral(4), iwn(4), wpi(4), ural(4), rum(4), upgt(4), and zyd(4) The following options have been added to ifconfig(8): wpa, wpapsk, wpaprotos, wpaakms, wpaciphers, wpagroupcipher wpa-psk(8) can be used to generate keys from passphrases. tested by many@ ok deraadt@
Revision 1.72 / (download) - annotate - [select for diffs], Mon Oct 29 15:40:23 2007 UTC (16 years, 7 months ago) by chl
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE,
OPENBSD_4_3
Changes since 1.71: +3 -3 lines
Diff to previous 1.71 (colored)
MALLOC/FREE -> malloc/free ok krw@
Revision 1.71 / (download) - annotate - [select for diffs], Tue Sep 18 22:02:18 2007 UTC (16 years, 8 months ago) by djm
Branch: MAIN
Changes since 1.70: +2 -2 lines
Diff to previous 1.70 (colored)
arc4random_bytes() is the preferred interface for generating nonces; "looks ok" markus@
Revision 1.70 / (download) - annotate - [select for diffs], Wed Aug 29 19:54:46 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.69: +46 -32 lines
Diff to previous 1.69 (colored)
- use ieee80211_get_hdrlen() where appropriate. - discard all EAPOL-Key frames with an unknown descriptor version. - when receiving message 3/4 of the 4-way handshake, do not install the PTK if the INSTALL bit is not set. this fixes 4-way handshake with APs using group keys only. - similarly, do not mark the 802.1X port as valid if the SECURE bit is not set (it will be marked as valid after group key handshake).
Revision 1.69 / (download) - annotate - [select for diffs], Mon Aug 27 20:14:21 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.68: +65 -45 lines
Diff to previous 1.68 (colored)
rework ieee80211_recv_4way_msg2() function. add some RSNA authenticator state machine bits.
Revision 1.68 / (download) - annotate - [select for diffs], Mon Aug 27 18:53:27 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.67: +66 -45 lines
Diff to previous 1.67 (colored)
Checking the MIC early in ieee80211_recv_eapol() does not work for message 2/4 of the 4-way handshake because the authenticator must derive the PTK first (the MIC is computed using the KCK). Move calls to ieee80211_eapol_key_check_mic() - and as a consequence ieee80211_eapol_key_decrypt() - directly in the ieee80211_recv_{group,4way}_msg*() functions. Unconstify the first parameter since checking the MIC modifies the frame. Remove ni->ni_ptk_ok field while i'm here.
Revision 1.67 / (download) - annotate - [select for diffs], Thu Aug 23 18:44:00 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.66: +19 -1 lines
Diff to previous 1.66 (colored)
add a new ieee80211_save_ie() function to make a copy of an information element in a management frame. the authenticator has to make a copy of the RSN/WPA1 IE from (Re)Association requests so that it can be compared with the one included in message 2/4 of the 4-way handshake.
Revision 1.66 / (download) - annotate - [select for diffs], Thu Aug 23 16:59:32 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.65: +26 -1 lines
Diff to previous 1.65 (colored)
add ieee80211_get_hdrlen() to compute the size of the 802.11 header of a management or data frame (check if the i_qos, i_ht or i_addr4 are present).
Revision 1.65 / (download) - annotate - [select for diffs], Thu Aug 23 16:53:51 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.64: +17 -19 lines
Diff to previous 1.64 (colored)
the authenticator can't differentiate 4-way handshake message 2 from message 4 based on the EAPOL-Key frame secure bit. the only thing that differentiate these messages is the presence of the RSN/WPA1 IE in the EAPOL-Key frame data field. only message 2/4 contains this IE.
Revision 1.64 / (download) - annotate - [select for diffs], Wed Aug 22 20:40:34 2007 UTC (16 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.63: +68 -79 lines
Diff to previous 1.63 (colored)
- add k_rxmic and k_txmic fields to struct ieee80211_key to store the Tx/Rx MIC for TKIP. - add two functions to map a PTK and a GTK to an IEEE 802.11 key and use them in ieee80211_input.c instead of duplicating the same code. properly set Tx/Rx MIC in the IEEE 802.11 key in the case of TKIP. - add ic_psk to struct ieee80211com to store the pre-shared key. - fix setting of the SECURE bit in outgoing EAPOL-Key frames. - when receiving msg 2 of the 4-way handshake, deauthenticate the station if the RSN IE does not match that of the (Re)Association request. - before parsing an RSN or WPA IE, check that there's enough room for the version field (2 bytes) which is mandatory. - various tweaks while i'm here.
Revision 1.63 / (download) - annotate - [select for diffs], Thu Aug 16 14:59:14 2007 UTC (16 years, 9 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE,
OPENBSD_4_2
Changes since 1.62: +0 -3 lines
Diff to previous 1.62 (colored)
back out part of last diff; breaks all hardware wep decryption. from damien
Revision 1.62 / (download) - annotate - [select for diffs], Tue Aug 14 20:33:47 2007 UTC (16 years, 10 months ago) by bluhm
Branch: MAIN
Changes since 1.61: +4 -1 lines
Diff to previous 1.61 (colored)
Prevent sneaking in unencrypted packets into WEP traffic. ok damien@, put it ok deraadt@
Revision 1.61 / (download) - annotate - [select for diffs], Fri Aug 3 20:18:42 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.60: +5 -4 lines
Diff to previous 1.60 (colored)
fix parsing of GTK KDE.
Revision 1.60 / (download) - annotate - [select for diffs], Fri Aug 3 16:51:06 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.59: +7 -9 lines
Diff to previous 1.59 (colored)
add a ni_eapol_desc field to struct ieee80211_node to know whether a station is using WPA1 or RSN descriptors. make sure that a station that advertises WPA1 capability in an IE uses the WPA1 EAPOL-Key descriptor type and not the RSN one. fix construction of EAPOL-Key frames for WPA1. i can now successfuly complete a 4-way and group-key handshake with both a WPA1 and a WPA2 access point. add some TKIP encapsulation code (no SW crypto yet). ok deraadt@
Revision 1.59 / (download) - annotate - [select for diffs], Wed Aug 1 18:14:00 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.58: +7 -6 lines
Diff to previous 1.58 (colored)
allow ic_set_key to be NULL so that drivers won't need to implement it (for instance if they don't support HW crypto).
Revision 1.58 / (download) - annotate - [select for diffs], Wed Aug 1 16:23:48 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.57: +3 -1 lines
Diff to previous 1.57 (colored)
make sure the MIC field is set in group key handshake messages before passing the frame to the handlers.
Revision 1.57 / (download) - annotate - [select for diffs], Wed Aug 1 16:16:09 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.56: +15 -12 lines
Diff to previous 1.56 (colored)
make ieee80211_recv_wpa_group_msg1() install the GTK in ic_nw_keys[] too. i only converted ieee80211_recv_rsn_group_msg1() in my previous commit.
Revision 1.56 / (download) - annotate - [select for diffs], Wed Aug 1 15:40:40 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.55: +47 -37 lines
Diff to previous 1.55 (colored)
add generic ieee80211_encrypt() and ieee80211_decrypt() functions that can handle multiple ciphers (the key to use is determined automatically by these functions based on the frame's destination address). add ieee80211_ccmp_encrypt() and ieee80211_ccmp_decrypt(). those two functions only do encapsulation/decapsulation of CCMP frames for now (they don't do SW crypto). they will help to test things with drivers that can do HW crypto. add a ni_pairwise_key field to struct ieee80211_node to actually install the pairwise transient key. install the GTK in ic_nw_keys[].
Revision 1.55 / (download) - annotate - [select for diffs], Wed Aug 1 15:22:12 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.54: +2 -2 lines
Diff to previous 1.54 (colored)
unbreak.
Revision 1.54 / (download) - annotate - [select for diffs], Wed Aug 1 13:25:19 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.53: +8 -4 lines
Diff to previous 1.53 (colored)
check the key length field in message 3 of the 4-way handshake. change ieee80211_recv_eapol() so that it is called without the ethernet header striped.
Revision 1.53 / (download) - annotate - [select for diffs], Wed Aug 1 12:59:33 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.52: +64 -7 lines
Diff to previous 1.52 (colored)
group key handshake message 1 is very different between RSN and WPA1. RSN uses a GTK KDE while WPA1 stores the GTK in the EAPOL-Key frame data field (encrypted) and uses some bits in the info field. split ieee80211_recv_group_msg1() in two separate functions.
Revision 1.52 / (download) - annotate - [select for diffs], Wed Aug 1 12:47:55 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.51: +2 -2 lines
Diff to previous 1.51 (colored)
pass the supplicant's nonce generated on reception of message 1 of the 4-way handshake to ieee80211_send_4way_msg2().
Revision 1.51 / (download) - annotate - [select for diffs], Wed Aug 1 12:43:58 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.50: +19 -2 lines
Diff to previous 1.50 (colored)
in 4-way handshake messages 2 and 3, parse vendor-specific WPA1 IEs too. fix a test for ni_replaycnt_ok while i'm here.
Revision 1.50 / (download) - annotate - [select for diffs], Wed Aug 1 12:32:26 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.49: +8 -5 lines
Diff to previous 1.49 (colored)
PMKID KDE is optionnal in message 1 of the 4-way handshake (at least when using WPA-PSK). add a ni_replaycnt_ok flag to struct ieee80211_node to mark the replay counter as valid. the replay counter is marked valid only when message 3 of the 4-way handshake is received since message 1 contains no MIC.
Revision 1.49 / (download) - annotate - [select for diffs], Wed Aug 1 12:26:16 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.48: +2 -2 lines
Diff to previous 1.48 (colored)
fix parsing and construction of RSN/WPA IEs.
Revision 1.48 / (download) - annotate - [select for diffs], Wed Aug 1 12:23:26 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.47: +1 -4 lines
Diff to previous 1.47 (colored)
all WPA implementations i have tested use EAPOL-Key frames version 1, so use that too and remove a check in ieee80211_recv_eapol(). WPA1 stores the group key id into bits 4-5 of the EAPOL-Key frame info field and uses bit 6 to indicate if the key is Rx/Tx or Rx only. remove a check in ieee80211_eapol_key_decrypt() because WPA1 encrypts the payload of message 1 of the group-key handshake without setting the encrypted bit in the info field.
Revision 1.47 / (download) - annotate - [select for diffs], Wed Aug 1 12:02:50 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.46: +2 -2 lines
Diff to previous 1.46 (colored)
KEYACK bit is not set for 4-way handshake messages 2 and 4. it is set in message 3.
Revision 1.46 / (download) - annotate - [select for diffs], Wed Aug 1 11:59:40 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.45: +2 -2 lines
Diff to previous 1.45 (colored)
cipher suite type for CCMP is 4 not 3.
Revision 1.45 / (download) - annotate - [select for diffs], Sat Jul 28 11:24:06 2007 UTC (16 years, 10 months ago) by damien
Branch: MAIN
Changes since 1.44: +606 -2 lines
Diff to previous 1.44 (colored)
adds functions to parse and to build EAPOL-Key frames used in the 4-way and group-key handshake. the state machine is still missing though so this is not used anywhere yet.
Revision 1.44 / (download) - annotate - [select for diffs], Sat Jul 14 19:58:05 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.43: +35 -19 lines
Diff to previous 1.43 (colored)
update QoS Tx/Rx sequence numbers for each TID. add a parameter to ieee80211_decap() to handle different 802.11 header sizes. cleanup and clarify ieee80211_classify().
Revision 1.43 / (download) - annotate - [select for diffs], Fri Jul 13 19:56:03 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.42: +12 -26 lines
Diff to previous 1.42 (colored)
cleanup parsing of beacon and probe response mgmt frames.
Revision 1.42 / (download) - annotate - [select for diffs], Fri Jul 13 19:32:53 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.41: +7 -9 lines
Diff to previous 1.41 (colored)
in ieee80211_recv_assoc_resp(), do not start updating the node structure until the frame has been fully validated.
Revision 1.41 / (download) - annotate - [select for diffs], Fri Jul 13 19:26:09 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.40: +46 -28 lines
Diff to previous 1.40 (colored)
change the way we parse IEs to make sure we never read past the end of the rx buffer.
Revision 1.40 / (download) - annotate - [select for diffs], Fri Jul 13 19:09:23 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.39: +40 -39 lines
Diff to previous 1.39 (colored)
properly check ieee80211_setup_rates() return code. some cleanup while i'm here.
Revision 1.39 / (download) - annotate - [select for diffs], Fri Jul 6 19:33:58 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.38: +62 -48 lines
Diff to previous 1.38 (colored)
have ieee80211_parse_rsn() return a reason code so that we can deauth associating stations with bad RSN IEs. cleanup parsing of vendor-specific IEs.
Revision 1.38 / (download) - annotate - [select for diffs], Fri Jul 6 18:18:43 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.37: +1 -185 lines
Diff to previous 1.37 (colored)
remove remaining bits for pre-RSNA shared authmode support. it has been #if 0'd since 3.9 and we have never supported this mode (no ifconfig option etc...).
Revision 1.37 / (download) - annotate - [select for diffs], Fri Jul 6 17:58:04 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.36: +7 -17 lines
Diff to previous 1.36 (colored)
don't check the IEEE80211_CAPINFO_PRIVACY bit in (re)association requests. the spec says that "APs ignore the Privacy subfield within received Association and Reassociation Request managements frames". if the IEEE80211_CAPINFO_ESS bit is not set, reply with the correct status code (IEEE80211_STATUS_CAPINFO instead of IEEE80211_STATUS_BASIC_RATE). indent things a bit while i'm here.
Revision 1.36 / (download) - annotate - [select for diffs], Wed Jul 4 20:19:12 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.35: +11 -11 lines
Diff to previous 1.35 (colored)
ignore WMM vendor IEs that are not parameter sets.
Revision 1.35 / (download) - annotate - [select for diffs], Tue Jul 3 20:25:32 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.34: +9 -12 lines
Diff to previous 1.34 (colored)
maintain the traffic-indication (TIM) virtual bitmap by defining a default ieee80211_set_tim() function that drivers can override by setting ic_set_tim.
Revision 1.34 / (download) - annotate - [select for diffs], Tue Jul 3 17:04:13 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.33: +34 -29 lines
Diff to previous 1.33 (colored)
fix kernel builds with IEEE80211_DEBUG enabled. pointed out by claudio@
Revision 1.33 / (download) - annotate - [select for diffs], Mon Jul 2 20:21:46 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.32: +78 -41 lines
Diff to previous 1.32 (colored)
split ieee80211_parse_rsn() so the same function can be used to parse both WPA1 and RSN (WPA2) IEs. rename ieee80211_parse_edca_params_common() into ieee80211_parse_edca_params_body() while i'm here.
Revision 1.32 / (download) - annotate - [select for diffs], Mon Jul 2 16:29:26 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.31: +17 -17 lines
Diff to previous 1.31 (colored)
replace some letoh16(*(u_int16_t *)frm) by LE_READ_2(frm) for consistency.
Revision 1.31 / (download) - annotate - [select for diffs], Thu Jun 21 20:11:16 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.30: +158 -5 lines
Diff to previous 1.30 (colored)
add (currently unused) code to parse RSN IEs.
Revision 1.30 / (download) - annotate - [select for diffs], Thu Jun 21 19:48:48 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.29: +44 -10 lines
Diff to previous 1.29 (colored)
parse vendor-specific Microsoft WMM OUI. unfortunately, most APs that advertise themselves as being 802.11e capable still use the Microsoft OUI instead of the standard IEEE 802.11 information element.
Revision 1.29 / (download) - annotate - [select for diffs], Thu Jun 21 18:20:18 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.28: +116 -5 lines
Diff to previous 1.28 (colored)
add code to parse EDCA parameter set information elements. add myself to the copyright list.
Revision 1.28 / (download) - annotate - [select for diffs], Thu Jun 21 16:15:29 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.27: +685 -583 lines
Diff to previous 1.27 (colored)
split ieee80211_recv_mgmt() into smaller functions: - ieee80211_recv_probe_resp - ieee80211_recv_probe_req - ieee80211_recv_auth - ieee80211_recv_assoc_req - ieee80211_recv_assoc_resp - ieee80211_recv_deauth - ieee80211_recv_disassoc "reads ok" jsg@ claudio@ mglocker@
Revision 1.27 / (download) - annotate - [select for diffs], Sat Jun 16 18:36:01 2007 UTC (16 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.26: +5 -7 lines
Diff to previous 1.26 (colored)
move global declaration of ieee80211_merge_print_intvl into the only function that uses it.
Revision 1.26 / (download) - annotate - [select for diffs], Sat Jun 16 13:17:05 2007 UTC (17 years ago) by damien
Branch: MAIN
Changes since 1.25: +10 -7 lines
Diff to previous 1.25 (colored)
constify
Revision 1.25 / (download) - annotate - [select for diffs], Sat Jun 16 11:59:58 2007 UTC (17 years ago) by damien
Branch: MAIN
Changes since 1.24: +5 -5 lines
Diff to previous 1.24 (colored)
don't mix u_int{8,16,32}_t and uint{8,16,32}_t use u_int{8,16,32}_t everywhere.
Revision 1.24 / (download) - annotate - [select for diffs], Sat Jun 16 11:56:20 2007 UTC (17 years ago) by damien
Branch: MAIN
Changes since 1.23: +15 -10 lines
Diff to previous 1.23 (colored)
de-static ok jsg@
Revision 1.23 / (download) - annotate - [select for diffs], Wed Jun 6 19:31:07 2007 UTC (17 years ago) by damien
Branch: MAIN
Changes since 1.22: +1 -5 lines
Diff to previous 1.22 (colored)
The license permits us to redistribute this code under the BSD or the GPLv2. Choose the BSD license so that future enhancements will be BSD-only. ok jsg@ reyk@ deraadt@
Revision 1.22 / (download) - annotate - [select for diffs], Mon Dec 25 19:24:26 2006 UTC (17 years, 5 months ago) by reyk
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE,
OPENBSD_4_1
Changes since 1.21: +5 -3 lines
Diff to previous 1.21 (colored)
print the phy mode in IFF_DEBUG status output which helps to debug dual/multi mode chipset operation. ok jsg@
Revision 1.21 / (download) - annotate - [select for diffs], Tue Aug 29 18:10:34 2006 UTC (17 years, 9 months ago) by damien
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE,
OPENBSD_4_0
Changes since 1.20: +5 -13 lines
Diff to previous 1.20 (colored)
Fix handling of beacon frames by stations while they're associated. Changes in the ERP information element and in the capinfo field were not detected properly, so the drivers were not able to adjust their settings (like short slot time, short preamble, protection mode etc...) dynamically. Should fix BSS mode with both 802.11b and 802.11g stations. ok reyk@
Revision 1.20 / (download) - annotate - [select for diffs], Tue Aug 29 18:02:41 2006 UTC (17 years, 9 months ago) by damien
Branch: MAIN
Changes since 1.19: +20 -15 lines
Diff to previous 1.19 (colored)
make ic_stats.is_rx_tooshort statistic more accurate. cosmetic tweaks. ok reyk@
Revision 1.19 / (download) - annotate - [select for diffs], Sat Jul 29 11:31:47 2006 UTC (17 years, 10 months ago) by miod
Branch: MAIN
Changes since 1.18: +1 -3 lines
Diff to previous 1.18 (colored)
ALIGNED_POINTER is always defined.
Revision 1.18 / (download) - annotate - [select for diffs], Tue Jun 27 20:55:51 2006 UTC (17 years, 11 months ago) by reyk
Branch: MAIN
Changes since 1.17: +9 -2 lines
Diff to previous 1.17 (colored)
add the net80211 hostap options "nwflag hidenwid" for hidden SSID mode and "nwflag nobridge" to prevent inter-station communications. "hidenwid" will also work with wi(4) to replace the old -E 3 option of wicontrol. ok damien@ jmc@
Revision 1.17 / (download) - annotate - [select for diffs], Sun Jun 18 18:55:27 2006 UTC (17 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.16: +2 -3 lines
Diff to previous 1.16 (colored)
s/memcmp/IEEE80211_ADDR_EQ/
Revision 1.16 / (download) - annotate - [select for diffs], Sun Jun 18 18:39:41 2006 UTC (17 years, 11 months ago) by damien
Branch: MAIN
Changes since 1.15: +77 -11 lines
Diff to previous 1.15 (colored)
Improve 802.11b/g interoperability and move toward better compliance with IEEE Std 802.11g-2003 standard: - add ERP Information Element in probe responses and beacons - keep track of the number of associated non-ERP STAs and non-short slot time capable STAs in the BSS - enable use of RTS/CTS or CTS-to-self protection when required by the BSS - add a ic_updateslot() callback to notify drivers of slot time changes - cleanup computation of mgmt frames sizes in ieee80211_output.c - nuke unnecessary <sys/cdefs.h> includes - remove an unused macro (LOGICALLY_EQUAL) while i'm here From {free,net}bsd, with additional fixes. ok brad@, reyk@
Revision 1.15 / (download) - annotate - [select for diffs], Sat Mar 25 22:41:48 2006 UTC (18 years, 2 months ago) by djm
Branch: MAIN
Changes since 1.14: +5 -5 lines
Diff to previous 1.14 (colored)
allow bpf(4) to ignore packets based on their direction (inbound or outbound), using a new BIOCSDIRFILT ioctl; guidance, feedback and ok canacar@
Revision 1.14 / (download) - annotate - [select for diffs], Wed Jan 11 00:18:17 2006 UTC (18 years, 5 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE,
OPENBSD_3_9
Changes since 1.13: +15 -5 lines
Diff to previous 1.13 (colored)
Disable shared key mode until we have a way for the user to specify that they explicitly want it. What we have currently doesn't seem to work anyway. Add support for specifying a status type when sending managemnent frames; adapted from FreeBSD. OK jsg@
Revision 1.13 / (download) - annotate - [select for diffs], Mon Jan 2 08:05:36 2006 UTC (18 years, 5 months ago) by reyk
Branch: MAIN
Changes since 1.12: +3 -3 lines
Diff to previous 1.12 (colored)
use the correct format string directive %llu instead of "%ull". pointed out by Thorsten Glaser.
Revision 1.12 / (download) - annotate - [select for diffs], Thu Nov 3 20:00:18 2005 UTC (18 years, 7 months ago) by reyk
Branch: MAIN
Changes since 1.11: +10 -1 lines
Diff to previous 1.11 (colored)
re-implement the bpf "filter drop" option that it actually works. the bpf FILDROP interface exists for about one year but the required interface to the drivers was missing - so it was useless. this new approach based on a design by henning@ uses a new mbuf flag to mark filtered packets and to drop them in the generic network stack input routines (like ether_input). for example; after some additional testing, this could be used by dhclient to filter everything except DHCP packets (track tech@ for a corresponding dhclient diff). the "filter dropped" packets won't reach the network stack. so it's probably some kind of a very basic application layer packet filter ;). ok canacar@, discussed with henning@ and others
Revision 1.11 / (download) - annotate - [select for diffs], Tue Sep 13 12:11:03 2005 UTC (18 years, 9 months ago) by reyk
Branch: MAIN
Changes since 1.10: +13 -12 lines
Diff to previous 1.10 (colored)
replace the node hash table with a red-black tree. this fixes some bugs in the node table (like duplicate nodes in hostap mode), we get rid of possible hash collisions, and it simplifies the code. tested by many, ok damien@, jsg@
Revision 1.10 / (download) - annotate - [select for diffs], Thu Sep 8 13:24:52 2005 UTC (18 years, 9 months ago) by reyk
Branch: MAIN
Changes since 1.9: +28 -27 lines
Diff to previous 1.9 (colored)
mostly knf ok jsg@
Revision 1.9 / (download) - annotate - [select for diffs], Thu Sep 8 12:44:55 2005 UTC (18 years, 9 months ago) by jsg
Branch: MAIN
Changes since 1.8: +7 -7 lines
Diff to previous 1.8 (colored)
Remove the last of the FreeBSD compatiblity goop. ok reyk@
Revision 1.8 / (download) - annotate - [select for diffs], Thu Sep 8 09:11:08 2005 UTC (18 years, 9 months ago) by jsg
Branch: MAIN
Changes since 1.7: +20 -21 lines
Diff to previous 1.7 (colored)
Remove FreeBSD if_printf compat function from net80211. ok reyk@
Revision 1.7 / (download) - annotate - [select for diffs], Wed Sep 7 05:40:11 2005 UTC (18 years, 9 months ago) by jsg
Branch: MAIN
Changes since 1.6: +1 -58 lines
Diff to previous 1.6 (colored)
Remove FreeBSD/NetBSD ifdef mess. We are not likely to be doing a wholesale merge with them in future. very enthusiastic ok from reyk@
Revision 1.6 / (download) - annotate - [select for diffs], Sat May 7 02:50:47 2005 UTC (19 years, 1 month ago) by jsg
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE,
OPENBSD_3_8
Changes since 1.5: +4 -4 lines
Diff to previous 1.5 (colored)
Fix compilation with IEEE80211_DEBUG defined. Spotted by djm@. ok djm@, reyk@
Revision 1.5 / (download) - annotate - [select for diffs], Tue Mar 8 18:09:20 2005 UTC (19 years, 3 months ago) by mickey
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE,
OPENBSD_3_7
Changes since 1.4: +9 -9 lines
Diff to previous 1.4 (colored)
make this compile
Revision 1.4 / (download) - annotate - [select for diffs], Thu Feb 17 18:28:05 2005 UTC (19 years, 3 months ago) by reyk
Branch: MAIN
Changes since 1.3: +199 -215 lines
Diff to previous 1.3 (colored)
derived from NetBSD: --- Make the node table into an LRU cache: least-recently used nodes are at the end of the node queue. Change the reference-counting discipline: ni->ni_refcnt indicates how many times net80211 has granted ni to the driver. Every node in the table with ni_refcnt=0 is eligible to be garbage-collected. The mere presence of a node in the table does not any longer indicate its auth/assoc state; nodes have a ni_state variable, now. While I am here, patch ieee80211_find_node_for_beacon to do a "best match" by bssid/ssid/channel, not a "perfect match." This keeps net80211 from caching duplicate nodes in the table. --- ok deraadt@ dlg@, looks good jsg@
Revision 1.3 / (download) - annotate - [select for diffs], Mon Dec 6 11:15:14 2004 UTC (19 years, 6 months ago) by dlg
Branch: MAIN
Changes since 1.2: +3 -2 lines
Diff to previous 1.2 (colored)
add a flag that lets a wireless card indicate it can receive probe responses or beacons on any channel during a scan. ok damien@ "come on" deraadt@
Revision 1.2 / (download) - annotate - [select for diffs], Tue Nov 2 02:15:49 2004 UTC (19 years, 7 months ago) by reyk
Branch: MAIN
Changes since 1.1: +104 -1 lines
Diff to previous 1.1 (colored)
some changes merged in from netbsd. ieee80211_regdomain.# will be used by sdr (software defined radios). ok deraadt@ millert@ damien@
Revision 1.1 / (download) - annotate - [select for diffs], Tue Jun 22 22:53:52 2004 UTC (19 years, 11 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE,
OPENBSD_3_6
Import current NetBSD/FreeBSD 802.11 framework. Based in part on a diff from Matthew Gream.