diff options
author | Jouni Malinen <j@w1.fi> | 2009-03-27 15:59:49 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-04-22 16:54:28 -0400 |
commit | a3b8b0569fbef725597f05278ec58083321f6e9d (patch) | |
tree | cb3beb05c841a9564a3fdd44d540570c7b89c9f6 /include/linux/nl80211.h | |
parent | 53b46b8444f600cc1744521ea096ea0c5d494dd0 (diff) |
nl80211: Add Michael MIC failure event
Define a new nl80211 event, NL80211_CMD_MICHAEL_MIC_FAILURE, to be
used to notify user space about locally detected Michael MIC failures.
This matches with the MLME-MICHAELMICFAILURE.indication() primitive.
Since we do not actually have TSC in the skb anymore when
mac80211_ev_michael_mic_failure() is called, that function is changed
to take in the TSC as an optional parameter instead of as a
requirement to include the TSC after the hdr field (which we did not
really follow). For now, TSC is not included in the events from
mac80211, but it could be added at some point.
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/linux/nl80211.h')
-rw-r--r-- | include/linux/nl80211.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/include/linux/nl80211.h b/include/linux/nl80211.h index cbe8ce3bf486..27f230f063b3 100644 --- a/include/linux/nl80211.h +++ b/include/linux/nl80211.h | |||
@@ -199,6 +199,14 @@ | |||
199 | * NL80211_CMD_AUTHENTICATE but for Disassociation frames (similar to | 199 | * NL80211_CMD_AUTHENTICATE but for Disassociation frames (similar to |
200 | * MLME-DISASSOCIATE.request and MLME-DISASSOCIATE.indication primitives). | 200 | * MLME-DISASSOCIATE.request and MLME-DISASSOCIATE.indication primitives). |
201 | * | 201 | * |
202 | * @NL80211_CMD_MICHAEL_MIC_FAILURE: notification of a locally detected Michael | ||
203 | * MIC (part of TKIP) failure; sent on the "mlme" multicast group; the | ||
204 | * event includes %NL80211_ATTR_MAC to describe the source MAC address of | ||
205 | * the frame with invalid MIC, %NL80211_ATTR_KEY_TYPE to show the key | ||
206 | * type, %NL80211_ATTR_KEY_IDX to indicate the key identifier, and | ||
207 | * %NL80211_ATTR_KEY_SEQ to indicate the TSC value of the frame; this | ||
208 | * event matches with MLME-MICHAELMICFAILURE.indication() primitive | ||
209 | * | ||
202 | * @NL80211_CMD_MAX: highest used command number | 210 | * @NL80211_CMD_MAX: highest used command number |
203 | * @__NL80211_CMD_AFTER_LAST: internal use | 211 | * @__NL80211_CMD_AFTER_LAST: internal use |
204 | */ | 212 | */ |
@@ -260,6 +268,8 @@ enum nl80211_commands { | |||
260 | NL80211_CMD_DEAUTHENTICATE, | 268 | NL80211_CMD_DEAUTHENTICATE, |
261 | NL80211_CMD_DISASSOCIATE, | 269 | NL80211_CMD_DISASSOCIATE, |
262 | 270 | ||
271 | NL80211_CMD_MICHAEL_MIC_FAILURE, | ||
272 | |||
263 | /* add new commands above here */ | 273 | /* add new commands above here */ |
264 | 274 | ||
265 | /* used to define NL80211_CMD_MAX below */ | 275 | /* used to define NL80211_CMD_MAX below */ |
@@ -408,6 +418,9 @@ enum nl80211_commands { | |||
408 | * @NL80211_ATTR_REASON_CODE: ReasonCode for %NL80211_CMD_DEAUTHENTICATE and | 418 | * @NL80211_ATTR_REASON_CODE: ReasonCode for %NL80211_CMD_DEAUTHENTICATE and |
409 | * %NL80211_CMD_DISASSOCIATE, u16 | 419 | * %NL80211_CMD_DISASSOCIATE, u16 |
410 | * | 420 | * |
421 | * @NL80211_ATTR_KEY_TYPE: Key Type, see &enum nl80211_key_type, represented as | ||
422 | * a u32 | ||
423 | * | ||
411 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 424 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
412 | * @__NL80211_ATTR_AFTER_LAST: internal use | 425 | * @__NL80211_ATTR_AFTER_LAST: internal use |
413 | */ | 426 | */ |
@@ -492,6 +505,8 @@ enum nl80211_attrs { | |||
492 | NL80211_ATTR_AUTH_TYPE, | 505 | NL80211_ATTR_AUTH_TYPE, |
493 | NL80211_ATTR_REASON_CODE, | 506 | NL80211_ATTR_REASON_CODE, |
494 | 507 | ||
508 | NL80211_ATTR_KEY_TYPE, | ||
509 | |||
495 | /* add attributes here, update the policy in nl80211.c */ | 510 | /* add attributes here, update the policy in nl80211.c */ |
496 | 511 | ||
497 | __NL80211_ATTR_AFTER_LAST, | 512 | __NL80211_ATTR_AFTER_LAST, |
@@ -1062,4 +1077,17 @@ enum nl80211_auth_type { | |||
1062 | NL80211_AUTHTYPE_FT, | 1077 | NL80211_AUTHTYPE_FT, |
1063 | NL80211_AUTHTYPE_NETWORK_EAP, | 1078 | NL80211_AUTHTYPE_NETWORK_EAP, |
1064 | }; | 1079 | }; |
1080 | |||
1081 | /** | ||
1082 | * enum nl80211_key_type - Key Type | ||
1083 | * @NL80211_KEYTYPE_GROUP: Group (broadcast/multicast) key | ||
1084 | * @NL80211_KEYTYPE_PAIRWISE: Pairwise (unicast/individual) key | ||
1085 | * @NL80211_KEYTYPE_PEERKEY: PeerKey (DLS) | ||
1086 | */ | ||
1087 | enum nl80211_key_type { | ||
1088 | NL80211_KEYTYPE_GROUP, | ||
1089 | NL80211_KEYTYPE_PAIRWISE, | ||
1090 | NL80211_KEYTYPE_PEERKEY, | ||
1091 | }; | ||
1092 | |||
1065 | #endif /* __LINUX_NL80211_H */ | 1093 | #endif /* __LINUX_NL80211_H */ |