platform/upstream/systemd.git
5 years agoMinor fix regarding "update-alternatives --remove systemd-shutdown.." 51/198551/1
Hyotaek Shim [Fri, 25 Jan 2019 08:50:42 +0000 (17:50 +0900)]
Minor fix regarding "update-alternatives --remove systemd-shutdown.."

Change-Id: I33510d36510a468c9fa67265f3ba3e73934080a0
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
5 years agotizen: Allow replacing systemd-shutdown 06/197106/7 accepted/tizen/unified/20190128.061802 submit/tizen/20190124.124507
Karol Lewandowski [Wed, 9 Jan 2019 15:16:19 +0000 (16:16 +0100)]
tizen: Allow replacing systemd-shutdown

This will be used by deviced to install custom shutdown handler.

Change-Id: I1f921fbae7d05f9ba937bb68cfa997a310407484

5 years agodbus1-generator: Fixed the problem of passing NULL argument to strcmp 63/197663/1
INSUN PYO [Tue, 15 Jan 2019 05:19:43 +0000 (14:19 +0900)]
dbus1-generator: Fixed the problem of passing NULL argument to strcmp

If /usr/share/dbus-1/[system-]services does not have "Exec=" field, "exec" variable is NULL.
Passing NULL to strcmp, "Segmentation fault" occurs.

Change-Id: I04fa32d97452ab97dfd4cf4ec70a670fe96a2c09

5 years agofd-util: Fix error handling in safe_fclose 79/194279/2 accepted/tizen/unified/20181205.063358 submit/tizen/20181204.070128
Paweł Szewczyk [Fri, 30 Nov 2018 11:35:23 +0000 (12:35 +0100)]
fd-util: Fix error handling in safe_fclose

Function fclose_nointr returns negative value on error.

Change-Id: I881469ed78037d531d73e41c77b57aab004a713a
Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
5 years agoRevert "Revert "tizen: All logins should use User::Shell smack label"" 38/193538/1 accepted/tizen/unified/20181130.134740 submit/tizen/20181122.025733 submit/tizen/20181130.022847
Karol Lewandowski [Wed, 21 Nov 2018 14:40:31 +0000 (15:40 +0100)]
Revert "Revert "tizen: All logins should use User::Shell smack label""

This reverts commit c2d66807f77cd0607bf6d961d2cb11b64f7a97c5.

The problem was in security-config package that removed the service
file during image creation stage.  The removal was caused by change
(SmackProcessLabel=) that didn't match its own "saved" policy.

Change-Id: I2680299ae1ea1920538f284a9e6c229d8b71f5c1

5 years agoMerge "Revert "tizen: All logins should use User::Shell smack label"" into tizen accepted/tizen/unified/20181119.073102 submit/tizen/20181119.064943
Hyotaek Shim [Mon, 19 Nov 2018 06:47:58 +0000 (06:47 +0000)]
Merge "Revert "tizen: All logins should use User::Shell smack label"" into tizen

5 years agoRevert "tizen: All logins should use User::Shell smack label" 04/193304/1
Hyotaek Shim [Mon, 19 Nov 2018 06:44:39 +0000 (06:44 +0000)]
Revert "tizen: All logins should use User::Shell smack label"

This reverts commit b94ec26c22938d9d83642732e3642b677bedbeb0.

Change-Id: I44c10ed7b75dc738fad7ef2df5c0ca1d50f22c1f

5 years agoMerge "tizen: All logins should use User::Shell smack label" into tizen accepted/tizen/unified/20181119.013234 submit/tizen/20181116.003516
Hyotaek Shim [Fri, 16 Nov 2018 00:22:26 +0000 (00:22 +0000)]
Merge "tizen: All logins should use User::Shell smack label" into tizen

5 years agotizen: All logins should use User::Shell smack label 75/193175/1
Karol Lewandowski [Thu, 15 Nov 2018 13:02:51 +0000 (14:02 +0100)]
tizen: All logins should use User::Shell smack label

Change-Id: I8c0e7de59689aa83bd0273af4a66dd7a8f823ec9

6 years agoRemove kdbus interface header 48/192448/1 accepted/tizen/unified/20181107.082157 submit/tizen/20181106.112838
Michal Bloch [Mon, 5 Nov 2018 14:26:39 +0000 (15:26 +0100)]
Remove kdbus interface header

kdbus.h is now provided with other linux kernel headers.

Change-Id: Ida7d06aa1f27d88040f949fffd73f0d6cfd5f23e
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
6 years agocore: don't drop timer expired but not yet processed when system date is changed 27/192227/2
Hyotaek Shim [Thu, 1 Nov 2018 04:38:43 +0000 (13:38 +0900)]
core: don't drop timer expired but not yet processed when system date is changed

There is difference between time set by the user and real elapsed time because of accuracy feature.
If you change the system date(or time) between these times, the timer drops.

You can easily reproduce it with the following command.
-----------------------------------------------------------
$ systemd-run --on-active=3s ls; sleep 3; date -s "`date`"
-----------------------------------------------------------

In the following command, the problem is rarely reproduced. But it exists.
---------------------------------------------------------------------------------------------
$ systemd-run --on-active=3s --timer-property=AccuracySec=1us ls ; sleep 1; date -s "`date`"
---------------------------------------------------------------------------------------------

Note : Global AccuracySec value.
----------------------------------------------------------------------
$ cat /etc/systemd/system.conf
DefaultTimerAccuracySec=1min
----------------------------------------------------------------------

Origin source: https://github.com/systemd/systemd/commit/fee04d7f3ab810e99b97535ca5fda2f9517acda9

Change-Id: Ibaaa89bec9c55f43336388ee85f07b89c1a50ea4
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
6 years agoRemove unused bluetooth.target 39/192039/2
Hyotaek Shim [Mon, 29 Oct 2018 06:58:49 +0000 (15:58 +0900)]
Remove unused bluetooth.target

Change-Id: I0ecbde7c179056840f34b05152d7dfaee48a6c0e
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
6 years agosocket: Serialize auxiliary file descriptors 22/190822/1 accepted/tizen/5.0/unified/20181102.025736 accepted/tizen/unified/20181010.061732 submit/tizen/20181008.100454 submit/tizen_5.0/20181101.000008
Paweł Szewczyk [Fri, 5 Oct 2018 12:48:39 +0000 (14:48 +0200)]
socket: Serialize auxiliary file descriptors

When socket is serialized/deserialized it's important to keep all file
descriptors. This commit adds the serialization of auxiliary fds.

For now, only ffs sockets are using auxiliary descriptors.

Change-Id: I5fea0152fee51560e160fe5df4806b55a5b369d6
Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
6 years agoD-Bus policy configs: fixed rules 14/189914/2 accepted/tizen/unified/20180928.080531 submit/tizen/20180927.030248
Adrian Szyndela [Fri, 21 Sep 2018 14:11:05 +0000 (16:11 +0200)]
D-Bus policy configs: fixed rules

Removed duplicate rules in all three configs, and specified proper sender
for receiving ActivationRequest signal in org.freedesktop.systemd1.conf.

Change-Id: I550c07ede30a0bb70a9bb3ca00d5771e1722826b

6 years agoMerge "Remove build warnings" into tizen accepted/tizen/unified/20180927.073724 submit/tizen/20180921.011155
pr.jung [Fri, 21 Sep 2018 01:11:27 +0000 (01:11 +0000)]
Merge "Remove build warnings" into tizen

6 years agoRemove build warnings 41/189341/7
pr.jung [Mon, 17 Sep 2018 06:39:43 +0000 (15:39 +0900)]
Remove build warnings

- Add TIZEN_JOURNALD_KMSG
- Print kmsg log on dlogutil because journald is heavier than dlogutil

Change-Id: I763cfccbb0d877c52d8448de4a50966a33c84981
Signed-off-by: pr.jung <pr.jung@samsung.com>
6 years agoSet the smack label of executable binary tools 91/188491/5 accepted/tizen/unified/20180906.144205 submit/tizen/20180906.020620
Hyotaek Shim [Wed, 5 Sep 2018 09:23:10 +0000 (18:23 +0900)]
Set the smack label of executable binary tools

Apps (3rd party and even in-house Apps) are not permitted to run systemd tools directly.
User System::Tools rx
User::Shell System::Tools rx
System::TEF System::Tools rx
System::Privileged System::Tools rx
System System::Tools rx

Change-Id: I55a9b00a6ec0583d4673d9a41cdda7fbd9e23310
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
6 years agoautomount: ack automount requests even when already mounted 85/183785/1 accepted/tizen/unified/20180713.160208 accepted/tizen/unified/20180810.132532 submit/tizen/20180712.015849 submit/tizen/20180810.001302
Anchor Cat [Wed, 10 May 2017 11:23:58 +0000 (21:23 +1000)]
automount: ack automount requests even when already mounted

If a process accesses an autofs filesystem while systemd is in the
middle of starting the mount unit on top of it, it is possible for the
autofs_ptype_missing_direct request from the kernel to be received after
the mount unit has been fully started:

  systemd forks and execs mount             ...
            ...                     access autofs, blocks
  mount exits                               ...
  systemd receives SIGCHLD                  ...
            ...                     kernel sends request
  systemd receives request                  ...

systemd needs to respond to this request, otherwise the kernel will
continue to block access to the mount point.

Cherry-picked from https://github.com/systemd/systemd/commit/e7d54bf58789545a9eb0b3964233defa0b007318
Change-Id: Ibacc2c0ffee32846321864987324763214648732
(cherry picked from commit 5ccd5b2efc60d9f775a812878528f06b01189da5)

6 years agobusctl: eliminated some warnings 32/183532/1
Adrian Szyndela [Fri, 6 Jul 2018 09:07:10 +0000 (11:07 +0200)]
busctl: eliminated some warnings

Eliminated const and casting warnings, along with a declaration
order warning.

Change-Id: I031a5d3d7bab61a2ec7afc6262eb12af159a74c8

6 years agobusctl: add usage of Monitoring interface for non-kernel connections 56/183456/1
Adrian Szyndela [Sat, 14 May 2016 20:10:22 +0000 (22:10 +0200)]
busctl: add usage of Monitoring interface for non-kernel connections

This commit is loosely based on Lars Uebernickel's commit
(reverted in 8f2f0ffe8246) in a way that it takes
his implementation of calling the Monitoring interface.
Unfortunately the original commit broke kernel connections. That's why
this commit makes it different for kernel and non-kernel connections.

To make it cleaner, preparing connections is extracted to separate
functions.

From Lars Uebernickel's original commit message - about Monitoring interface:
This is now the recommended way to do monitoring by upstream D-Bus.
It's also allowed in the default policy, whereas eavesdrop is not
anymore, which effectively broke busctl on many systems.

Change-Id: I886fff5a3ec49df6aab26b217d881f249591ca9a

6 years agoRevert "resolved: apply epoch to system time from PID 1" 59/182759/1 accepted/tizen/unified/20180704.154010 submit/tizen/20180704.010647
Hyotaek Shim [Wed, 27 Jun 2018 10:47:30 +0000 (19:47 +0900)]
Revert "resolved: apply epoch to system time from PID 1"

This reverts commit 021dd87bc055a5bfb2dcef83fc868fe24648b959.

In Tizen Watch products, users can set the RTC as they want, even to the past.
Here, it has been observed that the system clock is reset every booting.

For instance,
1) After a boot, Kernel RTC is 2018-01-02.

2) Since the system clock initialized by RTC is 2018-01-02 is less than 2018-06-27 (TIME_EPOCH_USEC),
Systemd resets the system clock as TIME_EPOCH_USEC, but does not modify RTC.
Although the system clock shown to users is not an intended value, the time goes by to 2018-06-28.

3) After another reboot, the system clock is restored to 2018-06-27 (TIME_EPOCH_USEC)
because RTC is still less than TIME_EPOCH_USEC.

Change-Id: Ib2c61e9b1fd9d4b0d33f99868dda1daaec21878d
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
6 years agospec: configure rpmmacrosdir instead of manually installing rpm macros 61/122461/3 accepted/tizen/unified/20180619.142044 submit/tizen/20180619.052936
Łukasz Stelmach [Fri, 31 Mar 2017 11:05:09 +0000 (13:05 +0200)]
spec: configure rpmmacrosdir instead of manually installing rpm macros

Change-Id: Iec5f938f97695f8eafcfc4f3b0b120d5fe77a54e

6 years agoinstall: fix disable when /etc/systemd/system is a symlink 61/172361/3
Lukas Nykryn [Tue, 30 Aug 2016 13:04:07 +0000 (15:04 +0200)]
install: fix disable when /etc/systemd/system is a symlink

Change-Id: I1bafa3e4bfea556e2abceee33b2b2bc6ab97b137
Origin: https://github.com/systemd/systemd/commit/67852d08e6a35d34b428e8be64efdb3f003f4697

6 years agobuild-sys: make RPM macros installation path configurable (#5564) 60/122460/3
steelman [Tue, 14 Mar 2017 23:16:47 +0000 (00:16 +0100)]
build-sys: make RPM macros installation path configurable (#5564)

--with-rpmmacrosdir=no disables installation of the macros.

Change-Id: Ia663c3fb86bf658da57b59a4c17916c5c22645af
Origin: https://github.com/systemd/systemd/commit/ff2e33db54719bfe8feea833571652318c6d197c

6 years agoSet the default deny policy for system dbus 34/178734/4 accepted/tizen/unified/20180515.163421 submit/tizen/20180515.054527
Mateusz Moscicki [Fri, 11 May 2018 12:58:41 +0000 (14:58 +0200)]
Set the default deny policy for system dbus

org.freedesktop.locale1.conf  - send: deny, own: deny
org.freedesktop.login1.conf   - send: deny, own: deny
org.freedesktop.systemd1.conf - send: deny, own: deny

Change-Id: I49f402d56f83700fe7528eab3e034cd845afc0a2
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
6 years agobuildsys,journal: allow -fsanitize=address without VALGRIND defined 96/171896/1 accepted/tizen/unified/20180309.064126 submit/tizen/20180308.045612 submit/tizen/20180309.010635
Cristian Rodríguez [Fri, 5 Aug 2016 16:10:41 +0000 (16:10 +0000)]
buildsys,journal: allow -fsanitize=address without VALGRIND defined

Fixed (master) versions of libtool pass -fsanitize=address correctly
into CFLAGS and LDFLAGS allowing ASAN to be used without any special
configure tricks..however ASAN triggers in lookup3.c for the same
reasons valgrind does. take the alternative codepath if
__SANITIZE_ADDRESS__ is defined as well.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I1eb6c14a7d91b4d34fdc792620fe57a329037fa4

6 years agologind: change smack label /run/user/%UID/system_share to "*" accepted/tizen/unified/20180307.141023 submit/tizen/20180307.075746
INSUN PYO [Wed, 7 Mar 2018 07:40:53 +0000 (16:40 +0900)]
logind: change smack label /run/user/%UID/system_share to "*"

6 years agologind: change group and permission /run/user/%UID 90/171190/12 accepted/tizen/unified/20180307.071353 submit/tizen/20180307.004745
INSUN PYO [Tue, 27 Feb 2018 08:48:52 +0000 (17:48 +0900)]
logind: change group and permission /run/user/%UID

1. change group and pemission of /run/usre/%UID to uid/system_share,0750
2. make /run/user/%UID/system_share to uid/system_share,0750

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ie22b8d4e96c1669f7068005952d83f7f4086b60c
Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
6 years agorevert: Description : Adding to enable/disable the multiuser feature. 48/171248/2 accepted/tizen/unified/20180301.114103 submit/tizen/20180228.050403
INSUN PYO [Wed, 28 Feb 2018 02:29:47 +0000 (11:29 +0900)]
revert: Description : Adding to enable/disable the multiuser feature.

* I don't revert "unit/user@.service.m4.in (Environment=XDG_RUNTIME_DIR=/run/user/%U)
* If you want to revert this, you should add "session  required pam_loginuid.so" to /etc/pam.d/systemd-user

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I6f8e132eb46a150968662bc2574fdf85eb715a52

6 years agojournald: Limit system journal size from 10M to 4M 76/168776/1 accepted/tizen/unified/20180201.075943 submit/tizen/20180131.013722
INSUN PYO [Wed, 31 Jan 2018 01:02:17 +0000 (10:02 +0900)]
journald: Limit system journal size from 10M to 4M

A journald always loads two journal files (one is current and the other is just before) in memory using mmap.
So it always consumes as much memory as file size.

A journald rotates the log in 8 files.
Each log file has a SystemMaxUse/8 size.
(But the minimum value is 512k.)

So SystemMaxUse is 4M to minimize memory usage. (512k * 8 = 4M)

sh-3.2# memps `pidof systemd-journald`
S(CODE)  S(DATA)  P(CODE)  P(DATA)  ADDR(start-end)  OBJECT NAME
-------- -------- -------- -------- -----------------------------------------------
4        0      508        0 f6d80000-f6ec0000 /opt/var/log/journal/999fcdd05c714da0859337c08df2230e/system@800f735a88e44c35bc7cca47\
9a6984b1-00000000000015ad-000561d5c48aab1f.journal
0        4      302        0 f6c40000-f6d80000 /opt/var/log/journal/999fcdd05c714da0859337c08df2230e/system.journal

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I9aa53189eae878464acba58b5fdd490f6b3ba7f8

6 years agoreboot: change log level of reboot command from warning to debug 31/167631/1 accepted/tizen/unified/20180123.061126 submit/tizen/20180119.020400
INSUN PYO [Fri, 19 Jan 2018 01:55:39 +0000 (10:55 +0900)]
reboot: change log level of reboot command from warning to debug

To prevent the annoying warning messages below :
   "Failed to read reboot parameter file: No such file or directory"

"SYSTEMD_LOG_LEVEL=debug reboot" command can see the original log.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I7bb619998bb2cce8959956f73f3dd62d48525c33

6 years agoMerge "Add well-known-names -> unique names on graph" into tizen
Adrian Szyndela [Fri, 22 Dec 2017 08:08:31 +0000 (08:08 +0000)]
Merge "Add well-known-names -> unique names on graph" into tizen

6 years agoMerge "Add tool for processing graph generated by busctl dot." into tizen
Adrian Szyndela [Fri, 22 Dec 2017 08:06:28 +0000 (08:06 +0000)]
Merge "Add tool for processing graph generated by busctl dot." into tizen

6 years agoMerge "Generate graph from the traffic observable by busctl monitor." into tizen
Adrian Szyndela [Fri, 22 Dec 2017 08:04:30 +0000 (08:04 +0000)]
Merge "Generate graph from the traffic observable by busctl monitor." into tizen

6 years agoAdd well-known-names -> unique names on graph 57/160057/18
Dawid Kuczma [Tue, 5 Dec 2017 08:31:16 +0000 (09:31 +0100)]
Add well-known-names -> unique names on graph

Usage:
--well-known-names=true

Change-Id: Ife01bd8d1a2d6acc4a45c6595bcc52c15d523742

6 years agoAdd tool for processing graph generated by busctl dot. 85/158385/12
Dawid Kuczma [Mon, 6 Nov 2017 12:50:59 +0000 (13:50 +0100)]
Add tool for processing graph generated by busctl dot.

Usage:
1) gvpr -f graphinfo.gvpr input_file
2) gvpr -f graphinfo.gvpr input_file -a node -a NODE
3) gvpr -f graphinfo.gvpr input_file -a -node -a NODE

Change-Id: Ie4d05c715df17b61c8c7ad1f7724977c9c2f8bb8

6 years agoGenerate graph from the traffic observable by busctl monitor. 93/153493/24
Dawid Kuczma [Thu, 28 Sep 2017 13:08:20 +0000 (15:08 +0200)]
Generate graph from the traffic observable by busctl monitor.

Busctl dot is used to visualize IPC traffic.
It generate dot output whitch can be visualized e.g. by using graphviz.
Also adds filtering by sender/receiver pid.
Internally busctl dot works similar to busctl capture.
It reuses monitor() framework.

--pid=PID -only show messages where sender or receiver pid is equal to PID
--sender-pid=PID -only show messages where sender pid is equal to PID
--receiver-pid=PID -same as above, but filtering by receiver pid.

Signed-off-by: Dawid Kuczma <d.kuczma@partner.samsung.com>
Change-Id: Id9ce46f5085dde10010e89057f78d58b3088d3bc

6 years agotizen: Change the permission of /dev/kmsg to "root:log 660 *" 78/164078/5
Hyotaek Shim [Fri, 15 Dec 2017 06:56:43 +0000 (15:56 +0900)]
tizen: Change the permission of /dev/kmsg to "root:log 660 *"

Through this patch, /usr/bin/dlog_logger (log:log) can access /dev/kmsg
without root credentials.

Change-Id: Ie955499c4a0bf1581cd64244cb94acfa6279719d
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
[ Minor style change in commit log. ]
Signed-off-by: Karol Lewandowski <k.lewandowsk@samsung.com>
6 years agoadjust the uid and secure_uid range 41/164041/1 accepted/tizen/unified/20171220.145736 submit/tizen/20171215.072741
INSUN PYO [Fri, 15 Dec 2017 03:35:07 +0000 (12:35 +0900)]
adjust the uid and secure_uid range

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I03793a7fb43e229999bee511298e39d68bf26f4d

7 years agounits: [user@.service] Set Group as users 16/152816/2 accepted/tizen/unified/20170928.072140 submit/tizen/20170927.072201
INSUN PYO [Wed, 27 Sep 2017 07:10:21 +0000 (16:10 +0900)]
units: [user@.service] Set Group as users

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iaf0d6f57e6a4a124ac0301e38527bddcbb7fe679

7 years agosmack: [systemd-journald.service] Set SmackProcessLabel as System. 11/152811/1
INSUN PYO [Wed, 27 Sep 2017 07:03:46 +0000 (16:03 +0900)]
smack: [systemd-journald.service] Set SmackProcessLabel as System.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I55a3857e1afbb6f9e583f8901a7bcaf75699fdc8

7 years agocore: merge the second CapabilityBoundingSet= lines by AND when it is prefixed with... 60/147360/1 accepted/tizen/unified/20170905.184138 submit/tizen/20170904.055916
iplayinsun [Mon, 4 Sep 2017 03:12:27 +0000 (12:12 +0900)]
core: merge the second CapabilityBoundingSet= lines by AND when it is prefixed with tilde (#6724)

If a unit file contains multiple CapabilityBoundingSet= or
AmbientCapabilities= lines, e.g.,
===
CapabilityBoundingSet=CAP_A CAP_B
CapabilityBoundingSet=~CAP_B CAP_C
===
before this commit, it results all capabilities except CAP_C are set to
CapabilityBoundingSet=, as each lines are always merged by OR.
This commit makes lines prefixed with ~ are merged by AND. So, for the
above example only CAP_A is set.
This makes easier to drop capabilities with drop-in config files.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ia5c42cfde0f3937f696f858f384387610477c6ea

7 years agopackaging: Remove unused systemd-tmpfiles-clean.service, systemd-tmpfiles-clean.timer 88/146888/1 submit/tizen/20170831.055812
INSUN PYO [Thu, 31 Aug 2017 04:10:36 +0000 (13:10 +0900)]
packaging: Remove unused systemd-tmpfiles-clean.service, systemd-tmpfiles-clean.timer

systemd-tmpfiles-clean.service and systemd-tmpfiles-clean.timer are already disabled.

Removes the file that was left to identify the history.
Removes the user to remove the systemd-tmpfiles-clean.service manually.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ifb105bedc29d7ab660c303059c8e3378c59a6e31

7 years agosmack: Set SmackProcessLabel as System. 54/146354/1
INSUN PYO [Mon, 28 Aug 2017 07:20:20 +0000 (16:20 +0900)]
smack: Set SmackProcessLabel as System.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I9019b145d0195ab6d5a8983adb15a24ac31ddd43

7 years agoRemove upgrade script file from package 97/144897/2 accepted/tizen/4.0/unified/20170828.221520 accepted/tizen/unified/20170822.023823 submit/tizen/20170821.062931 submit/tizen_4.0/20170828.100007
Yunmi Ha [Fri, 18 Aug 2017 08:37:11 +0000 (17:37 +0900)]
Remove upgrade script file from package

Change-Id: If547cb04400e412c00559881e312f831c2d25688
Signed-off-by: Yunmi Ha <yunmi.ha@samsung.com>
7 years agohostnamed : disable hostnamed 74/141374/1
INSUN PYO [Mon, 31 Jul 2017 07:46:46 +0000 (16:46 +0900)]
hostnamed : disable hostnamed

Requested by MCD.
The connman, efl, bluez using hostnamed have also agreed to disable.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iecb82b74305201696caa77d108efa216051181ce

7 years agoAdd "NOEXEC" mount flag for /run 24/140724/1 accepted/tizen/4.0/unified/20170816.011219 accepted/tizen/unified/20170731.153719 submit/tizen/20170727.015143 submit/tizen/20170728.031241 submit/tizen_4.0/20170811.094300
Yunmi Ha [Wed, 26 Jul 2017 06:56:36 +0000 (15:56 +0900)]
Add "NOEXEC" mount flag for /run

Mount flags(nosuid, noexec, nodev) must be set for tmpfs that any app can access.

Change-Id: Ib60e8876abe2641a3dde6caab83a60afca017375
Signed-off-by: Yunmi Ha <yunmi.ha@samsung.com>
7 years agoremove caps cap_mac_override 70/136370/1 submit/tizen/20170710.055051
sanghyeok.oh [Thu, 29 Jun 2017 08:19:05 +0000 (17:19 +0900)]
remove caps cap_mac_override

Change-Id: I17f200cbabffd3176cd8d78571c24440f7f35497
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
7 years agoSecurity: resolved: bugfix of null pointer p->question dereferencing (#6020) 66/133366/1 accepted/tizen/unified/20170629.085943 accepted/tizen/unified/20170629.110043 submit/tizen/20170612.055512 submit/tizen/20170626.113904 submit/tizen/20170627.004434
sanghyeok.oh [Mon, 12 Jun 2017 02:34:22 +0000 (11:34 +0900)]
Security: resolved: bugfix of null pointer p->question dereferencing (#6020)

commit a924f43f30f9c4acaf70618dd2a055f8b0f166be
Refs: v233-511-ga924f43
Author:     Evgeny Vereshchagin <evvers@ya.ru>
AuthorDate: Wed May 24 08:56:48 2017 +0300
Commit:     GitHub <noreply@github.com>
CommitDate: Wed May 24 08:56:48 2017 +0300

    resolved: bugfix of null pointer p->question dereferencing (#6020)

    See https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1621396

Change-Id: I49d03500576c24b4b382accf1dcde8e1d4a5060e
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
7 years agoRemove "Requires(post): gawk" in the spec. 82/133282/2
Hyotaek Shim [Fri, 9 Jun 2017 12:10:29 +0000 (21:10 +0900)]
Remove "Requires(post): gawk" in the spec.

This patch is needed for reducing storage usage in IoT/Headless devices.

Change-Id: Ie0a5833ef1cf114202d9d783eb63135b31a1f6d6
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
7 years ago55-udev-smack-default.rules: add group rw permission to input nodes 82/132582/1 accepted/tizen/unified/20170608.072537 submit/tizen/20170607.110629
Hyotaek Shim [Wed, 7 Jun 2017 04:37:29 +0000 (13:37 +0900)]
55-udev-smack-default.rules: add group rw permission to input nodes

Change-Id: I61c7a3bb1098406172e5ed289cc0510b02794ea5
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
7 years agodbus: change session dbus address from /run/user/uid/dbus/user_bus_socket to /usr... 76/121976/4 accepted/tizen/unified/20170602.153900 submit/tizen/20170531.094248
INSUN PYO [Wed, 29 Mar 2017 16:25:40 +0000 (01:25 +0900)]
dbus: change session dbus address from /run/user/uid/dbus/user_bus_socket to /usr/user/uid/bus

Sync to upstream.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I40ac5b641e5e7484a19a3fe9d7844c3491e48846

7 years agorules: watch metadata changes in mmcblk devices 15/131315/5
Krzysztof Jackiewicz [Fri, 26 May 2017 08:06:57 +0000 (10:06 +0200)]
rules: watch metadata changes in mmcblk devices

Formatting sd-cards does not trigger "change" uevents. As a result clients
using udev API don't get any updates afterwards and get outdated information
about the device.

Include mmcblk* in a match for watch option assignment.

Origin: https://github.com/systemd/systemd/commit/e74d0a9a5cdd8562aeaab1994ebd9c4cd07e82c3
Change-Id: Icdac9968d9cca85eb2c5e413433f7f8238182c90
Signed-off-by: Krzysztof Jackiewicz <k.jackiewicz@samsung.com>
7 years agopackaging: Disable systemd-tmpfiles-clean.timer 28/131028/2 accepted/tizen/unified/20170531.082509 submit/tizen/20170525.063631
INSUN PYO [Thu, 25 May 2017 05:50:55 +0000 (14:50 +0900)]
packaging: Disable systemd-tmpfiles-clean.timer

If you change the time in 15 minutes after booting,
some files in /tmp are removed by systemd-tmpfiles-clean.service.

Also, VD and MCD does't want tmpfile cleanup to be run.

I have modified the timer to not run automatically at boot time.
The timer and service are left unerased.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I5ce99c5a37488e5a89af6a49f32150cc7391a5ef

7 years agoExport sd_bus_message_append_ap. It is renamed to sd_bus_message_appendv to follow... 60/129960/3 accepted/tizen/unified/20170519.200934 submit/tizen/20170519.132705 tizen_4.0.m1_release
Krzysztof Opasiak [Thu, 18 May 2017 12:04:18 +0000 (14:04 +0200)]
Export sd_bus_message_append_ap. It is renamed to sd_bus_message_appendv to follow systemd naming conventions. (#5753)

Moreover, man page for sd_bus_message_append is updated with reference to new exposed function.
Makefile-man is updated too, to reflect new alias.

Change-Id: I7c02ce686a2699b35afd583fd4646f734adc9c7b
Origin: https://github.com/systemd/systemd/commit/19fe49f62cc916f1237ea92a04fc80ee75285dde
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
7 years agolicense:change test-runner's license from Apache 2.0 to BSD-2-clause 25/126725/4 accepted/tizen/unified/20170427.180200 submit/tizen/20170427.020248
sanghyeok.oh [Tue, 25 Apr 2017 03:22:06 +0000 (12:22 +0900)]
license:change test-runner's license from Apache 2.0 to BSD-2-clause

To avoid license conflict between LGPL-2.1 and Apache-2.0, change it.

Change-Id: I60125a53b19193fb300f516387d08243cfa94698
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
7 years agoLicense:add license file for Apache-2.0 89/125189/3
sanghyeok.oh [Fri, 14 Apr 2017 05:50:54 +0000 (14:50 +0900)]
License:add license file for Apache-2.0

Change-Id: I9c6d1128fdc89b099c68c5fc2c7fd46fa193f0bc
Signed-off-by: sanghyeok.oh <sanghyeok.oh@samsung.com>
7 years agotizen: Do not try to read /proc/1/cgroup from unprivileged processes 59/124359/1 accepted/tizen/unified/20170411.164528 submit/tizen/20170411.075124
INSUN PYO [Tue, 11 Apr 2017 07:26:57 +0000 (16:26 +0900)]
tizen: Do not try to read /proc/1/cgroup from unprivileged processes

In Tizen access to /proc/1 is restricted via Smack. However, there are
unprivileged functions that need to work with information from this dir.
This function caches cgroup information in /run, allowing system-wide
access to this information.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I2a2977400c7917804599cfb6f225dab897dc8b14

7 years agosmack: remove duplicated code 42/123142/1 submit/tizen/20170411.060544
INSUN PYO [Tue, 4 Apr 2017 15:29:09 +0000 (00:29 +0900)]
smack: remove duplicated code

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I248de63a01529eb490d5ca1585783f8c0679a640

7 years agoLicense: add license files for systemd-analyze package 77/122077/1 accepted/tizen_common accepted/tizen_ivi accepted/tizen_mobile accepted/tizen_tv accepted/tizen_wearable accepted/tizen/common/20170330.151825 accepted/tizen/ivi/20170330.224647 accepted/tizen/mobile/20170330.224616 accepted/tizen/tv/20170330.224633 accepted/tizen/unified/20170330.224653 accepted/tizen/wearable/20170330.224640 submit/tizen/20170330.062718
INSUN PYO [Thu, 30 Mar 2017 06:18:35 +0000 (15:18 +0900)]
License: add license files for systemd-analyze package

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Iea4a6b72d5c277e1bcf3a4604ec6c5b603d1d973

7 years agoMerge "License: add license files" into tizen accepted/tizen/common/20170329.172141 accepted/tizen/ivi/20170329.222333 accepted/tizen/mobile/20170329.222249 accepted/tizen/tv/20170329.222311 accepted/tizen/unified/20170329.222339 accepted/tizen/wearable/20170329.222326 submit/tizen/20170329.022045
INSUN PYO [Wed, 29 Mar 2017 02:19:22 +0000 (19:19 -0700)]
Merge "License: add license files" into tizen

7 years agoLicense: add license files 15/121315/3
INSUN PYO [Mon, 27 Mar 2017 13:50:39 +0000 (22:50 +0900)]
License: add license files

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I39d99a2040f267c29529d331ff5de7591cbf1fa5

7 years agocore: Fix USB functionfs activation and clarify its documentation (#4188) 80/120880/1
Paweł Szewczyk [Mon, 26 Sep 2016 16:45:47 +0000 (18:45 +0200)]
core: Fix USB functionfs activation and clarify its documentation (#4188)

There was no certainty about how the path in service file should look
like for usb functionfs activation. Because of this it was treated
differently in different places, which made this feature unusable.

This patch fixes the path to be the *mount directory* of functionfs, not
ep0 file path and clarifies in the documentation that ListenUSBFunction should be
the location of functionfs mount point, not ep0 file itself.

Change-Id: I320c34c0037f2bd6a6f6cf09a90eba632a54e9e9

7 years agopackaging: Make documentation package optional 38/119938/2
Karol Lewandowski [Mon, 20 Mar 2017 16:35:25 +0000 (17:35 +0100)]
packaging: Make documentation package optional

By default documentation is disabled.

Change-Id: I33648ee019945d47d367e5db3abe84afa3400cc0

7 years agopackaging: Simplify kdbus setup for Tizen:Unified 37/119937/7
Karol Lewandowski [Mon, 20 Mar 2017 16:30:27 +0000 (17:30 +0100)]
packaging: Simplify kdbus setup for Tizen:Unified

This commit adds marker file to extension-kdbus package to signal that
kdbus should really be used only if this package is installed.

Additionally, build time is reduced by a half.

Change-Id: I6d27b7c15985b189432fc7ff54bb4693cf79be24

7 years agospec: fix build error for aarch64 and x86_64 56/119756/1 accepted/tizen/common/20170320.173536 accepted/tizen/ivi/20170320.065310 accepted/tizen/mobile/20170320.065221 accepted/tizen/tv/20170320.065248 accepted/tizen/unified/20170320.065333 accepted/tizen/wearable/20170320.065252 submit/tizen/20170320.022333
INSUN PYO [Mon, 20 Mar 2017 04:09:34 +0000 (13:09 +0900)]
spec: fix build error for aarch64 and x86_64

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: I2c6bdd50e9ffbf95bce03ef3d9a3945c17f4b4ce

7 years ago[4.0] Remove OBS Project Dependency (kdbus/TV) 79/117879/14
hk57.kim [Thu, 9 Mar 2017 08:14:32 +0000 (17:14 +0900)]
[4.0] Remove OBS Project Dependency (kdbus/TV)

- When you SR this, you need to create JIRA-TRE issue of:
  : add systemd-extension-kdbus  for TV/arm-wayland images.
- Without this commit, this package won't be built correctly in Tizen 4.0.

(It's add, not replace.)

Change-Id: Ic616a3b20450d4594857cc268e2dbf25e80dba37
Signed-off-by: hk57.kim <hk57.kim@samsung.com>
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Signed-off-by: hk57.kim <hk57.kim@samsung.com>
Signed-off-by: insun.pyo <insun.pyo@samsung.com>
7 years agospec: Enable systemd-tests package accepted/tizen/ivi/20170320.010256 accepted/tizen/mobile/20170320.010212 accepted/tizen/tv/20170320.010222 accepted/tizen/unified/20170320.010313 accepted/tizen/wearable/20170320.010240 submit/tizen/20170317.143532
Łukasz Stelmach [Mon, 6 Mar 2017 13:36:27 +0000 (14:36 +0100)]
spec: Enable systemd-tests package

This reverts commit 7137c6fe9d362f69d14581ac1bde124b77930f67.

Change-Id: I2679eb43d68d9d74075ed339c7b7f397c43bc340
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
7 years agoRevert "busctl: use Monitoring interface (#3245)"
Karol Lewandowski [Fri, 2 Dec 2016 12:05:41 +0000 (13:05 +0100)]
Revert "busctl: use Monitoring interface (#3245)"

This reverts commit 17fd746098bb, which reworks busctl monitor to use D-Bus'
new BecomeMonitor call.  This broke monitor on kdbus system so revert this
change for now.

Change-Id: I70626c03b375f692a184214a3d5055ec0a96b5c8

7 years agokdbus: Create dummy dbus.service and dbus.socket instead of masking
Karol Lewandowski [Thu, 9 Mar 2017 14:29:30 +0000 (15:29 +0100)]
kdbus: Create dummy dbus.service and dbus.socket instead of masking

systemd >= v223 changed method of handling masked units.  Currently
unit that specifies Requires= on masked unit will fail to start.

Previously enabling kdbus resulted in masking dbus.* units, which
does not work in new systemd version.

This change reworks dbus1-generator to resolve this problem.

Change-Id: I855eb05b6d4f26798772fa6c4dd1d8223020cd6e

7 years agosystemd-tests: set common output format
Lukasz Skalski [Mon, 21 Nov 2016 10:00:09 +0000 (11:00 +0100)]
systemd-tests: set common output format

Change-Id: Ia52ad37927bca67e36a932982523cfc75e80e640

7 years agokdbus: modify DBUS_SESSION_BUS_ADDRESS environment for user systemd
INSUN PYO [Thu, 23 Feb 2017 06:12:12 +0000 (15:12 +0900)]
kdbus: modify DBUS_SESSION_BUS_ADDRESS environment for user systemd

Signed-off-by: INSUN PYO <insun.pyo@ubuntu1604.playinsun.pe.kr>
Change-Id: Ie4f85324d1f5d010933b4433a2dd4b7aa4f6fb14

7 years agokdbus: mask dbus.socket
INSUN PYO [Thu, 16 Feb 2017 15:38:00 +0000 (00:38 +0900)]
kdbus: mask dbus.socket

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Id168043bfe80c9e6c177b526c5bcae6475561096

7 years agoRemove etc tmpfile generation as they are unused
silas jeon [Wed, 18 Jan 2017 05:42:13 +0000 (14:42 +0900)]
Remove etc tmpfile generation as they are unused

To support read-only root filesystem, there should be nothing modified on /etc.
Also these five files in /etc are handled by other packages as below. So these
are removed.

os-release : tizen-release
localtime : tzdata
mtab : setup
nsswitch.conf : glibc
pam.d : pam

Change-Id: I0dc490ddf6d299d956504405419e6c5d71e52a97

7 years agoRemove mtab generation line from tmpfile
silas jeon [Tue, 17 Jan 2017 10:05:28 +0000 (19:05 +0900)]
Remove mtab generation line from tmpfile

To support read-only root filesystem, there should be nothing modified in root
filesystem. This line was made to make mtab symlink in /etc, so it should be
deleted. Also, it was not used anyway. 'Setup' package is handling the mtabfile
in /etc.

Change-Id: I2ff30ec94ca5833a2b95762cd2d7715bb7f93476

7 years agoMv /etc/systemd/{system,user} to /opt/etc/systemd/
silas jeon [Tue, 17 Jan 2017 09:32:59 +0000 (18:32 +0900)]
Mv /etc/systemd/{system,user} to /opt/etc/systemd/

To support read-only root filesystem, the unit file directories should be in the
/opt directory. After Applying this patch, systemd moves /etc/systemd/{system,
user} to /opt/etc/systemd/{system,user} and make symbolic links to them from old
paths.

Change-Id: If1315687c178fbe5345b721dca9d0b5369fcfab4

7 years agolibsystemd : Fixed a bug of sd_get_active_uids
wchang kim [Wed, 23 Nov 2016 05:13:51 +0000 (14:13 +0900)]
libsystemd : Fixed a bug of sd_get_active_uids
sd_get_active_uids returns the number of normal active users.
But the condition of normal user range is wrong.

Change-Id: I7f2ab1ce7dfe5552f8a0d73cc374df56b78e3a3e
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agotizen : Disable the predictable network interface name
wchang kim [Fri, 6 Jan 2017 00:04:50 +0000 (09:04 +0900)]
tizen : Disable the predictable network interface name

Change-Id: Ic2f2d9b50bb5601d3ec7d5940284f89acab7d3f0
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agotizen: upgrade script patches
wchang kim [Fri, 2 Dec 2016 07:52:22 +0000 (16:52 +0900)]
tizen: upgrade script patches

1) tizen : Adding the priority number to the filename of systemd_upgrade.sh
 (https://review.tizen.org/gerrit/#/c/101825/)
2) tizen: exclude upgrade script directory
 (https://review.tizen.org/gerrit/#/c/104341/)

Change-Id: I708a8505fcd08ed5789e69e716163cf9cd0dd0be

7 years agojournald: Limit system journal size to 10M
Hyeongsik Min [Wed, 30 Nov 2016 07:33:22 +0000 (16:33 +0900)]
journald: Limit system journal size to 10M

In v219, journald implicitly limits system journal(/var/log/journal) size
to 8MB(twice of the minimum journal file size) with SystemMaxUse=0 setting.
But in v231, journald doesn't stop allocating when max_use is 0.

Change-Id: I6b36320191fcc69d5b45cfec5b27a462d0ab8310
Signed-off-by: Hyeongsik Min <hyeongsik.min@samsung.com>
7 years agoRevert "Add some groups for user session daemons"
Rafal Krypa [Wed, 16 Nov 2016 09:47:49 +0000 (10:47 +0100)]
Revert "Add some groups for user session daemons"

Security-manager 1.1.16 has made this obsolete.
There is no longer a need for manually adding privilege-related supplementary
groups to user sessions. They will be added by a dedicated NSS plugin:
libnss-security-manager.

This reverts commit 78a648a0611caccdd87a38f99f65ba296608da69.

Change-Id: Ic421a2ee65550762356784b585d2fba8645fbd5c

7 years agoDescription : Fixed to fail to systemd-hostnamed service
wchang kim [Wed, 16 Nov 2016 01:26:37 +0000 (10:26 +0900)]
Description : Fixed to fail to systemd-hostnamed service

tizen platform links /opt/home to /home.

systemd-hostnamed.service has the parameter - ProtectHome=yes.

In this case, it occurs that systemd-hostnamed.service: Failed at step NAMESPACE spawning /usr/lib/systemd/systemd-hostnamed: Too many levels of symbolic links

I can't change the link. So I removed "ProtectHome=yes".

Change-Id: I640c2f6d410eb9aff7ba3d120a2ffb58b9990c95
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Adding to send new system signal for user session done.
wchang kim [Tue, 15 Nov 2016 02:29:15 +0000 (11:29 +0900)]
Description : Adding to send new system signal for user session done.
When user-session is done, systemd will send new system signal for user-session done.

interface=org.freedesktop.systemd1.Manager,member=UserSessionStartupFinished
UserSessionStartupFinished(t user_id)

Change-Id: I2ee9a2f232c22428894217fc2a519ec9c017fb2c
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Added the compatiblie pkgconfig to v219 version.
wchang kim [Thu, 10 Nov 2016 06:11:24 +0000 (15:11 +0900)]
Description : Added the compatiblie pkgconfig to v219 version.

systemd v231 removed the libraries of login, id128, journal and daemon and merged the
libsystemd.

And it removed thier pkgconfig files.

Other packages in tizen still use them.

So we need to add their pkgconfig files.

Change-Id: Ia120a0f2441cf9744ee192300a33d4b0d0cfb872
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Changed the spec file for systemd v231
wchang kim [Thu, 10 Nov 2016 02:49:47 +0000 (11:49 +0900)]
Description : Changed the spec file for systemd v231

Change-Id: I50cc42956efb6093286b8bacdc3af4789c8b8fa0
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescrciption : Fixed the mistakes of rebase v231.
wchang kim [Thu, 10 Nov 2016 02:48:19 +0000 (11:48 +0900)]
Descrciption : Fixed the mistakes of rebase v231.

Change-Id: I9d770908f4e65d286756483b2e6b5909623949d7
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Changed the spec file for systemd-231
wchang kim [Wed, 9 Nov 2016 23:14:15 +0000 (08:14 +0900)]
Description : Changed the spec file for systemd-231

Change-Id: I44eb84919bddf4d251e082b3a379aaae0b1ee9b5
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Apply dbus and kdbus for systemd 231
wchang kim [Wed, 9 Nov 2016 22:55:22 +0000 (07:55 +0900)]
Description : Apply dbus and kdbus for systemd 231

It is applied by referring the branch of remotes/origin/sandbox/lstelmach/systemd-upgrade-231

Change-Id: Iaf7441140b96cad25753bb383577ae9ca4d8390c
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Fixing the mistakes of rebase.
wchang kim [Wed, 9 Nov 2016 22:10:39 +0000 (07:10 +0900)]
Description : Fixing the mistakes of rebase.

Change-Id: I1309509e17ce5a8f80e962344c6fd79c33725ecc
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoRevert 479050b36302a360048c2af5e79683d14ad56fb3
wchang kim [Wed, 9 Nov 2016 08:15:56 +0000 (17:15 +0900)]
Revert 479050b36302a360048c2af5e79683d14ad56fb3

core: drop Capabilities= setting

The setting is hardly useful (since its effect is generally reduced to
zero
due to file system caps), and with the advent of ambient caps an
actually useful
replacement exists, hence let's get rid of this.

I am pretty sure this was unused and our man page already recommended
against its use,
hence this should be a safe thing to remove.

Change-Id: I24367aea159b1decc732b3fbaf448a40e59f2634
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Adding new interfaces related to user information.
wchang kim [Thu, 3 Nov 2016 10:59:56 +0000 (19:59 +0900)]
Description : Adding new interfaces related to user information.

1. int sd_get_active_uids(uid_t **users) - get active user uids.
2. int sd_get_systemd_uids(uid_t uid, uid_t **users) - get system user uids for uid
3. int sd_get_uid_type(uid_t uid) - get user type of uid.

These interfaes are for multi-user feature.

Change-Id: I35d9324c8a671b86fb4fb15552453bbf99f38227
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : pid1: don't return any error in manager_dispatch_notify_fd()
wchang kim [Mon, 31 Oct 2016 23:08:26 +0000 (08:08 +0900)]
Description : pid1: don't return any error in manager_dispatch_notify_fd()

If manager_dispatch_notify_fd() fails and returns an error then the handling of
service notifications will be disabled entirely leading to a compromised system.

For example pid1 won't be able to receive the WATCHDOG messages anymore and
will kill all services supposed to send such messages.

This patch is related to CVE-2016-7795 and CVE-2016-7796.

Back-ported fbuihuu's committed on 29 Sep, commit
f1e852245a30b60d5e6e0a487d049a04a40772fe

Change-Id: I27b6b78cff23c774f6fbcc59dacefcdcc45e7326
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agosd-bus: add support for 'dbus-integration-tests' framework
Lukasz Skalski [Fri, 16 Sep 2016 15:30:35 +0000 (17:30 +0200)]
sd-bus: add support for 'dbus-integration-tests' framework

Change-Id: Ie5da780d4c90d943676c5d1872d32d76af50478b

7 years agoFix for Kdbus-disabled Profiles to avoid busname parsing
Karol Lewandowski [Thu, 6 Oct 2016 09:40:08 +0000 (11:40 +0200)]
Fix for Kdbus-disabled Profiles to avoid busname parsing

Change-Id: Id45193adf624d60fc3bfbda09c4f6c357ff90e2a

7 years agoDescription : Added the local PATH to a shell script.
wchang kim [Thu, 29 Sep 2016 22:17:55 +0000 (07:17 +0900)]
Description : Added the local PATH to a shell script.

Adding the local PATH into 50-systemd-user.sh

Change-Id: Ic466577a5db001d99a41410c950220cb49f3d55e
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Fixed the security hole.
wchang kim [Wed, 28 Sep 2016 09:05:28 +0000 (18:05 +0900)]
Description : Fixed the security hole.

In case of "systemctl --user enable <path>", a application can insert
the malicious user service.

So systemctl can only enable the service with service name.

Change-Id: I570f45985516ee3636720f36787080590e6f90ef
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDescription : Added the upgrade script from 2.4 to 3.0
wchang kim [Mon, 12 Sep 2016 06:51:15 +0000 (15:51 +0900)]
Description : Added the upgrade script from 2.4 to 3.0

systemd_upgrade.sh is installed to /usr/share/upgrade/scripts.
It changes the smack rule for /var/log/wtmp and /var/lib/systemd.

Change-Id: Iebffca3238bcedd195ec2e91afdf5e46a882ec42
Signed-off-by: Woochang Kim <wchang.kim@samsung.com>
7 years agoDisable Polkit
Kunhoon Baik [Mon, 12 Sep 2016 04:05:57 +0000 (13:05 +0900)]
Disable Polkit

Tizen uses Cynara instead of Polkit.
https://wiki.tizen.org/wiki/Security:Cynara:ComparisonWithOtherSolutions

Change-Id: I519d84e41225e9a4c3343bec74871727e51a54ad

7 years agousb: socket activation fix
Paweł Szewczyk [Thu, 21 Jul 2016 08:17:43 +0000 (10:17 +0200)]
usb: socket activation fix

There was no certainty about how the path in service file should look
like for usb functionfs activation. Because of this ot was trated
differently in different places, which made this feature unusable.

This patch fixes the path to be the *mount directory* of functionfs, not
ep0 file path.

Change-Id: I387bed097d5246d020f81336027f4878a63d6c48
Signed-off-by: Paweł Szewczyk <p.szewczyk@samsung.com>
7 years agopackaging: Do not append kdbus suffix conditionally
Karol Lewandowski [Mon, 5 Sep 2016 10:17:13 +0000 (12:17 +0200)]
packaging: Do not append kdbus suffix conditionally

Appending suffix to release flags causes following warning - which
terminates build process.

  warning: spec file systemd.spec has not been exported to .../GBS-ROOT/local/sources/tizen_org_tv/systemd-219-0+kdbus/ correctly, please check if there're special macros in Name/Version/Release fields

This commit drops condional suffix.  This is in line with other packages
providing kdbus support (libdbus, glib).

Change-Id: I91405faeb00352d8f615a6b9b73bdacf42f102df