diff options
author | Colleen Twitty <colleen@cozybit.com> | 2013-05-08 11:45:59 -0700 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-05-16 22:39:43 +0200 |
commit | 6e16d90b5218307db805e6b3e0b06d3946eb8c4c (patch) | |
tree | bbd37b170d3657f7df53475f8f9d4d6f73b7260e /net/wireless/nl80211.c | |
parent | 7ade7036043e2e8e2831ae189ce5c248386062f1 (diff) | |
download | op-kernel-dev-6e16d90b5218307db805e6b3e0b06d3946eb8c4c.zip op-kernel-dev-6e16d90b5218307db805e6b3e0b06d3946eb8c4c.tar.gz |
cfg80211: Userspace may inform kernel of mesh auth method.
Authentication takes place in userspace, but the beacon is
generated in the kernel. Allow userspace to inform the
kernel of the authentication method so the appropriate
mesh config IE can be set prior to beacon generation when
joining the MBSS.
Signed-off-by: Colleen Twitty <colleen@cozybit.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/nl80211.c')
-rw-r--r-- | net/wireless/nl80211.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 9cdcd9e..5f10f7a 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -4672,6 +4672,7 @@ static const struct nla_policy [NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL] = { .type = NLA_U8 }, [NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC] = { .type = NLA_U8 }, [NL80211_MESH_SETUP_USERSPACE_AUTH] = { .type = NLA_FLAG }, + [NL80211_MESH_SETUP_AUTH_PROTOCOL] = { .type = NLA_U8 }, [NL80211_MESH_SETUP_USERSPACE_MPM] = { .type = NLA_FLAG }, [NL80211_MESH_SETUP_IE] = { .type = NLA_BINARY, .len = IEEE80211_MAX_DATA_LEN }, @@ -4857,6 +4858,13 @@ static int nl80211_parse_mesh_setup(struct genl_info *info, if (setup->is_secure) setup->user_mpm = true; + if (tb[NL80211_MESH_SETUP_AUTH_PROTOCOL]) { + if (!setup->user_mpm) + return -EINVAL; + setup->auth_id = + nla_get_u8(tb[NL80211_MESH_SETUP_AUTH_PROTOCOL]); + } + return 0; } |