linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Jouni Malinen <jouni@qca.qualcomm.com>
Cc: linux-wireless@vger.kernel.org, vamsi krishna <vamsin@qti.qualcomm.com>
Subject: Re: [PATCH] cfg80211: Random local address for Public Action frame exchange
Date: Mon, 02 Jan 2017 12:34:14 +0100	[thread overview]
Message-ID: <1483356854.4596.14.camel@sipsolutions.net> (raw)
In-Reply-To: <1482266379-9723-1-git-send-email-jouni@qca.qualcomm.com>


> + * @random_sa: indicates whether the source address is randomized.
> When this is
> + *	true, the driver needs to transmit the management frame
> using the
> + *	address specified in the SA field (Address 2) in the
> buffer and the
> + *	driver needs to receive and acknowledge the response frame
> to this
> + *	address instead of its permanent MAC address.
>   */
>  struct cfg80211_mgmt_tx_params {
>  	struct ieee80211_channel *chan;
> 

Is this really of much value to the driver - rather than comparing the
addresses?

> + * @NL80211_ATTR_MGMT_TX_RANDOM_SA: A flag attribute indicating
> whether the
> + *	source address is randomized in frames sent using
> %NL80211_CMD_FRAME.
> + *	If this flag is not set, the source address field is
> verified to match
> + *	local MAC address. Random SA can be used only with Public
> Action frames
> + *	(e.g., GAS/ANQP).

Likewise here, is this really of much value?

Or is the intent to make sure that userspace *really* intended things
to be randomized, and didn't just have a bug?

What I mean is more like this: if the driver supports "random SA", that
basically means it supports "arbitrary SA". The driver could thus
(unconditionally even, or after comparing to the iface address)
configure the RX filters appropriately.

Therefore, the only thing that would really be needed is the nl80211
extended feature flag to bypass the address check in
cfg80211_mlme_mgmt_tx().

What extra value do we get from having the "yes I really did intend it
to be random" attribute?

johannes

      parent reply	other threads:[~2017-01-02 11:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-20 20:39 [PATCH] cfg80211: Random local address for Public Action frame exchange Jouni Malinen
2016-12-30 19:55 ` IgorMitsyanko
2017-01-02 11:28   ` Johannes Berg
2017-01-02 14:29     ` IgorMitsyanko
2017-01-02 14:33       ` Johannes Berg
2017-01-02 11:34 ` Johannes Berg [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1483356854.4596.14.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=jouni@qca.qualcomm.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=vamsin@qti.qualcomm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).