APK 安装失败:[INSTALL_FAILED_VERIFICATION_FAILURE] [英] APK installation failed: [INSTALL_FAILED_VERIFICATION_FAILURE]

查看:78
本文介绍了APK 安装失败:[INSTALL_FAILED_VERIFICATION_FAILURE]的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在运行 AOSP 版本的 Jelly Bean (4.2) 的设备上安装 APK.

I'm trying to install an APK on a device running an AOSP build of Jelly Bean (4.2).

当我adb install my.apk"时,出现错误:

When I "adb install my.apk", I get the error:

[INSTALL_FAILED_VERIFICATION_FAILURE]

[INSTALL_FAILED_VERIFICATION_FAILURE]

我尝试使用testsign.jar"来签署"apk,但它并没有改变结果

I've tried using "testsign.jar" to "sign" the apk but it does not change the outcome

推荐答案

您需要在 ADB 安装期间禁用 APK 验证.如果安全中的设置变灰或不起作用,因为它应该尝试对设备进行脱壳,并且根据您的 API 级别(全局、系统、安全)运行的设置数据库中的设置

You need to disable verification of the APK during ADB install. If the setting in Security is greyed out or isn't working as it should try shelling into the device and, depending on which settings database the setting is in per your API level (Global, System, Secure) run

$ adb shell settings put global verifier_verify_adb_installs 0

如果您真的可以设置它,它将阻止通过 ADB 检查 APK.

If you can actually set it, it will prevent checking of APKs over ADB.

有时您还需要使用以下方法禁用包验证器:

Sometimes you will need to disable the package verifier as well using:

$ adb shell settings put global package_verifier_enable 0

在 KitKat 上,您可以在此处看到这些设置位于全局数据库中:

On KitKat, you can see here that these settings are in the Global database:

http://androidxref.com/4.4.2_r2/xref/frameworks/base/core/java/android/provider/Settings.java#5015

这篇关于APK 安装失败:[INSTALL_FAILED_VERIFICATION_FAILURE]的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆