From: Junghyun Yeon Date: Sun, 5 Nov 2017 23:56:36 +0000 (+0900) Subject: Add StepRevokeTrustAnchor steps for several installation cases. X-Git-Tag: accepted/tizen/unified/20180514.094115~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F87%2F158887%2F9;p=platform%2Fcore%2Fappfw%2Ftpk-backend.git Add StepRevokeTrustAnchor steps for several installation cases. - When updating pkg has failed, trust anchor should be revoked. Related changes: [app-installers] : https://review.tizen.org/gerrit/#/c/158351/ Change-Id: I02e39983e26129f8618ccb0329448c00afec7208 Signed-off-by: Junghyun Yeon --- diff --git a/src/tpk/tpk_installer.cc b/src/tpk/tpk_installer.cc index d23debd..427c2f1 100644 --- a/src/tpk/tpk_installer.cc +++ b/src/tpk/tpk_installer.cc @@ -83,6 +83,7 @@ #include #include #include +#include #include #include "tpk/step/configuration/step_adjust_install_location.h" @@ -188,6 +189,7 @@ void TpkInstaller::UpdateSteps() { AddStep(); AddStep(); AddStep(true); + AddStep(); AddStep(); AddStep(); AddStep(); @@ -263,6 +265,7 @@ void TpkInstaller::ReinstallSteps() { AddStep(); AddStep(); AddStep(); + AddStep(); AddStep(); AddStep(); AddStep(); @@ -312,6 +315,7 @@ void TpkInstaller::DeltaSteps() { AddStep(); AddStep(); AddStep(true); + AddStep(); AddStep(); AddStep(); AddStep(); @@ -367,6 +371,8 @@ void TpkInstaller::RecoverySteps() { AddStep(); AddStep(); AddStep(); + AddStep( + ci::security::StepRegisterTrustAnchor::RegisterType::UPDATE); } void TpkInstaller::MountInstallSteps() { @@ -433,6 +439,7 @@ void TpkInstaller::MountUpdateSteps() { ci::configuration::StepParseManifest::ManifestLocation::INSTALLED, ci::configuration::StepParseManifest::StoreLocation::BACKUP); AddStep(); + AddStep(); AddStep(); AddStep(); AddStep(); @@ -614,6 +621,7 @@ void TpkInstaller::ReadonlyUpdateInstallSteps() { AddStep(); AddStep(); AddStep(); + AddStep(); AddStep(); AddStep(); AddStep(); @@ -655,6 +663,7 @@ void TpkInstaller::ReadonlyUpdateUninstallSteps() { AddStep(); AddStep(); AddStep(); + AddStep(); AddStep( ci::security::StepRegisterTrustAnchor::RegisterType::UPDATE); AddStep(