Google Drive 显示我自制的 apk 是病毒?

问题描述 投票:0回答:2

当我尝试从 google Drive 安装自制 APK 时,收到消息:“apk 感染了病毒”。

或者类似的东西:

我将APK上传到https://www.virustotal.com,只有google检查失败。但我没有得到进一步的说明为什么。

我在 build.gradle(模块级)中使用以下依赖项

plugins {
    id 'com.android.application'
    id 'org.jetbrains.kotlin.android'
    id 'com.google.dagger.hilt.android'
    id 'androidx.navigation.safeargs'
}

apply plugin: 'kotlin-kapt'

android {
    ...
    compileSdk 33

    defaultConfig {
        ...
        minSdk 28
        targetSdk 33
    }
}

dependencies {
    def room_version = "2.5.0"

    implementation 'androidx.core:core-ktx:1.9.0'
    implementation 'androidx.appcompat:appcompat:1.6.1'
    implementation 'com.google.android.material:material:1.8.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
    implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.6.0'
    implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.0'
    implementation 'androidx.navigation:navigation-fragment-ktx:2.5.3'
    implementation 'androidx.navigation:navigation-ui-ktx:2.5.3'
    testImplementation 'junit:junit:4.13.2'
    testImplementation "androidx.arch.core:core-testing:2.2.0"
    androidTestImplementation 'androidx.test.ext:junit:1.1.5'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
    androidTestImplementation "androidx.arch.core:core-testing:2.2.0"

    implementation("androidx.room:room-runtime:$room_version")
    annotationProcessor("androidx.room:room-compiler:$room_version")
    kapt("androidx.room:room-compiler:$room_version")
    implementation("androidx.room:room-ktx:$room_version")
    implementation("androidx.room:room-paging:$room_version")

    androidTestImplementation("androidx.room:room-testing:$room_version")
    androidTestImplementation 'androidx.test:rules:1.5.0'

    implementation("com.google.dagger:hilt-android:2.44")
    kapt("com.google.dagger:hilt-android-compiler:2.44")

    testImplementation("com.google.dagger:hilt-android-testing:2.44")
    kaptTest("com.google.dagger:hilt-android-compiler:2.44")

    androidTestImplementation("com.google.dagger:hilt-android-testing:2.44")
    kaptAndroidTest("com.google.dagger:hilt-android-compiler:2.44")
}

和build.gradle(顶级)

buildscript {
    repositories {
        google()
    }
    dependencies {
        classpath("androidx.navigation:navigation-safe-args-gradle-plugin:2.6.0-alpha07")
    }
}

plugins {
    id 'com.android.application' version '7.4.2' apply false
    id 'com.android.library' version '7.4.2' apply false
    id 'org.jetbrains.kotlin.android' version '1.8.0' apply false
    id 'com.google.dagger.hilt.android' version "2.45" apply false
}

在我的 Android 设备上,我使用 Android 13。

有谁知道如何解决问题或获取有关哪个文件或库导致此错误的更多信息?

android security apk google-play-protect
2个回答
1
投票

事实证明,build.gradle(module-level) 中的release buildTypes 中的

debuggable true
选项负责产生警告消息。 我不知道这个选项会导致 google Drive 阻止 apk,并相信该选项已经启用了一段时间。不过,现在可以照常安装 APK。


0
投票

我能够通过将应用程序 build.gradle 中的约束布局版本从 2.1.4 更新到 2.2.0 来解决此问题:

androidx.constraintlayout:constraintlayout:2.2.0-alpha13

© www.soinside.com 2019 - 2024. All rights reserved.