2416 Commits

Author SHA1 Message Date
Otto Seiskari
a184a4b1da Fix tests/runtests.sh
The location of FrameworksWifiTests.apk installed by the script
with adb seems to have changed. The path of the APK contains the
TARGET_ARCH environment variable, which is now fetched
with a similar method as in system/netd/tests/runtests.sh.

Noticed the issue with "lunch aosp_x86_64-eng". Before this fix,
the test script produced an error:

    adb: failed to stat [...]/FrameworksWifiApiTests.apk:
    No such file or directory

Test: ./frameworks/base/wifi/tests/runtests.sh

Change-Id: Id4a33ca89fa21a9a4ef791c5c1c5760e0e2badaf
Merged-In: Id4a33ca89fa21a9a4ef791c5c1c5760e0e2badaf
Signed-off-by: Otto Seiskari <otto.seiskari@indooratlas.com>
2019-04-26 18:51:33 +00:00
Andrei Onea
efd37eff41 Add @UnsupportedAppUsage annotations
For packages:
  android.net
  android.net.wifi
  android.nfc

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Merged-In: I7489aad1dceeb18ed7ca48a1ed8829a668b3fa04
Change-Id: I16570aef456b45a5543bf889dddc7a0d25441928
2019-02-28 14:39:20 +00:00
Xin Li
0e71b4f19b DO NOT MERGE - Merge pi-platform-release (PPRL.190205.001) into
stage-aosp-master

Bug: 124234733
Change-Id: Ic4f67fde0835da0b1c363906cccef0d244e38393
2019-02-14 09:48:06 -08:00
Mathew Inwood
55418eada5 Limit access to suspected false positives.
Members modified herein are suspected to be false positives: i.e. things
that were added to the greylist in P, but subsequent data analysis
suggests that they are not, in fact, used after all.

Add a maxTargetSdk=P to these APIs. This is lower-risk that simply
removing these things from the greylist, as none of out data sources are
perfect nor complete.

For APIs that are not supported yet by annotations, move them to
hiddenapi-greylist-max-p.txt instead which has the same effect.

Exempted-From-Owner-Approval: Automatic changes to the codebase
affecting only @UnsupportedAppUsage annotations, themselves added
without requiring owners approval earlier.

Bug: 115609023
Test: m
Change-Id: Ia937d8c41512e7f1b6e7f67b9104c1878b5cc3a0
Merged-In: I020a9c09672ebcae64c5357abc4993e07e744687
2018-12-28 14:26:35 +00:00
Treehugger Robot
a32f898720 Merge "DO NOT MERGE - Merge pie-platform-release (PPRL.181205.001) into master" 2018-12-13 05:45:20 +00:00
Adrian Roos
6115769c16 API: Clean up redundant and ineffective usages of SystemApi and TestApi
Everything that is marked SystemApi or TestApi, but not @hide is still
part of the public SDK, it is therefore not sound to have that combination.

In the future, specifing such a combination will be considered an error
to prevent inadvertently exposing SystemApi and TestApi as public API.

Bug: 115333477
Change-Id: Ibd5d6a22862fdbc1e20a1cb3925280f5a682edea
Merged-In: Ibd5d6a22862fdbc1e20a1cb3925280f5a682edea
Test: METALAVA_PREPEND_ARGS="--error UnhiddenSystemApi" m checkapi
Exempt-From-Owner-Approval: API cleanup
2018-12-12 15:02:26 +01:00
Xin Li
15b123ef45 DO NOT MERGE - Merge pie-platform-release (PPRL.181205.001) into master
Bug: 120502534
Change-Id: Idc8bfb6d97a869b76cfb87ca1a494201baf9e8bd
2018-12-11 14:13:44 -08:00
Nathan Harold
f5cf9f24ed Merge "Move some members to the "Q blacklist"." 2018-10-23 21:53:51 +00:00
Mathew Inwood
45d2c252b1 Move some members to the "Q blacklist".
Based on some analysis, these fields/methods are likely false positives.
Set maxTargetSdk=P so that any apps using them are required to migrate off
them in future. See the bug for more details.

Exempted-From-Owner-Approval: Automatic changes to the codebase
affecting only @UnsupportedAppUsage annotations, themselves added
without requiring owners approval earlier.

Bug: 115609023
Test: m
Merged-In: I719b5c94e5b1f4fa562dd5d655953422958ad37e
Change-Id: I719b5c94e5b1f4fa562dd5d655953422958ad37e
(cherry picked from commit 8c854f86a477fbbee38092f449333e1425e5cd7e)
2018-10-22 17:28:24 -07:00
Neil Fuller
49b054800d Merge "Remove usage of StringFactory"
am: 8a79748b0c

Change-Id: Ifebd392e5fec43089a3cd7722fbf6e3d6637f935
2018-10-10 14:40:02 -07:00
Neil Fuller
ce3ed5487f Remove usage of StringFactory
Code outside of the runtime should not use StringFactory.
The java.lang.String API works fine.

Bug: 113148576
Test: build only
Change-Id: I2912e02265306dcd5c5923de019b2c376349ea29
2018-10-10 15:49:31 +01:00
Andrew Solovay
a44f2c075b docs: Replacing {#link with {@link
Several java files had the typo {#link (for cross-references to other
Javadocs) instead of the proper {@link format. This was confusing the
new doc publish tool (Mivi) since that's the format used for {# Django
comments #}.

Fixed a couple of links that had other errors (which prevented building
once the {# -> {@ was done) and other typos.

Replaced throughout the frameworks/base project; I'll need a separate CL
for the AndroidX fixes.

Staged to:

go/dac-stage/reference/android/app/Instrumentation.html
go/dac-stage/reference/android/bluetooth/BluetoothAdapter.html
go/dac-stage/reference/android/bluetooth/BluetoothDevice.html
go/dac-stage/reference/android/bluetooth/BluetoothServerSocket.html
go/dac-stage/reference/android/inputmethodservice/InputMethodService.html
go/dac-stage/reference/android/view/KeyCharacterMap.html
go/dac-stage/reference/android/view/KeyEvent.html
go/dac-stage/reference/android/media/AudioManager.html
go/dac-stage/reference/android/net/wifi/WifiConfiguration.html

(Other files were not in the public Javadocs.)

Bug: 111925950
Test: make ds-docs
Exempt-From-Owner-Approval: Docs-only change
Change-Id: Ia06e1fffd814671289a1caebd5962aedc18a28d7
Merged-In: Ia06e1fffd814671289a1caebd5962aedc18a28d7
2018-10-04 18:20:51 +00:00
David Castro
f0d5c5c30a docs: Updates the documentation for the wepKeys field.
Updated documentation indicates that four WEP key values must be
provided. This replaces the earlier reference to "up to four." Providing
fewer than four values causes a java.lang.IllegalArgumentException.

Documentation also references the option to provide empty strings for up
to three of the values.

Test: make ds-docs

Bug: 36949880

Change-Id: I1da9f0ecfb390623f4d53ca508a554303861ed98
Exempt-From-Owner-Approval: Docs-only change
2018-09-20 17:01:51 -04:00
Oscar Shu
e3de537252 Merge "Fix some fields in WifiInfo are not written into Parcel"
am: 5add10333d

Change-Id: Idce8900c306b8e59f89825f34d0190c3092136b1
2018-08-29 17:50:50 -07:00
keigo, nishira
f53446deca Fix some fields in WifiInfo are not written into Parcel
Some fields in WifiInfo are not written into Parcel so
these fields will not be carried over process boundaries.

cherry-picked from: ag/4820524

Bug: 79889311
Test: compile & verified fields are filled from app
Test: Unit tests

Change-Id: I0d8f453c49212fc6d12d28537454c9a9657c1ef7
2018-08-28 16:24:01 -07:00
Mathew Inwood
629a3828e2 Merge "Add @UnsupportedAppUsage annotations"
am: d717c04b12

Change-Id: I8f8c9106b494caa6dc5ad405111f2a285a01e49f
2018-08-15 10:12:01 -07:00
Mathew Inwood
fa3a7466e1 Add @UnsupportedAppUsage annotations
For packages:
  android.net.wimax
  android.net.wifi.p2p.nsd
  android.net.wifi.p2p
  android.net.wifi.hotspot2.pps
  android.net.wifi.hotspot2.omadm
  android.net.wifi.hotspot2
  android.net.wifi.aware
  android.net.wifi
  android.net.util
  android.net.sip
  android.net.rtp
  android.net.nsd
  android.net.metrics
  android.net.lowpan
  android.net.http
  android.net.captiveportal
  android.net

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: Ie25423113ee1a8071cd5039382c00de6ce0af7fd
Merged-In: I520be7a4c79e68310c12e4f55bf66acaa94145a1
2018-08-14 14:44:29 +01:00
Andrew Solovay
5c704e6deb docs: Updating setDomainSuffixMatch() for Android P
Small update to reflect P-related change (that common-name verification
is no longer supported), per
https://android-dot-devsite.googleplex.com/about/versions/p/android-9.0-changes#certificate-common-name

Also added some missing paragraph breaks while I was doing it.

Doc is staged to:

http://go/dac-stage/reference/android/net/wifi/WifiEnterpriseConfig#setDomainSuffixMatch(java.lang.String)

Exempt-From-Owner-Approval: Docs-only change
Bug: 110483059
Test: make ds-docs
Change-Id: I50b6eb70bf16c17dd0ae4e54711c5bb599c47c1a
2018-07-25 18:57:05 +00:00
Rebecca Silberstein
5f5f4788f1 Merge "SettingsBackupAgent: notify of apBand conversion" into pi-dev
am: cbf554b78b

Change-Id: I7f717d4d6d8a836fc86d67cc453a464830865508
2018-06-22 11:26:10 -07:00
Rebecca Silberstein
d41106c52e SettingsBackupAgent: notify of apBand conversion
Added support to notify user of a change to their softap configuration
preferences after being restored via SettingsBackupAgent.

Bug: 80251951
Test: frameworks/opt/net/wifi/tests/wifitests/runtests.sh
Test: manually confirmed configs are converted for different device
Change-Id: I4cec15549d694cdb1a7b09f1426d027eec021122
2018-06-19 09:59:12 -07:00
Rebecca Silberstein
b14e1fdbff Merge "WifiManager: add call to see if apband conversion is required" into pi-dev
am: 85bdd711ce

Change-Id: I4f2c8e9ebcfd4bb92cad23f222218960188ca09b
2018-06-06 09:51:50 -07:00
Rebecca Silberstein
34f0631ec1 WifiManager: add call to see if apband conversion is required
Add call @hide allowing settings to check if the device requires softap
configs be converted from 5GHz only to ANY

Bug: 80251951
Test: frameworks/base/wifi/tests/runtests.sh
Change-Id: Id4d435eb55e2696d23ceb4d301e5d039e134d66a
2018-06-01 17:52:12 -07:00
Roshan Pius
dee99a1b2b Merge "WifiConfiguration: New temp disable network status for no internet" into pi-dev
am: 95509057f8

Change-Id: I73fc1ed24e79689315ed5d4501a412afce24f6e8
2018-05-21 10:20:11 -07:00
Roshan Pius
95509057f8 Merge "WifiConfiguration: New temp disable network status for no internet" into pi-dev 2018-05-21 17:04:10 +00:00
Etan Cohen
ad2ef030a7 Merge "[RTT] Legacy RTT API: add attempted/succeeded counts" into pi-dev
am: 9f9ce0462d

Change-Id: I2e21bc3ab963de5df240d921a92498a3327d6975
2018-05-17 08:20:56 -07:00
Etan Cohen
49821a11e1 [RTT] Legacy RTT API: add attempted/succeeded counts
Wi-Fi RTT legacy API is (now) a wrapper around the new API. Two
new result parameters were added to the new API but not propagated
to the corresponding legacy API:

- Count of attempted measurements
- Count of successful measurements

Bug: 79883720
Test: unit tests
Test: RangeApSupporting11McTest:test_legacy_rtt_80211mc_supporting_aps
Change-Id: Id000c691c22319474e3e98f5ba5d77e4bb4c343e
2018-05-16 17:50:53 -07:00
Roshan Pius
d61e3930ac WifiConfiguration: New temp disable network status for no internet
Add a new network disable reason to temporarily blacklist an
auto-connected network.

Bug: 72635747
Test: Manually verified that device switched away from an
auto-connected network when it detects no internet.
Change-Id: Id3d2de05f6b2869c0b64d5e427e14573e8912905
2018-05-14 14:18:57 -07:00
Etan Cohen
057718d6e8 Merge "[RTT] Update RTT preamble selection algorithm" into pi-dev
am: 51f3c4481c

Change-Id: I7922b6d07c6327a597f76f1002b3c7652af7d165
2018-05-06 21:07:25 -07:00
Etan Cohen
67f5ffb7e8 [RTT] Update RTT preamble selection algorithm
Select preamble to use for RTT exchange using IEs advertised by the
AP rather than channel width (which is used as a backup method).

Bug: 69965964
Test: unit test & integration tests
Change-Id: I60ef31c4627795bd4da505f31998b49668d1a115
2018-05-05 05:01:31 +00:00
android-build-team Robot
1191a4c5da Merge "[AWARE] Update docs for service discovery callbacks" into pi-dev
am: b9147471ec

Change-Id: I84f79736947e39addfa1b1f0b865e2bb523fb87d
2018-05-04 19:22:19 -07:00
android-build-team Robot
b9147471ec Merge "[AWARE] Update docs for service discovery callbacks" into pi-dev 2018-05-05 02:11:03 +00:00
Roshan Pius
7436da4317 WifiConfiguration: Fix documentation for SSID
am: 183a5f0a35

Change-Id: I265fa98e6aa62a047ff6c7d6cf4c2fe3693dbc88
2018-05-04 15:26:06 -07:00
Roshan Pius
183a5f0a35 WifiConfiguration: Fix documentation for SSID
SSID strings can be UTF-8 encoded. Fix documentation to reflect that.

Bug: 78483295
Test: Compiles
Change-Id: Ib25967a52627a17a13b5d5b418fc3c3c3d05f7c8
2018-05-04 22:12:29 +00:00
Etan Cohen
4b45f8da5e [AWARE] Update docs for service discovery callbacks
Clarify that service discovery callbacks may be triggered multiple
times (and that therefore apps should deal correctly with it). These
may happen for several reasons (not documented since too low level):
- Peer went out-of-hearing-range and came back
- Peer went out of geofence range and came back
- Concurrency limitations caused discovery to switch from ranging-based
  to non-ranging-based or back

Bug: 77925576
Test: N/A
Change-Id: I9fbb909e5bd57fb714aa82bcfeb2834361722149
2018-05-04 10:33:59 -07:00
Roshan Pius
f2153e333c Merge "Revert "Revert "WifiManager: Return status from startScan()""" into pi-dev
am: e93daa4659

Change-Id: Ie6c120c62194686de2c043d1bee45e5fc78b4c11
2018-04-27 17:32:12 -07:00
Roshan Pius
e93daa4659 Merge "Revert "Revert "WifiManager: Return status from startScan()""" into pi-dev 2018-04-28 00:09:03 +00:00
Roshan Pius
c705615816 Revert "Revert "WifiManager: Return status from startScan()""
This reverts commit 4c36c2903d85a829efcc0ecaf2a67d0d05fcb967.

Reason for revert: Compilation failure in Arc++ fixed.
Bug: 77297012
Change-Id: Ic707f7256e8d7430c28e58085c6c2208f88042f2
2018-04-27 19:05:15 +00:00
Doris Ling
cb27c77b55 Merge "Revert "WifiManager: Return status from startScan()"" into pi-dev
am: ebcb2e006b

Change-Id: I328b6e331052a8b2b0717663c65599ed3cee04bc
2018-04-26 16:53:28 -07:00
Doris Ling
ebcb2e006b Merge "Revert "WifiManager: Return status from startScan()"" into pi-dev 2018-04-26 23:26:09 +00:00
Doris Ling
4c36c2903d Revert "WifiManager: Return status from startScan()"
This reverts commit b81c3d5f9a86e4e1f90be2ffaa81ea5df8fce684.

Bug: 77297012
Change-Id: Ie8727343650b549d4f438643d50a10fe50ab52b1
Reason: this change is breaking the build
2018-04-26 22:31:45 +00:00
Roshan Pius
1eeab66937 Merge "WifiManager: Return status from startScan()" into pi-dev
am: deb2e6ed8c

Change-Id: I289d25d233c53ab854df32ae418231ece8c5900e
2018-04-26 14:42:46 -07:00
TreeHugger Robot
deb2e6ed8c Merge "WifiManager: Return status from startScan()" into pi-dev 2018-04-26 21:14:46 +00:00
Roshan Pius
b81c3d5f9a WifiManager: Return status from startScan()
Bug: 77297012
Test: Ensured that scans from settings are still running.
Test: Unit tests
Change-Id: I0ffea57c48ad2ef5312dd90462b4b707cbf2368c
2018-04-24 15:55:51 +00:00
Rebecca Silberstein
c5e42dc131 Merge "update wifi unit test script" into pi-dev
am: 4a7913c268

Change-Id: I1a55eed1317ab101837b24d3162d1218d19c6ef6
2018-04-24 05:58:08 -07:00
Rebecca Silberstein
3f26ff2f56 update wifi unit test script
Need to add "--no-hidden-api-checks" to unit test script.

Verified by running runtests

Bug: 78465388
Test: frameworks/opt/net/wifi/tests/wifitests/runtests.sh
Change-Id: I916a2870bde2cbfe1966d18a0f7a13def2bd1ce7
2018-04-23 15:54:36 -07:00
Nicolas Geoffray
03ba2d9241 Merge "Exempt tests for hidden APIs." into pi-dev
am: 0e675bd901

Change-Id: I012a1ce8483f5fdddf60cfd33ea4303d72455fca
2018-04-10 09:56:52 -07:00
TreeHugger Robot
0e675bd901 Merge "Exempt tests for hidden APIs." into pi-dev 2018-04-10 16:34:05 +00:00
Roshan Pius
15bdc033ee Merge "WifiConfiguration: Remove a bunch of unused fields" into pi-dev
am: 086633e03d

Change-Id: Ib64b419627f453d4d3a0a330de56fa313ebdc29c
2018-04-06 13:03:06 -07:00
TreeHugger Robot
086633e03d Merge "WifiConfiguration: Remove a bunch of unused fields" into pi-dev 2018-04-06 19:54:20 +00:00
Roshan Pius
230f737932 Merge "WifiConfiguration: Modify time display in toString" into pi-dev
am: 1024314c67

Change-Id: I6af5338d7036cc085377b0c4185ad8f35fe88442
2018-04-06 11:34:37 -07:00