]> git.baikalelectronics.ru Git - kernel.git/commit
afs: Fix SELinux setting security label on /afs
authorDavid Howells <dhowells@redhat.com>
Mon, 9 Dec 2019 15:04:45 +0000 (15:04 +0000)
committerDavid Howells <dhowells@redhat.com>
Mon, 9 Dec 2019 16:37:36 +0000 (16:37 +0000)
commit5a1a81dd5722741885ad5f0149143f0ca84e524f
treeaf861c2614079326353fa9f1157dd0178276db83
parentd7b78af4b22af7a54d3e827322e43efa3be3fd9d
afs: Fix SELinux setting security label on /afs

Make the AFS dynamic root superblock R/W so that SELinux can set the
security label on it.  Without this, upgrades to, say, the Fedora
filesystem-afs RPM fail if afs is mounted on it because the SELinux label
can't be (re-)applied.

It might be better to make it possible to bypass the R/O check for LSM
label application through setxattr.

Fixes: e97edd9a54e2 ("afs: Support the AFS dynamic root")
Signed-off-by: David Howells <dhowells@redhat.com>
Reviewed-by: Marc Dionne <marc.dionne@auristor.com>
cc: selinux@vger.kernel.org
cc: linux-security-module@vger.kernel.org
fs/afs/super.c