admin管理员组文章数量:1297002
I am writing an application/service for a product that DOES NOT meet the requirements for PackageInstaller.SessionParams.setRequireUserAction, namely it's written specifically for a piece of hardware that only supports Android 7.1 (Nougat), which is API level 25. The intent is to allow the application to poll a web server, download and subsequently install an updated APK when necessary.
.SessionParams#setRequireUserAction(int)
For installers that have been granted the REQUEST_INSTALL_PACKAGES permission, user action will not be required when all of the following conditions are met:
requireUserAction is set to USER_ACTION_NOT_REQUIRED. The app being installed targets:
API 29 or higher on Android S (API 31)
API 30 or higher on Android T (API 33)
API 31 or higher on Android U (API 34)
API 33 or higher on Android V (API 35)
The installer is:
The update owner of an existing version of the app (in other words, this install session is an app update) if the update ownership enforcement is enabled.
The installer of record of an existing version of the app (in other words, this install session is an app update) if the update ownership enforcement isn't enabled.
Updating itself.
The installer declares the UPDATE_PACKAGES_WITHOUT_USER_ACTION permission.
However, I'm wondering if I give this application elevated privileges, will it not require user action anymore?
I'm also tagging this with android-source since making this change requires us to allow-list the application, I believe. I could be mistaken, though.
Thanks for your help!
本文标签: androidCan systemprivileged applications update themselves without user interactionStack Overflow
版权声明:本文标题:android - Can systemprivileged applications update themselves without user interaction? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741630590a2389340.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论