Age | Commit message (Collapse) | Author |
|
This reverts commit dd85e91cea26c7f706af36c852e79d5b4ca1f173.
Bug: 217366135
Reason for revert: Need this to fix a crash bug in tm-dev
Change-Id: I2a94c278edc0681c5b8af6ea0a0171b71d72c650
(cherry picked from commit dbaf406ccb0ed887d4e93057c9ec0d3457f14457)
Merged-In: I2a94c278edc0681c5b8af6ea0a0171b71d72c650
|
|
This reverts commit 02dcbe72b3564559eaa9c2e2714824e4aac6f18c.
Reason for revert: Causing builds to fail b/237471430
Change-Id: I6165d838abf312085050359377f67a68a5f8b51a
(cherry picked from commit f5dd42bbd05e68f7763ccaa9fae5642acc4ceba1)
Merged-In: I6165d838abf312085050359377f67a68a5f8b51a
|
|
Bug: 217366135
Tag: #feature
Test: manual
Ignore-AOSP-First: to be chery-picked
Change-Id: If8ae530a284151888a3f89a51d2c58f2a5cd3644
(cherry picked from commit 02dcbe72b3564559eaa9c2e2714824e4aac6f18c)
Merged-In: If8ae530a284151888a3f89a51d2c58f2a5cd3644
|
|
Since Bluetooth is becoming a mainline module, it can no longer call the
allowBlocking hidden api.
Instead, corresponding aidl are moved to be oneway and use a synchronous
data to handle the return value.
also: aosp/1927380 for similar work on all bluetooth profiles
BluetoothGatt will be done next
Bug: 211851706
Test: build + start bt
Tag: #refactor
Ignore-AOSP-First: merge conflict resolution
Change-Id: I715cc2d8f2ae42be6d1099cd73095d37fa9e30f4
|
|
|
|
Modified myAttributionSource() to check for global AS for
process in ActivityThread and fallback to building new AS
with PackageManager#getPackageForUid(myUid()) if null.
Tag: #feature
Bug: 210467846
Bug: 210468546
Test: build
Change-Id: I7aa75395469bf0bb806100420faaf98c52057355
CTS-Coverage-Bug: 210906055
|
|
Attributable is called by bluetooth and it's hidden.
By copying into bluetooth we are now allowed to call it
Bug: 210467788
Test: build
Tag: #refactor
Change-Id: I73ea07c9439988ab5477c82799f718c6d81513be
|
|
This reverts commit 39639385f90678e97aa6848ae3b43de6bfb3b49e.
Reason for revert: Introducing regression for gms core
Test: None
Change-Id: I644b10c1869c12e1622300de43bfbdb57fb583d8
|
|
Tag: #feature
Bug: 200202780
Test: manual
Change-Id: I8d4be1da1bcb5b819c324f1a3a89c7dc317c31d6
|
|
Attribution source constructor are hidden api
Add a Builder option to take a AttributionSource as parameter
Test: atest BluetoothInstrumentationTests
Bug: 195144968
Tag: #refactor
Ignore-AOSP-First: No such thing on aosp
Change-Id: I901c8afff6a40bd8484fd8e10baf290aa483c280
|
|
Since developers can use a BluetoothDevice object can make remote
calls, it needs to have an accurate AttributionSource. Previous CLs
had updated many places where these BluetoothDevice instances were
passed across Binder interfaces, but this change updates several
remaining locations which had been missed.
Introduces new "Attributable" marker interface to offer consistent
tooling when applying AttributionSource updates.
Bug: 187097694
Test: atest BluetoothInstrumentationTests
Change-Id: Icad3b9726591f0fbad58a493cefa5a0af7648280
|
|
To prepare for future work which will plumb AttributionSource values
through all remaining AIDLs, we need profiles to interact directly
with the specific BluetoothAdapter they were created from. This is
how we'll ensure that the relevant AttributionSource can be chained
down from the original Context they're obtained from.
This change also marks getDefaultAdapter() as deprecated to clearly
communicate that BluetoothManager.getAdapter() is the best-practice
path to obtaining a correctly scoped BluetoothAdapter instance.
Bug: 183626112
Test: atest BluetoothInstrumentationTests
Change-Id: I1e15170d7679019bbb6e396279d6e633e3dad4d6
|
|
This adds attribution source to BT method calls. This is now
required to allow the app ops for the new BT permissions
(BLUETOOTH_CONNECT, BLUETOOTH_ADVERTISE, and BLUETOOTH_SCAN)
to be noted.
Bug: 183626112
Test: atest BluetoothInstrumentationTests
Change-Id: I81598553b762e491d6364064a2e1ef41dec89bf9
|
|
Previous CLs had started passing AttributionSource values across
Binder calls inside BluetoothDevice instances, but this can cause
confuse the permission check logic in the future; we should instead
always aim to use the AttributionSource closest to the app making
the call, instead of parceling it.
This change also improves logging to highlight when we're quietly
treating a permission as denied, and when a UID is mismatched.
Bug: 186106084
Test: atest BluetoothInstrumentationTests
Change-Id: I5d3fdb3c573cb9e77474952d8680caa4c4c464eb
|
|
This change adds a "BluetoothPermissionChecker" that ensures that
all Bluetooth permission annotations are consistent. In addition, it
verifies that all Bluetooth public APIs have been audited to be
permission protected where relevant.
We've currently standardized on saying that APIs that return device
or Bluetooth state information (without sharing details about any
particular remote Bluetooth device) do not need to be permission
protected.
This change is only annotations and has no behavior changes.
Bug: 183626724
Test: ./build/soong/soong_ui.bash --make-mode Bluetooth RUN_ERROR_PRONE=true
Change-Id: Ie80b15b058359bf1e9a6ee881b89cb3e5b584ca1
|
|
Recent work has introduced a new "Nearby devices" runtime permission
which protects all existing Bluetooth APIs; we've done this by
defining a <split-permission> to convert the old BLUETOOTH and
BLUETOOTH_ADMIN permissions into one of three new permissions:
* BLUETOOTH_ADVERTISE: Required to be able to advertise to nearby
Bluetooth devices.
* BLUETOOTH_CONNECT: Allows applications to connect to paired
bluetooth devices.
* BLUETOOTH_SCAN: Required to be able to discover and pair
nearby Bluetooth devices.
At its core, this change begins updating the Bluetooth APIs to have
correct @RequiresPermission indicating which permission is actually
enforced internally. To ensure alignment across Binder, the newly
added "RequiresPermissionChecker" Error Prone checker was used to
discover any inconsistencies, ensuring correctness from server-side
enforcement up through to the public APIs.
In addition, since developers will continue building apps for both
modern and legacy platforms, this change introduces new auto-doc
annotations which will emit helpful consistent documentation
describing the behavior of older devices that are still using the
old permission model.
Bug: 183626724
Test: ./build/soong/soong_ui.bash --make-mode Bluetooth RUN_ERROR_PRONE=true
Change-Id: I02aa127e8e07f239561f4f2a3bbdfc6fccb82f7f
|
|
With this patch it is possible to enable eatt_support as a GATT Client
or GATT Server.
Tag: #feature
Bug: 159786353
Test: manually verified against device supporting EATT
Sponsor: jpawlowski@
Change-Id: I6835a2bbd1b0ab9d6d64ee2bac5dfc96c0563afd
|
|
In the core functionality this changes everything including aidl's and
field names:
- Context
- ContentProvider
- AppOps*
- Package parsing
For the rest, this is a shallow change to only change to the changed
APIs. This keeps the change small-ish
Exempt-From-Owner-Approval: Rename
Fixes: 148792795
Test: TH
Change-Id: I2a2245fe76e09e62cb13d5785d2efb4a304ba54a
Merged-In: I2a2245fe76e09e62cb13d5785d2efb4a304ba54a
|
|
Test: atest CtsAppOpsTestCases (Now with canary test for this code)
Bug: 136595429
Change-Id: I90bb6b017da4f03038fce76760a860390b727f00
|
|
FeatureIds are not yet available, hence in BTManager we assume always a
"null" featureId.
The effect of this change is that for apps that opt into using
featureIds, they will have one BluetoothAdapter per feature, not one per
process as before. In my testing this caused no problem. Most apps
won't use featureIds, hence for most apps there is no change in
behavior.
Test: used bluetooth
Bug: 136595429
Change-Id: Ic40326ea331c60f764f213bb2673cb4c49a81604
|
|
By checking bluetooth adaptor before accessing it,
because it could be null on devices that do not
support bluetooth, such as android emulator.
BUG: 121129248
Test:
lunch sdk_gphone_x86-userdebug
make -j
emulator
launch chrome and it should not crash
Change-Id: Ia75b5ee1efa3a8195056dada079239931eb9d901
|
|
Test: manual
Bug: 118347252
Change-Id: Icbc2e7e756b16ffd181924b586a0292c2bf32ec5
|
|
Fixes: 71491860
Test: Pair and connect with a phone
Change-Id: I3ead8154765267105c74cd800f571933bbe82e07
|
|
Certain APIs require that a device have a specific feature to operate
correctly, so start annotating them.
Test: builds, boots
Bug: 72284763
Change-Id: Ie2f30284bdfdb6acc4067f434eba3b5433837606
Exempt-From-Owner-Approval: simple annotations
|
|
* Automatic style corrections through IDE
Bug: 63596319
Test: make checkbuild, no manual changes, no functional changes
Change-Id: I2397d55abc34c9b7a9b748bec6137778df3421a7
|
|
am: 3205ff1331
Change-Id: I0cd44ad8d22da154d0bf666b9075a3fcbc655439
|
|
It was somewhat unclear which is the preferred method of retrieving a
BluetoothAdapter. Make it clear that using BluetoothManager is
preferred, and remove references to the old method in BluetoothManager
docs since it is only avaialable in API 18 or higher.
Test: recompile, check that documentation is updated
Fix: 33355430
Change-Id: Ia20b4e45dca03bc2f13c2ab477799b89c5e14f45
|
|
Most @SystemApi methods should be protected with system (or higher)
permissions, so annotate common methods with @RequiresPermission to
make automatic verification easier.
Verification is really only relevant when calling into system
services (where permissions checking can happen on the other side of
a Binder call), so annotate managers with the new @SystemService
annotation, which is now automatically documented.
This is purely a docs change; no logic changes are being made.
Test: make -j32 update-api && make -j32 offline-sdk-docs
Bug: 62263906
Change-Id: I2554227202d84465676aa4ab0dd336b5c45fc651
|
|
Add support for AnyThread, CallSuper, and UiThread.
Another related CL started documenting @RequiresPermission, so remove
duplicated information in existing APIs.
Suppress auto-doc on a handful of classes that are already
well-documented.
Test: make -j32 offline-sdk-docs
Bug: 37526420
Change-Id: I791437dccec0f11d5349a23b982ba098cb551af8
|
|
All that this member variable is doing right now is leaking a
reference to a context without any benefit.
Bug: 31752040
Bug: 31710795
Change-Id: If2241422533318b866340e8dcc9f5fbd9518349c
|
|
Fixed the link that points to the Bluetooth guide.
Bug: 29268546
Change-Id: I51c48cebf45c78481f8853a93ff7bcd8483d69ba
|
|
Bug: 27665077
Change-Id: I2a06c1a65f22b2f9095a859f5bdd39d4626da165
|
|
Change-Id: I5bc86f8ec6ea5c873f1e14dab0e0c47c5c9df7f7
|
|
Support for passing preferred transport for GATT connections as part of
Connect APIs
Change-Id: I93938dce519b8fa12de41d7e8690dc9355ce2dc5
|
|
App does not need to explicitly register/unregister callback
bug 8599881
Change-Id: I18cfef14d7ddb344722945e657dcb959823b412b
|
|
Updated API headers. Add BluetoothManager to be retrieved by
context.getSystemService(Context.BLUETOOTH_SERVICE).
LE scan functions are placed in BluetoothAdapter
The GATT API are device driven instead of a profile-driver.
bug 8450158
Change-Id: I424a4cedaac3ef8120a05996500008dd210d2553
|