diff options
Diffstat (limited to 'sys/net80211/ieee80211_crypto_bip.c')
-rw-r--r-- | sys/net80211/ieee80211_crypto_bip.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/net80211/ieee80211_crypto_bip.c b/sys/net80211/ieee80211_crypto_bip.c index 6ab5fb676bf..307c05b1bce 100644 --- a/sys/net80211/ieee80211_crypto_bip.c +++ b/sys/net80211/ieee80211_crypto_bip.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ieee80211_crypto_bip.c,v 1.7 2015/11/24 13:45:06 mpi Exp $ */ +/* $OpenBSD: ieee80211_crypto_bip.c,v 1.8 2017/03/23 04:10:10 tb Exp $ */ /*- * Copyright (c) 2008 Damien Bergamini <damien.bergamini@free.fr> @@ -68,8 +68,10 @@ ieee80211_bip_set_key(struct ieee80211com *ic, struct ieee80211_key *k) void ieee80211_bip_delete_key(struct ieee80211com *ic, struct ieee80211_key *k) { - if (k->k_priv != NULL) - free(k->k_priv, M_DEVBUF, 0); + if (k->k_priv != NULL) { + explicit_bzero(k->k_priv, sizeof(struct ieee80211_bip_ctx)); + free(k->k_priv, M_DEVBUF, sizeof(struct ieee80211_bip_ctx)); + } k->k_priv = NULL; } |