summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-10-08Switch from libsystemd to glibtizen_5.5.m2_releasesubmit/tizen_5.5_wearable_hotfix/20201026.184304submit/tizen_5.5_mobile_hotfix/20201026.185104submit/tizen_5.5/20191031.000004submit/tizen/20191009.095955accepted/tizen/unified/20191009.231758accepted/tizen/5.5/unified/wearable/hotfix/20201027.112750accepted/tizen/5.5/unified/mobile/hotfix/20201027.090057accepted/tizen/5.5/unified/20191031.022213tizen_5.5_wearable_hotfixtizen_5.5_tvtizen_5.5_mobile_hotfixaccepted/tizen_5.5_unified_wearable_hotfixaccepted/tizen_5.5_unified_mobile_hotfixMaciej Slodczyk12-359/+241
Change-Id: Ibe5d385ff53996126f0eb39443ae0a57dc7061c2 Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com> Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-09-24Use more of the available information in some error casesMichal Bloch2-6/+6
Change-Id: I0806e577936f1ca2e1156521b6f1029986f88394 Signed-off-by: Michal Bloch <m.bloch@samsung.com>
2019-09-17Fix svace issuesubmit/tizen/20190917.062742accepted/tizen/unified/20190918.102147Yunmi Ha2-2/+8
- Add logic for checking return value Change-Id: I96fc6357e2aa451d6ea09c45557d4827c7b2230b Signed-off-by: Yunmi Ha <yunmi.ha@samsung.com>
2019-09-17svace fixsubmit/tizen/20190917.020352sanghyeok.oh1-3/+8
Change-Id: Ice65d826b4331e3bbb2ef02a10652a7223a317e5 Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
2019-08-29Fix dbus policysubmit/tizen/20190906.005604accepted/tizen/unified/20190906.111903Hyotaek Shim1-1/+11
This patch places the check rule into the default context. <check send_destination="org.tizen.activationd" send_type="method_call" privilege="http://tizen.org/privilege/internal/sysadmin"/> This might make processes with System::Privileged, System, User bypass the <check> rule, but with this cynara rule we apply default DENY rule for http://tizen.org/privilege/internal/sysadmin. So, applications only with the privilege can be allowed by the <check> rule. https://review.tizen.org/gerrit/#/c/platform/core/security/security-manager/+/212942 cyad --set-policy --bucket=MANIFESTS_GLOBAL --client="$client" --user="*" --privilege="http://tizen.org/privilege/internal/sysadmin" --type=DENY Change-Id: Ie1d05cc24c368e22cbc2f2d5015db11cefbccdd0 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-27fix compilation warnings, add -WerrorMaciej Slodczyk10-49/+58
Change-Id: I4dca3549fc20713f7996469bc99341e845c9dc3f Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-08-26Adjust to libsyscommon API changesubmit/tizen/20190827.024510submit/tizen/20190826.120923accepted/tizen/unified/20190827.110626Karol Lewandowski1-1/+1
Change-Id: I2c7b340fc100080ee915087c7dc962ede57a12a0
2019-08-22Release 0.2submit/tizen/20190822.153849accepted/tizen/unified/20190823.001442Karol Lewandowski1-1/+1
This release brings abitility to re-transmit received dbus signals to specified destinations. Change-Id: Icdbea97c4c1cd2a2021442b45219bf209ae88ac7
2019-08-22signal forward: pass broadcast signal parametersMaciej Slodczyk7-37/+42
Change-Id: I608faeeac606f113130449825f8e2348c07f6900 Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-08-22signal forward: check for event reason after the event is processedMaciej Slodczyk2-7/+4
Change-Id: I239f56ec3f4f90617da00215c214888c6b603217 Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-08-22activation_dm: Support signal re-emmisionKarol Lewandowski8-10/+167
This commit introduces ability for signal re-emmision. Basic procedure is as follows: - dbus_listener receives signals from system bus - signals to be forwarded need to be listed here - activationd_dm received "ForwardDBusSignal" `action` which needs to be specified, while `destination` specifies target dbus name to which signal has to be delivered - forward_signal acton is added which re-transmits the signal to specified destination This commit does not yet support passing original signal parameters. Change-Id: I72346c2dbb326f78252f6f0bdc24acceebbc4ae0
2019-08-20dbus_listener: Acquire signal parameters on event retrievalKarol Lewandowski1-4/+12
Do not use parameters used when configuring match but the params that actually caused the callback to be called. This is important because eg. one can specify path_namespace in match, but it's not parameter that will be in message - it's "match parameter" only(!) Change-Id: I4d3d922887accf9402282ae0210d682f170bbdb8
2019-08-20Fix svace issuessubmit/tizen/20190821.011758accepted/tizen/unified/20190821.064629Yunmi Ha5-34/+20
Change-Id: I15a9c64c01f34c58e1506eb15786fce544b24663 Signed-off-by: Yunmi Ha <yunmi.ha@samsung.com>
2019-08-13Switch to libsyscommon in unit_start actionsubmit/tizen/20190819.035335accepted/tizen/unified/20190819.081610Paweł Szewczyk3-67/+44
Change-Id: If5809e26cc1d508a8892c03057b7ad8a2f15bc93 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-08-13Switch to libsyscommon in unit control APIPaweł Szewczyk3-113/+77
Change-Id: I9e73046906fd9733f4c42fdba39d6a42cb652a60 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-08-13Fix dbus policy to prevent policy checker errorssubmit/tizen/20190813.044217accepted/tizen/unified/20190813.082406Hyotaek Shim1-1/+0
Change-Id: Ibcf3f73dbd1e939176965990eaf518209981ba41 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-09Add dependency to activationd-pluginsubmit/tizen/20190813.041902submit/tizen/20190813.023537Hyotaek Shim1-0/+1
Change-Id: I3fa9305eb59f59ffaac5f2c87667dee5e3fb518c Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-09Fix lower/uppercase for dbus interfacesHyotaek Shim7-15/+15
Reference: Well-known name: org.freedesktop.systemd1 Path: /org/freedesktop/systemd1 Interface: org.freedesktop.systemd1.Manager Member: StartUnit Change-Id: I3c76f42cd1ce78a9ef98c78460a4aad63a408172 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-09Temporarily allow method call for developmentHyotaek Shim1-0/+1
Change-Id: I1321b65f85eb4054e47883d97acfb7656fd74334 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-09Switch to libsyscommon API in dbus listenerPaweł Szewczyk4-120/+83
Change-Id: I3bb2f8a94b771d6e485a9ce726ddada639ceb452 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-08-08Merge "unit tests: new api function return values no longer break tests" ↵submit/tizen/20190808.042854accepted/tizen/unified/20190808.113635Hyotaek Shim1-13/+31
into tizen
2019-08-08Merge "unit_control: add separate return value when timeout occurs" into tizenHyotaek Shim2-17/+25
2019-08-07Merge changes I81ae2cb9,I09b94c71 into tizenMaciej Slodczyk10-25/+19
* changes: Drop example configuration unit_control_dm: drop unneeded assert
2019-08-07unit tests: new api function return values no longer break testsMaciej Slodczyk1-13/+31
Change-Id: I5eeb421fd6e4c51ce250bdb331e1f8ff65882430 Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-08-07unit_control: add separate return value when timeout occursMaciej Slodczyk2-17/+25
Change-Id: I663691dfb3ece5197efdcb0ed9fc4909dd4a0c0a Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-08-07Drop example configurationKarol Lewandowski9-24/+19
This will be maintained in separate repostiory - activationd-plugin. Change-Id: I81ae2cb9afadee5217811d9135d23a4a0b57b553
2019-08-07unit_control_dm: drop unneeded assertKarol Lewandowski1-1/+0
Config can be null when no configuration file was provided. Change-Id: I09b94c71c307db73f0d186b294151bd12e639229
2019-08-07Add -fPIC compilation optionHyotaek Shim1-0/+1
Change-Id: Iec84755bcf262b7e5095e111f28523004c7feba5 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-08-06unit_control: Ensure API always returns valid error codesubmit/tizen/20190807.020938accepted/tizen/unified/20190807.111823Karol Lewandowski2-19/+27
Additionally, introduce explicit return code for asynchronous requests - UNIT_CONTROL_REQUEST_SENT, which does only mean that request was posted, not completed. Change-Id: Ia5a8f7141ede8d196c8af5e3c0ec65d2058f9f73
2019-08-06libactd: pkgconfig: Ensure library clients use directory prefixKarol Lewandowski1-1/+1
ie. recommended use is #include <actd/unit_control.h> Change-Id: I475f531566eb4b8cabd9f79037de13b2992b7a23
2019-08-06unit_control: Improve timeout handlingKarol Lewandowski2-24/+35
- explicitly specify timeout unit in function signatures (ie. timeout_ms, instead of just timeout) - add UnitControlTimeout enum with default and max timeout constants Change-Id: I637ad82251739a245fdbaaa936999263c919591f
2019-08-06unit_control: Do not pollute global namespace with unqualifed enumsKarol Lewandowski1-2/+2
Change-Id: I0262d581a21836eef671f63c23cafa462e69c7bb
2019-08-05unit_control: don't quit on errorsAdrian Szyndela1-13/+9
This makes unit_control not return errors to systemd's source_dispatch. That is, errors are sent back to clients as replies through D-Bus, but the unit_control module itself does not report errors to the dispatch, because the dispatch would disable the unit_control. Such behaviour would make subsequent clients reaching their timeouts instead of getting meaningful responses, such as "Access denied", or "This is not supported, stupid!". Change-Id: I1f624c3d7bb0ed31a0310371946c341fd3ad7feb
2019-08-01Remove glib dependency from include/unit_control.hsubmit/tizen/20190801.020645accepted/tizen/unified/20190801.113337Hyotaek Shim2-24/+26
Change-Id: I1289fbc4a2bc019b2f34d17f5dedfef292561c45 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-07-31packaging: Ensure needed packages are installed for unit-control functionalitysubmit/tizen/20190801.013233Karol Lewandowski1-0/+1
Change-Id: Ie5ef7fc8b9e908a7920c15db540a26589112074b
2019-07-31Move libactd development files to separate package libactd-develKarol Lewandowski4-4/+28
Additionally, libactd pkgconfig package is provided. Change-Id: I9a36f3b0d2ae2e0bacb1b3f60460f481d5d412b7
2019-07-16Remove unneeded dependency on cmockaPaweł Szewczyk2-4/+1
Change-Id: I7551d2d36795a41672691f639ddd5a4fca8eee79 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-07-05tests: Install test services for user sessionPaweł Szewczyk2-0/+5
Change-Id: Iac8535667bd4eba8b87ed6275cd25917ccf200bc Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-07-05unit tests: check real unit state after issuing a method callMaciej Slodczyk1-63/+278
Change-Id: I532e2de9b2e91f05bfcdca6ab40408980ac98540 Signed-off-by: Maciej Slodczyk <m.slodczyk2@partner.samsung.com>
2019-06-27Release 0.1.1submit/tizen/20190627.154817accepted/tizen/unified/20190701.111808Paweł Szewczyk2-2/+2
Changelog: - introduced libactd library - using asynchronous calls where possible - added automatic tests - minor fixes in existing modules Change-Id: I5a37574e6abe1aeb0eea08fa94499883123d43d5 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-26unit_control: Do not query systemd for non-wildcardsPaweł Szewczyk1-1/+9
Unit names with wildcards can match multiple units, but non-wildcard names are always matched directly and do not need querying systemd. Avoiding this should reduce delay and fixes restarting inactive units (which systemctl does, and so should we) Change-Id: I2609fc619a84875e77039ae80995ed249edcf85d Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-24libactd: Change handler signature in unit_controlsubmit/tizen/20190626.083411accepted/tizen/unified/20190627.014800Paweł Szewczyk3-22/+47
The reply message is read inside the library and only a status is passed to registered handler in async calls. Change-Id: I71d2452d94d00d21b8a79c51102fc6f90a7801b6 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-21libactd: Add timeout parameter to unit-controlPaweł Szewczyk3-32/+32
Change-Id: I1a36439684424d9393a1a2eaf2ab529cf2f33391 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-17unit_control: Extend unit lookup for all loaded unitsPaweł Szewczyk1-1/+1
Change-Id: Ida251e3807ee9c844e4c8a0bd6e7d1cc5641f333 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-17unit_control: Reply with an error if no unit was matchedPaweł Szewczyk1-0/+9
Change-Id: I0a78a7d7830d88d26e0eff8d0b01401f85842af3 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-17tests: Add missing tests for API callsPaweł Szewczyk1-8/+55
Change-Id: Ib3f8dd2e9305e1b4384668447dad555b79590d7e Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-17libactd: Call systemd directly if on session busPaweł Szewczyk1-31/+111
Change-Id: I6508537d0289d0d4723a8f52317d48887b1150ce Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-17libactd: Use glib instead of libsyscommonPaweł Szewczyk6-46/+74
Libsyscommon does not provide neccessary control over dbus calls, e.g. makes it hard to select a bus to connect to. Change-Id: I79bab3bcc7d26bd4f68a6ab5ca58225081259581 Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
2019-06-12Apply ASLR for actd binary build, -piesubmit/tizen/20190612.045457accepted/tizen/unified/20190612.111703Hyotaek Shim1-1/+1
Change-Id: Ibca6f48af0025a7ae3a8a885ee2a677075e9fcd9 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
2019-06-11Fix dbus policy rulesubmit/tizen/20190611.023606accepted/tizen/unified/20190611.050217Hyotaek Shim1-1/+2
Change-Id: I240bfd5d6ff4ae19b3851abce748d2407eb06201 Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>