chiark / gitweb /
logind: load SELinux labelling system
authorNicolas Iooss <nicolas.iooss@m4x.org>
Tue, 2 Feb 2016 19:07:46 +0000 (20:07 +0100)
committerSven Eden <yamakuzure@gmx.net>
Wed, 17 May 2017 13:22:16 +0000 (15:22 +0200)
commitf5ce2eabeda330f36bb89649db00a8e030baaa93
treebe2f655ed04b30ac4dba23f17c07056af8a02e23
parent6656a93cab40e90fbb311433b65e4b97eaf21eaa
logind: load SELinux labelling system

elogind-logind uses mkdir_label and label_fix functions without calling
first mac_selinux_init.  This makes /run/user/$UID/ directories not
labelled correctly on an Arch Linux system using SELinux.

Fix this by calling mac_selinux_init("/run") early in elogind-logind.
This makes files created in /etc/udev/rules.d and /var/lib/elogind to be
labelled through transitions in the SELinux policy instead of using
setfscreatecon (with mac_selinux_create_file_prepare).
src/login/logind-dbus.c