gpt4 book ai didi

android - Android 应用程序升级在技术上是如何工作的?

转载 作者:塔克拉玛干 更新时间:2023-11-02 07:56:30 25 4
gpt4 key购买 nike

有人可以解释或指出我可以阅读 Android 应用升级实际上如何在操作系统级别细节上工作的资源吗?

最佳答案

从包管理器日志来看,似乎采取了以下升级步骤:

1) 在临时位置下载包。

act=android.intent.action.PACKAGE_NEEDS_VERIFICATION dat=file:///data/app/vmdl1854135520.tmp typ=application/vnd.android.package-archive

2) 做包校验。

06-30 17:59:02.751 3701 3751 D PackageManager: [MSG] PACKAGE_VERIFIED: observer{237546897}

3) 重命名包。

06-30 17:59:03.361 3701 3751 D PackageManager: Renaming /data/app/vmdl1854135520.tmp to /data/app/com.vzw.hss.myverizon-1

4) 杀死现有应用

06-30 17:59:03.361 3701 3751 D PackageManager: !@killApplicatoin: 10031, replace sys pkg

5) 卸载apk

06-30 17:59:03.381 3701 3751 D PackageManager: Running dexopt on: /data/app/com.vzw.hss.myverizon-1/base.apk pkg=com.vzw.hss.myverizon isa=arm64 vmSafeMode=false interpret_only=false

**06-30 17:59:02.741  3701  3751 D PackageManager: [VERIFY] Found 1 verifiers for intent Intent { act=android.intent.action.PACKAGE_NEEDS_VERIFICATION dat=file:///data/app/vmdl1854135520.tmp** typ=application/vnd.android.package-archive flg=0x10000001 } with 0 optional verifiers
06-30 17:59:02.741 3701 3751 D PackageManager: [VERIFY] sendOrderedBroadcastToRequiredVerifier:
06-30 17:59:02.741 3701 3751 D PackageManager: PackageVerificationState{
06-30 17:59:02.741 3701 3751 D PackageManager: verifier packages=com.android.vending(10034),
06-30 17:59:02.741 3701 3751 D PackageManager: intent=Intent { act=android.intent.action.PACKAGE_NEEDS_VERIFICATION dat=file:///data/app/vmdl1854135520.tmp typ=application/vnd.android.package-archive flg=0x10000001 (has extras) }
06-30 17:59:02.741 3701 3751 D PackageManager: others=28, false, false, false, false, false
06-30 17:59:02.741 3701 3751 D PackageManager: }
06-30 17:59:02.741 3701 3751 D PackageManager: remove MCS_UNBIND message and Posting MCS_UNBIND 10 secs later
06-30 17:59:02.751 3701 3701 D PackageManager: [VERIFY] onReceive for RequiredVerifier id=28
06-30 17:59:02.751 3701 3701 D PackageManager: [VERIFY] send delayed message for CHECK_PENDING_VERIFICATION after : 10000
06-30 17:59:02.751 3701 4589 D PackageManager: [VERIFY] verifyPendingInstall(28, VERIFICATION_ALLOW), uid=10034
06-30 17:59:02.751 3701 3751 D PackageManager: [MSG] PACKAGE_VERIFIED: observer{237546897}
06-30 17:59:02.751 3701 3751 D PackageManager: [VERIFY] PACKAGE_VERIFIED:
06-30 17:59:02.751 3701 3751 D PackageManager: PackageVerificationState{
06-30 17:59:02.751 3701 3751 D PackageManager: verifier packages=com.android.vending(10034),
06-30 17:59:02.751 3701 3751 D PackageManager: intent=Intent { act=android.intent.action.PACKAGE_NEEDS_VERIFICATION dat=file:///data/app/vmdl1854135520.tmp typ=application/vnd.android.package-archive flg=0x10000001 cmp=com.android.vending/com.google.android.vending.verifier.PackageVerificationReceiver (has extras) }
06-30 17:59:02.751 3701 3751 D PackageManager: others=28, false, false, false, false, false
06-30 17:59:02.751 3701 3751 D PackageManager: }
06-30 17:59:02.751 3701 3751 D PackageManager: [VERIFY] broadcastPackageVerified(28, VERIFICATION_ALLOW, file:///data/app/vmdl1854135520.tmp)
06-30 17:59:02.761 3701 3751 D PackageManager: /data/app/vmdl1854135520.tmp already staged; skipping copy
06-30 17:59:02.761 3701 3751 D PackageManager: remove MCS_UNBIND and Posting MCS_UNBIND
06-30 17:59:02.761 3701 3751 D PackageManager: [MSG] PROCESS_PENDING_INSTALL: observer{237546897}
06-30 17:59:02.761 3701 3751 D PackageManager: currentStatus{1}
06-30 17:59:02.761 3701 3751 D PackageManager: installPackageLI: path
06-30 17:59:03.321 3701 3751 W PackageManager: verifying app can be installed or not
**06-30 17:59:03.361 3701 3751 D PackageManager: Renaming /data/app/vmdl1854135520.tmp to /data/app/com.vzw.hss.myverizon-1**
**06-30 17:59:03.361 3701 3751 D PackageManager: replacePackageLI**
**06-30 17:59:03.361 3701 3751 D PackageManager: !@killApplicatoin: 10031, replace sys pkg**
06-30 17:59:03.371 3701 3751 W PackageManager: Trying to update system app code path from /system/priv-app/MyVerizon to /data/app/com.vzw.hss.myverizon-1
06-30 17:59:03.371 3701 3751 I PackageManager: scanFileNewer : com.vzw.hss.myverizon
**06-30 17:59:03.381 3701 3751 D PackageManager: Running dexopt on: /data/app/com.vzw.hss.myverizon-1/base.apk pkg=com.vzw.hss.myverizon isa=arm64 vmSafeMode=false interpret_only=false**
06-30 17:59:06.861 3701 3751 I PackageManager: do mInstaller.dexopt : 0
06-30 17:59:06.861 3701 3751 D PackageManager: Time to dexopt: 3.482 seconds
06-30 17:59:06.861 3701 3751 D PackageManager: !@killApplicatoin: 10031, update pkg
06-30 17:59:06.861 3701 3751 W PackageManager: Code path for pkg : com.vzw.hss.myverizon changing from /system/priv-app/MyVerizon to /data/app/com.vzw.hss.myverizon-1
06-30 17:59:06.861 3701 3751 W PackageManager: Resource path for pkg : com.vzw.hss.myverizon changing from /system/priv-app/MyVerizon to /data/app/com.vzw.hss.myverizon-1
06-30 17:59:06.961 3701 3751 D PackageManager: New package installed
06-30 17:59:06.971 3701 3751 I PackageManager: Un-granting permission android.permission.sec.ENTERPRISE_DEVICE_ADMIN from package com.samsung.mdmtest1 (protectionLevel=2 flags=0x89be44)
06-30 17:59:06.971 3701 3751 I PackageManager: Un-granting permission com.sec.enterprise.knox.permission.KNOX_ENTERPRISE_BILLING from package com.samsung.mdmtest1 (protectionLevel=2 flags=0x89be44)
06-30 17:59:07.141 3701 3751 D PackageManager: doPostInstall for uid{10031}
06-30 17:59:07.151 3701 3751 D PackageManager: [MSG] MCS_UNBIND
06-30 17:59:07.151 3701 3751 D PackageManager: [MSG] POST_INSTALL: observer{237546897}
06-30 17:59:07.151 3701 3751 D PackageManager: Handling post-install for 29
06-30 17:59:07.661 3701 3751 D PackageManager: result of install: 1{237546897}

关于android - Android 应用程序升级在技术上是如何工作的?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30242007/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com