summaryrefslogtreecommitdiff
path: root/sys/net80211/ieee80211_output.c
AgeCommit message (Collapse)Author
2007-08-27rework ieee80211_recv_4way_msg2() function.Damien Bergamini
add some RSNA authenticator state machine bits.
2007-08-27Checking the MIC early in ieee80211_recv_eapol() does not work forDamien Bergamini
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.
2007-08-22- add k_rxmic and k_txmic fields to struct ieee80211_key to store theDamien Bergamini
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.
2007-08-05Fix the length calculation of the TIM bitmask in ieee80211_add_tim().Claudio Jeker
Even no bit was set we copied the full 225bytes bitmaks into the beacon. Found the hard way with acx(4) by mglocker@ and myself. OK mglocker@ damien@
2007-08-03add a ni_eapol_desc field to struct ieee80211_node to know whetherDamien Bergamini
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@
2007-08-01set key length field in message 1 & 3 of the 4-way handshake.Damien Bergamini
2007-08-01pass the supplicant's nonce generated on reception of message 1 of theDamien Bergamini
4-way handshake to ieee80211_send_4way_msg2().
2007-08-01fix parsing and construction of RSN/WPA IEs.Damien Bergamini
2007-08-01the EAPOL-Key MIC must be computed with the MIC bit set.Damien Bergamini
this simplifies ieee80211_eapol_key_mic() and ieee80211_eapol_key_check_mic() quite a bit. set the EAPOL-Key body length before computing the MIC since the MIC is computed with the 802.1X header too. add a missing htons() while i'm here.
2007-08-01cipher suite type for CCMP is 4 not 3.Damien Bergamini
2007-07-28adds functions to parse and to build EAPOL-Key frames used inDamien Bergamini
the 4-way and group-key handshake. the state machine is still missing though so this is not used anywhere yet.
2007-07-14update QoS Tx/Rx sequence numbers for each TID.Damien Bergamini
add a parameter to ieee80211_decap() to handle different 802.11 header sizes. cleanup and clarify ieee80211_classify().
2007-07-13do not increment ic_stats.is_tx_nombuf in ieee80211_get_rts() andDamien Bergamini
ieee80211_get_cts_to_self() if mbuf allocation fails.
2007-07-06cleanup the computation of mgmt frames sizes.Damien Bergamini
still very ugly but hopefully correct.
2007-07-06remove remaining bits for pre-RSNA shared authmode support.Damien Bergamini
it has been #if 0'd since 3.9 and we have never supported this mode (no ifconfig option etc...).
2007-07-05always set the IEEE80211_CAPINFO_ESS bit in association requests.Damien Bergamini
fixes my 1.36 commit (the bit should not be set for non-AP STA only in Probe Responses and Beacons).
2007-07-05move the logic of determining whether an extended supported rates IE isDamien Bergamini
needed or not to the callers (instead of doing nothing in add_xrates).
2007-07-05split ieee80211_add_rsn() so that the code can be reused forDamien Bergamini
vendor-specific IE.
2007-07-04allow USEGROUP as the pairwise cipher for RSN IE.Damien Bergamini
add RSN IE to beacons, probe responses and (re)association requests.
2007-07-03maintain the traffic-indication (TIM) virtual bitmap by definingDamien Bergamini
a default ieee80211_set_tim() function that drivers can override by setting ic_set_tim.
2007-07-03add a function that builds an RSN IE (ieee80211_add_rsn).Damien Bergamini
2007-07-03move construction of IEs into individual functions so that we don'tDamien Bergamini
duplicate the same code multiple times. add references to the spec for all these functions. fixes beacon_alloc() for FH PHYs as a side-effect.
2007-07-03don't set the IEEE80211_CAPINFO_ESS bit in the Capability InformationDamien Bergamini
field if we're not operating as an AP (see 7.3.1.4).
2007-07-03no TIM in probe reponses.Damien Bergamini
2007-07-03In ieee80211_getmbuf(), if we need to allocate a mbuf cluster becauseDamien Bergamini
the length is greater than MHLEN, test that the allocation succeeded. Otherwise, free the mbuf header and return NULL. Callers assume that if the function returns a value != NULL then enough space has been allocated.
2007-07-03fix SSID IE in the case where HIDENWID is used.Damien Bergamini
HIDENWID has been broken from the very beginning.
2007-07-02initial bits for proper TIM support.Damien Bergamini
2007-07-02split ieee80211_send_mgmt() like I did for ieee80211_recv_mgmt()Damien Bergamini
2007-06-21add EDCA Parameter Set and QoS capability IEs to appropriate framesDamien Bergamini
when QoS is supported and activated.
2007-06-21add two new functions:Damien Bergamini
ieee80211_up_to_ac(): returns the access category to be used for transmitting a frame with a given user priority. ieee80211_classify(): returns the user-priority of an mbuf based on VLAN 802.1D user-priority (if any) or IP TOS precedence field. indent prototypes and add myself to the copyright list while i'm here.
2007-06-16don't mix u_int{8,16,32}_t and uint{8,16,32}_tDamien Bergamini
use u_int{8,16,32}_t everywhere.
2007-06-16de-staticDamien Bergamini
ok jsg@
2007-06-11adds 802.11e EDCA tables for QAPs and non-AP QSTAs.Damien Bergamini
not used yet. ok jsg@ deraadt@
2007-06-07move ieee80211_compute_duration() and ieee80211_compute_duration1()Damien Bergamini
functions into the two drivers that use them (atw and rtw.) this code is not generic enough to be used by other drivers and there is no chance that it will ever be used in newer driver since it supports 802.11b only. plus, it hurts my eyes each time i look into ieee80211_output.c. "fine with me as long as the logic doesn't change in the functions" jsg@
2007-06-06The license permits us to redistribute this code under the BSD or the GPLv2.Damien Bergamini
Choose the BSD license so that future enhancements will be BSD-only. ok jsg@ reyk@ deraadt@
2006-12-25print the phy mode in IFF_DEBUG status output which helps to debugReyk Floeter
dual/multi mode chipset operation. ok jsg@
2006-11-03Add two new functions:Damien Bergamini
- ieee80211_get_rts - ieee80211_get_cts_to_self that can be use by drivers for chipsets that don't offer hardware assisted RTS/CTS protection (like ral/ural/rum). "no objections here" jsg@
2006-06-27add the net80211 hostap options "nwflag hidenwid" for hidden SSID modeReyk Floeter
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@
2006-06-18Improve 802.11b/g interoperability and move toward better complianceDamien Bergamini
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@
2006-05-21account for the size of a 802.11 header in ieee80211_getmbuf().Damien Bergamini
fix some typos while i'm here. ok reyk@ brad@
2006-05-19use ieee80211_add_ssid() in ieee80211_beacon_alloc() and wpi(4) insteadDamien Bergamini
of duplicating the code. last commit was ok reyk@
2006-05-19- export ieee80211_add_ssid() just like ieee80211_add_(x)rates() so I don'tDamien Bergamini
need to duplicate the code in wpi(4) - fix ieee80211_alloc_beacon() - clean two comments while i'm here
2006-03-04With the exception of two other small uncommited diffs this movesBrad Smith
the remainder of the network stack from splimp to splnet. ok miod@
2006-02-20Fix kernel builds without bpfilter. Linking is still broken.Damien Bergamini
"Please commit this diff ASAP" brad@
2006-01-11Disable shared key mode until we have a way for the user to specifyTodd C. Miller
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@
2005-09-08mostly knfReyk Floeter
ok jsg@
2005-09-08Remove the last of the FreeBSD compatiblity goop.Jonathan Gray
ok reyk@
2005-09-08Remove FreeBSD if_printf compat function from net80211.Jonathan Gray
ok reyk@
2005-09-07Remove FreeBSD/NetBSD ifdef mess. We are not likely to beJonathan Gray
doing a wholesale merge with them in future. very enthusiastic ok from reyk@
2005-04-20send raw 802.11 frames with bpf(4) using the IEEE802_11 orReyk Floeter
IEEE802_11_RADIO data link types. ok canacar@ damien@