1 // Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by an apache-2.0 license that can be
3 // found in the LICENSE file.
5 #include "hybrid/hybrid_installer.h"
7 #include <common/step/backup/step_backup_icons.h>
8 #include <common/step/backup/step_backup_manifest.h>
9 #include <common/step/backup/step_copy_backup.h>
10 #include <common/step/configuration/step_block_cross_update.h>
11 #include <common/step/configuration/step_check_tizen_version.h>
12 #include <common/step/configuration/step_configure.h>
13 #include <common/step/configuration/step_fail.h>
14 #include <common/step/configuration/step_parse_manifest.h>
15 #include <common/step/configuration/step_parse_preload.h>
16 #include <common/step/filesystem/step_acquire_external_storage.h>
17 #include <common/step/filesystem/step_clear_data.h>
18 #include <common/step/filesystem/step_copy.h>
19 #include <common/step/filesystem/step_copy_storage_directories.h>
20 #include <common/step/filesystem/step_copy_tep.h>
21 #include <common/step/filesystem/step_create_icons.h>
22 #include <common/step/filesystem/step_create_globalapp_symlinks.h>
23 #include <common/step/filesystem/step_create_per_user_storage_directories.h>
24 #include <common/step/filesystem/step_create_storage_directories.h>
25 #include <common/step/filesystem/step_delta_patch.h>
26 #include <common/step/filesystem/step_disable_external_mount.h>
27 #include <common/step/filesystem/step_enable_external_mount.h>
28 #include <common/step/filesystem/step_recover_files.h>
29 #include <common/step/filesystem/step_recover_icons.h>
30 #include <common/step/filesystem/step_recover_manifest.h>
31 #include <common/step/filesystem/step_recover_external_storage.h>
32 #include <common/step/filesystem/step_recover_storage_directories.h>
33 #include <common/step/filesystem/step_remove_files.h>
34 #include <common/step/filesystem/step_remove_icons.h>
35 #include <common/step/filesystem/step_remove_globalapp_symlinks.h>
36 #include <common/step/filesystem/step_remove_per_user_storage_directories.h>
37 #include <common/step/filesystem/step_remove_temporary_directory.h>
38 #include <common/step/filesystem/step_remove_zip_image.h>
39 #include <common/step/filesystem/step_remove_tep.h>
40 #include <common/step/filesystem/step_unzip.h>
41 #include <common/step/filesystem/step_update_tep.h>
42 #include <common/step/mount/step_mount_install.h>
43 #include <common/step/mount/step_mount_unpacked.h>
44 #include <common/step/mount/step_mount_update.h>
45 #include <common/step/pkgmgr/step_check_removable.h>
46 #include <common/step/pkgmgr/step_check_restriction.h>
47 #include <common/step/pkgmgr/step_kill_apps.h>
48 #include <common/step/pkgmgr/step_recover_application.h>
49 #include <common/step/pkgmgr/step_register_app.h>
50 #include <common/step/pkgmgr/step_remove_manifest.h>
51 #include <common/step/pkgmgr/step_run_parser_plugins.h>
52 #include <common/step/pkgmgr/step_unregister_app.h>
53 #include <common/step/pkgmgr/step_update_app.h>
54 #include <common/step/pkgmgr/step_update_pkg_disable_info.h>
55 #include <common/step/recovery/step_open_recovery_file.h>
56 #include <common/step/security/step_check_signature.h>
57 #include <common/step/security/step_privilege_compatibility.h>
58 #include <common/step/security/step_recover_security.h>
59 #include <common/step/security/step_register_security.h>
60 #include <common/step/security/step_revoke_security.h>
61 #include <common/step/security/step_rollback_deinstallation_security.h>
62 #include <common/step/security/step_rollback_installation_security.h>
63 #include <common/step/security/step_update_security.h>
65 #include <tpk/step/filesystem/step_create_symbolic_link.h>
66 #include <tpk/step/filesystem/step_tpk_patch_icons.h>
67 #include <tpk/step/filesystem/step_tpk_prepare_package_directory.h>
68 #include <tpk/step/filesystem/step_tpk_update_package_directory.h>
69 #include <tpk/step/security/step_tpk_recover_signature.h>
71 #include "hybrid/hybrid_backend_data.h"
72 #include "hybrid/step/configuration/step_merge_tpk_config.h"
73 #include "hybrid/step/configuration/step_stash_tpk_config.h"
74 #include "hybrid/step/encryption/step_encrypt_resources.h"
75 #include "wgt/step/configuration/step_parse.h"
76 #include "wgt/step/encryption/step_remove_encryption_data.h"
77 #include "wgt/step/filesystem/step_copy_preview_icons.h"
78 #include "wgt/step/filesystem/step_create_symbolic_link.h"
79 #include "wgt/step/filesystem/step_wgt_patch_icons.h"
80 #include "wgt/step/filesystem/step_wgt_patch_storage_directories.h"
81 #include "wgt/step/pkgmgr/step_generate_xml.h"
82 #include "wgt/step/security/step_check_settings_level.h"
83 #include "wgt/step/security/step_check_wgt_background_category.h"
84 #include "wgt/step/security/step_check_wgt_notification_category.h"
85 #include "wgt/step/security/step_check_wgt_ime_privilege.h"
87 namespace ci = common_installer;
91 HybridInstaller::HybridInstaller(common_installer::PkgMgrPtr pkgmgr)
92 : AppInstaller("wgt", pkgmgr) {
93 context_->backend_data.set(new HybridBackendData());
95 switch (pkgmgr_->GetRequestType()) {
96 case ci::RequestType::Install:
97 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
98 AddStep<ci::filesystem::StepUnzip>();
99 AddStep<ci::configuration::StepParseManifest>(
100 ci::configuration::StepParseManifest::ManifestLocation::PACKAGE,
101 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
102 AddStep<hybrid::configuration::StepStashTpkConfig>();
103 AddStep<wgt::configuration::StepParse>(
104 wgt::configuration::StepParse::ConfigLocation::RESOURCE_WGT, true);
105 AddStep<hybrid::configuration::StepMergeTpkConfig>();
106 AddStep<ci::configuration::StepParsePreload>();
107 AddStep<ci::pkgmgr::StepCheckRestriction>();
108 AddStep<ci::configuration::StepCheckTizenVersion>();
109 AddStep<ci::security::StepCheckSignature>();
110 AddStep<ci::security::StepPrivilegeCompatibility>();
111 AddStep<wgt::security::StepCheckSettingsLevel>();
112 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
113 AddStep<wgt::security::StepCheckWgtNotificationCategory>();
114 AddStep<wgt::security::StepCheckWgtImePrivilege>();
115 AddStep<hybrid::encryption::StepEncryptResources>();
116 AddStep<ci::security::StepRollbackInstallationSecurity>();
117 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
118 AddStep<ci::filesystem::StepAcquireExternalStorage>(false);
119 AddStep<ci::filesystem::StepCopy>();
120 AddStep<ci::filesystem::StepCopyTep>();
121 AddStep<tpk::filesystem::StepTpkPatchIcons>();
122 AddStep<wgt::filesystem::StepWgtPatchIcons>();
123 AddStep<ci::filesystem::StepCreateIcons>();
124 AddStep<wgt::filesystem::StepCopyPreviewIcons>();
125 AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
126 AddStep<ci::filesystem::StepCreateStorageDirectories>();
127 AddStep<wgt::filesystem::StepCreateSymbolicLink>();
128 AddStep<tpk::filesystem::StepCreateSymbolicLink>();
129 AddStep<wgt::pkgmgr::StepGenerateXml>();
130 AddStep<ci::pkgmgr::StepRunParserPlugin>(
131 ci::Plugin::ActionType::Install);
132 AddStep<ci::pkgmgr::StepRegisterApplication>();
133 AddStep<ci::security::StepRegisterSecurity>();
134 AddStep<ci::filesystem::StepCreatePerUserStorageDirectories>();
135 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
137 case ci::RequestType::Update:
138 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
139 AddStep<ci::filesystem::StepUnzip>();
140 AddStep<ci::configuration::StepParseManifest>(
141 ci::configuration::StepParseManifest::ManifestLocation::PACKAGE,
142 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
143 AddStep<hybrid::configuration::StepStashTpkConfig>();
144 AddStep<wgt::configuration::StepParse>(
145 wgt::configuration::StepParse::ConfigLocation::RESOURCE_WGT, true);
146 AddStep<hybrid::configuration::StepMergeTpkConfig>();
147 AddStep<ci::configuration::StepParsePreload>();
148 AddStep<ci::configuration::StepCheckTizenVersion>();
149 AddStep<ci::security::StepCheckSignature>();
150 AddStep<ci::security::StepPrivilegeCompatibility>();
151 AddStep<wgt::security::StepCheckSettingsLevel>();
152 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
153 AddStep<wgt::security::StepCheckWgtNotificationCategory>();
154 AddStep<wgt::security::StepCheckWgtImePrivilege>();
155 AddStep<hybrid::encryption::StepEncryptResources>();
156 AddStep<ci::security::StepRollbackInstallationSecurity>();
157 AddStep<ci::configuration::StepParseManifest>(
158 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
159 ci::configuration::StepParseManifest::StoreLocation::BACKUP);
160 AddStep<ci::configuration::StepBlockCrossUpdate>();
161 AddStep<ci::pkgmgr::StepKillApps>();
162 AddStep<ci::backup::StepBackupManifest>();
163 AddStep<ci::backup::StepBackupIcons>();
164 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
165 AddStep<ci::filesystem::StepAcquireExternalStorage>(true);
166 AddStep<ci::backup::StepCopyBackup>();
167 AddStep<ci::filesystem::StepUpdateTep>();
168 AddStep<tpk::filesystem::StepTpkPatchIcons>();
169 AddStep<wgt::filesystem::StepWgtPatchIcons>();
170 AddStep<ci::filesystem::StepCreateIcons>();
171 AddStep<wgt::filesystem::StepCopyPreviewIcons>();
172 AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
173 AddStep<ci::filesystem::StepCopyStorageDirectories>();
174 AddStep<wgt::filesystem::StepCreateSymbolicLink>();
175 AddStep<tpk::filesystem::StepCreateSymbolicLink>();
176 AddStep<ci::security::StepUpdateSecurity>();
177 AddStep<wgt::pkgmgr::StepGenerateXml>();
178 AddStep<ci::pkgmgr::StepUpdateApplication>();
179 AddStep<ci::pkgmgr::StepRunParserPlugin>(
180 ci::Plugin::ActionType::Upgrade);
181 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
183 case ci::RequestType::Uninstall:
184 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
185 AddStep<ci::pkgmgr::StepCheckRestriction>();
186 AddStep<ci::pkgmgr::StepCheckRemovable>();
187 AddStep<ci::configuration::StepParseManifest>(
188 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
189 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
190 AddStep<ci::pkgmgr::StepRunParserPlugin>(
191 ci::Plugin::ActionType::Uninstall);
192 AddStep<ci::pkgmgr::StepKillApps>();
193 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
194 AddStep<ci::filesystem::StepAcquireExternalStorage>(true);
195 AddStep<ci::filesystem::StepRemovePerUserStorageDirectories>();
196 AddStep<ci::pkgmgr::StepUnregisterApplication>();
197 AddStep<ci::security::StepRollbackDeinstallationSecurity>();
198 AddStep<ci::filesystem::StepRemoveTep>();
199 AddStep<ci::filesystem::StepRemoveFiles>();
200 AddStep<ci::filesystem::StepRemoveZipImage>();
201 AddStep<ci::filesystem::StepRemoveIcons>();
202 AddStep<wgt::encryption::StepRemoveEncryptionData>();
203 AddStep<ci::security::StepRevokeSecurity>();
204 AddStep<ci::pkgmgr::StepRemoveManifest>();
205 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
207 case ci::RequestType::Reinstall:
208 // RDS is not supported for hybrid apps
209 AddStep<ci::configuration::StepFail>();
211 case ci::RequestType::Delta:
212 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
213 AddStep<ci::filesystem::StepUnzip>();
214 AddStep<ci::configuration::StepParseManifest>(
215 ci::configuration::StepParseManifest::ManifestLocation::PACKAGE,
216 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
217 AddStep<hybrid::configuration::StepStashTpkConfig>();
218 AddStep<ci::configuration::StepParseManifest>(
219 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
220 ci::configuration::StepParseManifest::StoreLocation::BACKUP);
221 AddStep<ci::filesystem::StepEnableExternalMount>();
222 AddStep<ci::filesystem::StepDeltaPatch>();
223 AddStep<ci::filesystem::StepDisableExternalMount>();
224 AddStep<wgt::configuration::StepParse>(
225 wgt::configuration::StepParse::ConfigLocation::RESOURCE_WGT, true);
226 AddStep<hybrid::configuration::StepMergeTpkConfig>();
227 AddStep<ci::configuration::StepCheckTizenVersion>();
228 AddStep<ci::security::StepCheckSignature>();
229 AddStep<ci::security::StepPrivilegeCompatibility>();
230 AddStep<wgt::security::StepCheckSettingsLevel>();
231 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
232 AddStep<wgt::security::StepCheckWgtNotificationCategory>();
233 AddStep<wgt::security::StepCheckWgtImePrivilege>();
234 AddStep<hybrid::encryption::StepEncryptResources>();
235 AddStep<ci::security::StepRollbackInstallationSecurity>();
236 AddStep<ci::configuration::StepBlockCrossUpdate>();
237 AddStep<ci::pkgmgr::StepKillApps>();
238 AddStep<ci::backup::StepBackupManifest>();
239 AddStep<ci::backup::StepBackupIcons>();
240 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
241 AddStep<ci::filesystem::StepAcquireExternalStorage>(true);
242 AddStep<ci::backup::StepCopyBackup>();
243 AddStep<ci::filesystem::StepUpdateTep>();
244 AddStep<tpk::filesystem::StepTpkPatchIcons>();
245 AddStep<wgt::filesystem::StepWgtPatchIcons>();
246 AddStep<ci::filesystem::StepCreateIcons>();
247 AddStep<wgt::filesystem::StepCopyPreviewIcons>();
248 AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
249 AddStep<ci::filesystem::StepCopyStorageDirectories>();
250 AddStep<wgt::filesystem::StepCreateSymbolicLink>();
251 AddStep<tpk::filesystem::StepCreateSymbolicLink>();
252 AddStep<ci::security::StepUpdateSecurity>();
253 AddStep<wgt::pkgmgr::StepGenerateXml>();
254 AddStep<ci::pkgmgr::StepUpdateApplication>();
255 AddStep<ci::pkgmgr::StepRunParserPlugin>(
256 ci::Plugin::ActionType::Upgrade);
257 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
259 case ci::RequestType::Recovery:
260 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
261 AddStep<ci::recovery::StepOpenRecoveryFile>();
262 AddStep<ci::configuration::StepParseManifest>(
263 ci::configuration::StepParseManifest::ManifestLocation::RECOVERY,
264 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
265 AddStep<ci::filesystem::StepRemoveTemporaryDirectory>();
266 AddStep<ci::filesystem::StepRecoverIcons>();
267 AddStep<ci::filesystem::StepRecoverManifest>();
268 AddStep<ci::filesystem::StepRecoverExternalStorage>();
269 AddStep<ci::filesystem::StepRecoverStorageDirectories>();
270 AddStep<ci::filesystem::StepRecoverFiles>();
271 AddStep<tpk::security::StepTpkRecoverSignature>();
272 AddStep<ci::pkgmgr::StepRecoverApplication>();
273 AddStep<ci::security::StepRecoverSecurity>();
275 case ci::RequestType::Clear:
276 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
277 AddStep<ci::configuration::StepParseManifest>(
278 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
279 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
280 AddStep<ci::filesystem::StepClearData>();
282 case ci::RequestType::MountInstall:
283 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
284 AddStep<ci::mount::StepMountUnpacked>();
285 AddStep<ci::configuration::StepParseManifest>(
286 ci::configuration::StepParseManifest::ManifestLocation::PACKAGE,
287 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
288 AddStep<hybrid::configuration::StepStashTpkConfig>();
289 AddStep<wgt::configuration::StepParse>(
290 wgt::configuration::StepParse::ConfigLocation::RESOURCE_WGT, true);
291 AddStep<hybrid::configuration::StepMergeTpkConfig>();
292 AddStep<ci::configuration::StepParsePreload>();
293 AddStep<ci::pkgmgr::StepCheckRestriction>();
294 AddStep<ci::configuration::StepCheckTizenVersion>();
295 AddStep<ci::security::StepCheckSignature>();
296 AddStep<ci::security::StepPrivilegeCompatibility>();
297 AddStep<wgt::security::StepCheckSettingsLevel>();
298 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
299 AddStep<wgt::security::StepCheckWgtNotificationCategory>();
300 AddStep<wgt::security::StepCheckWgtImePrivilege>();
301 AddStep<hybrid::encryption::StepEncryptResources>();
302 AddStep<ci::security::StepRollbackInstallationSecurity>();
303 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
304 AddStep<ci::mount::StepMountInstall>();
305 AddStep<tpk::filesystem::StepTpkPreparePackageDirectory>();
306 AddStep<ci::filesystem::StepCopyTep>();
307 AddStep<tpk::filesystem::StepTpkPatchIcons>();
308 AddStep<wgt::filesystem::StepWgtPatchIcons>();
309 AddStep<ci::filesystem::StepCreateIcons>();
310 AddStep<wgt::filesystem::StepCopyPreviewIcons>();
311 AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
312 AddStep<ci::filesystem::StepCreateStorageDirectories>();
313 AddStep<wgt::filesystem::StepCreateSymbolicLink>();
314 AddStep<tpk::filesystem::StepCreateSymbolicLink>();
315 AddStep<wgt::pkgmgr::StepGenerateXml>();
316 AddStep<ci::pkgmgr::StepRunParserPlugin>(
317 ci::Plugin::ActionType::Install);
318 AddStep<ci::pkgmgr::StepRegisterApplication>();
319 AddStep<ci::security::StepRegisterSecurity>();
320 AddStep<ci::filesystem::StepCreatePerUserStorageDirectories>();
321 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
323 case ci::RequestType::MountUpdate:
324 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
325 AddStep<ci::mount::StepMountUnpacked>();
326 AddStep<ci::configuration::StepParseManifest>(
327 ci::configuration::StepParseManifest::ManifestLocation::PACKAGE,
328 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
329 AddStep<hybrid::configuration::StepStashTpkConfig>();
330 AddStep<wgt::configuration::StepParse>(
331 wgt::configuration::StepParse::ConfigLocation::RESOURCE_WGT, true);
332 AddStep<hybrid::configuration::StepMergeTpkConfig>();
333 AddStep<ci::configuration::StepParsePreload>();
334 AddStep<ci::configuration::StepCheckTizenVersion>();
335 AddStep<ci::security::StepCheckSignature>();
336 AddStep<ci::security::StepPrivilegeCompatibility>();
337 AddStep<wgt::security::StepCheckSettingsLevel>();
338 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
339 AddStep<wgt::security::StepCheckWgtNotificationCategory>();
340 AddStep<wgt::security::StepCheckWgtImePrivilege>();
341 AddStep<hybrid::encryption::StepEncryptResources>();
342 AddStep<ci::security::StepRollbackInstallationSecurity>();
343 AddStep<ci::configuration::StepParseManifest>(
344 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
345 ci::configuration::StepParseManifest::StoreLocation::BACKUP);
346 AddStep<ci::configuration::StepBlockCrossUpdate>();
347 AddStep<ci::pkgmgr::StepKillApps>();
348 AddStep<ci::backup::StepBackupManifest>();
349 AddStep<ci::backup::StepBackupIcons>();
350 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
351 AddStep<ci::mount::StepMountUpdate>();
352 AddStep<tpk::filesystem::StepTpkUpdatePackageDirectory>();
353 AddStep<ci::filesystem::StepUpdateTep>();
354 AddStep<tpk::filesystem::StepTpkPatchIcons>();
355 AddStep<wgt::filesystem::StepWgtPatchIcons>();
356 AddStep<ci::filesystem::StepCreateIcons>();
357 AddStep<wgt::filesystem::StepCopyPreviewIcons>();
358 AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
359 AddStep<wgt::filesystem::StepCreateSymbolicLink>();
360 AddStep<tpk::filesystem::StepCreateSymbolicLink>();
361 AddStep<ci::security::StepUpdateSecurity>();
362 AddStep<wgt::pkgmgr::StepGenerateXml>();
363 AddStep<ci::pkgmgr::StepUpdateApplication>();
364 AddStep<ci::pkgmgr::StepRunParserPlugin>(
365 ci::Plugin::ActionType::Upgrade);
366 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
368 case ci::RequestType::ManifestDirectInstall:
369 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
370 AddStep<ci::configuration::StepParseManifest>(
371 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
372 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
373 AddStep<hybrid::configuration::StepStashTpkConfig>();
374 AddStep<wgt::configuration::StepParse>(
375 wgt::configuration::StepParse::ConfigLocation::INSTALLED, true);
376 AddStep<hybrid::configuration::StepMergeTpkConfig>();
377 AddStep<ci::configuration::StepParsePreload>();
378 AddStep<ci::configuration::StepCheckTizenVersion>();
379 AddStep<ci::security::StepCheckSignature>();
380 AddStep<ci::security::StepPrivilegeCompatibility>();
381 AddStep<wgt::security::StepCheckSettingsLevel>();
382 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
383 AddStep<ci::security::StepRollbackInstallationSecurity>();
384 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
385 AddStep<wgt::pkgmgr::StepGenerateXml>();
386 AddStep<ci::pkgmgr::StepRunParserPlugin>(
387 ci::Plugin::ActionType::Install);
388 AddStep<ci::pkgmgr::StepRegisterApplication>();
389 AddStep<ci::security::StepRegisterSecurity>();
390 AddStep<ci::filesystem::StepCreatePerUserStorageDirectories>();
391 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
393 case ci::RequestType::ManifestDirectUpdate:
394 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
395 AddStep<ci::filesystem::StepUnzip>();
396 AddStep<ci::configuration::StepParseManifest>(
397 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
398 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
399 AddStep<hybrid::configuration::StepStashTpkConfig>();
400 AddStep<wgt::configuration::StepParse>(
401 wgt::configuration::StepParse::ConfigLocation::INSTALLED, true);
402 AddStep<hybrid::configuration::StepMergeTpkConfig>();
403 AddStep<ci::configuration::StepParsePreload>();
404 AddStep<ci::configuration::StepCheckTizenVersion>();
405 AddStep<ci::security::StepCheckSignature>();
406 AddStep<ci::security::StepPrivilegeCompatibility>();
407 AddStep<wgt::security::StepCheckSettingsLevel>();
408 AddStep<wgt::security::StepCheckWgtBackgroundCategory>();
409 AddStep<ci::security::StepRollbackInstallationSecurity>();
410 AddStep<ci::configuration::StepParseManifest>(
411 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
412 ci::configuration::StepParseManifest::StoreLocation::BACKUP);
413 AddStep<ci::pkgmgr::StepKillApps>();
414 AddStep<ci::security::StepUpdateSecurity>();
415 AddStep<ci::filesystem::StepRemoveGlobalAppSymlinks>();
416 AddStep<wgt::pkgmgr::StepGenerateXml>();
417 AddStep<ci::pkgmgr::StepUpdateApplication>();
418 AddStep<ci::pkgmgr::StepRunParserPlugin>(
419 ci::Plugin::ActionType::Upgrade);
420 AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
422 case ci::RequestType::EnablePkg:
423 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
424 AddStep<ci::configuration::StepParseManifest>(
425 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
426 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
427 AddStep<ci::pkgmgr::StepKillApps>();
428 AddStep<ci::pkgmgr::StepUpdatePkgDisableInfo>(
429 ci::pkgmgr::StepUpdatePkgDisableInfo::ActionType::Enable);
430 AddStep<ci::pkgmgr::StepRunParserPlugin>(
431 ci::Plugin::ActionType::Uninstall);
433 case ci::RequestType::DisablePkg:
434 AddStep<ci::configuration::StepConfigure>(pkgmgr_);
435 AddStep<ci::configuration::StepParseManifest>(
436 ci::configuration::StepParseManifest::ManifestLocation::INSTALLED,
437 ci::configuration::StepParseManifest::StoreLocation::NORMAL);
438 AddStep<ci::pkgmgr::StepKillApps>();
439 AddStep<ci::pkgmgr::StepUpdatePkgDisableInfo>(
440 ci::pkgmgr::StepUpdatePkgDisableInfo::ActionType::Disable);
441 AddStep<ci::pkgmgr::StepRunParserPlugin>(
442 ci::Plugin::ActionType::Uninstall);
445 AddStep<ci::configuration::StepFail>();
450 } // namespace hybrid