platform/core/system/crash-worker.git
4 years agolog: Make LogLevel statically configurable 06/226206/6
Karol Lewandowski [Wed, 26 Feb 2020 08:24:40 +0000 (09:24 +0100)]
log: Make LogLevel statically configurable

Change-Id: I6d38d777ec5aaef0e8ba71d6d1c91907c4a68057

4 years agoMove system-tests to main .spec 14/225814/4
Karol Lewandowski [Mon, 24 Feb 2020 14:44:54 +0000 (15:44 +0100)]
Move system-tests to main .spec

Change-Id: I675555baab83ce3051401757054bde3cf4317271

4 years agoRelease 6.0.11: Hotfix: Do not return pointer to member of destroyed pkgmgr structure 44/225944/2 accepted/tizen/unified/20200227.121108 submit/tizen/20200225.153334
Karol Lewandowski [Tue, 25 Feb 2020 14:51:38 +0000 (15:51 +0100)]
Release 6.0.11: Hotfix: Do not return pointer to member of destroyed pkgmgr structure

Change-Id: Ibe121a4d98cec1fe4aaaf61dd8b321f0c88ddd9a

4 years agoRelease 6.0.10 47/225647/2 accepted/tizen/unified/20200225.224245 submit/tizen/20200221.151318
Karol Lewandowski [Fri, 21 Feb 2020 13:10:17 +0000 (14:10 +0100)]
Release 6.0.10

This release brings ability to exclude certain paths from
dumping via ExcludePaths config section.

Change-Id: I49bf203e836bf610ebb8836adb9af45cb23cabbb

4 years agoIntroduce list of processes excluded from dumping 48/225548/4
Karol Lewandowski [Thu, 20 Feb 2020 15:45:07 +0000 (16:45 +0100)]
Introduce list of processes excluded from dumping

This commits adds ability to specify list of executables
to be excluded from dumping via special new ExcludePaths
section, eg.

   /etc/crash-manager.conf.d/local.conf:
   [ExcludePaths]
   NameNotImportant=/usr/bin/daemon-with-sensitive-information

Change-Id: Ia1c7f6570a8fc243458c48cc8f5284ab461be256

4 years agoutil: Refactor get_cmd_info 46/225646/2
Karol Lewandowski [Fri, 21 Feb 2020 10:54:24 +0000 (11:54 +0100)]
util: Refactor get_cmd_info

Change-Id: Ie7c0584487367f7c059c49b0cc309ef5ac7e6542

4 years agoJanitorial: '<foo>*' -> '<foo> *' 46/225546/3
Karol Lewandowski [Thu, 20 Feb 2020 18:26:08 +0000 (19:26 +0100)]
Janitorial: '<foo>*' -> '<foo> *'

Place pointer signature consistently with rest of codebase.

Change-Id: Ie183a11724fe886036cf2929ca6acdfac989da9b

4 years agoutil: Add function to normalize paths produced by kernel.core_pattern %E 45/225545/3
Karol Lewandowski [Thu, 20 Feb 2020 15:46:03 +0000 (16:46 +0100)]
util: Add function to normalize paths produced by kernel.core_pattern %E

Change-Id: I0afbb7d946d16b2fff293c8697ae2e6d7db53e43

4 years agoComplain when livecoredumper is needed and not installed 44/225544/2
Karol Lewandowski [Thu, 13 Feb 2020 08:30:43 +0000 (09:30 +0100)]
Complain when livecoredumper is needed and not installed

This brings back functionality dropped in 22a0cccdad ("Simplify
struct crash_info setup").

Change-Id: If5ddddee6b99784d7ada9a93e89d3ad975facb6b

4 years agoconfig: Be more verbose about consequence of ExtraScript OOM condition 47/225547/2
Karol Lewandowski [Thu, 20 Feb 2020 18:26:59 +0000 (19:26 +0100)]
config: Be more verbose about consequence of ExtraScript OOM condition

Change-Id: I7add0d5df5fc2a0369c011574eff7a1eccd8343f

4 years agoRelease 6.0.9 75/225275/1 accepted/tizen/unified/20200219.130207 submit/tizen/20200218.160617
Karol Lewandowski [Mon, 17 Feb 2020 10:02:07 +0000 (11:02 +0100)]
Release 6.0.9

This release brings numerous fixes and one change - reports are named
with pkg name prefix for apps (regular processes still are named after
cmdline).

Change-Id: Ia0b6345e5d3735fa7e15cd0621818e55118a11f9

4 years agoMagic shall not prevail 45/225145/3
Michal Bloch [Mon, 17 Feb 2020 16:07:32 +0000 (17:07 +0100)]
Magic shall not prevail

Change-Id: I01eded05dc377efd992a2fa175891ac6765b4114
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoSimplify struct crash_info setup 16/225016/5
Karol Lewandowski [Fri, 14 Feb 2020 16:20:51 +0000 (17:20 +0100)]
Simplify struct crash_info setup

Change-Id: Ibbb13c4534b89d6e1ee4b951a438ae1748ae30d2

4 years agoUse package id as prefix for report files 82/224882/2
Karol Lewandowski [Wed, 12 Feb 2020 15:00:15 +0000 (16:00 +0100)]
Use package id as prefix for report files

Change-Id: I37ea45e2c0a262e9bcd2bb3bcdb97edba83cbc7d

4 years agocrash-manager: Be a bit more verbose about consequence of missing TID 80/224880/2
Karol Lewandowski [Thu, 13 Feb 2020 14:24:27 +0000 (15:24 +0100)]
crash-manager: Be a bit more verbose about consequence of missing TID

Change-Id: If5b5a4c5050c9fc5afea233311de6145222c445f

4 years agoDrop sys-assert leftovers 79/224879/1
Karol Lewandowski [Thu, 13 Feb 2020 08:27:41 +0000 (09:27 +0100)]
Drop sys-assert leftovers

Change-Id: Ia220cc73a1b1e60f165aedd58cdfe9360c8de63b

4 years agoMerge "Adjust codebase for iniparser upgrade (4.x)" into tizen accepted/tizen/unified/20200213.121625 submit/tizen/20200203.003549 submit/tizen/20200205.003954
Karol Lewandowski [Mon, 3 Feb 2020 11:51:21 +0000 (11:51 +0000)]
Merge "Adjust codebase for iniparser upgrade (4.x)" into tizen

4 years agoRelease 6.0.8 68/223168/1 accepted/tizen/unified/20200129.022638 submit/tizen/20200123.165339
Karol Lewandowski [Thu, 23 Jan 2020 16:49:04 +0000 (17:49 +0100)]
Release 6.0.8

This release brings minor fixes to dbus policy and system test.

Change-Id: I2bd9cc0a7979dd92e0fe819e0eeca0ec37afb28c

4 years agoFix livedump API DBus access policy 61/223161/2
Karol Lewandowski [Thu, 23 Jan 2020 12:43:46 +0000 (13:43 +0100)]
Fix livedump API DBus access policy

This commit partially reverts commit f24c53fb20 ("crash-service:
Restrict allow livedump API via privilege")

As discussed with SRPOL Security, the 'group membership' of given
process does not map directly to process 'having privilege', as
verified by Cynara/security-manager.  For now the checking has to
be done per-user for system services and via-privilege for apps.

Change-Id: I2a7b76174adb22be8ffe55e41678b48938d90bbb

4 years agoAdd missing system test to spec 83/223083/1
Karol Lewandowski [Wed, 22 Jan 2020 14:51:26 +0000 (15:51 +0100)]
Add missing system test to spec

Change-Id: I7d7b4d2a91e40938e65cb9153ebfc8d0e320876e

4 years agoRelease 6.0.7 12/222912/3 submit/tizen/20200121.141527 submit/tizen/20200123.105228
Karol Lewandowski [Tue, 21 Jan 2020 09:54:05 +0000 (10:54 +0100)]
Release 6.0.7

This version adds support option to support legacy 'ProcessCrashed' signal.

Change-Id: I964c7f8a58ac96f3055403d9a5c33aee223747e3

4 years agoAdd system test for legacy signal 55/222955/2
Karol Lewandowski [Tue, 21 Jan 2020 11:25:41 +0000 (12:25 +0100)]
Add system test for legacy signal

Change-Id: If4e2d007ebac2de6a11d64137c9d93e5efc75b6d

4 years agoAdd option to support legacy DBus 'ProcessCrashed' signal 91/222891/3
Kunhoon Baik [Tue, 21 Jan 2020 07:47:59 +0000 (16:47 +0900)]
Add option to support legacy DBus 'ProcessCrashed' signal

Original author: Kun-Hoon Baik <knhoon.baik@samsung.com>
Reworked by: Karol Lewandowski <k.lewandowsk@samsung.com>

Change-Id: I64b950b99d81b2a0a4ba4e67938d865431c1a25e

4 years agoAdjust codebase for iniparser upgrade (4.x) 79/222079/1
Karol Lewandowski [Thu, 9 Jan 2020 10:22:00 +0000 (11:22 +0100)]
Adjust codebase for iniparser upgrade (4.x)

Change-Id: I3d8e613b8d1cccbbbf84b7dceac5abde57578fe6

4 years agoRelease 6.0.6 72/221772/1 accepted/tizen/unified/20200108.131512 submit/tizen/20200107.101346
Karol Lewandowski [Tue, 7 Jan 2020 09:24:04 +0000 (10:24 +0100)]
Release 6.0.6

This release brings following changes:

 - Use designated privilege to limit livedump API.

   This replaces temporary use of per-used privilege
   check in dbus policy.

 - Gcc 9.x build fix

Change-Id: I2bad2792af9aefbd210cd1537293823a664d1a8f

4 years agocrash-service: Restrict allow livedump API via privilege 59/220359/6
Karol Lewandowski [Tue, 17 Dec 2019 13:58:15 +0000 (14:58 +0100)]
crash-service: Restrict allow livedump API via privilege

Use newly created http://tizen.org/privilege/internal/livecoredump
privilege to restrict access to crash-service's livedump dbus
interface.

Change-Id: I9b2f560c061426d561674e3560b60c10e36c384e

4 years agocrash-manager: Make permission handling in maps more abstract 23/221523/3
Karol Lewandowski [Fri, 3 Jan 2020 08:16:48 +0000 (09:16 +0100)]
crash-manager: Make permission handling in maps more abstract

This also fixes gcc9.2 build error.

Change-Id: Iae099a366063cd69cca840bd83121a8930d89088

4 years agoRelease 6.0.5 81/220481/3 submit/tizen/20191220.194729
Karol Lewandowski [Wed, 18 Dec 2019 14:36:27 +0000 (15:36 +0100)]
Release 6.0.5

This release brings ability to extend configuration via snippets
in /etc/crash-manager.conf.d/ directory.

Change-Id: Ic01f780a2bb3868e48f02bbe95ac725adcb384cd

4 years agoconfig: Ensure freed pointers are set to null 45/220745/1
Karol Lewandowski [Fri, 20 Dec 2019 19:32:46 +0000 (20:32 +0100)]
config: Ensure freed pointers are set to null

Change-Id: I779cff27a6873187e5f17415469864d6ccd0d1b7

4 years agoconfig: Search for configuration also under crash-manager.conf.d directory 73/220173/5
Karol Lewandowski [Wed, 18 Dec 2019 09:41:09 +0000 (10:41 +0100)]
config: Search for configuration also under crash-manager.conf.d directory

Change-Id: I9c5680eafb467a0514feec5225cb794609ba1823

4 years agoconfig: Separate config loading from processing 72/220172/5
Karol Lewandowski [Fri, 13 Dec 2019 12:11:08 +0000 (13:11 +0100)]
config: Separate config loading from processing

Change-Id: Ief38894e03904f9947ee72773f07044280f62b41

4 years agocrash-service: Stability monitor does not need to own crash-worker's dbus name 58/220358/1
Karol Lewandowski [Tue, 17 Dec 2019 13:56:06 +0000 (14:56 +0100)]
crash-service: Stability monitor does not need to own crash-worker's dbus name

Change-Id: Ida73ce27ac6ea040dcffb81f3a61e4096dc81940

4 years agoFix file permissions 71/220171/1
Karol Lewandowski [Fri, 13 Dec 2019 10:46:13 +0000 (11:46 +0100)]
Fix file permissions

Change-Id: I078c745cc56e1cf108997f2e76897dbe4cb194da

4 years agospec: add MIT to License field 05/218805/1 accepted/tizen/unified/20191208.221907 submit/tizen/20191128.084355 submit/tizen/20191128.095939 submit/tizen/20191129.160037 submit/tizen/20191202.125225 submit/tizen/20191206.142827
Adrian Szyndela [Thu, 28 Nov 2019 07:53:56 +0000 (08:53 +0100)]
spec: add MIT to License field

This adds MIT License to licenses specified in spec's License field.

Change-Id: I40635546c35d11c777767740dea7bac2993bedf3

4 years agolicense: add MIT license 27/218727/1 submit/tizen/20191127.103525
Adrian Szyndela [Wed, 27 Nov 2019 10:16:36 +0000 (11:16 +0100)]
license: add MIT license

Some part of src/crash-stack/crash-stack-x86.c seems to be copied
from libunwind. The part has MIT license.

This adds MIT license text and an entry in the spec file.

Change-Id: I8796d9ad2e61cd0671470eaaae184c2d00e6615f

4 years agoRelease 6.0.4 43/218643/2 accepted/tizen/unified/20191128.001532 submit/tizen/20191126.105153
Mateusz Moscicki [Tue, 26 Nov 2019 09:03:02 +0000 (10:03 +0100)]
Release 6.0.4

This release brings:

 - Add stability_monitor user to the crash-service dbus policy

Change-Id: Ief93724cbf23771163186a35c1b69806bd32027f

4 years agoAdd stability_monitor user to the crash-service dbus policy 42/218642/2
Mateusz Moscicki [Tue, 26 Nov 2019 09:02:31 +0000 (10:02 +0100)]
Add stability_monitor user to the crash-service dbus policy

Change-Id: If47b06d92e09a566a195763012bb2cd19f31eb6e

4 years agodump_systemstate: Ensure extra-files and extra-programs are included by default 45/218245/3
Karol Lewandowski [Wed, 20 Nov 2019 15:57:08 +0000 (16:57 +0100)]
dump_systemstate: Ensure extra-files and extra-programs are included by default

Needed as regular dump_systemstate functionality has been implemented
via .conf files.

Change-Id: I32d1c4cb954f6556c5782ff2e56f0f1c9d06acd4

4 years agodump_systemstate: Dump additional files and applications output 31/217031/6
Mateusz Moscicki [Tue, 5 Nov 2019 13:15:51 +0000 (14:15 +0100)]
dump_systemstate: Dump additional files and applications output

Change-Id: I2c1348a25f7da30c5a177489eb4e57aed5f730ea

4 years agodump_systemstate: Add flag to dump_systemstate to determine whether to run buxton2ctl... 63/215763/8
Mateusz Moscicki [Mon, 14 Oct 2019 11:04:56 +0000 (13:04 +0200)]
dump_systemstate: Add flag to dump_systemstate to determine whether to run buxton2ctl or not

The next commit introduces a change that causes the crash-service not to
have to be run as root, so there is need for another way to determine if
dmesg or buxton2ctl should be run.

Change-Id: I56df8f4dd1b9d8a2f6f072c886e8fa26dda0a317

4 years agoRelease 6.0.3 66/218466/1 submit/tizen/20191122.132437
Mateusz Moscicki [Fri, 22 Nov 2019 13:06:13 +0000 (14:06 +0100)]
Release 6.0.3

This release brings:

 - Revert "Allow new special priv_livecoredump group members to use livedump API" commit

Change-Id: I10a2458fd1504f475b39e05a91bcd1edfb5a382f

4 years agoRevert "Allow new special priv_livecoredump group members to use livedump API" 65/218465/1
Mateusz Moscicki [Fri, 22 Nov 2019 13:04:35 +0000 (14:04 +0100)]
Revert "Allow new special priv_livecoredump group members to use livedump API"

This reverts commit ab88e92b1eb4bae8d94523141afb2d59ffc5e6e6.

Change-Id: Ida972aa30aaa001ace379a5051ef654589119f76

4 years agoRelease 6.0.2 61/218361/2 submit/tizen/20191121.124127
Mateusz Moscicki [Thu, 21 Nov 2019 11:15:47 +0000 (12:15 +0100)]
Release 6.0.2

This release brings:

 - Run crash-service and crash-worker as crash_worker user
 - Fix the name of libcrash-service requirement in crash-worker_system-tests

Change-Id: Ib1e94342c475b20cde77bd10fbd21fd8a9ddfcb5

4 years agoChange system_fw user to crash_worker 60/218360/2
Mateusz Moscicki [Wed, 20 Nov 2019 11:03:43 +0000 (12:03 +0100)]
Change system_fw user to crash_worker

Change-Id: I79938533fc4475dfd4d9d95e5037fe29928ad0c7

4 years agoSet supplementary groups for the crash-manager process 08/218008/3
Mateusz Moscicki [Mon, 18 Nov 2019 08:24:40 +0000 (09:24 +0100)]
Set supplementary groups for the crash-manager process

Change-Id: I8283c0ca4605d6e882836e4a02079c65dd1ad30c

4 years agoDrop privileges when started by kernel 52/217352/4
Mateusz Moscicki [Thu, 7 Nov 2019 10:41:59 +0000 (11:41 +0100)]
Drop privileges when started by kernel

Change-Id: I3fa61c9f7b89f3fe7b8c7a8bedd8e852bdccf404

4 years agoConfigure the crash-service so that it doesn't require root privileges 64/215764/13
Mateusz Moscicki [Mon, 14 Oct 2019 12:00:40 +0000 (14:00 +0200)]
Configure the crash-service so that it doesn't require root privileges

Change-Id: I6bddc446a31449b7419074f10f795b8ee6c61714

4 years agoChange crash-worker-libcrash-service requirement to libcrash-service 59/218359/1
Mateusz Moscicki [Wed, 20 Nov 2019 09:33:16 +0000 (10:33 +0100)]
Change crash-worker-libcrash-service requirement to libcrash-service

Change-Id: I1fcc2886404daea67b6be86b6930bb567a0c3f32

5 years agoRelease 6.0.1 50/217350/1 submit/tizen/20191108.142020 submit/tizen/20191108.161448 submit/tizen/20191112.150934
Karol Lewandowski [Fri, 8 Nov 2019 13:24:13 +0000 (14:24 +0100)]
Release 6.0.1

Bump release version to next Tizen version.  Changes:

 - Fix preparing report for applications with too long name
 - Allow new special priv_livecoredump group members to use livedump API
 - Minor fixes

Change-Id: Iaa0374526fd110bd9f565a0afadc4044cd499fb7

5 years agospec: Standarize field justification to spaces 32/217132/2
Karol Lewandowski [Wed, 6 Nov 2019 11:37:19 +0000 (12:37 +0100)]
spec: Standarize field justification to spaces

Change-Id: I51e143520f84d3194c8735101cc93f4b4dd84fff

5 years agoProvide libcrash-service package, not crash-worker-libcrash-service 31/217131/1
Karol Lewandowski [Wed, 6 Nov 2019 10:41:18 +0000 (11:41 +0100)]
Provide libcrash-service package, not crash-worker-libcrash-service

Change-Id: I4def644bfb149b3d2eaf228addc38e011d5d5172

5 years agoAllow new special priv_livecoredump group members to use livedump API 30/217130/1
Karol Lewandowski [Wed, 6 Nov 2019 08:08:11 +0000 (09:08 +0100)]
Allow new special priv_livecoredump group members to use livedump API

Change-Id: Ia210a100bc2af1ce323ef90331e31950d8a8b277

5 years agoFix preparing report for applications with too long name 45/215845/5
Mateusz Moscicki [Wed, 16 Oct 2019 12:20:47 +0000 (14:20 +0200)]
Fix preparing report for applications with too long name

Crash-manager gets the application name from /proc/<pid>/cmdline, but
this value can be modified (e.g. by modify argv[0]), and may be
incorrect. Now report file name is prepared based on the executable
path.

Change-Id: Ia7f3b495bf501a67620888c99d49832e0fd6a23d

5 years agoExtract libcrash-service to a separate package 66/215766/8
Mateusz Moscicki [Tue, 15 Oct 2019 09:00:00 +0000 (11:00 +0200)]
Extract libcrash-service to a separate package

Change-Id: Ife9bf0274c226f3a2e85e8d97db567e0da8d4d4a

5 years agoAdd full coredump test 41/216241/1
Mateusz Moscicki [Tue, 22 Oct 2019 09:08:29 +0000 (11:08 +0200)]
Add full coredump test

Change-Id: I6c49d87be5a34e86744a929bfd16c2476cc39a0b

5 years agoRelease 5.5.26: Coverity fix 61/216161/2 accepted/tizen_5.5_unified_mobile_hotfix tizen_5.5_mobile_hotfix accepted/tizen/5.5/unified/20191031.023143 accepted/tizen/5.5/unified/mobile/hotfix/20201027.090745 accepted/tizen/unified/20191021.220204 submit/tizen/20191021.144555 submit/tizen_5.5/20191031.000004 submit/tizen_5.5_mobile_hotfix/20201026.185104 tizen_5.5.m2_release
Mateusz Moscicki [Mon, 21 Oct 2019 14:26:34 +0000 (16:26 +0200)]
Release 5.5.26: Coverity fix

This release brings:

 - Fix memory leak

Change-Id: Ida144b8ca6bd3f5ca954ef8478545f3dfff293e0

5 years agoRelease 5.5.25: Converity fix 59/216159/3 submit/tizen/20191021.135902
Mateusz Moscicki [Mon, 21 Oct 2019 13:04:09 +0000 (15:04 +0200)]
Release 5.5.25: Converity fix

This release brings:

 - Add check if sh_entsize is zero (coverity fix)
 - Ensure child termination is handled properly in crash-service

Change-Id: I91f400d1e747fbd84894d77b6f215fb5efc03635

5 years agoFix handling of child exit signal 62/215762/4
Mateusz Moscicki [Mon, 14 Oct 2019 14:29:39 +0000 (16:29 +0200)]
Fix handling of child exit signal

Change-Id: I01fcd716666876b6d4b03cce4a2f1e278118f547

5 years agoEnsure livedumper is installed for crash-service 51/216051/1 submit/tizen/20191021.093552
Karol Lewandowski [Fri, 18 Oct 2019 12:48:27 +0000 (14:48 +0200)]
Ensure livedumper is installed for crash-service

Change-Id: I5306c32142ecd2cec89a6b514af9a2f466a89dc6

5 years agoRelease 5.5.24 49/215549/2 accepted/tizen/unified/20191011.015545 submit/tizen/20191010.130640
Karol Lewandowski [Thu, 10 Oct 2019 11:52:27 +0000 (13:52 +0200)]
Release 5.5.24

This release brings:

 - optimizations to reduce memory footprint
 - removal of sys-assert (deprecated)

Change-Id: Ie3df6181e3c991d14ee8ef0da21208551d1c7f02

5 years agoReduce heap usage 69/215469/8
Mateusz Moscicki [Tue, 8 Oct 2019 10:13:14 +0000 (12:13 +0200)]
Reduce heap usage

When *.so_info was writing, for TPK packages, a complete list of
packages and paths was built, to find a RPM package that contains the
file. Now only the list of files is kept in memory, and then RPM
database is iterated to find suitable package.

Change-Id: I779661de26afd959945d441ba5ad160c99a014b2

5 years agoPass the "-s" (without_core) parameter to the minicoredumper if dump_core is set... 15/215215/5
Mateusz Moscicki [Mon, 30 Sep 2019 10:55:42 +0000 (12:55 +0200)]
Pass the "-s" (without_core) parameter to the minicoredumper if dump_core is set to 0

Change-Id: I04be2a58f72d7dbb2dbfacd4d0c4b6e23c97dcf1

5 years agoDrop sys-assert 48/215548/2
Karol Lewandowski [Thu, 10 Oct 2019 11:31:58 +0000 (13:31 +0200)]
Drop sys-assert

It's been deprecated for long time.

Change-Id: I0f5623cbf2ef32c9630d853ead61a6e92bfa27b2

5 years agoupgrade script: change confusing comments 47/215547/2
Karol Lewandowski [Thu, 10 Oct 2019 11:30:03 +0000 (13:30 +0200)]
upgrade script: change confusing comments

Change-Id: I50c6ef0195a63f39ebbf40cbe68cccca4bad7f83

5 years agoDrop log_dump scripts 46/215546/1
Karol Lewandowski [Thu, 10 Oct 2019 11:03:58 +0000 (13:03 +0200)]
Drop log_dump scripts

Change-Id: I9adf5d9cca48a3313338c881ee3227beb32880a3

5 years agoRelease 5.5.23 09/214809/2 submit/tizen/20191009.123450 submit/tizen/20191009.202509
Karol Lewandowski [Thu, 26 Sep 2019 12:36:31 +0000 (14:36 +0200)]
Release 5.5.23

This release drops log_dump, which is moved to separate repository.

Change-Id: I305f4a758721c1b5566aa61693d2ad65ad281a5a

5 years agoFix coverity issue - ensure that the buffer is null terminated 86/215486/2
Mateusz Moscicki [Wed, 9 Oct 2019 08:26:06 +0000 (10:26 +0200)]
Fix coverity issue - ensure that the buffer is null terminated

Change-Id: Ia5eb44790320f48f6751aa247d1d600cb01a9f10

5 years agoInitialize variables to NULL 90/215290/4
Mateusz Moscicki [Thu, 3 Oct 2019 15:46:29 +0000 (17:46 +0200)]
Initialize variables to NULL

Change-Id: I8d9abdea13e0a11ac3c0b55386a137f095767803

5 years agoMerge "Make remaining macros behave like standard statements" into tizen
Karol Lewandowski [Tue, 8 Oct 2019 11:58:56 +0000 (11:58 +0000)]
Merge "Make remaining macros behave like standard statements" into tizen

5 years agoMerge "Move log_dump to platform/core/system/log_dump" into tizen
Karol Lewandowski [Mon, 30 Sep 2019 13:25:33 +0000 (13:25 +0000)]
Merge "Move log_dump to platform/core/system/log_dump" into tizen

5 years agoMerge "Separate log_dump from crash-worker" into tizen
Karol Lewandowski [Mon, 30 Sep 2019 13:25:28 +0000 (13:25 +0000)]
Merge "Separate log_dump from crash-worker" into tizen

5 years agoMerge "Run all existing tests from tests/system/ directory" into tizen
Karol Lewandowski [Mon, 30 Sep 2019 13:25:20 +0000 (13:25 +0000)]
Merge "Run all existing tests from tests/system/ directory" into tizen

5 years agoMake remaining macros behave like standard statements 23/214923/1
Karol Lewandowski [Sat, 28 Sep 2019 16:28:01 +0000 (18:28 +0200)]
Make remaining macros behave like standard statements

Change-Id: Id09a320422eeac2ddd459b47b023df8d4d975971

5 years agoFix compilation on 64-bit architectures 18/214818/1 submit/tizen/20190926.222014 submit/tizen/20190927.061310
Karol Lewandowski [Thu, 26 Sep 2019 19:42:09 +0000 (21:42 +0200)]
Fix compilation on 64-bit architectures

64-bit architetures have lib in lib64, fix this by using
cmake-provided information about target system directories.

Change-Id: I794c89ad06b7bd80acd50acd3e64a36ffe86ea5d

5 years agoMove log_dump to platform/core/system/log_dump 05/213905/2
Mateusz Moscicki [Tue, 10 Sep 2019 12:22:49 +0000 (14:22 +0200)]
Move log_dump to platform/core/system/log_dump

Change-Id: I7349a275c370cef32cb6da143acb1b5255de68f3

5 years agoSeparate log_dump from crash-worker 75/212875/3
Mateusz Moscicki [Mon, 19 Aug 2019 11:33:15 +0000 (13:33 +0200)]
Separate log_dump from crash-worker

crash-worker can be installed without log_dump

Change-Id: Ifa045dede15148e4c5215b1a54fd0e3280d75f52

5 years agoRun all existing tests from tests/system/ directory 04/213904/2
Mateusz Moscicki [Tue, 10 Sep 2019 10:16:38 +0000 (12:16 +0200)]
Run all existing tests from tests/system/ directory

This allows to put there tests by other crash-manager related packages

Change-Id: I3dea8cdb77cf20c8bed68ff9b8891d87c0bd5da2

5 years agoRelease 5.5.22 08/214808/1 submit/tizen/20190926.140827
Karol Lewandowski [Thu, 26 Sep 2019 12:29:23 +0000 (14:29 +0200)]
Release 5.5.22

This version brings one major enhancement - livedump API, available
for platform service developers.

pkgconfig name: crash-service
       include: libcrash-service.h
                   API: livedump_pid()

Change-Id: I25d22fc9f43e647dd48ea4f02cebb2dbb5ac49ec

5 years agoAdd crash manager API 74/212874/13
Mateusz Moscicki [Thu, 25 Jul 2019 09:02:43 +0000 (11:02 +0200)]
Add crash manager API

Privileged processes can send a D-Bus method call to create report of
any living process. Signature is (iss):

- INT    (in) PID
- STRING (in) dump reason
- STRING (out) report path

There is a library libcrashservice that sends the D-Bus method call.

A function signature is:

    int livedump_pid(pid_t pid,
                     const char *dump_reason,
                     char *report_path);

Change-Id: Id8528bdbaac517d4b5fc649821368e0ff020862f

5 years agoMove code to the shared library 47/212547/11
Mateusz Moscicki [Tue, 20 Aug 2019 11:39:42 +0000 (13:39 +0200)]
Move code to the shared library

Change-Id: I05f3bc5902bd7b13b4f50dac32622e7f3cbaedab

5 years agoAdd --output option 43/212043/12
Mateusz Moscicki [Thu, 25 Jul 2019 06:50:37 +0000 (08:50 +0200)]
Add --output option

This option allows to specify the custom output directory for reports

Change-Id: I7a49d958f268f73f346b7f5b692cf3ce56808f37

5 years agoRelease 5.5.21 68/214168/1 accepted/tizen/unified/20190919.110156 submit/tizen/20190918.132704
Mateusz Moscicki [Wed, 18 Sep 2019 13:02:39 +0000 (15:02 +0200)]
Release 5.5.21

Changes:
 - livedumper: fix coverity issuses
 - livedumper: check open() result

Change-Id: Iee7fce1be940cc8163162a31202121180f111afc

5 years agoFix Coverity issues 41/214141/1
Mateusz Moscicki [Wed, 18 Sep 2019 09:34:49 +0000 (11:34 +0200)]
Fix Coverity issues

Change-Id: I84d25d996c2134e141bb366ca3adc77743ba98ba

5 years agoCheck if open() was successful 03/212103/6
Mateusz Moscicki [Tue, 13 Aug 2019 11:25:39 +0000 (13:25 +0200)]
Check if open() was successful

Change-Id: I801699a864f2df60bfae0734fce20a925c104553

5 years agoRelease 5.5.20 55/212455/3 accepted/tizen/unified/20190904.224501 submit/tizen/20190904.110321
Karol Lewandowski [Wed, 21 Aug 2019 16:52:14 +0000 (18:52 +0200)]
Release 5.5.20

This release brings few small improvements:

  - refactor crash-manager main invocation code
  - dump_scripts: move_dump.sh: set PATH exactly as security team requires
  - crash-manager: print textual error code where possible
  - assorted fixes

Change-Id: I319c10c4e96249b246fea8698b590147d2636da5

5 years agoconfig: Use same type to store all bools 52/213052/3
Karol Lewandowski [Thu, 29 Aug 2019 20:57:02 +0000 (22:57 +0200)]
config: Use same type to store all bools

Change-Id: Ife768dd5b71355759db7d678d7c3fd6a5399e811

5 years agoconfig: Fix invalid default setting for MaxRetentionSec 87/213087/3
Karol Lewandowski [Fri, 30 Aug 2019 06:38:50 +0000 (08:38 +0200)]
config: Fix invalid default setting for MaxRetentionSec

Change-Id: I809d86fdd0242c2c280b4db4eef009cadfd4652b

5 years agoconfig: Add missing free() for extra_script 51/213051/2
Karol Lewandowski [Thu, 29 Aug 2019 20:56:42 +0000 (22:56 +0200)]
config: Add missing free() for extra_script

Change-Id: Ie17d4dd90e08f02192139acbd8edf5c5682a4f59

5 years agoMove code to a separate function 40/212040/5
Mateusz Moscicki [Thu, 25 Jul 2019 09:00:26 +0000 (11:00 +0200)]
Move code to a separate function

Change-Id: I81bd9ac6467214ce9251213dee193fd6f53c71c2

5 years agocrash-manager: print textual error code where possible 51/212451/5
Karol Lewandowski [Wed, 21 Aug 2019 13:29:01 +0000 (15:29 +0200)]
crash-manager: print textual error code where possible

Change-Id: Ia2536417d55d9b8275424983ce24ec6cdadc7d5a

5 years agocrash-manager: Janitorial: rename crash_crash_path to crash_dump_path for readability 50/211950/6
Karol Lewandowski [Mon, 12 Aug 2019 11:54:37 +0000 (13:54 +0200)]
crash-manager: Janitorial: rename crash_crash_path to crash_dump_path for readability

Change-Id: Id62ade3ac22c27360bad000b37e3e9bc53e5b254

5 years agocrash-manager: Rewrite make_dump_path() for readability 50/212450/5
Karol Lewandowski [Wed, 21 Aug 2019 13:29:31 +0000 (15:29 +0200)]
crash-manager: Rewrite make_dump_path() for readability

Change-Id: I523ca95903f16118e87ca724cc035b82c879d459

5 years agodump_scripts: move_dump.sh: set PATH exactly as security team requires 52/212452/3 accepted/tizen/unified/20190822.045421 submit/tizen/20190821.171906
Karol Lewandowski [Wed, 21 Aug 2019 13:45:32 +0000 (15:45 +0200)]
dump_scripts: move_dump.sh: set PATH exactly as security team requires

Change-Id: I8750d45b43ebb090e9cf31b8c1814eb1550fdce7

5 years agoRelease 5.5.19 68/211868/2 accepted/tizen/unified/20190812.235604 submit/tizen/20190809.125447
Karol Lewandowski [Fri, 9 Aug 2019 11:36:49 +0000 (13:36 +0200)]
Release 5.5.19

This release brings:

 - lowering priority of crash-worker sysctl file to allow
   easy overwriting of sysctls by local files

 - few fixes for reliability

 - minor system tests refactoring

Change-Id: If12efeb3c59c68ed642c32d83e789592520a18af

5 years agoshared: Simplify get_exe_path 21/211721/2
Karol Lewandowski [Thu, 8 Aug 2019 08:49:27 +0000 (10:49 +0200)]
shared: Simplify get_exe_path

Change-Id: I26839430a4836454f96c1f273a1500899dc6b607

5 years agocrash-manager: fix potential cinfo->cmdline double free 20/211720/2
Karol Lewandowski [Thu, 8 Aug 2019 08:13:04 +0000 (10:13 +0200)]
crash-manager: fix potential cinfo->cmdline double free

Change-Id: I1ea39c92f076834defe4dfc0e7f4a6d0f798f066

5 years agoLower the number (and priority) of crash-worker sysctl config file 09/211409/2
Karol Lewandowski [Thu, 1 Aug 2019 14:38:12 +0000 (16:38 +0200)]
Lower the number (and priority) of crash-worker sysctl config file

Install sysctl file with 70 prefix instead of 99.  This will allow
overriding variables by creating eg. 99-local.conf file with appropriate
vars.

Change-Id: I88e25839a59a66896ab540d0836776b2d64225e5

5 years agosystem tests: Simplify exit helper functions 58/211258/1
Karol Lewandowski [Thu, 25 Jul 2019 11:13:09 +0000 (13:13 +0200)]
system tests: Simplify exit helper functions

Change-Id: Iecafa3632ac0c81454c2692037de34b486dfa2e2

5 years agoRelease 5.5.18 79/210679/2 accepted/tizen/unified/20190725.112358 submit/tizen/20190724.102627
Karol Lewandowski [Tue, 23 Jul 2019 15:25:00 +0000 (17:25 +0200)]
Release 5.5.18

This release introduces following features:

  - Addition of signal that caused crash and thread name to
    dbus signal (in sys.signal and sys.tid.comm fields, respectively)

    Additionally, report path is appended properly to the signal
    (bugfix)

  - Livecoredump reports are saved in livedump/ subdirectory
    from this release

  - Executable name is passed to minicoredumper allowing per-app
    recipes to be specified

  - All executables are rebuild as PIE as needed for ASLR to work

Change-Id: I91b2222c603d1d75b5e3df501f3d57eed5d7ff4e

5 years agoPass the executable name to the minicoredumper 97/210397/5
Mateusz Moscicki [Thu, 18 Jul 2019 15:58:38 +0000 (17:58 +0200)]
Pass the executable name to the minicoredumper

Change-Id: Iccd4abead0a87873d05e05333630bd859d34ef46