diff options
author | Stephen Smalley <sds@tycho.nsa.gov> | 2008-12-05 09:12:19 -0500 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2008-12-20 09:01:03 +1100 |
commit | 459c19f524a9d89c65717a7d061d5f11ecf6bcb8 (patch) | |
tree | e3026017e0d58736e46406f13bd370b75cfdf674 /security | |
parent | 1e641743f055f075ed9a4edd75f1fb1e05669ddc (diff) | |
download | linux-stable-459c19f524a9d89c65717a7d061d5f11ecf6bcb8.tar.gz linux-stable-459c19f524a9d89c65717a7d061d5f11ecf6bcb8.tar.bz2 linux-stable-459c19f524a9d89c65717a7d061d5f11ecf6bcb8.zip |
SELinux: correctly detect proc filesystems of the form "proc/foo"
Map all of these proc/ filesystem types to "proc" for the policy lookup at
filesystem mount time.
Signed-off-by: James Morris <jmorris@namei.org>
Diffstat (limited to 'security')
-rw-r--r-- | security/selinux/hooks.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 520f82ab3fbf..8dbc54cde59e 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c @@ -702,7 +702,7 @@ static int selinux_set_mnt_opts(struct super_block *sb, sbsec->proc = 1; /* Determine the labeling behavior to use for this filesystem type. */ - rc = security_fs_use(sb->s_type->name, &sbsec->behavior, &sbsec->sid); + rc = security_fs_use(sbsec->proc ? "proc" : sb->s_type->name, &sbsec->behavior, &sbsec->sid); if (rc) { printk(KERN_WARNING "%s: security_fs_use(%s) returned %d\n", __func__, sb->s_type->name, rc); |