11 years agoandroid: wpa_s template: disassoc on low ack by default (ANDROID) R5.xx_Build-76 R5.xx_Build-77 R5.xx_Build-78 R5.xx_Build-79 R5.xx_Build-81 R5.xx_Build-82 R8.xx_Build-70 R8.xx_Build-71 R8.xx_Build-72 R8.xx_Build-73 R8.xx_Build-74 R8.xx_Build-76 R8.xx_Build-78 R8.xx_Build-79
android: wpa_s template: disassoc on low ack by default (ANDROID)
When operating as a GO, disassoc the peer station on aging/Tx failure
Signed-off-by: Arik Nemtsov <arik@wizery.com>
When operating as a GO, disassoc the peer station on aging/Tx failure
Signed-off-by: Arik Nemtsov <arik@wizery.com>
11 years agoP2P: block find if P2P GO or CLI are active (INTERNAL) R5.xx_Build-70 R5.xx_Build-71 R5.xx_Build-72 R8.xx_Build-67 R8.xx_Build-68 R8.xx_Build-69
P2P: block find if P2P GO or CLI are active (INTERNAL)
The roc on a channel for 100+ ms which is part of the find
disturbs the P2P GO/CLI as these scenarios are unsupported
in non multi channel driver.
Therefore block the find in this case.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The roc on a channel for 100+ ms which is part of the find
disturbs the P2P GO/CLI as these scenarios are unsupported
in non multi channel driver.
Therefore block the find in this case.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Revisit "nl80211: dummy DRIVER SETBAND handler"
Used the wrong string compare API before.
Fix it by using the correst API.
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
Used the wrong string compare API before.
Fix it by using the correst API.
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
11 years agowpa_s: handle channel conflicts on GO+STA shared interface R5.xx_Build-65 R5.xx_Build-66 R8.xx_Build-64 ol_r8.a4.03
wpa_s: handle channel conflicts on GO+STA shared interface
Stop blocking GO role if its operational channel
differs from the STA channel, as now the driver
can handle channel conflicts by sending channel
switch request to the userspace.
Signed-off-by: Victor Goldenshtein <victorg@ti.com>
Stop blocking GO role if its operational channel
differs from the STA channel, as now the driver
can handle channel conflicts by sending channel
switch request to the userspace.
Signed-off-by: Victor Goldenshtein <victorg@ti.com>
11 years agonl80211: dummy DRIVER SETBAND handler R5.xx_Build-62 R5.xx_Build-63 R5.xx_Build-64 R8.xx_Build-58 R8.xx_Build-59 R8.xx_Build-60 R8.xx_Build-61 R8.xx_Build-62 R8.xx_Build-63
nl80211: dummy DRIVER SETBAND handler
SETBAND command is handled in wpa_supplicant_driver_cmd API.
Add a dummy handler in driver_nl80211 for avoiding misleading log,
"Unsupported command: SETBAND ".
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
SETBAND command is handled in wpa_supplicant_driver_cmd API.
Add a dummy handler in driver_nl80211 for avoiding misleading log,
"Unsupported command: SETBAND ".
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
P2P: correct p2p_mult_chan operation (SQUASH)
Should be squashed with:
commit 61d59eaa7ebf59c926d40b00228e227b3d27f8c9
Author: Arik Nemtsov <arik@wizery.com>
Date: Mon Sep 24 17:39:23 2012 +0200
P2P: add conf param to prefer p2p multi channel
Reported-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Should be squashed with:
commit 61d59eaa7ebf59c926d40b00228e227b3d27f8c9
Author: Arik Nemtsov <arik@wizery.com>
Date: Mon Sep 24 17:39:23 2012 +0200
P2P: add conf param to prefer p2p multi channel
Reported-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
11 years agoandroid: wpa_s template: allow p2p multi channel operation (ANDROID) R5.xx_Build-61 R8.xx_Build-55 R8.xx_Build-56 R8.xx_Build-57
android: wpa_s template: allow p2p multi channel operation (ANDROID)
Set the p2p_multi_chan parameter to 1 by default. It will have no effect
if the current driver doesn't support multi-channel. Otherwise it will
allow the P2P channel to be set while disregarding other connected
interfaces on the phy.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Set the p2p_multi_chan parameter to 1 by default. It will have no effect
if the current driver doesn't support multi-channel. Otherwise it will
allow the P2P channel to be set while disregarding other connected
interfaces on the phy.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
P2P: add conf param to prefer p2p multi channel
When p2p_multi_chan=1 is set in the wpa_supplicant.conf file, don't set
the P2P operating channel according to any existing shared frequency.
Normally we would force the operating channel to be the same as that of
other interfaces operating on the same phy. This param allow us to optimize
P2P user experience by allowing an arbitrary operating channel.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
When p2p_multi_chan=1 is set in the wpa_supplicant.conf file, don't set
the P2P operating channel according to any existing shared frequency.
Normally we would force the operating channel to be the same as that of
other interfaces operating on the same phy. This param allow us to optimize
P2P user experience by allowing an arbitrary operating channel.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
P2P: fix oper channel selection (SQUASH)
Handles the forgotten p2p_process_go_neg_resp() case of patch:
commit 66b8140a08b9f6297cd49a3428ada713bf668300
Author: Arik Nemtsov <arik@wizery.com>
Date: Thu Aug 30 21:06:45 2012 +0300
P2P: always re-select oper channel if not hard coded
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Handles the forgotten p2p_process_go_neg_resp() case of patch:
commit 66b8140a08b9f6297cd49a3428ada713bf668300
Author: Arik Nemtsov <arik@wizery.com>
Date: Thu Aug 30 21:06:45 2012 +0300
P2P: always re-select oper channel if not hard coded
Signed-off-by: Arik Nemtsov <arik@wizery.com>
P2P: don't handle concurrency conflicts in multi-chan mode (ANDROID)
When the multi-channel flag is on, don't try to force specific
p2p connection modes or change go_intent.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
When the multi-channel flag is on, don't try to force specific
p2p connection modes or change go_intent.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
11 years agonl80211_copy: update from latest 12xx drv (INTERNAL) R5.xx_Build-39 R5.xx_Build-40 R5.xx_Build-41 R5.xx_Build-46 R5.xx_Build-47 R5.xx_Build-48 R5.xx_Build-49 R5.xx_Build-50 R5.xx_Build-51 R5.xx_Build-52 R5.xx_Build-53 R5.xx_Build-56 R5.xx_Build-59 R5.xx_Build-60 R8.xx_Build-38 R8.xx_Build-39 R8.xx_Build-40 R8.xx_Build-41 R8.xx_Build-42 R8.xx_Build-43 R8.xx_Build-44 R8.xx_Build-45 R8.xx_Build-46 R8.xx_Build-48 R8.xx_Build-49 R8.xx_Build-50 R8.xx_Build-51 R8.xx_Build-52 R8.xx_Build-53 ol_R5.SP3.01
nl80211_copy: update from latest 12xx drv (INTERNAL)
add channel switch related commands and attributes
Signed-off-by: Arik Nemtsov <arik@wizery.com>
add channel switch related commands and attributes
Signed-off-by: Arik Nemtsov <arik@wizery.com>
nl80211: add channel switch ability to AP & GO (INTERNAL)
Implement AP channel switch command. Handle
channel switch request and channel switch
complete events.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
Implement AP channel switch command. Handle
channel switch request and channel switch
complete events.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
hostap: add channel switch ability to AP & GO (INTERNAL)
Add channel switch command and handle channel switch
request/complete events.
New hostapd_eid_csa() which builds the channel switch
announcement IE. Add this CSA to the beacon frame prior
performing a channel switch and remove it once it's
completed.
New EVENT_REQ_CH_SW which indicates that the driver
has requested to perform a channel switch.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
Add channel switch command and handle channel switch
request/complete events.
New hostapd_eid_csa() which builds the channel switch
announcement IE. Add this CSA to the beacon frame prior
performing a channel switch and remove it once it's
completed.
New EVENT_REQ_CH_SW which indicates that the driver
has requested to perform a channel switch.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
hostapd: implement channel switch request drv ops (INTERNAL)
New hostapd_channel_switch – to handle channel switch request.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
New hostapd_channel_switch – to handle channel switch request.
Signed-hostap: Victor Goldenshtein <victorg@ti.com>
nl80211: make unicast RX filter always match STA iface mac (ANDROID)
This is part of changing the RX filters configuration to being
global and not dependent on the interface context.
RX filter #0 should point to a filter matching any unicast frame
sent to the STA (wlan0) mac. The configuration is done by
querying the mac address of the interface. As we now have
reconfiguration of filters done from the context of the p2p interface
filter #0 would get reconfigured with the P2P dev mac.
Avoid this by hard coded querying for the mac of wlan0 when
creating the pattern for RX filter #0.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
This is part of changing the RX filters configuration to being
global and not dependent on the interface context.
RX filter #0 should point to a filter matching any unicast frame
sent to the STA (wlan0) mac. The configuration is done by
querying the mac address of the interface. As we now have
reconfiguration of filters done from the context of the p2p interface
filter #0 would get reconfigured with the P2P dev mac.
Avoid this by hard coded querying for the mac of wlan0 when
creating the pattern for RX filter #0.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: reconfigure RX filters whenever a new interface is added (ANDROID)
This is used to reconfigure RX filters to include a new filter whenever
the P2P group interface is added. The new filter matches any unicast
frame sent to a dest mac which matches the P2P group interface mac.
This is important as otherwise we wouldn't allow any data frames through
to this interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
This is used to reconfigure RX filters to include a new filter whenever
the P2P group interface is added. The new filter matches any unicast
frame sent to a dest mac which matches the P2P group interface mac.
This is important as otherwise we wouldn't allow any data frames through
to this interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: support configuring RX filters dynamically (ANDROID)
The current RX filters are statically defined and can only
be enabled or disabled by the DRIVER RX-FILTER commands.
Add support to add or remove RX filters "on the fly" from
within wpa_s code so we can use this to add an RX filter matching
unicast packets going to the new P2P interface mac.
Whenever the filters change the whole list of filters needs
to be configured to the kernel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The current RX filters are statically defined and can only
be enabled or disabled by the DRIVER RX-FILTER commands.
Add support to add or remove RX filters "on the fly" from
within wpa_s code so we can use this to add an RX filter matching
unicast packets going to the new P2P interface mac.
Whenever the filters change the whole list of filters needs
to be configured to the kernel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: make rx filters config global (ANDROID)
The RX filters (wowlan) configuration is per interface
but this doesn't reflect the state in the kernel where it's
per hw device (effectively in Android global).
In JB this is more important as wpa_s uses up to 3 different
interfaces when running P2P+STA. Also, fix a minor bug
in nl80211_toggle_wowlan_trigger where the wpa_s wowlan state
changed even if configuring the kernel failed.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The RX filters (wowlan) configuration is per interface
but this doesn't reflect the state in the kernel where it's
per hw device (effectively in Android global).
In JB this is more important as wpa_s uses up to 3 different
interfaces when running P2P+STA. Also, fix a minor bug
in nl80211_toggle_wowlan_trigger where the wpa_s wowlan state
changed even if configuring the kernel failed.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
11 years agonl80211: Remove driver specific commands not used in JB (JB) R5.xx_Build-36 R5.xx_Build-37 R8.xx_Build-36
nl80211: Remove driver specific commands not used in JB (JB)
The following driver specific commands aren't used in JB
and were replaced by other APIs:
POWERMODE,GETPOWER,LINKSPEED,RSSI,RSSI-APPROX
Remove code handling these commands.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The following driver specific commands aren't used in JB
and were replaced by other APIs:
POWERMODE,GETPOWER,LINKSPEED,RSSI,RSSI-APPROX
Remove code handling these commands.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: Remove driver command DROPBCAST (ANDROID)
There's no support for this in the driver for now
as the relevant patches were dropped. Therefore
remove relevant code in wpa_s as well.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
There's no support for this in the driver for now
as the relevant patches were dropped. Therefore
remove relevant code in wpa_s as well.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
11 years agoMake copies basic_rates list more useful R5.xx_Build-25 R5.xx_Build-26 R5.xx_Build-27 R5.xx_Build-28 R5.xx_Build-32 R5.xx_Build-34 R8.xx_Build-23 R8.xx_Build-24 R8.xx_Build-25 R8.xx_Build-27 R8.xx_Build-28 R8.xx_Build-32 R8.xx_Build-34 ol_r8.a4.02
Make copies basic_rates list more useful
Commit e5693c4775bae65faa960f80889f98b0a6cb2e1c added a copy of the
determined basic rate set into struct hostapd_iface, but did not
actually copy the terminating -1 value. This could be problematic if
something were to actually try to use this list since would be no way to
know what is the last entry in the list. Fix this by copying the
terminating value.
Signed-hostap: Jouni Malinen <j@w1.fi>
Commit e5693c4775bae65faa960f80889f98b0a6cb2e1c added a copy of the
determined basic rate set into struct hostapd_iface, but did not
actually copy the terminating -1 value. This could be problematic if
something were to actually try to use this list since would be no way to
know what is the last entry in the list. Fix this by copying the
terminating value.
Signed-hostap: Jouni Malinen <j@w1.fi>
11 years agoP2P: prefer operating channels where HT40 is possible R5.xx_Build-20 R5.xx_Build-22 R5.xx_Build-23 R5.xx_Build-24 R8.xx_Build-15 R8.xx_Build-16 R8.xx_Build-17 R8.xx_Build-18 R8.xx_Build-20 R8.xx_Build-21 R8.xx_Build-22
P2P: prefer operating channels where HT40 is possible
When no other user preference is specified, opt to use an operating
channel that allows HT40 operation. This way, if driver capabilities
and regulatory constraints allow, we might enjoy increased bandwidth.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
When no other user preference is specified, opt to use an operating
channel that allows HT40 operation. This way, if driver capabilities
and regulatory constraints allow, we might enjoy increased bandwidth.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
P2P: always re-select oper channel if not hard coded
Since the operating channel is randomly set to 1/6/11 on init, which is
always in the channel intersection, we were effectively ignoring the set
of p2p preferred channels.
Fix this by trying to get the best channel we can, unless the user hard
coded the operating channel in the configuration file. Fall back to the
initial randomly selected channel if a better one cannot be chosen.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
Since the operating channel is randomly set to 1/6/11 on init, which is
always in the channel intersection, we were effectively ignoring the set
of p2p preferred channels.
Fix this by trying to get the best channel we can, unless the user hard
coded the operating channel in the configuration file. Fall back to the
initial randomly selected channel if a better one cannot be chosen.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
android: wpa_s template: allow HT40 GO by default (ANDROID)
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
P2P: add a conf parameter to start a GO as HT40 if allowed
When specified in the conf file this parameter will make all
invocations of p2p_group_add and p2p_connect behave as if "ht40"
has been specified on the command line.
This shouldn't do harm since regulatory constraints and driver
capabilities are consulted anyway before starting HT40 mode.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
When specified in the conf file this parameter will make all
invocations of p2p_group_add and p2p_connect behave as if "ht40"
has been specified on the command line.
This shouldn't do harm since regulatory constraints and driver
capabilities are consulted anyway before starting HT40 mode.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
P2P: Use larger GO config timeout if HT40 is used
Increase GO config timeout if HT40 is used since it takes some time
to scan channels for coex purposes before the BSS can be started.
Signed-hostap: Jouni Malinen <j@w1.fi>
Increase GO config timeout if HT40 is used since it takes some time
to scan channels for coex purposes before the BSS can be started.
Signed-hostap: Jouni Malinen <j@w1.fi>
P2P: Add optional "ht40" argument for p2p_connect
This can be used to start negotiated GO in 40 MHz channel width
in 5GHz band.
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
This can be used to start negotiated GO in 40 MHz channel width
in 5GHz band.
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
P2P: Enable 40 MHz support for autonomous P2P group addition
Add optional "ht40" argument for p2p_group_add command to enable 40 MHz
in 5GHz band. This configures the secondary channel, when HT support is
enabled and if the HW supports 40 MHz channel width.
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Add optional "ht40" argument for p2p_group_add command to enable 40 MHz
in 5GHz band. This configures the secondary channel, when HT support is
enabled and if the HW supports 40 MHz channel width.
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
P2P: Move channel validation into a separate function
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-hostap: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Supply the connection scan results to bgscan after init
If bgscan is enabled, then bgscan is initiated after the connection,
with no bss scan result information. Since a scan was performed prior to
the connection, the information exists and can be used to initialize the
bgscan's cache.
Signed-hostap: Yoni Divinsky <yoni.divinsky@ti.com>
If bgscan is enabled, then bgscan is initiated after the connection,
with no bss scan result information. Since a scan was performed prior to
the connection, the information exists and can be used to initialize the
bgscan's cache.
Signed-hostap: Yoni Divinsky <yoni.divinsky@ti.com>
Revert "Supply the connection scan results to bgscan after init"
This reverts commit 1cd9da6b88d7dd9b3c887b62a584aba4bb08299f.
This old commit has a memory leak. Use a newer commit from upstream that
amends this.
This reverts commit 1cd9da6b88d7dd9b3c887b62a584aba4bb08299f.
This old commit has a memory leak. Use a newer commit from upstream that
amends this.
Remove default ACM=1 from AC_VO and AC_VI
There is no need to mandate admission control (ACM=1) by default, so
clear that flag in the case the configuration file does not specify
wmm_ac_{vo,vi}_acm value. This gets closer to the values mentioned
in the sample hostapd.conf file and reduces the need to specify WMM
parameters in the configuration file for most common use cases.
Signed-hostap: Jouni Malinen <j@w1.fi>
There is no need to mandate admission control (ACM=1) by default, so
clear that flag in the case the configuration file does not specify
wmm_ac_{vo,vi}_acm value. This gets closer to the values mentioned
in the sample hostapd.conf file and reduces the need to specify WMM
parameters in the configuration file for most common use cases.
Signed-hostap: Jouni Malinen <j@w1.fi>
AP: configure basic rates from iface and not conf
The conf doesn't contain any basic rates in some cases. Most notably,
when starting a p2p GO in 5Ghz. Use the iface rates which are
initialized in hostapd_prepare_rates() to the conf rates or set to
default values if no conf values exist.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
The conf doesn't contain any basic rates in some cases. Most notably,
when starting a p2p GO in 5Ghz. Use the iface rates which are
initialized in hostapd_prepare_rates() to the conf rates or set to
default values if no conf values exist.
Signed-hostap: Arik Nemtsov <arik@wizery.com>
11 years agoctrl_iface: allow forcing go_intent during p2p_connect (ANDROID) R5.xx_Build-10 R5.xx_Build-11 R5.xx_Build-12 R5.xx_Build-13 R5.xx_Build-14 R5.xx_Build-15 R5.xx_Build-16 R5.xx_Build-17 R5.xx_Build-19 R5.xx_Build-57 R5.xx_Build-58 R5.xx_Build-6 R5.xx_Build-7 R5.xx_Build-8 R5.xx_Build-9 R8.xx_Build-10 R8.xx_Build-2 R8.xx_Build-3 R8.xx_Build-4 R8.xx_Build-5 R8.xx_Build-6 R8.xx_Build-7 R8.xx_Build-8 R8.xx_Build-9 ol_r8.a3.14 ol_r8.a4.01
ctrl_iface: allow forcing go_intent during p2p_connect (ANDROID)
Allow the p2p_connect command to ignore android p2p concurrency
considerations.
Use the command line argument "no_p2p_conc" to p2p_connect in order to
be able to set the go_intent.
For instance:
wpa_cli p2p_connect 00:11:22:33:44:55 pbc no_p2p_conc go_intent=3
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Allow the p2p_connect command to ignore android p2p concurrency
considerations.
Use the command line argument "no_p2p_conc" to p2p_connect in order to
be able to set the go_intent.
For instance:
wpa_cli p2p_connect 00:11:22:33:44:55 pbc no_p2p_conc go_intent=3
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Add P2P IEs to probe requests only when in P2P (UPSTREAM)
The current code caused P2P and consquently WPS IEs to be added
to any probe as the check was for non null global->p2p.
global->p2p gets set whenever P2P is initialized globally
and that occurs on the first interface init.
Fix this by indicating wps is in use only when in active P2P
discovery or connection establishement.
(i.e. not P2P_IDLE - either doing search, neg or provisioning)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The current code caused P2P and consquently WPS IEs to be added
to any probe as the check was for non null global->p2p.
global->p2p gets set whenever P2P is initialized globally
and that occurs on the first interface init.
Fix this by indicating wps is in use only when in active P2P
discovery or connection establishement.
(i.e. not P2P_IDLE - either doing search, neg or provisioning)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
WPS: fix nonce comparisons (UPSTREAM)
Multiple memcmps of nonces were actually comparing
only the first byte instead of all 16 bytes.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Multiple memcmps of nonces were actually comparing
only the first byte instead of all 16 bytes.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Fix adding extra ies in sched scan (UPSTREAM)
Refactoring done in
commit 46ee04 IEEE 802.11u: Allow Interworking and HESSID to be configured
broke adding extra ies in sched scan.
Fix it and remove unused params arg in wpa_supplicant_extra_ies.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Refactoring done in
commit 46ee04 IEEE 802.11u: Allow Interworking and HESSID to be configured
broke adding extra ies in sched scan.
Fix it and remove unused params arg in wpa_supplicant_extra_ies.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Increase GO Negotiation timeouts
p2p_set_timeout() calls in GO Neg Req/Resp TX callbacks used timeout of
100 ms which is the value given in the P2P specification for GO
Negotiation, but this was actually shorter than the
wait-for-offchannel-TX value (200 ms) used for the driver call. In
addition, it looks like some devices (e.g., Galaxy Nexus with JB image)
can take longer time to reply to GO Negotiation Response (somewhere
between 200 and 250 ms has been observed).
Increase the wait-for-GO-Neg-Resp timeout from 100 ms to 200 ms if GO
Negotiation Request frame was acknowledged (this matches with the
offchannel wait timeout that used previously). The no-ack case is left
at 100 ms since we use GO Negotiation Request frame also to discover
whether the peer is on its Listen channel.
Increase the wait-for-GO-Neg-Conf timeout from 100 ms to 250 ms (and
increase the offchannel wait timeout to matching 250 ms) as a workaround
for devices that take over 200 ms to reply to GO Negotiation Response.
Signed-hostap: Jouni Malinen <j@w1.fi>
p2p_set_timeout() calls in GO Neg Req/Resp TX callbacks used timeout of
100 ms which is the value given in the P2P specification for GO
Negotiation, but this was actually shorter than the
wait-for-offchannel-TX value (200 ms) used for the driver call. In
addition, it looks like some devices (e.g., Galaxy Nexus with JB image)
can take longer time to reply to GO Negotiation Response (somewhere
between 200 and 250 ms has been observed).
Increase the wait-for-GO-Neg-Resp timeout from 100 ms to 200 ms if GO
Negotiation Request frame was acknowledged (this matches with the
offchannel wait timeout that used previously). The no-ack case is left
at 100 ms since we use GO Negotiation Request frame also to discover
whether the peer is on its Listen channel.
Increase the wait-for-GO-Neg-Conf timeout from 100 ms to 250 ms (and
increase the offchannel wait timeout to matching 250 ms) as a workaround
for devices that take over 200 ms to reply to GO Negotiation Response.
Signed-hostap: Jouni Malinen <j@w1.fi>
Fix wpa_s crash and kickstart sched scan (INTERNAL-SQ)
data may be NULL and should be checked before dereferencing it.
This can happen when scan times out for example.
Another bug fixed is that sched scan wouldn't be kick started
from anywhere. Previously it was started following a normal scan
which didn't find any results. Fix it by start it if it's not running.
(These issues were introduced by commit
a523a28 wpa_s: don't reschedule the sched scan on each scan complete event
and the fix should be squashed into it)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Victor Goldenshtein <victorg@ti.com>
data may be NULL and should be checked before dereferencing it.
This can happen when scan times out for example.
Another bug fixed is that sched scan wouldn't be kick started
from anywhere. Previously it was started following a normal scan
which didn't find any results. Fix it by start it if it's not running.
(These issues were introduced by commit
a523a28 wpa_s: don't reschedule the sched scan on each scan complete event
and the fix should be squashed into it)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Victor Goldenshtein <victorg@ti.com>
SME: Fix handle Netgear APs WEP shared quirks (UPSTREAM-SQ)
If the network entry is created with both WPA_AUTH_ALG_OPEN and
WPA_AUTH_ALG_SHARED set in wpa_s->current_ssid->auth_alg, the
existing logic will end up picking WPA_AUTH_ALG_LEAP instead of
shared when open authentication fails.
Fix this by using a bitwise-and to check for WPA_AUTH_ALG_OPEN instead.
(Should be squashed into commit
2e35a02 SME: Handle Netgear APs WEP shared quirks)
Signed-Off-By: William List <wlist@ti.com>
Signed-Off-By: Eyal Shapira <eyal@wizery.com>
If the network entry is created with both WPA_AUTH_ALG_OPEN and
WPA_AUTH_ALG_SHARED set in wpa_s->current_ssid->auth_alg, the
existing logic will end up picking WPA_AUTH_ALG_LEAP instead of
shared when open authentication fails.
Fix this by using a bitwise-and to check for WPA_AUTH_ALG_OPEN instead.
(Should be squashed into commit
2e35a02 SME: Handle Netgear APs WEP shared quirks)
Signed-Off-By: William List <wlist@ti.com>
Signed-Off-By: Eyal Shapira <eyal@wizery.com>
WPS: Update dev.config_methods in wps_update_config
dev.config_methods was not updated when wps_update_config was called.
This could lead to mismatching config methods between Probe Request and
M1 packets. Add missing part for it.
dev.config_methods was not updated when wps_update_config was called.
This could lead to mismatching config methods between Probe Request and
M1 packets. Add missing part for it.
Fix a couple memory leaks
Found using valgrind.
Signed-hostap: Paul Stewart <pstew@chromium.org>
Found using valgrind.
Signed-hostap: Paul Stewart <pstew@chromium.org>
android: wpa_s template: set p2p_go_max_inactivity (ANDROID)
Set p2p_go_max_inactivity to 30 secs (instead of the default
of 300 secs) to avoid creating a user of experience of a
WiFi Direct connection which doesn't disconnect. This may
happen if the P2P GO interface misses a deauth/disassoc frame
and keeps on thinking the client is connected. Limit this
time to 30 secs which creates a better user experience.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Set p2p_go_max_inactivity to 30 secs (instead of the default
of 300 secs) to avoid creating a user of experience of a
WiFi Direct connection which doesn't disconnect. This may
happen if the P2P GO interface misses a deauth/disassoc frame
and keeps on thinking the client is connected. Limit this
time to 30 secs which creates a better user experience.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Add p2p_go_max_inactivity config option (UPSTREAM)
This enables setting a different max inactivity timeout for P2P GO.
This timeout is used to detect inactive clients. In some scenarios
it may be useful to have control over this and set a shorter timeout
than the default 300s. For example when running STA and P2P GO interfaces
concurrently, the STA interface may perform scans which may cause the
GO to miss a disassoc / deauth frames from a client and keep assuming
that the client is connected until the inactivity detection kicks in.
300 secs is a bit too long for such scenarios and creates a bad user
experience.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
This enables setting a different max inactivity timeout for P2P GO.
This timeout is used to detect inactive clients. In some scenarios
it may be useful to have control over this and set a shorter timeout
than the default 300s. For example when running STA and P2P GO interfaces
concurrently, the STA interface may perform scans which may cause the
GO to miss a disassoc / deauth frames from a client and keep assuming
that the client is connected until the inactivity detection kicks in.
300 secs is a bit too long for such scenarios and creates a bad user
experience.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
11 years agoandroid: wpa_s template: use group interface and set conc mode ol_R5.SP2.04 ol_r8.a3.11_jb
android: wpa_s template: use group interface and set conc mode
Make sure we operate the same way as BRCM, with a separate group
interface, by incorporating a driver param.
Also set a default p2p_conc_mode (set to 2), to fit WL6/7 cards. Note
this will have to be changed to p2p_conc_mode=1 for WL8 cards.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Make sure we operate the same way as BRCM, with a separate group
interface, by incorporating a driver param.
Also set a default p2p_conc_mode (set to 2), to fit WL6/7 cards. Note
this will have to be changed to p2p_conc_mode=1 for WL8 cards.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
wpa_s: support p2p concurrency modes when connecting P2P
Prevent P2P connection when STA concurrency requirements do not allow
it. The behavior is determined according to the p2p_conc_mode
config file parameter.
We force go_intent=15 if only GO is allowed and abort the connection
if join is attempted with go_intent=15.
Also manipulate go_intent in our favor (go_intent=14) to minimize the
chances of a concurrency conflict in p2p_conc_mode=2. This supersedes a
similar previous patch by Eyal S.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Prevent P2P connection when STA concurrency requirements do not allow
it. The behavior is determined according to the p2p_conc_mode
config file parameter.
We force go_intent=15 if only GO is allowed and abort the connection
if join is attempted with go_intent=15.
Also manipulate go_intent in our favor (go_intent=14) to minimize the
chances of a concurrency conflict in p2p_conc_mode=2. This supersedes a
similar previous patch by Eyal S.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
wpa_s: support different p2p concurrency modes when connecting STA
support p2p concurrency modes using the p2p_conc_mode=0/1/2 config
file parameter. Meaning is as follows:
0 - support STA + P2P CL/GO on the same channel (BRCM default)
1 - support only one connection at a time (WL8)
2 - support STA + P2P GO on same channel, but not P2P CL (WL6/7)
When connecting STA, disallow the connection or disconnect existing
p2p connection, according to existing concurrency preference.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
support p2p concurrency modes using the p2p_conc_mode=0/1/2 config
file parameter. Meaning is as follows:
0 - support STA + P2P CL/GO on the same channel (BRCM default)
1 - support only one connection at a time (WL8)
2 - support STA + P2P GO on same channel, but not P2P CL (WL6/7)
When connecting STA, disallow the connection or disconnect existing
p2p connection, according to existing concurrency preference.
Signed-off-by: Arik Nemtsov <arik@wizery.com>
nl80211: avoid using another interface for P2P GO (INTERNAL)
Relevant for wl6/7 only, we need to figure out the wl8 MR case.
We now declare iface combinations in wlcore due to cfg80211
enforcement of that. Since we declare support for concurrent
STA and P2P_GO, wpa_s would like to use another interface for
GO. However, since we don't really support P2P_GO so well in MR
but we do want to enable it in MR, prevent wpa_s from using P2P
concurrent mode.
This should be removed once we support P2P_GO properly in MR.
[Arik - should be changed to a configuration parameter to wpa_s, and the
current default should be preserved]
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Relevant for wl6/7 only, we need to figure out the wl8 MR case.
We now declare iface combinations in wlcore due to cfg80211
enforcement of that. Since we declare support for concurrent
STA and P2P_GO, wpa_s would like to use another interface for
GO. However, since we don't really support P2P_GO so well in MR
but we do want to enable it in MR, prevent wpa_s from using P2P
concurrent mode.
This should be removed once we support P2P_GO properly in MR.
[Arik - should be changed to a configuration parameter to wpa_s, and the
current default should be preserved]
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Initialize P2P on p2p0 and not wlan0 (JB)
P2P is being initialized using a global struct
which points to the first initialized interface wpa_s
struct. That's causing P2P commands sent on the control
socket matching p2p0 to generate scan and ROC on the
wrong interface (wlan0) as well as events like PEER_DEVICE_FOUND
are sent on the wrong control socket to the Android framework.
This caused the framework to ignore these and prevent
displaying the P2P peer in the UI.
Solve it by an ugly hack for now to enable P2P only when the
interface p2p0 is being initialized.
This probably should be fixed upstream as well by marking
somehow on which interface you can do p2p or enable p2p per
interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P is being initialized using a global struct
which points to the first initialized interface wpa_s
struct. That's causing P2P commands sent on the control
socket matching p2p0 to generate scan and ROC on the
wrong interface (wlan0) as well as events like PEER_DEVICE_FOUND
are sent on the wrong control socket to the Android framework.
This caused the framework to ignore these and prevent
displaying the P2P peer in the UI.
Solve it by an ugly hack for now to enable P2P only when the
interface p2p0 is being initialized.
This probably should be fixed upstream as well by marking
somehow on which interface you can do p2p or enable p2p per
interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Increase P2P_MAX_CLIENT_IDLE to 20 secs (BRCM)
This is from Jithu Jance submission to hostap ML:
Consider the disconnect event generated due to EAP-FAILURE(after WPS handshake)
during the P2P connection.
In this disconnect context, the group idle timer will be set to 10 and assoc retry starts.
If the connection doesn't go through in the first attempt the group will be removed.
This is because the authentication timeout happens at 10secs and the assoc will be retried only after that.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
This is from Jithu Jance submission to hostap ML:
Consider the disconnect event generated due to EAP-FAILURE(after WPS handshake)
during the P2P connection.
In this disconnect context, the group idle timer will be set to 10 and assoc retry starts.
If the connection doesn't go through in the first attempt the group will be removed.
This is because the authentication timeout happens at 10secs and the assoc will be retried only after that.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Handle new interface parameter in ctrl commands (BRCM)
Some commands sent to wpa_s by the framework in JB include
a new interface parameter. Handle it and dispatch the the
command on the correct interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Some commands sent to wpa_s by the framework in JB include
a new interface parameter. Handle it and dispatch the the
command on the correct interface.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Fix a crash in WPS PBC overlap (BRCM)
Supposedly fixed a crash which occurs during actual PBC overlap
according to BRCM commit log.
(Not quite sure what's the exact cause of the crash here. However
this looks like a non BRCM specific change so take it).
p2p_dev_addr can be NULL in some of the calls. Might cause a problem ?)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Supposedly fixed a crash which occurs during actual PBC overlap
according to BRCM commit log.
(Not quite sure what's the exact cause of the crash here. However
this looks like a non BRCM specific change so take it).
p2p_dev_addr can be NULL in some of the calls. Might cause a problem ?)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Avoid peer expiration while connection in progress (BRCM)
(This seems to be a bug fix squashed in one of the BRCM patches.
Could be that the probability of this occuring once the expiration
time was reduced to 30s is higher)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
(This seems to be a bug fix squashed in one of the BRCM patches.
Could be that the probability of this occuring once the expiration
time was reduced to 30s is higher)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Improve scan results handling (BRCM)
Avoid reporting scan results to the application in case a P2P search
is in progress as there will be many events but the scan is only
done on channels 1,6,11. This may cause APs on other channels to "disappear"
from the scan results.
Also avoid updating P2P interfaces with STA interfaces scan results
in order to avoid having results which are not on the social channels.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Avoid reporting scan results to the application in case a P2P search
is in progress as there will be many events but the scan is only
done on channels 1,6,11. This may cause APs on other channels to "disappear"
from the scan results.
Also avoid updating P2P interfaces with STA interfaces scan results
in order to avoid having results which are not on the social channels.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Start blocked p2p find even if scan was on another interface (BRCM)
p2p find can now defer starting the p2p scan due to an ongoing
scan on a different interface. Relying on p2p_cb_on_scan_complete
which is a per interface flag is wrong here and we won't resume
the p2p find in case the scan wasn't on the same interface (which is
the case in Android JB).
Fix this by relying on the global p2p state instead.
(This description is based on analysis of the code as the original
BRCM commit doesn't contain any useful information)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
p2p find can now defer starting the p2p scan due to an ongoing
scan on a different interface. Relying on p2p_cb_on_scan_complete
which is a per interface flag is wrong here and we won't resume
the p2p find in case the scan wasn't on the same interface (which is
the case in Android JB).
Fix this by relying on the global p2p state instead.
(This description is based on analysis of the code as the original
BRCM commit doesn't contain any useful information)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Defer p2p scan if scanning on other interfaces (BRCM)
The current defer p2p scan until scan complete works
only when the scanning is done on the same interface.
However in Android case there are scans in progress on the STA
interface so these would fail the p2p_scan and consequently
the p2p find.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
The current defer p2p scan until scan complete works
only when the scanning is done on the same interface.
However in Android case there are scans in progress on the STA
interface so these would fail the p2p_scan and consequently
the p2p find.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: Decrease peer expiry time (BRCM)
Changed from 5 min to 30 secs probably in order
to avoid stale peers appearing in the Android UI.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Changed from 5 min to 30 secs probably in order
to avoid stale peers appearing in the Android UI.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: add parameter to force multi channel concurrency (BRCM)
Add a parameter which can be set from wpa_s commandline
or conf file to force real multi channel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Add a parameter which can be set from wpa_s commandline
or conf file to force real multi channel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: fix extending shared_freq detection to AP/GO (BRCM)
Commit d3bd0f "nl80211: Extend shared_freq to handle AP/GO mode interfaces"
still discards AP/GO interfaces so effectively shared_freq
won't work on AP/GO interaces like intended.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Commit d3bd0f "nl80211: Extend shared_freq to handle AP/GO mode interfaces"
still discards AP/GO interfaces so effectively shared_freq
won't work on AP/GO interaces like intended.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
P2P: fix freq conflict resolution in case of P2P and STA
The conflict resolution code doesn't run in case wpa_s SME is used
so moved it up wpa_supplicant_associate.
wpas_p2p_handle_frequency_conflicts assumes use of a different interface
created for p2p group (p2p_group_interface != 0) but that's not
necessarily the case with all drivers. Switch to detect if an iface
is used for P2P_GO by looking at current_ssid->mode.
[Arik - fix the separate interface case, was broken by the original
patch]
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
The conflict resolution code doesn't run in case wpa_s SME is used
so moved it up wpa_supplicant_associate.
wpas_p2p_handle_frequency_conflicts assumes use of a different interface
created for p2p group (p2p_group_interface != 0) but that's not
necessarily the case with all drivers. Switch to detect if an iface
is used for P2P_GO by looking at current_ssid->mode.
[Arik - fix the separate interface case, was broken by the original
patch]
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
P2P: Resolve frequency conflicts between STA and P2P (BRCM)
Upon association check whether there's a a frequency
conflict given that no support for multi channel. In case
there's a freq conflict with an existing P2P_GO or P2P_CLI
decide how to resolve it (which one to disable or disconnect)
according to the priority configuration.
Effectively on Android JB, STA is always prioritized over P2P
so in case of a conflict P2P will be disconnected so that STA
can associate on a different channel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Upon association check whether there's a a frequency
conflict given that no support for multi channel. In case
there's a freq conflict with an existing P2P_GO or P2P_CLI
decide how to resolve it (which one to disable or disconnect)
according to the priority configuration.
Effectively on Android JB, STA is always prioritized over P2P
so in case of a conflict P2P will be disconnected so that STA
can associate on a different channel.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Prep work to configure a prioritized interface (BRCM)
Add a new configurable property which points to the interface
name that should prioritized in case of resolving connection
conflicts.
(This appears to be prep work which doesn't get used however
we include it to better align with JB)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Add a new configurable property which points to the interface
name that should prioritized in case of resolving connection
conflicts.
(This appears to be prep work which doesn't get used however
we include it to better align with JB)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
nl80211: Use native cfg80211 sta events (BRCM)
[Eyal - Keep specific BRCM specific stuff under
ANDROID_BRCM_P2P_PATCH and not ANDROID_P2P which
TI solution compiles with]
Change-Id: I0f6222839ac87241f1bfbbb1fdc6469bf6359652
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
[Eyal - Keep specific BRCM specific stuff under
ANDROID_BRCM_P2P_PATCH and not ANDROID_P2P which
TI solution compiles with]
Change-Id: I0f6222839ac87241f1bfbbb1fdc6469bf6359652
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Fix p2p service discovery
- Fix listen timing to improve SD reliability
- Fix SD packet scheduling
Signed-off-by: Eyal Shapira <eyal@wizery.com>
- Fix listen timing to improve SD reliability
- Fix SD packet scheduling
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Fix null pointer access for SSID printing.
Fix SSID printing in events
Add SSID in supplicant change event
Allow immediate scan request even if another scan was scheduled later
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Android.mk: Define ANDROID_P2P
Changes within #ifdef ANDROID_P2P are BRCM additions
which are non BRCM specific and there should be included.
That's in contrast of ANDROID_BRCM_P2P_PATCH which mark
parts that are BRCM implementation specific (like device_ap_sme)
and therefore would be compiled in only when compiling with BRCM
driver.
Change-Id: I031f0908055756b6e85b64c5151c18b8a73b9841
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Changes within #ifdef ANDROID_P2P are BRCM additions
which are non BRCM specific and there should be included.
That's in contrast of ANDROID_BRCM_P2P_PATCH which mark
parts that are BRCM implementation specific (like device_ap_sme)
and therefore would be compiled in only when compiling with BRCM
driver.
Change-Id: I031f0908055756b6e85b64c5151c18b8a73b9841
Signed-off-by: Eyal Shapira <eyal@wizery.com>
wpa_supplicant: Fix compilation without BOARD_WPA_SUPPLICANT_DRIVER
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Use keystore ENGINE for private key operations
The new keystore ENGINE is usable to perform private key operations when
we can't get the actual private key data. This is the case when hardware
crypto is enabled: the private key never leaves the hardware.
Subsequently, we need to be able to talk to OpenSSL ENGINEs that aren't
PKCS#11 or OpenSC. This just changes a few #define variables to allow us
to talk to our keystore engine without having one of those enabled and
without using a PIN.
The new keystore ENGINE is usable to perform private key operations when
we can't get the actual private key data. This is the case when hardware
crypto is enabled: the private key never leaves the hardware.
Subsequently, we need to be able to talk to OpenSSL ENGINEs that aren't
PKCS#11 or OpenSC. This just changes a few #define variables to allow us
to talk to our keystore engine without having one of those enabled and
without using a PIN.
Restore OpenSSL ENGINE support
We now use an OpenSSL ENGINE to support keystore functionality.
We now use an OpenSSL ENGINE to support keystore functionality.
Add network connection event for status
We need both supplicant state and network connection state
for proper sync up with framework
We need both supplicant state and network connection state
for proper sync up with framework
Add state message sent after 'status' command
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Moving keystore to system/security
keystore used to be in frameworks/base/cmds/keystore, but this include
needs to be changed to support the move to system/security
keystore used to be in frameworks/base/cmds/keystore, but this include
needs to be changed to support the move to system/security
wpa_supplicant: delay scans only for android builds (INTERNAL)
commit e48cd17 ("android: Delay scan after startup to
prevent race with framework (INTERNAL)") is fixing some
bug wrt. android framework, but introduce pretty annoying
delay when working with native linux.
Surround the new functionality with ifdefs in order
to apply it only for android build.
Signed-off-by: Eliad Peller <eliad@wizery.com>
commit e48cd17 ("android: Delay scan after startup to
prevent race with framework (INTERNAL)") is fixing some
bug wrt. android framework, but introduce pretty annoying
delay when working with native linux.
Surround the new functionality with ifdefs in order
to apply it only for android build.
Signed-off-by: Eliad Peller <eliad@wizery.com>
android: Delay scan after startup to prevent race with framework (INTERNAL)
On Android, the immediate scan may cause the following race:
1. Framework starts wpa_s
2. wpa_s loads and initates a scan
3. A matching AP is found and successfully connected to
4. wpa_s reports CTRL-EVENT-CONNECTED but the framework
WiFi state machine didn't progress yet to the correct state
so this event is unexpected.
5. As a result the DHCP state machine isn't triggered.
The end result is successful assoc with the AP but no DHCP request
being sent. Avoid this by delaying the initial scan by scan_interval.
This doesn't delay getting scan results or connectibg to a rememebered AP
as the Android framework initiates a scan through the control interface
anyways after detecting that the supplicant started.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
On Android, the immediate scan may cause the following race:
1. Framework starts wpa_s
2. wpa_s loads and initates a scan
3. A matching AP is found and successfully connected to
4. wpa_s reports CTRL-EVENT-CONNECTED but the framework
WiFi state machine didn't progress yet to the correct state
so this event is unexpected.
5. As a result the DHCP state machine isn't triggered.
The end result is successful assoc with the AP but no DHCP request
being sent. Avoid this by delaying the initial scan by scan_interval.
This doesn't delay getting scan results or connectibg to a rememebered AP
as the Android framework initiates a scan through the control interface
anyways after detecting that the supplicant started.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Use normal scan on first scan after init
Avoid using sched scan as the initial scan after wpa_s
init. This prevents a scenario on Android in which
the Android framework scan is preempted by a saved scan_ssid AP
being connected to due to immediate sched scan.
This delays receiving scan results.
Avoid using sched scan as the initial scan after wpa_s
init. This prevents a scenario on Android in which
the Android framework scan is preempted by a saved scan_ssid AP
being connected to due to immediate sched scan.
This delays receiving scan results.
wpa_supplicant: reduce wps2 IE in conf template (INTERNAL)
wpa_supplicant: VERSION_STR_POSTFIX is now defined to 'git describe'
print ctrl_iface commands
the android wpa_supplicant currently doesn't implement
wpa_hexdump_ascii, so add a simple print for the control
interface commands
Signed-off-by: Eliad Peller <eliad@wizery.com>
the android wpa_supplicant currently doesn't implement
wpa_hexdump_ascii, so add a simple print for the control
interface commands
Signed-off-by: Eliad Peller <eliad@wizery.com>
Use exact interface as socket parameter for init
For p2p, there are virtual interfaces (like p2p-wlan0-X) created and
that results in binding to the common init socket right now.
Instead, have the init bind fail for p2p interfaces and create seperate
sockets specified by the ctrl_interface path in config file
Bug: 5002384
Change-Id: Ia155df079a0bcca1871b6bcab2ef7111f0cba6c1
For p2p, there are virtual interfaces (like p2p-wlan0-X) created and
that results in binding to the common init socket right now.
Instead, have the init bind fail for p2p interfaces and create seperate
sockets specified by the ctrl_interface path in config file
Bug: 5002384
Change-Id: Ia155df079a0bcca1871b6bcab2ef7111f0cba6c1
Android: wpa_s: changes to default build config
Enable roaming and bgscan
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Ido Reis <idor@ti.com>
Enable roaming and bgscan
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Ido Reis <idor@ti.com>
Android: hostapd: enable N rates in build config
Signed-off-by: Ido Reis <idor@ti.com>
Signed-off-by: Ido Reis <idor@ti.com>
config: enable NL80211
Just enable it in both hostapd and wpa_s.
Signed-off-by: Luciano Coelho <coelho@ti.com>
Just enable it in both hostapd and wpa_s.
Signed-off-by: Luciano Coelho <coelho@ti.com>
nl80211_driver: add private commands to use dropbcast
Add DRIVER DROPBCAST {GET,ENABLE,DISABLE} commands to show the current
setting, enable and disable the feature of dropping all broadcast
packets while in suspend mode.
Signed-off-by: Luciano Coelho <coelho@ti.com>
Add DRIVER DROPBCAST {GET,ENABLE,DISABLE} commands to show the current
setting, enable and disable the feature of dropping all broadcast
packets while in suspend mode.
Signed-off-by: Luciano Coelho <coelho@ti.com>
nl80211: Implement some private cmds
Implement the LINKSPEED and RSSI/RSSI-APPROX private commands.
Upstream implementation sends the HANGED state event on
private command failure. Unimplemented commands were
sent to the driver as-is, causing the HANGED event to be sent
and cause a recovery. Private command handling was modified so
that only implemented commands are sent to the driver and
the sending of the HANGED event was removed.
[Arik - The "linkspeed" driver command incorrectly reported the
rate in kbps. Fix this]
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: Yotam Rubin <yotam@wizery.com>
Implement the LINKSPEED and RSSI/RSSI-APPROX private commands.
Upstream implementation sends the HANGED state event on
private command failure. Unimplemented commands were
sent to the driver as-is, causing the HANGED event to be sent
and cause a recovery. Private command handling was modified so
that only implemented commands are sent to the driver and
the sending of the HANGED event was removed.
[Arik - The "linkspeed" driver command incorrectly reported the
rate in kbps. Fix this]
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: Yotam Rubin <yotam@wizery.com>
nl80211: add support for drop rx filters
Enable configuring rx filters which will be
dropped even if matching another rx filter. This
can be used for generating exception filters.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Enable configuring rx filters which will be
dropped even if matching another rx filter. This
can be used for generating exception filters.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
driver_nl80211: Enable only unicast RXFILTER by default
In GB the framework always enabled RXFILTER for unicast
and bcast. This seems to be missing in ICS so enable
unicast by default as this is always required.
Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
In GB the framework always enabled RXFILTER for unicast
and bcast. This seems to be missing in ICS so enable
unicast by default as this is always required.
Signed-off-by: Pontus Fuchs <pontus.fuchs@gmail.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
driver_nl80211: Add and align rx filters IDs
Add more patterns (SSDP, ARP, DHCP) and align IDs to a common
vendor Android framework implementation.
Note that ARP pattern shouldn't be used as our FW
responds to ARPs by default without waking up the host.
It is added only for ID alignments purposes.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Add more patterns (SSDP, ARP, DHCP) and align IDs to a common
vendor Android framework implementation.
Note that ARP pattern shouldn't be used as our FW
responds to ARPs by default without waking up the host.
It is added only for ID alignments purposes.
Signed-off-by: Eyal Shapira <eyal@wizery.com>
driver_nl80211: rx filters - add support for longer patterns
- Add support for long patterns (longer than 8 bytes)
- Separate Rx filters static configuration from code
- Add DHCP and ARP Rx filters
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Assaf Azulay <assaf@ti.com>
- Add support for long patterns (longer than 8 bytes)
- Separate Rx filters static configuration from code
- Add DHCP and ARP Rx filters
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: Assaf Azulay <assaf@ti.com>
driver_nl80211: Add support for DRIVER RXFILTER command
Add support for this Android specific feature using WoWLAN packet
pattern triggers.
Signed-off-by: Pontus Fuchs <pontus.fuchs@tactel.se>
Add support for this Android specific feature using WoWLAN packet
pattern triggers.
Signed-off-by: Pontus Fuchs <pontus.fuchs@tactel.se>
hostapd: add support for android created sockets (/dev/socket/)
Add the same support that wpa_supplicant has with sockets created
by the Android system using the init.rc services options
Just as the supplicant, if the ctrl_iface is a name and not a path
(i.e. doesn't start with '/') the hostapd will assume that this is
an Android created socket named wpa_$(ctrl_iface) which is opened
in /dev/socket/
hostapd_cli sockets will be created in /data/misc/wifi/sockets
The hardcoded configuration is set in the Android.mk of hostapd
just like it is with the supplicant.
In addition, the hostapd_cli needs an Android property by the name
ap.interface to hold the ctrl_iface name to connect to the hostapd's
socket.
Add the same support that wpa_supplicant has with sockets created
by the Android system using the init.rc services options
Just as the supplicant, if the ctrl_iface is a name and not a path
(i.e. doesn't start with '/') the hostapd will assume that this is
an Android created socket named wpa_$(ctrl_iface) which is opened
in /dev/socket/
hostapd_cli sockets will be created in /data/misc/wifi/sockets
The hardcoded configuration is set in the Android.mk of hostapd
just like it is with the supplicant.
In addition, the hostapd_cli needs an Android property by the name
ap.interface to hold the ctrl_iface name to connect to the hostapd's
socket.
wpa_s: make SETBAND take immediate effect
Make SETBAND disconnect from the current AP if it's not
in the correct band. Also expire APs which aren't in the correct
band so scan results will immediately reflect the band change.
[Eyal - ammended commit description]
Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com>
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Make SETBAND disconnect from the current AP if it's not
in the correct band. Also expire APs which aren't in the correct
band so scan results will immediately reflect the band change.
[Eyal - ammended commit description]
Signed-off-by: Panduranga Mallireddy <panduranga_mallireddy@ti.com>
Signed-off-by: Vishal Mahaveer <vishalm@ti.com>
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Android: Implement SETBAND for scan requests
This provides partial SETBAND driver command implementation by
converting the request into a filter for which channels are scanned
by wpa_supplicant.
This provides partial SETBAND driver command implementation by
converting the request into a filter for which channels are scanned
by wpa_supplicant.
nl80211: Add get_noa() support for WFD certification (BRCM)
BUG: b/5367351
Change-Id: I14ed79e10ade205c5dd4cdc0d2e888ed1279d1bb
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
BUG: b/5367351
Change-Id: I14ed79e10ade205c5dd4cdc0d2e888ed1279d1bb
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
nl80211: Special send_mlme rules (BRCM)
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
nl80211: Add MLME events (BRCM)
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
nl80211: Add set_noa, set_p2p_powersave, set_ap_wps_ie
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Fix WFD and WPS certification problem for GO (BRCM)
Change-Id: I5bbac818aad7c0a14fddb3beb88a6a2d87c07ea0
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Broadcom: nl80211: Register assoc/disassoc/deauth frames with Probe Request
TODO: This is not the correct place for registering these frames. Would
need to first figure out whether these are still needed and if so, for
what.
Change-Id: Iafec4bedbd33836d0a64e7ea054d8a46ef8ec204
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
TODO: This is not the correct place for registering these frames. Would
need to first figure out whether these are still needed and if so, for
what.
Change-Id: Iafec4bedbd33836d0a64e7ea054d8a46ef8ec204
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>