Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 880f42d4 authored by Orion Hodson's avatar Orion Hodson Committed by Automerger Merge Worker
Browse files

Merge "installd: pass verification state from odsign to ART tools" am: e582496d

Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/1753962

Change-Id: I4b4a9e647d906f8e182eaa405d758f98fcc74c73
parents 5a8592ef e582496d
Loading
Loading
Loading
Loading
+16 −0
Original line number Diff line number Diff line
@@ -492,6 +492,14 @@ class RunProfman : public ExecVHelper {
                 std::to_string(min_new_methods_percent_change));
        }

        // On-device signing related. odsign sets the system property odsign.verification.success if
        // AOT artifacts have the expected signatures.
        const bool trust_art_apex_data_files =
                ::android::base::GetBoolProperty("odsign.verification.success", false);
        if (!trust_art_apex_data_files) {
            AddRuntimeArg("-Xdeny-art-apex-data-files");
        }

        // Do not add after dex2oat_flags, they should override others for debugging.
        PrepareArgs(profman_bin);
    }
@@ -1231,6 +1239,14 @@ class RunDexoptAnalyzer : public ExecVHelper {
            }
        }

        // On-device signing related. odsign sets the system property odsign.verification.success if
        // AOT artifacts have the expected signatures.
        const bool trust_art_apex_data_files =
                ::android::base::GetBoolProperty("odsign.verification.success", false);
        if (!trust_art_apex_data_files) {
            AddRuntimeArg("-Xdeny-art-apex-data-files");
        }

        PrepareArgs(dexoptanalyzer_bin);
    }

+7 −0
Original line number Diff line number Diff line
@@ -283,6 +283,13 @@ void RunDex2Oat::PrepareCompilerConfigFlags(const UniqueFile& input_vdex,
        }
    }

    // On-device signing related. odsign sets the system property odsign.verification.success if
    // AOT artifacts have the expected signatures.
    const bool trust_art_apex_data_files = GetBoolProperty("odsign.verification.success", false);
    if (!trust_art_apex_data_files) {
        AddRuntimeArg("-Xdeny-art-apex-data-files");
    }

    if (target_sdk_version != 0) {
        AddRuntimeArg(StringPrintf("-Xtarget-sdk-version:%d", target_sdk_version));
    }