Lines Matching refs:ext

505 	struct iw_encode_ext *ext = (struct iw_encode_ext *)extra;  in libipw_wx_set_encodeext()  local
524 if (ext->ext_flags & IW_ENCODE_EXT_GROUP_KEY) { in libipw_wx_set_encodeext()
529 if (idx != 0 && ext->alg != IW_ENCODE_ALG_WEP) in libipw_wx_set_encodeext()
539 ext->alg == IW_ENCODE_ALG_NONE) { in libipw_wx_set_encodeext()
564 switch (ext->alg) { in libipw_wx_set_encodeext()
579 dev->name, ext->alg); in libipw_wx_set_encodeext()
591 dev->name, ext->alg); in libipw_wx_set_encodeext()
617 if (ext->key_len > 0 && (*crypt)->ops->set_key && in libipw_wx_set_encodeext()
618 (*crypt)->ops->set_key(ext->key, ext->key_len, ext->rx_seq, in libipw_wx_set_encodeext()
626 if (ext->ext_flags & IW_ENCODE_EXT_SET_TX_KEY) { in libipw_wx_set_encodeext()
632 if (ext->alg != IW_ENCODE_ALG_NONE) { in libipw_wx_set_encodeext()
633 int key_len = clamp_val(ext->key_len, 0, SCM_KEY_LEN); in libipw_wx_set_encodeext()
635 memcpy(sec.keys[idx], ext->key, key_len); in libipw_wx_set_encodeext()
638 if (ext->alg == IW_ENCODE_ALG_WEP) { in libipw_wx_set_encodeext()
642 } else if (ext->alg == IW_ENCODE_ALG_TKIP) { in libipw_wx_set_encodeext()
646 } else if (ext->alg == IW_ENCODE_ALG_CCMP) { in libipw_wx_set_encodeext()
667 struct iw_encode_ext *ext = (struct iw_encode_ext *)extra; in libipw_wx_get_encodeext() local
671 max_key_len = encoding->length - sizeof(*ext); in libipw_wx_get_encodeext()
683 if (!(ext->ext_flags & IW_ENCODE_EXT_GROUP_KEY) && in libipw_wx_get_encodeext()
684 ext->alg != IW_ENCODE_ALG_WEP) in libipw_wx_get_encodeext()
689 memset(ext, 0, sizeof(*ext)); in libipw_wx_get_encodeext()
692 ext->alg = IW_ENCODE_ALG_NONE; in libipw_wx_get_encodeext()
693 ext->key_len = 0; in libipw_wx_get_encodeext()
697 ext->alg = IW_ENCODE_ALG_WEP; in libipw_wx_get_encodeext()
699 ext->alg = IW_ENCODE_ALG_TKIP; in libipw_wx_get_encodeext()
701 ext->alg = IW_ENCODE_ALG_CCMP; in libipw_wx_get_encodeext()
705 ext->key_len = sec->key_sizes[idx]; in libipw_wx_get_encodeext()
706 memcpy(ext->key, sec->keys[idx], ext->key_len); in libipw_wx_get_encodeext()
708 if (ext->key_len && in libipw_wx_get_encodeext()
709 (ext->alg == IW_ENCODE_ALG_TKIP || in libipw_wx_get_encodeext()
710 ext->alg == IW_ENCODE_ALG_CCMP)) in libipw_wx_get_encodeext()
711 ext->ext_flags |= IW_ENCODE_EXT_TX_SEQ_VALID; in libipw_wx_get_encodeext()