Direct manifest installation should not check signature 36/55236/5 accepted/tizen/mobile/20160108.064848 accepted/tizen/tv/20160108.064908 accepted/tizen/wearable/20160108.064936 submit/tizen/20160108.020058
authorTomasz Iwanek <t.iwanek@samsung.com>
Tue, 22 Dec 2015 08:43:17 +0000 (09:43 +0100)
committerjongmyeongko <jongmyeong.ko@samsung.com>
Fri, 8 Jan 2016 01:49:14 +0000 (10:49 +0900)
There is no signature in those packages. Privilege level = PLATFORM
is automatically granted for directly installed packages.

Change TpkAppQueryInterface::IsAppInstalledByArgv according to other
changes.

Change-Id: Ie6c5e906aa6e60b71b3ebb8cfa9897a6c080da99
Signed-off-by: jongmyeongko <jongmyeong.ko@samsung.com>
src/tpk/tpk_app_query_interface.cc
src/tpk/tpk_installer.cc

index 5e816b4..b1e1568 100644 (file)
@@ -44,23 +44,17 @@ std::string GetInstallationPackagePath(int argc, char** argv) {
   return path;
 }
 
-std::string GetXmlPath(int argc, char** argv) {
-  std::string path;
+std::string GetPkgIdFromCmd(int argc, char** argv) {
+  std::string pkgid;
   for (int i = 0; i < argc; ++i) {
-    if (!strcmp(argv[i], "-x")) {
+    if (!strcmp(argv[i], "-y")) {
       if (i + 1 < argc) {
-        path = argv[i + 1];
+        pkgid = argv[i + 1];
         break;
       }
     }
   }
-  return path;
-}
-
-std::string GetPkgIdFromXml(const std::string&path) {
-  bf::path xml_path(path);
-
-  return xml_path.stem().string();
+  return pkgid;
 }
 
 std::string GetPkgIdFromPath(const std::string& path) {
@@ -101,11 +95,7 @@ bool TpkAppQueryInterface::IsAppInstalledByArgv(int argc, char** argv) {
   std::string pkg_id;
   if (path.empty()) {
     // check if it is manifest direct install
-    path = GetXmlPath(argc, argv);
-    if (path.empty())
-      return false;
-
-    pkg_id = GetPkgIdFromXml(path);
+    pkg_id = GetPkgIdFromCmd(argc, argv);
   } else {
     pkg_id = GetPkgIdFromPath(path);
   }
index 89a95fc..2ca527f 100644 (file)
@@ -204,7 +204,6 @@ void TpkInstaller::ManifestDirectUpdateSteps() {
   AddStep<tpk::parse::StepParse>();
   AddStep<ci::security::StepPrivilegeCompatibility>();
   AddStep<tpk::security::StepCheckTpkBackgroundCategory>();
-  AddStep<ci::security::StepCheckOldCertificate>();
   AddStep<ci::pkgmgr::StepKillApps>();
   AddStep<ci::security::StepRollbackInstallationSecurity>();
   AddStep<ci::security::StepRegisterSecurity>();