Age | Commit message (Collapse) | Author |
|
MediaProvider#INCLUDED_DEFAULT_DIRECTORIES is internally used to grant
access for file rename based on relative path. It can be misused by
setting it in the bundle. Updated the code to stop using this extra and
stope respecting it in AccessChecker class.
Test: atest MediaProviderTests
Bug: 415783046
Flag: EXEMPT bug fix
Change-Id: I91c44428dc730be4cf42b3cb9c02e8eca4440f81
(cherry picked from commit a631dca1a8c02d39d9a578ce331a7b23bf7ef962)
Merged-In: I91c44428dc730be4cf42b3cb9c02e8eca4440f81
|
|
MediaProvider
The content values retrieved from extras in the MediaProvider can have
values preset by the calling app and can affect other fields set.
Instead of retrieving the content values, we only retrieve a boolean
field that says whether the is_favorite is to be set to true or false.
All processing logic is shifted to MediaProvider.
Bug: 417194323
Test: EXEMPT Bugfix
Flag: EXEMPT Bugfix
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:17ebbe43efe36a7c00d3941513d5caf2db91f628)
Merged-In: I0227139b0a04efcb7456557fbf2d47996c017bad
Change-Id: I0227139b0a04efcb7456557fbf2d47996c017bad
|
|
|
|
There is a bug in AppOpsManager that keeps legacy storage granted even
when an app updates its targetSdkVersion from value <30 to >=30.
If an app upgrades from targetSdk 29 to targetSdk 33, legacy storage
remains granted and in targetSdk 33, app are required to replace R_E_S
with R_M_*. If an app updates its manifest with R_M_*, permission check
in MediaProvider will look for R_E_S and will not grant read access as
the app would be still treated as legacy.
Test: atest PermissionUtilsTest
Bug: 315914683
Flag: EXEMPT bug fix
Change-Id: I22d0a329fbea5afe9dea2bc5179596db7a2ef402
|
|
MediaStore.getExternalVolumeNames()." into main
|
|
* changes:
Handle x-profile delegation for java picker.
Properly handle delegation in x-profile checks.
|
|
|
|
Bug: b/402367358
Test: atest MediaProviderTests:UserManagerStateTest
Flag: EXEMPT bug_fix
Change-Id: Iabc4de0d39720dcb355cf98c99724feacf6899e0
|
|
Created new API to bulk update oem_metadata. This can be done only with
UPDATE_OEM_METADATA_PERMISSION which is signature and privileged.
Triggering bulk update of oem_metadata column will mark it as null for
rows with oem supported mime type till the next idle maintenance run
re-fetches the values from OEMMetadataService. Also added support
for OEM_METADATA update for a URI using update API.
Test: atest OemMetadataServiceTest
Bug: 352528913
Change-Id: If2ee9050304ab1f60ca402bf4205a34b58277e76
Flag: com.android.providers.media.flags.enable_oem_metadata_update
|
|
MediaStore.getExternalVolumeNames().
Test: MediaProviderChangeIdTest
Bug: 391360514
Flag: com.android.providers.media.flags.exclude_unreliable_volumes
Change-Id: I137bd91ce8452754a32c6f048e6e24f191643ebe
|
|
The mime type could be null when looking up extension in getExtFromMimeType. Check it first to avoid an NPE.
Test: com.android.providers.media.util.MimeUtilsTest
Bug: 401468886
Flag: EXEMPT test fix
Change-Id: Ie4b5424da6d38a11e300995fd407d8429a67cd39
|
|
|
|
|
|
Use checkOp calls instead of noteOp in scenarios where -
* No data is delivered after checking permissions for the given uid
* The record of permission check is not required
This is done to improve permission checks performance and decrease the load on AppOpsManager since noteOp calls take significantly more time than checkOps.
BUG: 323574186
Test: build MP
Flag: EXEMPT bugfix
Change-Id: Ie954e71e98dec28e4b7cb2dcacb6af7540b397aa
|
|
Bug: 389681152
Test: atest PickerDbFacadeTest
Flag: EXEMPT bug fix
Change-Id: Ibe8a80d65c4dff6368352944e004c5c934430953
|
|
|
|
Bug: b/394231676
Test: atest MediaProviderTests
Flag: EXEMPT bug_fix
Change-Id: Id739048e66ae64ffebec97eedf5740743d974e38
|
|
|
|
In Android 15, some unsupported MIME types were introduced, causing incorrect extension selection for unsupported MIME types. This fix ensures that the correct extensions are assigned to these MIME types.
Test: atest MimeTypeFixHandlerTest
Test: atest PhotoPickerTest
Flag: com.android.providers.media.flags.enable_mime_type_fix_for_android_15
Bug: 376910932
Bug: 397897311
Change-Id: Ib6c969b8a0b9c719b628c71309afc5bd0a498af0
|
|
into main
|
|
* Ensure that CrossProfileIntentForwarderActivity resolution is accurate.
This relies on the @hide property `targetUserId` by accessing it via
reflection as there is no API that can surface this information for
`module_current` targets.
* Add test cases for devices that may be configured to have more than
one managed profile, and may not be compatible with AOSP source code
assumption to ensure CrossProfile detection fails closed.
Bug: b/394231676
Test: atest MediaProviderTests:UserManagerStateTest
Flag: EXEMPT bugfix
Change-Id: I0770a5723b67fe963bdaa9c5b8e6f7ca12eff6b4
|
|
Build.VERSION_CODES.BAKLAVA is flagged right now. MTS is unable to
recognize the flag.
BUG: 400347834
Test: banchan com.google.android.mediaprovider mainline_modules_arm64 -> atest CtsScopedStorageDeviceOnlyTest
Flag: EXEMPT bugfix
Change-Id: Ic931d3c43629227bd5b5d6cd6068e8580cf525ae
|
|
categoryId and its authority" into main
|
|
categoryId and its authority
The current implementation erases the complete cache for both media sets
and media set content. It is fine for the MVP since we only have one
category at the moment but in case we add more in the future, this
should not be the behaviour.
Test: verified manually, fixed corresponding tests
Bug: 394050877
Flag: com.android.providers.media.flags.enable_photopicker_search
Change-Id: Idd8980c0e573376df8100b44102dcc01b5e8e992
|
|
class
-SearchWorkerUtil holds all the common methods
Test: verified manually
Bug: 380815166
Flag: com.android.providers.media.flags.enable_photopicker_search
Change-Id: Ie00dc844baf0e644d23cc2fb97caf4e7d3073e6f
|
|
|
|
|
|
content." into main
|
|
* Media set contents are only visible in Photopicker UI if they have
also been synced in the main media table.
* For large cloud libraries, in case a full sync is triggered, it
can take a while before media sets contents can be displayed to
the user. In order to mitigate this, hide the categories that
contain media set contents while a full sync pending or in progress.
Bug: 393046585
Test: atest PickerSyncControllerTest
Flag: EXEMPT mitigation
Change-Id: Ie50daa7e9e8d84ee3e565f4299ba53310ea3a1ed
|
|
content.
Also update corresponding tests
Test: verified manually, all corresponding tests updated
Bug: 384475145
Flag: com.android.providers.media.flags.enable_photopicker_search
Change-Id: I1056ee98587cf736742dba654e8a450cdb64ab6c
|
|
Call notifyChange for attaching volume on Foreground instead of main
thread. When MediaProvider starts up it attaches existing volumes (most
probably only internal volume), attachVolume operation involves
notifying content observers about the volume attachment. Currently, this
happens on main thread during MediaProvider initialization, which would
take time if SyncManager is busy with other requests.
Running notifyChange on foreground thread saves us about 20% of MP
initialization time.
Test: manual & atest MediaProviderTests
Bug: 399347278
Flag: EXEMPT bug fix
Change-Id: If6f50169df2985d7eee8140b91b6ee83ef723851
|
|
Currently, picker DB is being opened in the initialization path of
MediaProvider which is discouraged operation. DB open could take time to
happen, especially if DB upgrade is to occure, which could significantly
increase MediaProvider initialization.
Instead, we deferred opening the DB to the first use of the DB.
getWritableDatabase is making sure that the DB is opened once, by
caching the DB opened on the first call and returning the same DB on any
subsequent get.
Test: atest PickerDbFacadeTest
Bug: 399347278
Flag: EXEMPT bug fix
Change-Id: Ib57a0f1716349ad5a8c71977035835b69247f2ce
|
|
main
|
|
This change :
* Uses CollapsibleToolbarBaseActivity for PhotopickerSettingsActivity
* Uses SettingsBasePreferenceFragment
BUG: 349670985
Test: manual
Flag: EXEMPT ui changes
Change-Id: I1148356700473fe52294ecfbc3bf5199c4c894c2
|
|
6da5c24dad am: b7afcb2d59
Original change: https://android-review.googlesource.com/c/platform/packages/providers/MediaProvider/+/3481292
Change-Id: I65c449199a158b77b7ee48b1dd65d3e5607b648a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
|
|
Checking for HDR plugin at creation could happen before
mediaserver is ready to respond, which could lead to ANRs at boot
especially for slower devices.
Bug: 361082713
Bug: 392798901
Test: presubmit
Change-Id: Ia8f8ca20cc1c36b6d92b26e726e9000e8e37e9e3
|
|
* There is an issue in CMP where resuming of syncs causes their
pagination logic to break. This change makes sure that we never resume
search results sync with the CMP.
Bug: 397368798
Test: atest PickerSyncManagerTest
Test: atest SearchResultsSyncWorkerTest
Flag: EXEMPT bug fix
Change-Id: I527cb6579acca8b39e81a5a83c8bb5ec884f933c
|
|
|
|
This reverts commit 804ffda5c53b853ef6b1d7297f8d4a0bf5354458.
Reason for revert: gantry rollout caused breakages
Change-Id: I8e118197c0dd8d3280d0af6500607d481979d7f5
|
|
|
|
Instead of creating a new thread everytime we want to fetch OEM
metadata, updating code to use a fixed thread pool of 3 threads. We do
not expect lot of concurrent requests to this as scanner code is
currently serialised, hence keeping thread pool size low. Also guarded
oem metadata connection code with try-catch to avoid onCreate() crash.
Test: atest OemMetadataServiceTest
Bug: 377432406
Change-Id: I70a0b6ca6ae43f7ba7ab086103365cc16b3497fa
Flag: EXEMPT minor fix
|
|
|
|
MediaStore.getExternalVolumeNames()." into main
|
|
In Android 15, certain unsupported MIME types were introduced. This ensures new files with these MIME types are handled with the correct MIME type also fixed the exsiting incorrect mime type and media type
Test: atest MimeTypeFixHandlerTest
Flag: com.android.providers.media.flags.enable_mime_type_fix_for_android_15
Bug: 376910932
Change-Id: I642ab9a03cf8cd059d28fe258b80fe05ab31c8ce
|
|
MediaStore.getExternalVolumeNames().
Test: MediaProviderChangeIdTest
Bug: 391360514
Flag: com.android.providers.media.flags.exclude_unreliable_volumes
Change-Id: I3fc6c71b6466ca195f77daf63764a3b3c9a3fc9c
|
|
|
|
MediaProvider" into main
|
|
Bug: 195138692
Test: com.android.providers.media.backupandrestore.MediaBackupAgentTest
Flag: com.android.providers.media.flags.enable_backup_and_restore
Change-Id: I9be5c57b9e6d19ef7b187153d4b2fb84727fda27
|
|
Bug: 395887352
Test: atest MediaGroupCursorUtilsTest
Flag: EXEMPT bug fix
Change-Id: Id96115ad30e6213634e1e53dac79ee30249c6363
|