diff options
author | ngie <ngie@FreeBSD.org> | 2015-10-05 00:11:49 +0000 |
---|---|---|
committer | ngie <ngie@FreeBSD.org> | 2015-10-05 00:11:49 +0000 |
commit | e3bac3a30a41f56ac36f4791a7df260f2155c8db (patch) | |
tree | ac20948d4aa368300bc16ece67336a1bed25e992 /sys/net80211/ieee80211_crypto_none.c | |
parent | ca6cf0ba737487849f2ee102afce74545600850c (diff) | |
parent | 85fa330dc74592563cea8d7cf0e628fd30683993 (diff) | |
download | FreeBSD-src-e3bac3a30a41f56ac36f4791a7df260f2155c8db.zip FreeBSD-src-e3bac3a30a41f56ac36f4791a7df260f2155c8db.tar.gz |
MFhead @ r281414
Diffstat (limited to 'sys/net80211/ieee80211_crypto_none.c')
-rw-r--r-- | sys/net80211/ieee80211_crypto_none.c | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/sys/net80211/ieee80211_crypto_none.c b/sys/net80211/ieee80211_crypto_none.c index b1ffbb4..30f2fc3 100644 --- a/sys/net80211/ieee80211_crypto_none.c +++ b/sys/net80211/ieee80211_crypto_none.c @@ -48,7 +48,8 @@ __FBSDID("$FreeBSD$"); static void *none_attach(struct ieee80211vap *, struct ieee80211_key *); static void none_detach(struct ieee80211_key *); static int none_setkey(struct ieee80211_key *); -static int none_encap(struct ieee80211_key *, struct mbuf *, uint8_t); +static void none_setiv(struct ieee80211_key *, uint8_t *); +static int none_encap(struct ieee80211_key *, struct mbuf *); static int none_decap(struct ieee80211_key *, struct mbuf *, int); static int none_enmic(struct ieee80211_key *, struct mbuf *, int); static int none_demic(struct ieee80211_key *, struct mbuf *, int); @@ -62,6 +63,7 @@ const struct ieee80211_cipher ieee80211_cipher_none = { .ic_attach = none_attach, .ic_detach = none_detach, .ic_setkey = none_setkey, + .ic_setiv = none_setiv, .ic_encap = none_encap, .ic_decap = none_decap, .ic_enmic = none_enmic, @@ -87,20 +89,28 @@ none_setkey(struct ieee80211_key *k) return 1; } +static void +none_setiv(struct ieee80211_key *k, uint8_t *ivp) +{ +} + static int -none_encap(struct ieee80211_key *k, struct mbuf *m, uint8_t keyid) +none_encap(struct ieee80211_key *k, struct mbuf *m) { struct ieee80211vap *vap = k->wk_private; #ifdef IEEE80211_DEBUG struct ieee80211_frame *wh = mtod(m, struct ieee80211_frame *); #endif + uint8_t keyid; + + keyid = ieee80211_crypto_get_keyid(vap, k); /* * The specified key is not setup; this can * happen, at least, when changing keys. */ IEEE80211_NOTE_MAC(vap, IEEE80211_MSG_CRYPTO, wh->i_addr1, - "key id %u is not set (encap)", keyid>>6); + "key id %u is not set (encap)", keyid); vap->iv_stats.is_tx_badcipher++; return 0; } |