Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1612053
| From | Tomeu Vizoso <tomeu.vizoso@collabora.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts |
| Date | 2017-03-29 17:30 +0200 |
| Message-ID | <tqnHQ-lp-9@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Labelling of files in a NFSv4.2 currently fails with ENOTSUPP because the mount point doesn't have SBLABEL_MNT. Add specific condition for NFS4 filesystems so it gets correctly labeled. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Cc: J. Bruce Fields <bfields@redhat.com> --- Hi, cannot remotely say that I currently understand how selinux is expected to work within NFS mounts, but this change allowed me to fully boot AOSP with its rootfs and ramdisk on a single NFS share. Thanks, Tomeu --- security/selinux/hooks.c | 1 + 1 file changed, 1 insertion(+) diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 0c2ac318aa7f..71cd1d8c67c2 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c @@ -485,6 +485,7 @@ static int selinux_is_sblabel_mnt(struct super_block *sb) !strcmp(sb->s_type->name, "debugfs") || !strcmp(sb->s_type->name, "tracefs") || !strcmp(sb->s_type->name, "rootfs") || + !strcmp(sb->s_type->name, "nfs4") || (selinux_policycap_cgroupseclabel && (!strcmp(sb->s_type->name, "cgroup") || !strcmp(sb->s_type->name, "cgroup2"))); -- 2.9.3
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] selinux: Fix SBLABEL_MNT for NFS mounts Tomeu Vizoso <tomeu.vizoso@collabora.com> - 2017-03-29 17:30 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts "J. Bruce Fields" <bfields@redhat.com> - 2017-03-29 23:40 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts Tomeu Vizoso <tomeu.vizoso@collabora.com> - 2017-03-30 09:50 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts Stephen Smalley <sds@tycho.nsa.gov> - 2017-03-30 19:30 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts "J. Bruce Fields" <bfields@redhat.com> - 2017-03-30 19:50 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts Stephen Smalley <sds@tycho.nsa.gov> - 2017-03-30 20:00 +0200
Re: [PATCH] selinux: Fix SBLABEL_MNT for NFS mounts "J. Bruce Fields" <bfields@redhat.com> - 2017-04-05 01:30 +0200
csiph-web