1460 Commits

Author SHA1 Message Date
Etan Cohen
b103b29488 [NAN] API changes/fixes addressing apilint issues
am: 9825309424

Change-Id: I55eb3368c7add766ea0b6463b3e2479b71c38c2e
2016-08-23 02:35:41 +00:00
Etan Cohen
9825309424 [NAN] API changes/fixes addressing apilint issues
Bug: 30983968
Change-Id: I2189442755380ad5d04f80bcb5978ca0c28e6420
2016-08-22 17:30:07 -07:00
Etan Cohen
0db76ad6ec [NAN] Add method to ConfigRequest to determine if non-default
am: 8266b3f876

Change-Id: I37c81386ef115524a2c7264a0821ce4e0ad19b9c
2016-08-19 23:28:43 +00:00
Etan Cohen
0153a74590 [NAN] Simplify publish/subscribe configuration - merge match filters
am: 6007681b19

Change-Id: I2f1e1368806d86417fc9c06271dadfd6e667e374
2016-08-19 23:21:57 +00:00
Etan Cohen
5782aae1be [NAN] Udpate NAN API documentation, clean-up visibility
am: 2e37b06dde

Change-Id: Iba3682d9ce1a3d2d1bd07636ef7c633d8e7ed847
2016-08-19 23:21:52 +00:00
Etan Cohen
8266b3f876 [NAN] Add method to ConfigRequest to determine if non-default
To be used in permission check.

Bug: 27696149
Change-Id: I5be5aed93c556cf24b596bd2a7c5672502f84d74
2016-08-19 12:31:31 -07:00
Etan Cohen
6007681b19 [NAN] Simplify publish/subscribe configuration - merge match filters
Merge Tx/Rx match filters into single Match filter configuration. Only
a single filter can be used at a time (either Tx or Rx).

Bug: 30948496
Change-Id: I32a9a0306dfd08295bc63145bccfe3739862f17d
2016-08-19 12:31:31 -07:00
Etan Cohen
2e37b06dde [NAN] Udpate NAN API documentation, clean-up visibility
Change-Id: I951340eebab35c10efe98dab86b58fe8efada169
2016-08-19 12:31:31 -07:00
Etan Cohen
ccb0b65be6 resolve merge conflicts of 6ffbcb3 to master
Change-Id: I23af5223f0e9810aa90fda4594ff6ccfc69b4053
2016-08-19 11:22:06 -07:00
Etan Cohen
879bc353c0 Merge "[NAN] Update finalize to check and warn user if resources not freed" into mm-wireless-dev
am: 907ce63ed1

Change-Id: Id45d1727dcfdf234e6345f546144c26408ae5fe6
2016-08-19 17:54:35 +00:00
Etan Cohen
6ffbcb3f73 Merge "[NAN] Provide calling package name to service" into mm-wireless-dev 2016-08-19 17:23:15 +00:00
Etan Cohen
907ce63ed1 Merge "[NAN] Update finalize to check and warn user if resources not freed" into mm-wireless-dev 2016-08-19 17:22:26 +00:00
Etan Cohen
83c9496cba [NAN] Do not expose WifiManager.isNanSupported as new API
am: a3264c4e3d

Change-Id: Ifd6a9bb6a129e441b033f3e392c88162ed029493
2016-08-19 16:58:00 +00:00
Etan Cohen
a3264c4e3d [NAN] Do not expose WifiManager.isNanSupported as new API
The WifiManager.isXxxSupported() only functions if HAL is enabled
and seems to be a duplicate of:

PackageManager.hasSystemFeature(PackageManager.FEATURE_WIFI_NAN)

Bug: 28251988
Change-Id: I8f410def6f0bd3d3fc0926072ab66acce52a0e14
2016-08-18 21:16:25 +00:00
Etan Cohen
9d55649613 [NAN] Update finalize to check and warn user if resources not freed
Use CloseGuard to check that disconnect() is called to free the resources
allocated by connect(). finalize() will still call disconnect() but now
also print out errors (if StrictMode enabled for feature).

Bug: 28068773
Change-Id: I5f5847c0261ef9f79a21fdb935509a85761591cc
2016-08-18 10:38:05 -07:00
Etan Cohen
cb34ec8f3a [NAN] Fix bad merge use rethrowFromSystemServer
Added 'throw' to the 'e.rethrowXXX()'. Not needed but seems
to be the accepted style.

Change-Id: I75e42d68ee6092699a55e26ee05151373139606d
2016-08-17 11:20:39 -07:00
Etan Cohen
7531a28e26 [NAN] Provide calling package name to service
Useful for permission checks.

Bug: 30000323
Change-Id: I8c7f06cff346437aa24ca5da9822cbd7b20c59c4
2016-08-11 09:31:21 -07:00
Svetoslav Ganov
d3663c04a7 Add WiFi toggle prompts - framework
If permission review is enabled toggling WiFi on or off
results in a user prompt to collect a consent. This applies
only to legacy apps, i.e. ones that don't support runtime
permissions as they target SDK 22.

bug:28715749

Change-Id: I020601e208c0736005bcabc7b7b77b96eee45b03
2016-08-09 17:01:43 -07:00
Roshan Pius
23173a2efa WifiConfiguration: Expose NetworkSelectionStatus strings
Make the status/disable reason string arrays public to be used in
XmlUtil for restoring of data.

BUG: 30448209
Change-Id: If8201df9397edcc4251e5b6aa4d613212fb576ad
TEST: Unit tests
2016-07-28 10:19:51 -07:00
Etan Cohen
a3c30c3753 [NAN] Add LV utilities (TLV with T size of 0).
am: 009b1fcb85

Change-Id: I8cac5a1f9a6d57da82e4a99af496bff2d699774f
2016-07-22 18:10:17 +00:00
Etan Cohen
009b1fcb85 [NAN] Add LV utilities (TLV with T size of 0).
NAN uses LV (not TLV). Expose an LV variant of TLV to make API
cleaner.

Bug: 30096512
Change-Id: I74b4c514d50f1df5750b521bd68a5e2d832d92c3
2016-07-22 10:24:10 -07:00
Etan Cohen
04e1a246f9 [NAN] Fix TlvElement member names - reflect public access.
am: e40b4d344e

Change-Id: I22cc48b0ba4b873c299fb01df1a925cea8f5727a
2016-07-22 00:30:01 +00:00
Etan Cohen
e0a9ad3729 [NAN] TLV utilities iterator - throw correct exception
am: 3e5ac12302

Change-Id: Ic6638a0d937f9eddba34cc1777655ab05e0e1bf6
2016-07-22 00:29:46 +00:00
Etan Cohen
4acf412746 [NAN] Modify arguments from \"array, length\" to \"array\"
am: 0a5b7efcb2

Change-Id: I0ce1c4cbaac1f54f67d2593e31f2956e67b5eb9f
2016-07-21 22:52:53 +00:00
Etan Cohen
e40b4d344e [NAN] Fix TlvElement member names - reflect public access.
Bug: 30096512
Change-Id: Ic2ab61e891bead6f6e8f13d9ac311ead8fecba5b
2016-07-18 11:39:28 -07:00
Etan Cohen
3e5ac12302 [NAN] TLV utilities iterator - throw correct exception
Make sure that iterator.next() validates that next element exists -
otherwise throw the exception specified by the interface.

Bug: 30096512
Change-Id: I327da433e3f1181e272c81ee503cbe8aab323f7e
2016-07-18 10:37:20 -07:00
Etan Cohen
0a5b7efcb2 [NAN] Modify arguments from "array, length" to "array"
Arrays carry their own lengths. There's no need to provide mechanism
to 'shave' the array - could be done explicitly by caller if needed.

Bug: 29617160
Change-Id: Ib135aa04145f400163cd1a8908dfca4590b4480d
2016-07-18 10:33:39 -07:00
Etan Cohen
73867f93cf [NAN] NAN System Api: RTT
am: ab9ef45971

Change-Id: I34039caac1a40a2c26d8a89d5a0d938fa5a4af62
2016-07-15 16:52:06 +00:00
Etan Cohen
ab9ef45971 [NAN] NAN System Api: RTT
Modify visibility of startRanging [NAN RTT] to SystemApi. Matches the
visibliity of the RttManager API.

Change-Id: Ia92de9885d0b38dfce74484f437bd122dd53cbf6
2016-07-14 16:59:55 -07:00
Etan Cohen
baa4d940ef [NAN] Provide inteface MAC address to app.
am: d097f8a4e5

Change-Id: I62b0b2cfd4a95c23b89c938cef1118ab81c304ce
2016-07-14 00:36:30 +00:00
Etan Cohen
fbe1bfd93f [NAN] Add (T)LV validation testing
am: c13b9f6b7d

Change-Id: I45f0ebc14c06fd869309b569adb2e5fd87c5cc28
2016-07-13 23:06:49 +00:00
Etan Cohen
2bd65a3255 [NAN] Add validity checks for service name
am: adfbfb3a93

Change-Id: I1f4ae4f673e5b08188d0727d1c9221d8af63a988
2016-07-13 21:18:14 +00:00
Etan Cohen
d097f8a4e5 [NAN] Provide inteface MAC address to app.
Expose NAN discovery interface MAC address to app. Required
to enable OOB discovery with other NAN functionality
(e.g. data-path).

Bug: 30000035
Change-Id: Id3c336a61a36522d7011557c805bc3c5307747a1
2016-07-13 12:09:51 -07:00
Etan Cohen
c13b9f6b7d [NAN] Add (T)LV validation testing
Test for validity of a (T)LV. Used in construction of publish and
subscribe configuration (both Tx and Rx filters).

Bug: 30007730
Change-Id: Ibf2179121d45c582bb054c06ec2a765ed0927040
2016-07-13 12:08:38 -07:00
Etan Cohen
e8fa8aa5c7 [NAN] Fix assumption about Strings containing single-byte characters.
am: 9a6161c61c

Change-Id: Id761eede5692131a9ca47497f03c088c6a0cc492
2016-07-13 16:14:44 +00:00
Etan Cohen
98717f24c2 [NAN] NAN data-path API: network specifier
am: 15849dc463

Change-Id: I406276385708a3577393f5532cdf652b0d739302
2016-07-13 14:29:00 +00:00
Etan Cohen
adfbfb3a93 [NAN] Add validity checks for service name
Add checks that the service name is valid per spec (see bug for
details). Stores internally as a byte[] for further propagation.

Bug: 30000106
Change-Id: Iab413aba6755c97bfca0332d6eaa21f636e47f3f
2016-07-08 07:23:36 -07:00
Etan Cohen
9a6161c61c [NAN] Fix assumption about Strings containing single-byte characters.
Code assumed that each character was represented by a single byte.

Change-Id: I92ea63f7273379ed1035f10c207d41e3e352bf38
2016-07-06 13:07:31 -07:00
Etan Cohen
15849dc463 [NAN] NAN data-path API: network specifier
Adds network specifier API. These are used in creating a connectivity
request through ConnectivityManager. The network specifier provides
mechanism to pass information to the network factory.

Bug: 26564277
Change-Id: Ib5b88685e033a2957644f2e9cff39a70712ac7b5
2016-07-06 13:07:26 -07:00
Mitchell Wills
2b6a530851 Merge \"Merge \\"Add a WifiScanner API to listener for ongoing scans\\" into nyc-mr1-dev am: 9f750bf5f4\" into nyc-mr1-dev-plus-aosp
am: 9b62f770dd

Change-Id: I689e6e5cf6a0e9b2c3166c594ec862b01b5bd6f6
2016-06-27 18:28:35 +00:00
Mitchell Wills
9f750bf5f4 Merge "Add a WifiScanner API to listener for ongoing scans" into nyc-mr1-dev 2016-06-27 18:12:41 +00:00
Mitchell Wills
741ec91eaa Merge \\"Don\\'t save the anonymous identity for EAP-SIM/AKA/AKA-Prime\\" into nyc-mr1-dev am: 015c8a3ac0
am: 48a2b01de0

Change-Id: I2f0ead049896e67e9513340cd08443927a40542c
2016-06-24 20:36:44 +00:00
Mitchell Wills
015c8a3ac0 Merge "Don't save the anonymous identity for EAP-SIM/AKA/AKA-Prime" into nyc-mr1-dev 2016-06-24 20:24:13 +00:00
Mitchell Wills
a464a9fce8 Don't save the anonymous identity for EAP-SIM/AKA/AKA-Prime
wpa_supplicant can update this value when authenticating so if the
framework writes it back the new value can be overwritten.

TEST: Patch was validated by original reporter
      Enterprise tests pass (b/29608435)
Change-Id: If359b4ca625371fbdb68177c7cdb6498c3a519a1
Fixes: 28161335
2016-06-24 13:17:31 -07:00
Mitchell Wills
0a726ac690 Add a WifiScanner API to listener for ongoing scans
Bug: 29412469
Change-Id: Id884851a12f95c89f928b81f5b5baa1f9f80fafe
2016-06-23 14:38:59 -07:00
Paul Stewart
0dd7ae2163 Merge \\"Fix invitation request from persistent GC\\" into nyc-mr1-dev am: 72abb6a42e
am: 008b8f78c9

Change-Id: I7f5afdedf253840c0bbd73ad8e52116b9667ee71
2016-06-22 01:12:01 +00:00
daisuke niwa
af1eafd7b1 Fix invitation request from persistent GC
When the device received the second invitation request
from GC of the same PersistentGroup, the wifi framework
processes "sa" as mOwner of WifiP2pGroup. At this point,
if an invited group is persistent group, WifiP2pGroup can't
know whether "sa" is GC or GO yet. So the framework shouldn't
process mOwner in the constructor.

Bug: 28715251
Change-Id: Ie7065da0d6c978c3747ecbd6f728de87d9567009
2016-06-20 08:51:50 -07:00
Gina Dimino
4926ee18c0 Merge \\\"Docs: Suppress errors in SystemApi Build Bug: 28427390\\\" into nyc-dev am: d06520a488 am: b7181150c4
am: cb08f6805a

Change-Id: I65d3016319d0cc53a53f931aa62c642ac53b9520
2016-06-17 20:42:09 +00:00
Roshan Pius
6a89ee2d90 WifiConfiguration: Make NetworkSelectionStatus public
Expose a public constructor for |NetworkSelectionStatus| class and add a
setter in WifiConfiguration to set the |NetworkSelectionStatus| object.
Needed for config store persistence of this object.

BUG: 29273147
Change-Id: I9d9036928137760c4832567dd2b9d0fabc874940
TEST: Unit tests
2016-06-10 14:38:45 -07:00
Roshan Pius
08131593a8 WifiManager: Add new API to restore old backup data
Add a new API to restore the old backups containing the raw data from
wpa_supplicant.conf & ipconfig.txt files.
This helps clean up all the existing wifi configuration parsing
logic from SettingsBackupAgent.

BUG: 29075035
Change-Id: I8c7b93ef7c9e2decc8e4f9e5d7038939cf0ef196
2016-06-03 17:19:01 -07:00