This reverts commit cf4c99720b.
Reason for revert: not related to launcher changes
Test: will add CTS tests.
BUG: 162600626
CTS-Coverage-Bug: 168925819
Change-Id: I5a6832ef7907c2be90758a553514fb0dedb8c8e1
... Because the permission is already privileged and used by unbundled APKs.
Bug: 171062986
CTS-Coverage-Bug: 171196794
Test: build
Change-Id: Ibd6f961094fab8af71cfa26f54d97e69496633e2
* changes:
Revert "[incremental/pm] LauncherApps APIs for loading state and progress"
Revert "[pm/incremental/api] exposing package state names and reasons"
Revert "Fix LauncherAppsService queryIntentLauncherActivities"
This reverts commit e0b6a4df83.
Reason for revert: Testing a fix for b/171027242 - this doesn't imply this revert will be needed, or the commit is at fault.
Change-Id: Iaf8e2c075f188df95c68824b71362629c6adabfc
ag/12640480 accidentally changed the logic of
`queryIntentLauncherActivities`. Fixing it and
adding a few polish.
Test: atest NexusLauncherOutOfProcTests
BUG: 170963871
BUG: 170959052
Change-Id: I9a69ac15aba4d67fc03a581c381ead3cc3eae073
Those annotations could be inferred by some tools (like Kotlin), but the
https://checkerframework.org/ doesn't check inherited annotations
complaining about all equals() invocations that get nullable argument.
The change was generated by running
find . -name \*.java | xargs sed -i 's/public boolean equals(Object /public boolean equals(@Nullable Object /'
in the frameworks/base directory and by automatically adding and
formatting required imports if needed. No manual edits.
Bug: 170883422
Test: Annotation change only. Should have not impact.
Exempt-From-Owner-Approval: Mechanical change not specific to any component.
Change-Id: I5eedb571c9d78862115dfdc5dae1cf2a35343580
- Made all fields private.
- Replaced ParsedPermission usage with PermissionInfo.
The BasePermission class was using ParsedPermission and PermissionInfo
to keep track of the same set of information. Since we only need to
support getPermissionInfo(), we can keep track of the information with
PermissionInfo alone, dropping dependency on ParsedPermission which
isn't and won't be an API.
The logic of addToTree() and updateDynamicPermission() became a bit
weird/broken after the package parser refactoring regarding how the
new ParsedPermission/PermissionInfo was derived, so Pie BasePermission
implementation was taken as a reference for what the intended behavior
actually was.
Bug: 158736025
Test: presubmit
Change-Id: I414d43c3e98e9267d74de35eb62b7d1b6524a13f
We would like to expose package states and unstartable reasons to public
APIs. Two main users will be:
1) sys UI, which will display alert windows on top of a foreground app
when the package becomes unstartable, with different contents in the alert
window based on the reason code.
2) Play Store, which will collect package state change information which
will be used to determine future package delivery strategies.
Test: will add CTS tests.
BUG: 162600626
CTS-Coverage-Bug: 168925819
Change-Id: I71bafb36b230ea93b34e8556b57563e4ba3b837d
Bug: 157149018
Test: WindowLayoutAffinity shows up for activities that set this
attribute (android:windowLayoutAffinity in layout).
Change-Id: I36bce99e146992b6ecf6c7be1065ae1603a0fae7
Exposing package state changes and progress changes via LauncherApps
and LauncherActivityInfo as public APIs.
BUG: 165841645
Test: builds (will add CTS tests)
CTS-Coverage-Bug: 168925573
Change-Id: I2b5ea698799f9a762b7d9c79d62636d3db187c1f
Fixes: 168260114
Test: refactoring, manually enabled security logs, compared with the previous version
Change-Id: I36f4939386b57130767860c13ea2816873f9f46a
* changes:
Upgrade AndroidFrameworkBinderIdentity to fatal.
Tighten up Binder.clearCallingIdentity() usage.
Tighten up Binder.clearCallingIdentity() usage.
Tighten up Binder.clearCallingIdentity() usage.
This is a third CL in a chain that adjusts existing malformed code
to follow AndroidFrameworkBinderIdentity best-practices.
Specifically, if a thread clears an identity they need to restore it
to avoid obscure security vulnerabilities. In addition, the relevant
"try" block must start immediately after the identity is cleared to
ensure that its restored if/when any exceptions are thrown.
Bug: 155703208
Test: make
Exempt-From-Owner-Approval: trivial refactoring
Change-Id: I74cb958b68d55a647547aae21baff6ddc364859b
Introducing 'required-feature' and 'requred-not-feature' tags that could
be used "inside" 'uses-permission' elements.
Elements of both types should have non-empty 'android:name' attribute to
specify the name of the feature.
If the 'uses-permission' element contains 'required-feature' and/or
'required-not-feature' elements, the permission will only be "requested"
if the system supports all the 'required-feature's and does not support
any of the 'required-not-feature's.
The new elemets are "replacement" of the existing
'android:required(Not)Feature' attributes that can be optionally added
to 'uses-permission' elements, but allow to specify only 1 feature each.
However the 'android:required(Not)Feature' attributes remain supported
for compatibility and will be treated similarly to the
'require-(not-)feature' elements.
Bug: 168079571
Test: make && flash
Test: atest CtsContentTestCases:PermissionFeatureTest
Change-Id: Id3043530ebac6bd11805a611cebbf08b45e12f68
Introduce a new extra field for ACTION_PACKAGE_REMOVED intent to
signal that the application was removed automatically without the
user-initiated action.
If the system automatically prunes a package [eg. an instant app], we
mark the broadcast with that information. Launchers or other applications
can use this information to potentially alter their behaviour.
Bug: 111318529
Test: atest CtsAppSecurityHostTestCases:EphemeralTest
Change-Id: I3a4690d7df6e2dce10b246fe20a627ba2eed5da0
There was a regression in the AIDL compiler recently that removed the
requirement that, like in Java, .aidl unstructured parcelables (these
parcelable declarations) are in directories and files which match their
packages and file names. This CL moves relevant files to the correct
directory required by their type.
Bug: N/A
Test: build
Change-Id: I5fd112f1bcd0d1fc3be3c8dc7f1959242d43858e
When the DisplayAreaGroup has a different orientation from the Display,
reverse the app requested orientation.
As a result, when the display rotates to the reversed orientation, the
DAG and the requested app will be in the requested orientation.
For example, if the display is 1200x900 (landscape), and this DAG is
600x900 (portrait).
When an app below this DAG is requesting landscape, it should actually
request the display to be portrait, so that the DAG and the app will be
in landscape.
Bug: 155431879
Test: manual: test with dual display area policy
Test: atest WmTests:DisplayAreaGroupTest
Change-Id: Ie6874413ca0f6fa999632fb26f27e9913ccaee0d
Based on go/incremental-states-design with basic
setter/getters.
Defines IncrementalStates class which handles state transitions.
New (internal) Intent actions: PACKAGE_FULLY_LOADED, PACKAGE_STARTABLE,
PACKAGE_UNSTARTABLE.
BUG: 168043976
Test: unit tests
Change-Id: I7b0ec2dd9f028ee620a9307a1e71ddf12ea5a9af
* changes:
Do not show rationale when permission is restricted
Add role allowlist for restricted permissions
Add documentation to APIs using non-inclusive lanuage
Treat background mic/camera normally
Introduce new permissionFlag
Split camera and microphone for background modes
Add background microphone and camera permission
The client submits a RecognitionRequest via MusicRecognitionManager. System server opens an audio stream based on the request and sends it to a MusicRecognitionService (which is exposed by a system app). The result is passed back through system server to the original caller.
Test: tracked in b/169662646
Bug: 169403302
Change-Id: I4c7fd9d9d72ddd5678867fd037cab6198bff2c2d
This commit introduces the TimeManager API class. It is intended to
provide access to the time and time zone detector services, which
historically have had their own (internal) API classes to access them.
This commit contains various fixes to the listener handling logic
noticed while testing the APIs.
The first APIs on TimeManager are being exposed for use by SetUp Wizard,
which requires System APIs.
The APIs enable the calling app to determine the capabilities for /
config of the current user that affect time zone detection and then
alter them.
The primary usecase:
The rules for who can do what and when for time zone detection are
becoming more complicated, and device and user capabilities will be
affected by compile time constants, device config (resources) and device
hardware. By exposing this API, the complex logic can be encoded in one
place (the system server), rather than duplicating them in multiple
client apps.
These APIs are also intended for use by SettingsUI (and the various form
factor versions of that), but settings apps do not currently require
them to be marked with @SystemApi.
Bug: 159891384
Test: atest services/tests/servicestests/src/com/android/server/timezonedetector/
Test: atest android.app.time
Change-Id: I9b59099748e2391c180e124edf83fa521beb1b51
This API allows the test to create
contention on AM, PM and/or WM locks.
Test: a prototype lock contention test
Bug: 168630376
Change-Id: I656b6b412d517cb3b3b16367d8712f78ccbc33d8
The new permission flag is for restricted permissions which the
installer is not able to exempt.
Test: Install test app
Bug: 158311343
Change-Id: I7340948690ea69750ef479d1b8f0ac8a6177c98c