Tomasz Iwanek [Wed, 24 Jun 2015 12:02:21 +0000 (14:02 +0200)]
Remove unused dependencies from spec file
Change-Id: I760c21283ea152dcb10cb80db83e515b793ab82a
Tomasz Iwanek [Fri, 26 Jun 2015 09:49:06 +0000 (11:49 +0200)]
Clean up
Needless copy.
Future commit will change type returned by get_icon_paths().
Change-Id: If01b152705ada315fdc7150bd510ab555dc21464
Pawel Sikorski [Wed, 24 Jun 2015 10:35:17 +0000 (12:35 +0200)]
Fix in StepUpdateApplication.
proper pkgmgr_parser function used in case update is done
for Global user
Change-Id: I8d238804e29724843b3e6e0ae2d867c7dc71f8d7
Tomasz Iwanek [Thu, 11 Jun 2015 08:11:12 +0000 (10:11 +0200)]
Check widget settings according to privilege level
Some of widget settings requires certain privilege level
to be accepted by installation process.
In current shape of wrt spec, only one setting is forcing
privilege level: background-vibration
Change-Id: Ie88f415d84421859c250a8c7a55c9102ceed6c4e
Tomasz Iwanek [Wed, 10 Jun 2015 14:48:30 +0000 (16:48 +0200)]
Privilege level check
Implementation of privilege level check with use of privilege-checker
Change-Id: Ie2a5c6e8b9c6450580a1700c3e6c339de5e1f217
Tomasz Iwanek [Fri, 19 Jun 2015 13:14:06 +0000 (15:14 +0200)]
Fix tct test - widget02 - br
Add ContentHandler to wgt::StepParse
Change-Id: Idf6cd44c4c9a752bed63695b7257aa8ddec04f2a
WonYoung Choi [Mon, 22 Jun 2015 01:48:53 +0000 (10:48 +0900)]
Fix build error in step_generate_xml.cc
Change-Id: Ic8de16f871b98af400e32e7bb24fcd77498ce39b
WonYoung Choi [Mon, 22 Jun 2015 01:19:27 +0000 (18:19 -0700)]
Merge "Create '.applications/manifest/' if not exist" into tizen
WonYoung Choi [Mon, 22 Jun 2015 01:18:43 +0000 (18:18 -0700)]
Merge "Fix stylecheck and warnings" into tizen
Tomasz Iwanek [Wed, 10 Jun 2015 14:14:32 +0000 (16:14 +0200)]
Simplify repository structure (remove utils lib target)
Utils library was extracted to separate code imported from
crosswalk. As there is no more crosswalk code (signature was removed)
this structure could be simplified.
Before:
utils <- signature <- common <- wgt/tpk
After:
common (with utils) <- wgt/tpk
Additionally removed unused "native" directory.
Change-Id: I533f7d8864bd07766c2d488f952fb6a3e108de3d
Tomasz Iwanek [Fri, 29 May 2015 14:53:17 +0000 (16:53 +0200)]
Reimplement signature validation with cert-svc/vcore
This commit does not introduce any new feature in app-installer.
Signature is reimplemented only. Prililege level check and
other check will be implemented afterwards.
Removed dependencies to openssl and xmlsec as we are using
cert-svc now.
Reworked basic tests about signature:
"signature_unittest.cc"
Removed LICENSE-xwalk as it was not used anymore. All crosswalk
code was removed/moved to manifest-parser or rewritten.
Change-Id: I59462fd0e0082f5c2ec648caedebba8874e69ddf
Tomasz Iwanek [Wed, 17 Jun 2015 15:28:48 +0000 (17:28 +0200)]
Fix stylecheck and warnings
Change-Id: I65b18a60db3dfad37a9dd90fff1824531d0e99a7
Tomasz Iwanek [Thu, 18 Jun 2015 14:00:11 +0000 (16:00 +0200)]
Create '.applications/manifest/' if not exist
Change-Id: I5fc8e03e7dbd92a3581a38ad9c5f2834f809f6be
WonYoung Choi [Fri, 19 Jun 2015 02:06:06 +0000 (19:06 -0700)]
Merge "Fix update detection in app-installers" into tizen
WonYoung Choi [Fri, 19 Jun 2015 00:52:59 +0000 (17:52 -0700)]
Merge "Set <label> of manifest file is depend by long name instead of short name" into tizen
Tomasz Iwanek [Wed, 10 Jun 2015 12:49:03 +0000 (14:49 +0200)]
Fix update detection in app-installers
app-installers will need to detect update by itself to set
correct step for installation process. Therefore this patch
integrates previous workaround into common library code.
This will not requires changes in pkgmgr.
Introducing AppQueryInterface for each backend to provide.
This class will decide if update installation flow should
be forced or not. If pkgmgr backendlib would be developed
then this interface will require refactoring probably.
Please, note that tpk will need to provide own
AppQueryInterface instance.
Change-Id: Ic8d09b72227310fa4eb76bce882302c4291495d8
Tomasz Iwanek [Fri, 29 May 2015 13:50:42 +0000 (15:50 +0200)]
Cleanup - GetBackupPathForPackagePath
Backup directory in update installation is created per package
not per application (becuase we just copy whole content).
There should be one place which defines how this path is constructed.
Change-Id: I694d4641088acbeccd0cdab04d9e510b16415bf1
Tomasz Iwanek [Fri, 29 May 2015 10:29:17 +0000 (12:29 +0200)]
Create storage directories in widget
This commit adds creation of directories inside widget path:
${widget_dir}/data/
${widget_dir}/shared/
during installation.
Those directories should be preserved during update.
Change-Id: I37dca9e02304d7bde1c64c6dd459421d8c6ead79
Tomasz Iwanek [Fri, 12 Jun 2015 12:19:13 +0000 (14:19 +0200)]
Add metadata information to the manifest file
Change-Id: I38c19667042f40c1629ff1886ceeaba67108b065
Inhwan Lee [Wed, 17 Jun 2015 07:26:43 +0000 (16:26 +0900)]
Fix unexpected error when no value of <name> tag in config.xml
When there is no <name> tag in config.xml,
installer occur error unexpected because of empty string of manifest->uiapplication->label
Fix there are no <name> tag in config.xml, no <label> in manifest file
JIRA issue : http://168.219.209.56/jira/browse/XWALK-384
Change-Id: I236217e262faaaff6af3f2931568121ede51bbe8
Inhwan Lee [Wed, 17 Jun 2015 05:14:54 +0000 (14:14 +0900)]
Set <label> of manifest file is depend by long name instead of short name
There is not define with spec, but for backward competibility
And for pass tizen complience.
It's discripted by JIRA :
http://168.219.209.56/jira/browse/XWALK-409
Change-Id: I5f6df4dbc0f45b531ed0b5f6c7e79f2c9e4da331
Tomasz Iwanek [Tue, 9 Jun 2015 09:40:03 +0000 (11:40 +0200)]
StepParse must run before StepCheckSignature
The step_parse must be run before the step_signature in both
2 installers(wgt and tpk), in order to get several required
information(api-version, package type and privilege list)
from tizen-manifest.xml or config.xml.
Change-Id: Ifb89639af908d824738232620653861fd65e372b
Tomasz Iwanek [Thu, 11 Jun 2015 08:11:12 +0000 (10:11 +0200)]
Add field for backend specific data in installer context
There will be additional field in context just to store
backend specific data - "backend_data".
Each backend should set this to own instance of BackendData
implementation.
Settings field will be used in next commits.
Change-Id: Idf500cbac8d96c2dd10eb87113529f297fa3bcff
Tomasz Iwanek [Tue, 9 Jun 2015 08:47:21 +0000 (10:47 +0200)]
Cmake fixes
1) Spec should declare depenedency to pkgconfig package
2) Options should not be passed as string in cmake (ApplyPkgConfig.cmake)
(this causes problems in next commits)
Change-Id: I8c79143e2f224f819df0cbbffc26d35819975904
Tomasz Iwanek [Fri, 29 May 2015 12:17:01 +0000 (14:17 +0200)]
Cleanup of application_path
Change-Id: Ibcce5a9c7440bbf2e9c4f41ee01bd7010f14ae59
Tomasz Iwanek [Fri, 29 May 2015 12:17:01 +0000 (14:17 +0200)]
Extract macro PKGMGR_LIST_MOVE_NODE_TO_HEAD to separate header
Change-Id: I630a4b554196fd3dee5a5ac59c69e64a3784a659
Pawel Sikorski [Fri, 24 Apr 2015 10:32:40 +0000 (12:32 +0200)]
Small license fixes
Change-Id: Ib3ac72c277f80e6a93697f74aa7fb5058d102960
Sangyoon Jang [Fri, 5 Jun 2015 09:05:26 +0000 (18:05 +0900)]
Fix appcontrol on parse & generate xml
this patch is related with:
https://review.tizen.org/gerrit/#/c/40506/
Change-Id: If9e9eb900d688e794a3436e64a4e4c10662adfd2
Signed-off-by: Sangyoon Jang <s89.jang@samsung.com>
Inhwan Lee [Wed, 3 Jun 2015 04:21:56 +0000 (13:21 +0900)]
Copy icon file instead of move that
Icon file should copy at location of icon path, not move.
Original icon can use some test suite. (eg. web-tct-sp02-wrt-tests)
The issue can find in JIRA system (http://168.219.209.56/jira/browse/XWALK-320)
Change-Id: I18c4b4966fda497f2339526865864c13a856b053
Sangyoon Jang [Wed, 3 Jun 2015 04:48:09 +0000 (13:48 +0900)]
Fix step_generate_xml
add null check
Change-Id: Ic164b0975d0894e2c8b67f7b96d860fa33b6e019
Signed-off-by: Sangyoon Jang <s89.jang@samsung.com>
Tomasz Iwanek [Tue, 26 May 2015 13:31:41 +0000 (15:31 +0200)]
Workaround for update installation detection
This workaround is provided as pkgmgr requested.
This should be removed as soon as pkgmgr will handle
update detection and be passing correct options.
Removal of this should be easy as it is not modifing any flow
in installer.
Depends on pkgmgr: https://review.tizen.org/gerrit/#/c/38771/
Change-Id: Idae3b4ffd7842babc555c717986fe9beac39fece
Tomasz Iwanek [Tue, 26 May 2015 13:41:45 +0000 (15:41 +0200)]
Extracting unzipping to file utils
Change-Id: I7175e87bcecc6dd3463d1c80704f72e509e037c5
Youmin Ha [Wed, 27 May 2015 05:36:38 +0000 (14:36 +0900)]
Single app package support including service app
To run Tizen TCT packages, single-app packages having only service apps
must be able to be installed. This commit enables installing app packages
having only service apps.
- Removed mandatory ui-application app checking routine.
- Added a routine checking the existance of at least 1 ui or service app.
- Additional code for <service-application> attributes in
step_generate_xml.cc.
Change-Id: Iaac04f6fb20055fe06ca6b3a67294c9354695ec0
Signed-off-by: Youmin Ha <youmin.ha@samsung.com>
Youmin Ha [Wed, 6 May 2015 04:52:47 +0000 (13:52 +0900)]
Fix a log tag in step_register_app module
Even after renaming the module, still the log tag was not changed.
This small fix changes the tag name to make clear where the log is
from.
Change-Id: Iabeace9462e33716c6c0d7109eccb20617eceeea
Tomasz Iwanek [Tue, 28 Apr 2015 11:48:43 +0000 (13:48 +0200)]
Element-based localization for name, short_name, description
Value of name, short_name and description should affect platform
manifest fields: label and description.
Change-Id: Icf8fde530bb533f24d64810e46eb5608367aeac8
Wojciech Kosowicz [Thu, 7 May 2015 13:48:50 +0000 (15:48 +0200)]
[AppInstaller] Added definition of profile in spec
Change-Id: I4115f82847de3ab9a0c54361035c58f60982d1d7
Signed-off-by: Wojciech Kosowicz <w.kosowicz@samsung.com>
Jakub Izydorczyk [Tue, 21 Apr 2015 10:10:38 +0000 (12:10 +0200)]
Corrections related to API changes of manifest parser
Corrections related to API changes in WidgetInfo
manifest data class.
Relies on chang3s introduced in: https://review.tizen.org/gerrit/#/c/38685/
Change-Id: I181ddaff894c8b64b71380d845bd7db8a1768ba9
Tomasz Iwanek [Wed, 25 Mar 2015 15:24:11 +0000 (16:24 +0100)]
Skeloton for update installation
Tizen-JIRA: TC-2482
Change-Id: I8d0c0b18f8732360c32e99dbb03c0088436ff854
Tomasz Iwanek [Wed, 25 Mar 2015 12:34:45 +0000 (13:34 +0100)]
[CopyBackup] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: I8c366e911b218ec363959812db7b0e268b8da4ae
Tomasz Iwanek [Thu, 30 Apr 2015 11:19:12 +0000 (13:19 +0200)]
Fix StepBackupManifest::precheck
Change-Id: Ia6c0c0b82c0a71afb6275ccc19fb0e091802f5e7
Tomasz Iwanek [Tue, 28 Apr 2015 10:23:03 +0000 (12:23 +0200)]
Fix uninstallation - StepRevokeSecurity - remove check of context_->application_path
This path doesn't exist because files are removed before
security is revoked (otherwise they couldn't be).
Change-Id: I54136e38a4b4bc5ccdfa2804eb7162b80fc05487
Tomasz Iwanek [Thu, 2 Apr 2015 09:28:50 +0000 (11:28 +0200)]
[Gardening] Several fixes
- Byte size literals,
- use nullptr,
- some TODOs solved or removed,
Change-Id: I50517cf4c54b1d3134a7d6bbe98b556e15432f23
Jakub Izydorczyk [Thu, 2 Apr 2015 10:12:55 +0000 (12:12 +0200)]
[Unit tests] Add script run-unit-tests.sh
Script runs all unit tests for app-installer.
After all the results are available in xml files in
/usr/bin/app-installers-ut/ directory.
Change-Id: Ibe8ecd349b272cd00ad1761d906f548ca7ce4321
Tomasz Iwanek [Wed, 25 Mar 2015 11:19:08 +0000 (12:19 +0100)]
[BackupIcons] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: I76870b774aac8f7cb81624de8c66a09bd8b8eee9
Tomasz Iwanek [Tue, 24 Mar 2015 17:16:57 +0000 (18:16 +0100)]
[UpdateApplication] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: Ib0b2a60ba003fa81c9eaeb7c4df16fb97bdf7c21
Tomasz Iwanek [Tue, 24 Mar 2015 17:05:48 +0000 (18:05 +0100)]
Refactoring StepRecord
Initialization of user/global databases should not
be done in rollback of one step.
Tizen-JIRA: TC-2482
Change-Id: Ia0cd64a993d08a4781b642c75993d7a268e38f2f
Wojciech Kosowicz [Tue, 21 Apr 2015 13:53:09 +0000 (15:53 +0200)]
Creating root directory if not existing
Change-Id: I7e6e6039ec9db1ab8e6bbcd52722a65479533786
Signed-off-by: Wojciech Kosowicz <w.kosowicz@samsung.com>
Sangyoon Jang [Wed, 22 Apr 2015 06:39:09 +0000 (15:39 +0900)]
Fix result checking
pkgmgr_installer_receive_request returns 0 when complete successfully
Change-Id: I367292b035e79ee1860a07b9b83c3efed0bffa2d
Signed-off-by: Sangyoon Jang <s89.jang@samsung.com>
Tomasz Iwanek [Tue, 24 Mar 2015 16:12:12 +0000 (17:12 +0100)]
[BackupManifest] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: I09cfd57bf0edb9d2851fe49f02b4fdc11202e854
Tomasz Iwanek [Tue, 24 Mar 2015 15:52:28 +0000 (16:52 +0100)]
[UpdateSecurity] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: I2c2a60be64df60ad9d20f6cfce0733aecfd0eac5
Tomasz Iwanek [Tue, 24 Mar 2015 15:35:34 +0000 (16:35 +0100)]
[OldManifest] Added step for update installation
Tizen-JIRA: TC-2482
Change-Id: I37848449f6a6e199d796c2f01edbee422471591c
Tomasz Iwanek [Tue, 24 Mar 2015 15:22:00 +0000 (16:22 +0100)]
Add old_manifest_data property to context for update
Update installation will use this value to
restore security context if needed on rollback
operation.
For now, I'm leaving one context per all installation
types.
Tizen-JIRA: TC-2482
Change-Id: If0143e9036bd2149a0a1ba1d2aa359441785540e
Pawel Sikorski [Mon, 20 Apr 2015 11:54:19 +0000 (13:54 +0200)]
Buildbreak fix.
Empty overriden "precheck" method added to StepConfigure
Change-Id: Ic107c38be8b3d8d71b1f2c66e5b2623d3f0471dd
Pawel Sikorski [Tue, 14 Apr 2015 09:37:30 +0000 (11:37 +0200)]
StepConfigure - new step responsible for the InstallerContext
configuration.
Previously, AppInstaller included the general logic and some setup of
InstallerContext. However, InstallerContext should be only used within steps
(AppInstaller) should not mix the data and the logic.
Hence, Almost all context setup was moved to separate, new step - Configure
Change-Id: I508d2383bd6fca66326aa18df1bedb6f52fae3a6
Pawel Sikorski [Tue, 14 Apr 2015 10:00:25 +0000 (12:00 +0200)]
removal of not needed method call.
PkgmgrSingal::SendProgress method will just return false, if
state != Statue::Started.
This condition is always true in the beginning of Run() method.
Hence, this method will not perform anything.
Change-Id: I2ff46b156c931e9259fb434179a2a687a7ba93fa
Baptiste DURAND [Thu, 16 Apr 2015 12:10:12 +0000 (05:10 -0700)]
Merge "Adding Samsung License to files modified by Samsung engineers Adding Samsung engineers to AUTHORS files" into tizen
Pawel Sikorski [Wed, 8 Apr 2015 12:28:58 +0000 (14:28 +0200)]
Introducing "precheck" method for each step.
Precheck method should verify, if all necessary input data has been provided.
It returns OK on success (all necessary data has been provided to perform
"process" method).
Appinstaller, for each step, calls these methods in following order:
for(step: steps) {
...
if (step->precheck() != Step::Status::OK)
break;
step->process();
...
}
TODO:
* step_parse for WGT and TPK should introduce it
* step_create_symbolic_link for WGT and TPK should introduce it
Change-Id: Ibd506603bfb5c152723bae13e56301b517e94b2b
Pawel Sikorski [Wed, 15 Apr 2015 16:15:39 +0000 (18:15 +0200)]
Adding Samsung License to files modified by Samsung engineers
Adding Samsung engineers to AUTHORS files
Change-Id: I58001e73e7d9605cf92ae6a50e161bb18a8616f4
Tomasz Iwanek [Fri, 27 Mar 2015 08:26:38 +0000 (09:26 +0100)]
Extract MoveDir() to utils
Change-Id: Iae4d60d42b9c90003de4ed23070c9e34d358991d
Tomasz Iwanek [Tue, 14 Apr 2015 10:19:41 +0000 (12:19 +0200)]
Quickfix context->application_path
This field was set in context installer constructor where pkgid is
not yet available in installation case.
Change-Id: Ida6f97c763a2f3eec780d0c73fef08562de7547b
Tomasz Iwanek [Wed, 1 Apr 2015 14:41:31 +0000 (16:41 +0200)]
Context paths types changed to boost::filesystem::path
Change-Id: Ic82ebf53ecbae4029c39332e6fd057719d93a78d
Jakub Izydorczyk [Fri, 10 Apr 2015 10:01:41 +0000 (12:01 +0200)]
[Manifest parser] Remove manifest parser
Remove manifest-parser due to moving it to
separate repository.
Change-Id: I99dc8f7f363f0fed98a97a172643914b159aed04
Wojciech Kosowicz [Mon, 13 Apr 2015 13:32:12 +0000 (15:32 +0200)]
Revert "Xml manifest path in InstallerContext"
This commit needs to be reverted as it is removing setting up
variable which is later used in generating xml. Therefore
widgets do not install as crash occurs when calling function
on empty variable
Change-Id: Ic91a94851e00c35e4fa5bcd77c90b4dc556b7562
Signed-off-by: Wojciech Kosowicz <w.kosowicz@samsung.com>
Tomasz Iwanek [Mon, 30 Mar 2015 10:18:59 +0000 (12:18 +0200)]
Fix rollback for installation mode
There is an issue when we rollback an operation after appling
SMACK labels to widgets files.
In rollback security context is revoked before removing files
of widget. This will cause failure on rollback because
installer will try to remove files that it has no access to.
Bug-Tizen: TC-2484
Change-Id: Ic171732de546a62dd451be0ae39abdae18e76628
Tomasz Iwanek [Fri, 27 Mar 2015 13:26:55 +0000 (14:26 +0100)]
Xml manifest path in InstallerContext
This commit changes xml_path type to fs::type.
It also removes unnecessary setting from step_generate_xml
Change-Id: I2bc99da823959a4968802ca47367b6b1f2fca57c
Signed-off-by: Pawel Sikorski <p.sikorski@samsung.com>
Baptiste DURAND [Thu, 9 Apr 2015 13:07:48 +0000 (15:07 +0200)]
Remove hardcoded library path from PC files
BUG-Tizen:https://bugs.tizen.org/jira/browse/TC-2492
Change-Id: I5e69865c214b63401658d4602af080bb9b5bb190
Signed-off-by: Baptiste DURAND <baptiste.durand@open.eurogiciel.org>
Jakub Izydorczyk [Tue, 7 Apr 2015 08:40:53 +0000 (10:40 +0200)]
[Manifest parser] Create devel package, add new rpm
Create manifest-parser devel package,
add manifest-parser.pc pkgconfig file.
This also creates new rpm package for manifest parser
from, which app-installers should be dependant.
Change-Id: I70a744d138bce12eccb90705f80a2d1665cf91f4
Jakub Izydorczyk [Fri, 3 Apr 2015 12:44:39 +0000 (14:44 +0200)]
[Manifest parser] Separate filling manifest_x into few steps
Separate filling manifest_x structure into steps:
- filling widget info
- filling application info
- filling icon paths
- filling privileges
- filling app control
Change-Id: Ie4ea566bb797d2b7af196899663ff74342a1b493
Jakub Izydorczyk [Fri, 6 Mar 2015 12:12:53 +0000 (13:12 +0100)]
Remove assert checking for existance of widget package file
Remove assert, which checks if widget package file exsits
and replace it with checks from boost lib for file existence and
return error on failure.
Change-Id: I75dd117d85bef0fe1313da8a2510fe5bd6673dc7
Jakub Izydorczyk [Mon, 16 Feb 2015 08:33:20 +0000 (09:33 +0100)]
[Unit tests] Add unit tests for signature
3/3 tests PASS
Change-Id: I45e1e41b8e94ac171e75ad4e047cbd0d5379bb3b
Pawel Sikorski [Fri, 3 Apr 2015 12:41:32 +0000 (14:41 +0200)]
Allowing multiple instances of PkgmgrSignal.
This commit unifies states between multiple instances of
PkgmgrSignal objects (using static variable).
Change-Id: I698c509c60533534c49ba29f537aca0e56ae63a9
Pawel Sikorski [Fri, 3 Apr 2015 11:56:37 +0000 (13:56 +0200)]
Removal of request_type property from InstallerContext.
It is not used anywhere.
Change-Id: I6efd669e8b1827bb37659db0f13543029283aa31
Pawel Sikorski [Fri, 3 Apr 2015 11:36:27 +0000 (13:36 +0200)]
Introducing PkgMgrInterface to separate app-installer from
external library.
TODO:
* PkgMgrSignal should be refactor. Possibly, it could inherit from
PkgMgrInterface
Change-Id: I3f934674aec54c69073a122fcb4b71e16a94565f
Tomasz Iwanek [Thu, 19 Mar 2015 15:20:34 +0000 (16:20 +0100)]
[Signal] Sending progess to pkgmgr
Simple approach, calculate progress:
progress = numberOfStepExecuted * 100 / totalNumberOfSteps
No point to make it harder by now, IMO.
Change-Id: If20174e3756e1c087d8cac8fd4704bb82c1d5d13
Tomasz Iwanek [Thu, 19 Mar 2015 10:41:56 +0000 (11:41 +0100)]
[Signal] Send 'error' code to pkgcmd
All logic calling SignalPkgmgr class was moved to
AppInstaller class.
Change-Id: Ic99423abab4eaf5f239a27104b653e1dd12a8ad2
Signed-off-by: Pawel Sikorski <p.sikorski@samsung.com>
Jakub Izydorczyk [Wed, 8 Apr 2015 08:38:56 +0000 (10:38 +0200)]
Fix for not closed app-control element during xml generation
Commit https://review.tizen.org/gerrit/#/c/36834/ introduced
bug related to not closing app-control element and as a result
privilege element is inserted into ui-application element and
manifest don't pass validation.
Change-Id: If6e50fe196ffe783d307d80fb48821eb87a2da94
Jakub Izydorczyk [Thu, 5 Mar 2015 12:48:33 +0000 (13:48 +0100)]
Bring to common xml generation code
Make template function for generating common xml code
for uiapplication_x and serviceapplication_x
Make template funct
Change-Id: Iface15d6aed7055da0b42ba04ca374c8964cb880
Pawel Sikorski [Wed, 1 Apr 2015 09:21:51 +0000 (11:21 +0200)]
Introducing "Property" for ContextInstaller.
Currently, ContextInstaller contains attributes (declared as private).
And each attribute has its setter and getter defined.
Property hides declaration of these setters/getters.
TODO:
* Pi (PkgmgrSignal)
Change-Id: Iba6e8a796b54468798b35e708a8ecee03ec53988
Jakub Izydorczyk [Tue, 17 Mar 2015 13:30:12 +0000 (14:30 +0100)]
Unification of manfiest parser
This change includes changes according to architecture
planned in https://bugs.tizen.org/jira/browse/TC-2472
Further changes will be made later in next commits.
Change-Id: I9b3f2c9d340994b0248ba002d06effc70f30bffd
Baptiste DURAND [Mon, 30 Mar 2015 12:17:34 +0000 (14:17 +0200)]
add manifest for tpk backend
Change-Id: I5d632d00f86619111f222923c82f1d39da735621
Signed-off-by: Baptiste DURAND <baptiste.durand@gmail.com>
Pawel Sikorski [Fri, 27 Mar 2015 13:54:08 +0000 (14:54 +0100)]
Rename:
* StepSecurity -> StepRegisterSecurity
* StepSignature -> StepCheckSignature
* StepRemove -> StepRemoveFiles
* StepSymbolicLink -> StepCreateSymbolicLink
* StepRecord -> StepRegisterApplication
* StepUnregister -> StepUnregisterApplication
Most of the steps contain verb and noun in their names.
Hence, commit unifies all steps to follow this rule.
Change-Id: I59114dc41385b16e4661e23cd38fcb65637289a3
Tomasz Iwanek [Mon, 23 Mar 2015 10:05:19 +0000 (11:05 +0100)]
[Unittest] service_handler_unittests
This commit removes checks on GetManifestData()
as it ws used for multithreading purpose in crosswalk.
Change-Id: I2c3a19f834bb2af02f9319008ed813d427b2460c
Tomasz Iwanek [Fri, 20 Mar 2015 15:29:36 +0000 (16:29 +0100)]
[Parser] Add tizen:service handler
Spec: #1730
https://source.tizen.org/sites/default/files/page/tizen-2.3-wrt-core-spec.pdf
ValidateTizenApplicationId() was extracted due to use in multiple handlers.
Change-Id: I2c86d6a8f3e73709c57447781f96d62cb3cb8029
Tomasz Iwanek [Mon, 16 Mar 2015 13:38:57 +0000 (14:38 +0100)]
Available Storage Check
Solution calculates space needed for files.
This will ignore space for directories/icons/manifests but
in overall will prevent unneccesary unzipping the archive
in most cases.
Change-Id: Ib8e81c4cb56e771347a128021ece53e4cf2c9fce
Tomasz Iwanek [Thu, 12 Mar 2015 14:25:06 +0000 (15:25 +0100)]
[Copy] Move files instead of copy if possible
If move is not possible then fall back to copy/remove.
Change-Id: Icf2dbbf63b772ae6eccb4682a4295b397ca91548
Youmin Ha [Mon, 23 Mar 2015 10:19:17 +0000 (19:19 +0900)]
Support full spec of tpk manifest xml
With this commit, the tpk backend parses the full spec of the
tizen-manifest.xml.
* Multiple children having same name are parsed well.
* <author>, <service-application> are parsed.
* More attributes which are in the spec but not parsed are
supported.
Change-Id: I67689841125bb97048fa10accddab8e7e3839984
Singed-Off-By: Youmin Ha <youmin.ha@samsung.com>
Tomasz Iwanek [Wed, 25 Mar 2015 12:53:16 +0000 (13:53 +0100)]
Fix UTF8CharLength
This function is wrong because of char's 'signness' is
implementation defined.
C++ standard doesn't define char as unsigned char.
Basically,
char != signed char
char != unsigned char
This was ok for arm architeture but not for x86.
This overlook caused calculated length of character
to be wrong.
Change-Id: Ifd826ae38098e78da8de858fd5720a6a3dc46a38
Baptiste DURAND [Mon, 23 Mar 2015 13:56:58 +0000 (06:56 -0700)]
Merge "Allow optional elements in tpk manifest xml" into tizen
Tomasz Iwanek [Fri, 20 Feb 2015 09:36:39 +0000 (10:36 +0100)]
Move/rename widget-manifest-parser
Simplify naming and remove underscores in directory name.
Change-Id: I3df8b3212c70e6456e8cc47c0e3f263c1ebdc514
Tomasz Iwanek [Tue, 17 Mar 2015 13:48:55 +0000 (14:48 +0100)]
[Security] Fix passing path in StepRevokeSecurity::undo()
RegisterSecurityContextForApps() takes path to the root of
application (where the index.html is located).
Same as in: https://review.tizen.org/gerrit/#/c/36757/
Change-Id: Id46a569e4d140951edeecf7e7fba1c377c2b2daf
Youmin Ha [Tue, 17 Mar 2015 04:47:33 +0000 (13:47 +0900)]
Allow optional elements in tpk manifest xml
Some xml elements are optional, thus they can be omitted in the
tizen-manifest.xml.
This patch allows those elements to be omitted.
In addition, null checking routine in common/step/step_generate_xml.cc
is added, because if there is no description in tizen-manifest.xml,
manifest_x->description will be nullptr.
Change-Id: Ie37236b472011c9d516840cc9cda86b777a6a474
Signed-Off-By: Youmin Ha <youmin.ha@samsung.com>
Tomasz Iwanek [Wed, 18 Mar 2015 15:10:39 +0000 (16:10 +0100)]
Fix parser handlers
In current execution flow, there is call of Parse() function
for each handler. Handler should be prepared for situation that
there is no value it expects.
Change-Id: Ib17ed3e4bbb5600397c9bf23cf140d0d064b8d29
Jakub Izydorczyk [Fri, 13 Mar 2015 13:03:44 +0000 (14:03 +0100)]
Fix manfiest_util parsing localized text nodes
manifest_util was was adding bidi control characters in front and
in the back twice, when dir attribute was specified.
Manifest util test results:
12/12 tests PASS
Change-Id: Ic83a766508f871607849c298d335e813b4484db7
Tomasz Iwanek [Fri, 20 Feb 2015 15:16:39 +0000 (16:16 +0100)]
[Unitttests] string_utils_unittest
This commit adds unit tests for 'src/utils/string_util.*'
Change-Id: I237ebe67f7f761afb5f6dfa5d6d648206e8f7d13
Youmin Ha [Mon, 16 Mar 2015 08:29:46 +0000 (17:29 +0900)]
Fix tpk parser bug
Fixed condition of judging children count of an element
Change-Id: I9547294a2c1b1018a0bed87e4eab656a61ed2e2e
Signed-Off-By: Youmin Ha <youmin.ha@samsung.com>
Rafal Krypa [Wed, 18 Mar 2015 11:07:19 +0000 (12:07 +0100)]
Perform StepRevokeSecurity after StepRemove
Revoking security configuration causes StepRemove to fail.
Application files are labeled with per-app Smack label.
Access to that label is part of security configuration which shouldn't
be revoked before files are uninstalled.
Change-Id: Ib41ca3b04324f307954c64fa93cdefaf9da0325b
Signed-off-by: Rafal Krypa <r.krypa@samsung.com>
Jakub Izydorczyk [Fri, 13 Mar 2015 06:35:45 +0000 (07:35 +0100)]
Add missing unit tests for manifest util
10/12 tests PASSES
GetNodeText tests fails due to double addition
of bidi control characters
Change-Id: I766827bd7b61da469fd38376bdee1c6715034e2f
Jakub Izydorczyk [Fri, 6 Mar 2015 13:53:54 +0000 (14:53 +0100)]
Remove Manifest::Type from parser
Remove Manifest::Type, as this parser was supposed to be
only for config.xml from *.wgt applications.
Change-Id: Ie465f45c40d2c59492e3f9503132af8e47a4ccd0
Youmin Ha [Fri, 13 Mar 2015 05:14:46 +0000 (14:14 +0900)]
Fix the path of each application passed to security manager
Wrong path of each application was passed to the security manager. It
causes installation failure.
This commit fixes the installed application path.
Change-Id: I0b95e528ef2f4c41091b4e60bb9f42e1dce02333
Signed-Off-By: Youmin Ha <youmin.ha@samsung.com>
Signed-Off-By: Sangyoon Jang <s89.jang@samsung.com>
Youmin Ha [Thu, 5 Mar 2015 08:05:41 +0000 (17:05 +0900)]
Replace tpk manifest parser to XmlParser
Old manifest parser is replaced with the new general-purpose XmlParser.
With the XmlParser, the element hierarchy is fully preserved.
In addition, all exceptions are removed in this commit.
Change-Id: Id03384dc0b3c661bd876966bfbb3883b631cc68d
Signed-Off-By: Youmin Ha <youmin.ha@samsung.com>