platform/core/appfw/app-installers.git
3 years agoPrint version at history log 98/256998/3
Sangyoon Jang [Wed, 14 Apr 2021 10:35:37 +0000 (19:35 +0900)]
Print version at history log

Change-Id: Ic8aba0517c79a2f2eaeb1c90637c3f22a9239467
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoAdd HistoryLogger class 68/251068/8
Sangyoon Jang [Thu, 7 Jan 2021 10:34:59 +0000 (19:34 +0900)]
Add HistoryLogger class

Extract functions logs history to class.

Change-Id: Ieda82e8ca44afb41eff7cec3028c8862e4d9432a
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.33.4 00/256000/1 accepted/tizen/unified/20210328.230632 submit/tizen/20210326.090127
Junghyun Yeon [Fri, 26 Mar 2021 09:00:48 +0000 (18:00 +0900)]
Release version 1.33.4

Changes:
 - Add function call to clear memory db

Change-Id: I2c33fc57e5b140bf73a6783b801433eea3c9969f
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoAdd function call to clear memory db 99/255999/1
Junghyun Yeon [Fri, 26 Mar 2021 08:57:18 +0000 (17:57 +0900)]
Add function call to clear memory db

Change-Id: I9f73721835195241053cd32a1c39696b77b5e2ac
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.33.3 53/255353/2 accepted/tizen/unified/20210323.122927 submit/tizen/20210317.082331 submit/tizen/20210317.233905 submit/tizen/20210318.062905 submit/tizen/20210319.065928 submit/tizen/20210323.054210 submit/tizen/20210323.055934
Ilho Kim [Wed, 17 Mar 2021 08:21:20 +0000 (17:21 +0900)]
Release version 1.33.3

Changes:
 - Update installer signal policy
 - Fix tag plugin
 - Change to handle logic subprocess's Wait()
 - Clear memory database at the end of installation

Change-Id: Iffe27e2a0b65bb4d3ea60361387306072686ca12
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoClear memory database at the end of installation 08/254908/1
Ilho Kim [Wed, 10 Mar 2021 10:01:08 +0000 (19:01 +0900)]
Clear memory database at the end of installation

Change-Id: Iea5c43c88fd5bccf4f150b5f491b1e8dac6d3004
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoChange to handle logic subprocess's Wait() 18/254018/4
Ilho Kim [Mon, 22 Feb 2021 06:16:23 +0000 (15:16 +0900)]
Change to handle logic subprocess's Wait()

Change-Id: I7d02a2c2920cd00c1608b84bbbdab8f1fa68fd3e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix tag plugin 74/253674/2
Junghyun Yeon [Tue, 16 Feb 2021 08:40:08 +0000 (17:40 +0900)]
Fix tag plugin

When certain tag has removed during package update and
plugin related with it has executed, "removed" plugin
should be executed. But there are no tag in manifest so
nullptr will be delivered into plugin.

Change-Id: I9373934d7f7a317e2e9ea59cd5ee5efc8ef7b7ea
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoUpdate installer signal policy 39/252939/1
Junghyun Yeon [Wed, 3 Feb 2021 07:37:52 +0000 (16:37 +0900)]
Update installer signal policy

Tizen platform blocks install or update of user package
when same package is already installed as global.

Change-Id: I8e429c5ce5069a4ffc75ac44312ab6e98cb2c185
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.33.2 67/252667/1 accepted/tizen/unified/20210202.143614 submit/tizen/20210202.012904
Ilho Kim [Mon, 1 Feb 2021 08:01:34 +0000 (17:01 +0900)]
Release version 1.33.2

Changes:
 - Fix pkg_initdb tool to check backend execution result
 - Fix coding rule
 - Add virtual destructor

Change-Id: I03c79a69069b8006bdd034407dcae28acc22be40
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd virtual destructor 19/252619/1
jh9216.park [Mon, 1 Feb 2021 00:24:13 +0000 (19:24 -0500)]
Add virtual destructor

- require : https://review.tizen.org/gerrit/#/c/platform/core/appfw/manifest-parser/+/252618/

Change-Id: I1d7eaed8371bb7c456f37f276f06194f50f3fad4
Signed-off-by: jh9216.park <jh9216.park@samsung.com>
3 years agoFix coding rule 17/252417/1
Junghyun Yeon [Thu, 28 Jan 2021 00:35:37 +0000 (09:35 +0900)]
Fix coding rule

Change-Id: I690fb682f7853cf742c6c11d63e0bf50cad43b53
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix pkg_initdb tool to check backend execution result 01/252301/1
Junghyun Yeon [Tue, 26 Jan 2021 09:32:29 +0000 (18:32 +0900)]
Fix pkg_initdb tool to check backend execution result

Now pkg_initdb tool will check execution result of installer backends
and create /tmp/.preload_install_error.
It may cause failure of entire mic build.

Change-Id: I6bf99350853e5585df96f567b77e0e9a1f7c42a0
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.33.1 42/251542/1 accepted/tizen/unified/20210118.141051 submit/tizen/20210115.013110 submit/tizen/20210115.062551
Junghyun Yeon [Fri, 15 Jan 2021 01:05:40 +0000 (10:05 +0900)]
Release version 1.33.1

Changes:
 - Change name of StepCopyTep
 - Fix memory leak

Change-Id: I5933babe6fe3c4c8650865ff88a78ac4866de390
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix memory leak 20/251120/3
Junghyun Yeon [Fri, 8 Jan 2021 08:45:48 +0000 (17:45 +0900)]
Fix memory leak

Change-Id: Ifee4762f873e5b239878988cf89541844b244394
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoChange name of StepCopyTep 63/251363/1
Junghyun Yeon [Wed, 13 Jan 2021 05:27:08 +0000 (14:27 +0900)]
Change name of StepCopyTep

Change it for consistency.

Change-Id: I83c9bc332f55daada9d837531ba3a12eda42bea3
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.33.0 69/250369/1 accepted/tizen/unified/20201228.130122 submit/tizen/20201224.040323
Junghyun Yeon [Thu, 24 Dec 2020 03:26:29 +0000 (12:26 +0900)]
Release version 1.33.0

Changes:
 - Fix static analysis issues
 - Change log level of QueryCertificateAuthorCertificate
 - Remove unused logic
 - Adjust install step order
 - Change backup logic of StepBackupManifest

Change-Id: Id469cf7d9431c00be45a2655afe65d1046ff47b4
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoChange backup logic of StepBackupManifest 07/250307/2
Junghyun Yeon [Wed, 23 Dec 2020 08:51:21 +0000 (17:51 +0900)]
Change backup logic of StepBackupManifest

Change its method from copying it into move and copy
to ensure backup manifest is valid one.
(Move is atomic operation)

Change-Id: Ia65e2104d62f17be3c1c9fb28c44cf756b11977d
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoAdjust install step order 21/248721/2
Junghyun Yeon [Wed, 2 Dec 2020 00:18:05 +0000 (09:18 +0900)]
Adjust install step order

Necessary information will be set at security context handle so
pkginfo is no longer used while security registration.

Change-Id: I0b94073122e98d37d446c04bded7d6704a6c933b
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRemove unused logic 42/248742/3
Junghyun Yeon [Wed, 2 Dec 2020 04:02:06 +0000 (13:02 +0900)]
Remove unused logic

According to the previous Tizen concept, same package could be
installed both global and user pkg. And when user tries to
uninstall user pkg, symlinks for global pkg should be created to
change pkg as global pkg. This concept is no longer exists so
related logic should be removed.

Change-Id: I1fdf9b39043940ef3a2ede05695100acaac22105
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoChange log level of QueryCertificateAuthorCertificate 77/248677/2
Sangyoon Jang [Tue, 1 Dec 2020 09:46:41 +0000 (18:46 +0900)]
Change log level of QueryCertificateAuthorCertificate

Change to error from debug.

Change-Id: Id58ed1f3a08b5482808ed3f4d1db9abe6ac91e6a
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix static analysis issues 15/248615/2
Ilho Kim [Tue, 1 Dec 2020 01:52:30 +0000 (10:52 +0900)]
Fix static analysis issues

In InstallWithStorage function vconf_get and vconf_set function
can be failed so the return value need to be checked

Change-Id: I215799aa5f2e4a73474dc97c89acb8da1551f7db
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRelease version 1.32.24 73/248073/1 accepted/tizen/6.0/unified/20201201.091045 accepted/tizen/unified/20201201.124755 submit/tizen/20201120.074439 submit/tizen/20201201.002159 submit/tizen_6.0/20201120.074521 submit/tizen_6.0/20201201.004919
Ilho Kim [Fri, 20 Nov 2020 07:34:23 +0000 (16:34 +0900)]
Release version 1.32.24

Changes:
 - Aborting installation when failed to get admin user info

Change-Id: Ia0adaef47667cfb8c930d96cb13171797bc9ec84
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAborting installation when failed to get admin user info 90/246790/2
Sangyoon Jang [Wed, 4 Nov 2020 07:19:45 +0000 (16:19 +0900)]
Aborting installation when failed to get admin user info

Change-Id: Id1317cca5055590f708b00170c2b62e6c46bc4f8
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.32.23 43/247043/1 accepted/tizen/6.0/unified/20201109.031556 accepted/tizen/unified/20201109.123502 submit/tizen/20201106.091348 submit/tizen_6.0/20201106.091342
Sangyoon Jang [Fri, 6 Nov 2020 09:11:37 +0000 (18:11 +0900)]
Release version 1.32.23

Changes:
 - Fix writing recovery file

Change-Id: I28180713b60664810942c210f2f2f3771997a294
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix writing recovery file 37/247037/1
Sangyoon Jang [Fri, 6 Nov 2020 08:36:43 +0000 (17:36 +0900)]
Fix writing recovery file

If writing value of bf::path, the double quote will be appended.
To fix this, use string type instead
(This is fix of side-effect of previous commit:
 https://review.tizen.org/gerrit/c/platform/core/appfw/app-installers/+/243942)

Change-Id: Ide470d02e725c0bfce090c87d96480af579466bd
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.32.22 20/246220/1 accepted/tizen/unified/20201029.124936 submit/tizen/20201027.061339 submit/tizen/20201028.004037
Ilho Kim [Tue, 27 Oct 2020 05:25:54 +0000 (14:25 +0900)]
Release version 1.32.22

Changes:
 - Fix recovery file syncing logic
 - Change AppQueryInterface's some function to virtual
 - Fix memory leak
 - Remove Unnecessary allocation
 - Add missing codes for creating symlinks
 - Send a finished signal after all operation is completed

Change-Id: I1988443be599ce9b85b99d3df87ff67792f3c36b
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoSend a finished signal after all operation is completed 75/245875/4
Ilho Kim [Mon, 19 Oct 2020 02:30:15 +0000 (11:30 +0900)]
Send a finished signal after all operation is completed

Since the clean type recovery has been added
If the process of all steps is successful,
the installer considers all of the installation to be successful
and sends a finished signal
If there is an operation in a clean that has not yet been completed
like database commit operation, there is a timing issue that an application
that received the finished signal can access where it is not completed

Change-Id: I3195b46ded497cc67bfc2d12e528d9a9e7961cea
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd missing codes for creating symlinks 78/245678/3
Sangyoon Jang [Wed, 14 Oct 2020 06:28:28 +0000 (15:28 +0900)]
Add missing codes for creating symlinks

This was deleted when refactoring
(https://review.tizen.org/gerrit/c/platform/core/appfw/app-installers/+/221429)

Change-Id: I22ca4c36a5ee596fc56c32d44a539d29f1d82282
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRemove Unnecessary allocation 60/244860/2
Ilho Kim [Fri, 25 Sep 2020 06:59:49 +0000 (15:59 +0900)]
Remove Unnecessary allocation

The value of process_poll will allocated with value 'false' in the next line

Change-Id: I03d28429eca7eaff309a8f6205c8bc8352849792
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix memory leak 74/244674/1
Ilho Kim [Wed, 23 Sep 2020 06:43:24 +0000 (15:43 +0900)]
Fix memory leak

The memory allocated by getPublicKeyDER should be freed

Change-Id: I511d5cf0cb03c7f4656b362ceec3cebb75d4ff1a
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoChange AppQueryInterface's some function to virtual 88/244388/6
Ilho Kim [Fri, 18 Sep 2020 05:01:41 +0000 (14:01 +0900)]
Change AppQueryInterface's some function to virtual

Child class's logic of extracting manifest can be diffrent
and add a clear function for result of extracting function

Change-Id: Ic15edf83008a7b8f7f4e6021a51b1d53e3e40ac4
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix recovery file syncing logic 42/243942/2
Junghyun Yeon [Fri, 11 Sep 2020 08:47:42 +0000 (17:47 +0900)]
Fix recovery file syncing logic

- Rename() is atomic itself so it doesn't have to be synced.
- Change recovery writing logic using boost iostream and fsync()
  using file descriptor

Change-Id: I3ef8fe8ba9fb649581d67c1f843c887cb4a57f3b
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.21 23/244023/1 accepted/tizen_6.0_unified_hotfix tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.121514 accepted/tizen/6.0/unified/hotfix/20201103.003736 accepted/tizen/6.0/unified/hotfix/20201103.050555 accepted/tizen/unified/20200914.131252 submit/tizen/20200914.071241 submit/tizen_6.0/20201029.205102 submit/tizen_6.0_hotfix/20201102.192502 submit/tizen_6.0_hotfix/20201103.114802 tizen_6.0.m2_release
Sangyoon Jang [Mon, 14 Sep 2020 06:43:25 +0000 (15:43 +0900)]
Release version 1.32.21

Changes:
 - Fix static analysis issue
 - Fix removing packaged rw directories

Change-Id: I51695e6109f5e780f0b5eff73d2f95c28a432db6
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix removing packaged rw directories 51/243251/6
Sangyoon Jang [Fri, 4 Sep 2020 07:56:49 +0000 (16:56 +0900)]
Fix removing packaged rw directories

Remove shared/trusted directory when update case.
Make util function to remove rw directories.

Change-Id: Ide197cbcd97a4e6faf7faf1941880a50abf711fb
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix static analysis issue 38/243538/1
Sangyoon Jang [Tue, 8 Sep 2020 03:18:22 +0000 (12:18 +0900)]
Fix static analysis issue

Change-Id: I2f1c2634150246f48f8293794c117a7a1a58832e
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.32.20 29/243529/1 accepted/tizen/unified/20200908.130455 submit/tizen/20200908.025700
Ilho Kim [Tue, 8 Sep 2020 02:30:15 +0000 (11:30 +0900)]
Release version 1.32.20

Changes:
 - Fix static analysis issue
 - Change to use gmock package instead of gtest
 - Fix coding rule
 - Fix ReadonlyUpdateInstall's recovery
 - Fix StepRemoveUserData

Change-Id: Ia50bc83ca252091b7beb6fa0973ef85604966088
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix StepRemoveUserData 64/243364/1
Ilho Kim [Mon, 7 Sep 2020 05:57:47 +0000 (14:57 +0900)]
Fix StepRemoveUserData

When using boost's recursive_directory_iterator
Accessing to the iterator after remove file occur exception

Change-Id: If317b742f6eabe72bc6f14f3f38c646e5143dc53
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix ReadonlyUpdateInstall's recovery 38/243138/2
Ilho Kim [Thu, 3 Sep 2020 08:45:30 +0000 (17:45 +0900)]
Fix ReadonlyUpdateInstall's recovery

When performing the recovery of ReadonlyUpdateInstall
the xml of package that performed ReadonlyUpdateInstall should be removed

Change-Id: Id2b86b26a8a7b81e2b96dab441d23021c0892157
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix coding rule 25/242425/2
Junghyun Yeon [Thu, 27 Aug 2020 01:03:00 +0000 (10:03 +0900)]
Fix coding rule

Change-Id: I56461902d982830f1bee89c1c3c009f2b8c0117f
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoChange to use gmock package instead of gtest 72/239872/4
Ilho Kim [Wed, 29 Jul 2020 04:53:03 +0000 (13:53 +0900)]
Change to use gmock package instead of gtest

Change-Id: Ib1ca4234065363a7e3116a5278ed3043dea79dfb
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix static analysis issue 22/242222/1
Junghyun Yeon [Tue, 25 Aug 2020 05:03:51 +0000 (14:03 +0900)]
Fix static analysis issue

Change-Id: Iedeeb275edaa9b09e3a2ff7af88c88b5adfdbfb2
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.19 10/242110/1 accepted/tizen/unified/20200825.033229 submit/tizen/20200824.070831
Ilho Kim [Mon, 24 Aug 2020 06:51:15 +0000 (15:51 +0900)]
Release version 1.32.19

Changes:
 - Set pkg type while unregistering security context
 - Move test codes

Change-Id: I25ad93031ecbbfe465c06830e7b207b177c7f958
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoMove test codes 70/242070/3
Ilho Kim [Mon, 24 Aug 2020 03:41:13 +0000 (12:41 +0900)]
Move test codes

Move test codes info ${src root}/test and rename it to smoke_tests

Change-Id: Ifc954d6d38c403c7cf47a565edec744574b212e5
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoSet pkg type while unregistering security context 67/242067/1
Junghyun Yeon [Mon, 24 Aug 2020 02:42:32 +0000 (11:42 +0900)]
Set pkg type while unregistering security context

Change-Id: I1916775a86149481f713cb277a93cda5e6f22098
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.18 69/241969/1 submit/tizen/20200821.072757
Ilho Kim [Fri, 21 Aug 2020 07:23:57 +0000 (16:23 +0900)]
Release version 1.32.18

Changes:
 - Fix the behavior that sends start signal twice
 - Remove aul plugin info from plugins list configuration file
 - Set pkg type and privilege level while installation

Change-Id: I62f710dcb346ac9a40905e86ded749f9a3a2bbd2
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoSet pkg type and privilege level while installation 36/240836/4
Junghyun Yeon [Wed, 12 Aug 2020 04:47:56 +0000 (13:47 +0900)]
Set pkg type and privilege level while installation

Change-Id: I2df40379d48d33acf96c99c799a9338fdc2a65ea
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRemove aul plugin info from plugins list configuration file 04/241904/1
Hwankyu Jhun [Thu, 20 Aug 2020 23:06:11 +0000 (08:06 +0900)]
Remove aul plugin info from plugins list configuration file

libalias-appid-parser and liballowed-appid-parser are used instead of libaul-parser.

Related changes:
 - https://review.tizen.org/gerrit/#/c/platform/core/appfw/aul-1/+/241277/

Change-Id: I81b4d0c256723c842d25dad551307967b3371a8e
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
3 years agoFix the behavior that sends start signal twice 11/241411/1
Ilho Kim [Thu, 20 Aug 2020 02:38:26 +0000 (11:38 +0900)]
Fix the behavior that sends start signal twice

Change-Id: I440df908b97bfe5549dc780da8a4b6d81121b88e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRelease version 1.32.17 63/241063/1
Ilho Kim [Fri, 14 Aug 2020 07:42:53 +0000 (16:42 +0900)]
Release version 1.32.17

Changes:
 - Fix coding rule

Change-Id: I8e5c94e969401b7c4c15f3822e4c0cbeff2d1632
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix coding rule 37/241037/1
Junghyun Yeon [Fri, 14 Aug 2020 02:24:52 +0000 (11:24 +0900)]
Fix coding rule

Change-Id: Iab77a94e962dfe6c4d2b27c801dda19767009b11
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.16 44/240944/1 accepted/tizen/unified/20200813.122551 submit/tizen/20200813.053606
Ilho Kim [Thu, 13 Aug 2020 05:26:38 +0000 (14:26 +0900)]
Release version 1.32.16

Changes:
 - Change line ending
 - Fix Remove function in file_utils
 - Fix Remove function in file utils
 - Remove log

Change-Id: Ib87870b8acd71ba4f451efeb9ec3880fb2eb3c92
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRemove log 70/240870/1
Junghyun Yeon [Wed, 12 Aug 2020 08:07:12 +0000 (17:07 +0900)]
Remove log

Getting user list always failed during mic build.

Change-Id: Iaf1dd913285f71fb1ecd35e4051cb11da60d9781
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix Remove function in file utils 38/240838/1
Ilho Kim [Wed, 12 Aug 2020 04:59:00 +0000 (13:59 +0900)]
Fix Remove function in file utils

If the path is not exists Remove function should return true

Change-Id: Ib05529a4131d8afaa7ea192064bbfa04d7279db9
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix Remove function in file_utils 21/240721/2
Ilho Kim [Tue, 11 Aug 2020 02:15:41 +0000 (11:15 +0900)]
Fix Remove function in file_utils

Change-Id: I343fe3ebd842d907334a0630eb0308c3c30db60e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoChange line ending 25/240725/1
Junghyun Yeon [Tue, 11 Aug 2020 02:36:27 +0000 (11:36 +0900)]
Change line ending

Change line endings of some files from CRLF to LF

Change-Id: Ie185cf28e3075df2165d681e43d6c7ae8fb09f63
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.15 39/240639/1 accepted/tizen/unified/20200811.050444 submit/tizen/20200810.091347
Ilho Kim [Mon, 10 Aug 2020 08:13:04 +0000 (17:13 +0900)]
Release version 1.32.15

Changes:
 - Fix static analysis issue
 - Apply IZipInterface and MountBase into StepUnmount
 - Remove dulicate definition
 - Set ownership and permission while installing user package
 - Fix the behavior sending the signal

Change-Id: Ic9281dea93a34b437fc2dbf3b25d43531e45ca07
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix the behavior sending the signal 09/240509/1
Ilho Kim [Fri, 7 Aug 2020 03:52:01 +0000 (12:52 +0900)]
Fix the behavior sending the signal

If the installer failed to parse package's id
installer should send start signal with empty pkgid

Change-Id: I861c4b3b723035e75d364f11e899228f8a3d7bc0
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoSet ownership and permission while installing user package 29/239529/2
Ilho Kim [Mon, 27 Jul 2020 10:35:02 +0000 (19:35 +0900)]
Set ownership and permission while installing user package

Change-Id: I31db65fc6162bea8f70baacc6c95c70956311e9c
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRemove dulicate definition 79/240279/2
Junghyun Yeon [Wed, 5 Aug 2020 05:08:42 +0000 (14:08 +0900)]
Remove dulicate definition

Change-Id: I32873fae1e9e691d44e8e9603f6aef75a6d0c30c
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoApply IZipInterface and MountBase into StepUnmount 98/239698/5
Junghyun Yeon [Wed, 29 Jul 2020 05:14:02 +0000 (14:14 +0900)]
Apply IZipInterface and MountBase into StepUnmount

Change-Id: I26c4bb3c3db275ee7d376f53ab4b4a7fa3a08b7e
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix static analysis issue 90/240090/4
Sangyoon Jang [Mon, 3 Aug 2020 07:40:27 +0000 (16:40 +0900)]
Fix static analysis issue

Fix uncaught exception.

Change-Id: Ib2526443fcc27fd615fb9325282dbfd3515e9844
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.32.14 77/240077/1 submit/tizen/20200803.062829 submit/tizen/20200805.002122
Junghyun Yeon [Mon, 3 Aug 2020 05:51:56 +0000 (14:51 +0900)]
Release version 1.32.14

Changes:
 - Add checking routine for getting user list
 - Fix static analysis
 - Extract operations into functions

Change-Id: I070f6e99b11938fe4ebe5322e197315cddadb254
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoExtract operations into functions 75/239975/3
Junghyun Yeon [Fri, 31 Jul 2020 06:50:10 +0000 (15:50 +0900)]
Extract operations into functions

Change-Id: I0aa0818c060ab752dab8044a9084f51dceaec0a3
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix static analysis 55/239855/1
Junghyun Yeon [Thu, 30 Jul 2020 07:29:37 +0000 (16:29 +0900)]
Fix static analysis

Initialize class member variable

Change-Id: I7355695f1826bcbe397ed47834e524a905575ed8
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoAdd checking routine for getting user list 44/239144/2
Junghyun Yeon [Wed, 22 Jul 2020 05:45:11 +0000 (14:45 +0900)]
Add checking routine for getting user list

Getting user list could be failed.

Change-Id: Ifcef817bd5624ec5a19784725ec1fb214cea4af0
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.13 46/239346/1 accepted/tizen/unified/20200727.132055 submit/tizen/20200724.075535
Ilho Kim [Fri, 24 Jul 2020 05:43:31 +0000 (14:43 +0900)]
Release version 1.32.13

Changes:
 - Fix to remove skel directories when uninstalling with keep-rwdata
 - Change the SetOwnership function behavior
 - Refactor dependency checker
 - Set is_upgrade flag before sending signal
 - Add GetErrorMessage to dependency_checker

Change-Id: Ieb8c3365359c06fc8f39f7ba8b6ee5895dc53ae8
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd GetErrorMessage to dependency_checker 19/238219/4
Ilho Kim [Thu, 9 Jul 2020 01:39:37 +0000 (10:39 +0900)]
Add GetErrorMessage to dependency_checker

If dependency checker occurr error
installer runner need to know detailed information

Change-Id: Ie35e1af2876c09566fd079a87ec0aadbb56d1c0e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoSet is_upgrade flag before sending signal 94/238794/6
Ilho Kim [Fri, 17 Jul 2020 08:54:33 +0000 (17:54 +0900)]
Set is_upgrade flag before sending signal

There is no way to know whether a request type is "upgrade" when emitting signal
Installer can set upgrade flag before sending signal
and that flag is used to identify request type

Related change:
   [slp-pkgmgr] https://review.tizen.org/gerrit/#/c/platform/core/appfw/slp-pkgmgr/+/237961/
   [slp-pkgmgr] https://review.tizen.org/gerrit/#/c/platform/core/appfw/slp-pkgmgr/+/238789/

Change-Id: Ifcd05d766bd69422c0e7397bad7484282ec2f2b2
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRefactor dependency checker 16/238016/7
Ilho Kim [Mon, 6 Jul 2020 07:20:23 +0000 (16:20 +0900)]
Refactor dependency checker

Change-Id: Iff4e81c95e10c5ebb6df5e4991d4bf7e16adbe85
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoChange the SetOwnership function behavior 30/239230/2
Ilho Kim [Thu, 23 Jul 2020 02:11:55 +0000 (11:11 +0900)]
Change the SetOwnership function behavior

If a file is symbolic link, change a symbolic link's ownership, not skip

Change-Id: I8f8be27050b10d07827a4a7a20d6588049304708

3 years agoFix to remove skel directories when uninstalling with keep-rwdata 16/238916/1
Sangyoon Jang [Mon, 20 Jul 2020 08:23:57 +0000 (17:23 +0900)]
Fix to remove skel directories when uninstalling with keep-rwdata

Change-Id: Ic05f1f79c9e9537d2df1cb28f824538db378bb95
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRelease version 1.32.12 76/238676/1 accepted/tizen/unified/20200720.125618 submit/tizen/20200717.052111
Sangyoon Jang [Thu, 16 Jul 2020 07:25:53 +0000 (16:25 +0900)]
Release version 1.32.12

Changes:
 - Refactor pkg_initdb
 - Add dependency check logic for some request type
 - Minor refactor
 - Add initialization to RecoveryInfo's default constructor
 - Fix logging installation history
 - Fix file logging format

Change-Id: I0fa37a97fe469745f848b4a9c907b22e2fa37d7c
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix file logging format 80/238580/1
Sangyoon Jang [Wed, 15 Jul 2020 08:22:28 +0000 (17:22 +0900)]
Fix file logging format

Change-Id: I0d505736051b4ad43fedb06bf20790f9fe15e3fd
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix logging installation history 70/238570/1
Sangyoon Jang [Wed, 15 Jul 2020 07:15:26 +0000 (16:15 +0900)]
Fix logging installation history

Add additional log when starting installation process.

Change-Id: I29aa5ea082756851d1858c9caf132bee55a02e5b
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoAdd initialization to RecoveryInfo's default constructor 51/237951/2
Ilho Kim [Tue, 7 Jul 2020 02:11:55 +0000 (11:11 +0900)]
Add initialization to RecoveryInfo's default constructor

Change-Id: Ie30b1d1a9705e92fa07bf99b87cf3abda27fdf2e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoMinor refactor 12/237612/4
Junghyun Yeon [Thu, 2 Jul 2020 01:15:21 +0000 (10:15 +0900)]
Minor refactor

- Apply early-return policy.
- Extract common codes into separate function.

Change-Id: Ied7b9789e5063ec580baa7d297626763070eed0b
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoAdd dependency check logic for some request type 48/237048/4
Ilho Kim [Wed, 24 Jun 2020 04:19:24 +0000 (13:19 +0900)]
Add dependency check logic for some request type

Delta type : get dependency info from archive
ReadonlyUpdateUninstall type : get dependency info from xml in readonly area

Change-Id: Ie0d1a2a59c3e4f4d65d95cb74346f36940a643de
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRefactor pkg_initdb 68/237068/7
Junghyun Yeon [Wed, 24 Jun 2020 23:22:27 +0000 (08:22 +0900)]
Refactor pkg_initdb

Separate its operations into several classes
for further functionality expansion.

Change-Id: Iaf9733d3a7abad5e964014c86f087991fd902311

3 years agoRelease version 1.32.11 71/237871/1 accepted/tizen/unified/20200707.140931 submit/tizen/20200706.085806
Junghyun Yeon [Mon, 6 Jul 2020 08:08:54 +0000 (17:08 +0900)]
Release version 1.32.11

Changes:
 - Add smoke util function for multi install
 - Create empty directory when running backup in smoke test
 - Fix coding rule
 - Implement recovery for uninstallation
 - Relocate some utility files

Change-Id: I32ced6ff96c8aae1b6df322195d0e3ddfc20028f
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelocate some utility files 08/237608/2
Junghyun Yeon [Thu, 2 Jul 2020 00:43:16 +0000 (09:43 +0900)]
Relocate some utility files

Relocating some files to reduce modular circular dependency ratio.

Change-Id: I3aeaef2af1b341a0b09b94282d37adc1b8d8e77c
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoImplement recovery for uninstallation 65/235765/5
Junghyun Yeon [Tue, 9 Jun 2020 11:28:27 +0000 (20:28 +0900)]
Implement recovery for uninstallation

Change-Id: Idd134cf3418de715fa1ced02962483a52de7e85b
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoFix coding rule 38/237138/1
Junghyun Yeon [Thu, 25 Jun 2020 08:31:36 +0000 (17:31 +0900)]
Fix coding rule

Change-Id: Iffa9accd3a51c663d7d426f10be1d5c0c5f9cd04
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoCreate empty directory when running backup in smoke test 30/236530/2
Ilho Kim [Thu, 18 Jun 2020 01:56:55 +0000 (10:56 +0900)]
Create empty directory when running backup in smoke test

When run test with empty directory, there is posibility causing error
- Multi install case : installer can't create unified recovery file

Change-Id: Ifba13001ed047d54aa941bdbd694c85bab73f3a8
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd smoke util function for multi install 59/235159/5
Ilho Kim [Tue, 2 Jun 2020 08:13:05 +0000 (17:13 +0900)]
Add smoke util function for multi install

Change-Id: Idbe2867e50f61aae2d26074845245cb2c6d24309
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRelease version 1.32.10 35/236035/1 accepted/tizen/unified/20200616.171022 submit/tizen/20200612.081636 submit/tizen/20200615.005642
Junghyun Yeon [Fri, 12 Jun 2020 06:58:03 +0000 (15:58 +0900)]
Release version 1.32.10

Changes:
 - Implement unified recovery feature
 - Add ZipInterface and MountBase class for exandability
 - Refactor StepUnregisterApplication
 - Fix locating manifest when recovery mode
 - Set unpacked_dir to recovery file at StepMountUnpacked
 - Fix InstallerRunner
 - Change recovery files priority
 - Remove a outdated comment

Change-Id: Ie6fb6520a59d37ed39a39ea003a8f7b56d624d3c
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRemove a outdated comment 06/236006/1
Sangyoon Jang [Fri, 12 Jun 2020 02:29:00 +0000 (11:29 +0900)]
Remove a outdated comment

Change-Id: I63bcd683c1dd5fc7fe732502e4635e2c0310e766
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoChange recovery files priority 42/235242/2
Ilho Kim [Wed, 3 Jun 2020 04:17:53 +0000 (13:17 +0900)]
Change recovery files priority

If there are a recovery file with backup, backup file is used for recovery

Change-Id: Iaf6bf7a8b46e7279a6e71ab7aa864d2106557a34
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoFix InstallerRunner 02/235502/2
Junghyun Yeon [Fri, 5 Jun 2020 05:50:20 +0000 (14:50 +0900)]
Fix InstallerRunner

InstallerRunner will not try to add installer instance into installer list
if InstallerFactory failed to create installer instance.

Change-Id: Iad149945a2d399a6c2f11902004f4a597e358409
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoSet unpacked_dir to recovery file at StepMountUnpacked 30/235430/1
Sangyoon Jang [Thu, 4 Jun 2020 10:46:30 +0000 (19:46 +0900)]
Set unpacked_dir to recovery file at StepMountUnpacked

The unpacked dir path should be set for recovery mode.

Change-Id: I4fafbb4ffb9d48cbb3ce753041b1fde11c118e55
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoFix locating manifest when recovery mode 61/235361/3
Sangyoon Jang [Thu, 4 Jun 2020 05:48:04 +0000 (14:48 +0900)]
Fix locating manifest when recovery mode

Search backup manifest at manifest directory first.

Change-Id: I9ab4e28bb9e273a0e82640283ab233ecafe1ec93
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
3 years agoRefactor StepUnregisterApplication 50/228550/10
Junghyun Yeon [Tue, 24 Mar 2020 01:27:26 +0000 (10:27 +0900)]
Refactor StepUnregisterApplication

- Apply early-return policy.
- Fix coding rule.
- Adjust debug message for consistency.
- Remove unnecessary namespace declaration.

Change-Id: I140538bc5aee1028dacfbc2c6ae3d53791a30926
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoAdd ZipInterface and MountBase class for exandability 46/235346/3
Junghyun Yeon [Thu, 4 Jun 2020 04:42:30 +0000 (13:42 +0900)]
Add ZipInterface and MountBase class for exandability

Inherits MountBase and implementing CreateZipInterface which returns
IZipInterface enables using other zip interface instead of TZip.

Change-Id: Ie33b9e0b18c2a5d677fa8634f1a25d34dc3ee1e6
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoImplement unified recovery feature 03/234403/13
Junghyun Yeon [Tue, 26 May 2020 06:14:46 +0000 (15:14 +0900)]
Implement unified recovery feature

Unified recovery file will be parsed at pkg recovery tool and
passed into unified backend to handle multi recovery scenario.

Change-Id: I50d7b4b89af0864fde2e137677900aff1b3d5c6b
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
3 years agoRelease version 1.32.9 31/235031/1 accepted/tizen/unified/20200603.150218 submit/tizen/20200602.012953
Ilho Kim [Tue, 2 Jun 2020 01:12:50 +0000 (10:12 +0900)]
Release version 1.32.9

Changes:
 - Check dependency when the request type is required

Change-Id: I62f273f7577de280e6fd71c70f239f7c785bcb36
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoCheck dependency when the request type is required 31/234731/4
Ilho Kim [Thu, 28 May 2020 06:53:24 +0000 (15:53 +0900)]
Check dependency when the request type is required

Change-Id: I184f7b7100efd9baae5070c058871b811de53f4e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRelease version 1.32.8 37/234937/1 submit/tizen/20200601.023448
Ilho Kim [Mon, 1 Jun 2020 02:29:02 +0000 (11:29 +0900)]
Release version 1.32.8

Changes:
 - Fix InstallerRunner::Run()
 - Change path of directory for mount point of MountInstall mode
 - Add GetArchiveInfo
 - Add GetIndex() funtion to AppInstallers
 - Fix smoke utils to test unified installer
 - Add StepCrash class at smoke utils
 - Modify ReadonlyUpdateInstall CreateStorageDirectories
 - Fix updating shared data directories
 - Fix installing shared/data directory of ReadonlyUpdateUninstall
 - Fix coding rule
 - Set CMAKE_VERBOSE_MAKEFILE=OFF as default
 - Fix StepCheckBackgroundCategory
 - Add Uninstall function to smoke utils for multi uninstall
 - Add Dependency Checker
 - Remove manifest backup when update recover with cleanup

Change-Id: I1feb0281bca99853ce7243c4b4b254b00a066923
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoRemove manifest backup when update recover with cleanup 58/234858/1
Ilho Kim [Fri, 29 May 2020 08:10:08 +0000 (17:10 +0900)]
Remove manifest backup when update recover with cleanup

In case update, installer create backup xml file
This backup file should be removed when run recovery with cleanup flag

Change-Id: If517d33729d83c2a7625621c0db17ec52a8fbebb
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd Dependency Checker 46/228146/20
Ilho Kim [Thu, 2 Apr 2020 04:56:51 +0000 (13:56 +0900)]
Add Dependency Checker

In case multi install,
there is need to sort the install requests according to dependencies

This class sort Installers in dependency order

[example]
A pkg requires B pkg : A -> B
B pkg requires C pkg : B -> C
- Full dependencies : A -> B -> C

This class sorts A,B,C into C,B,A

Change-Id: Icd48374060d2a6b013fac9f68cbafc638eb416fb
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
3 years agoAdd Uninstall function to smoke utils for multi uninstall 19/230719/4
Ilho Kim [Tue, 14 Apr 2020 00:26:35 +0000 (09:26 +0900)]
Add Uninstall function to smoke utils for multi uninstall

Change-Id: Ia5ee2c64e1703a4108f2944ee4f4772057a7aa57
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>