summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorHarald Hoyer <harald@redhat.com>2016-04-15 01:14:29 +0200
committerSven Eden <yamakuzure@gmx.net>2017-06-16 10:12:57 +0200
commit34267dba6bc0f2eaed722e1d816ff600dcad7f3d (patch)
treeae9a9fac84eac219cc49d8703f2bfd43c30f2391 /src
parent45ee9637428c9104a4d4b8c297df45b6608b99b1 (diff)
core/mount-setup.c: also relabel /dev/shm for selinux (#3039)
daemons, which wish to transition state from the initramfs to the real root, might use /dev/shm for their state. As /dev is not relabeled across mount points, /dev/shm has to be relabled explicitly.
Diffstat (limited to 'src')
-rw-r--r--src/core/mount-setup.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/mount-setup.c b/src/core/mount-setup.c
index 0467fe210..0d73ce6fa 100644
--- a/src/core/mount-setup.c
+++ b/src/core/mount-setup.c
@@ -392,6 +392,7 @@ int mount_setup(bool loaded_policy) {
before_relabel = now(CLOCK_MONOTONIC);
nftw("/dev", nftw_cb, 64, FTW_MOUNT|FTW_PHYS|FTW_ACTIONRETVAL);
+ nftw("/dev/shm", nftw_cb, 64, FTW_MOUNT|FTW_PHYS|FTW_ACTIONRETVAL);
nftw("/run", nftw_cb, 64, FTW_MOUNT|FTW_PHYS|FTW_ACTIONRETVAL);
after_relabel = now(CLOCK_MONOTONIC);