mirror of
https://github.com/token2/snapd.git
synced 2026-03-13 11:15:47 -07:00
Some distros, eg. CentOS 7 do not have /tmp on tmpfs. Because of this, the
policy rules for tmpfs are not effective and the following denial can be
observed when disconnecting the x11 interface (which mounts /tmp/.X11-unix from
the host):
type=AVC msg=audit(1606220902.660:1383): avc: denied { rmdir } for
pid=28575 comm="snap-update-ns" name=".X11-unix" dev="sda2"
ino=17552915
scontext=system_u:system_r:snappy_mount_t:s0
tcontext=system_u:object_r:tmp_t:s0
tclass=dir permissive=1
We need to extend the policy to explicitly allow poking generic tmp_t files and
directories.
Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com>