Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=b1aa5301b9f88a4891061650c591fb8fe1c1d1da Commit: b1aa5301b9f88a4891061650c591fb8fe1c1d1da Parent: 99f1c97dbdb30e958edfd1ced0ae43df62504e07 Author: Stephen Smalley <[EMAIL PROTECTED]> AuthorDate: Fri Jan 25 13:03:42 2008 -0500 Committer: James Morris <[EMAIL PROTECTED]> CommitDate: Sat Jan 26 12:16:16 2008 +1100
selinux: fix labeling of /proc/net inodes The proc net rewrite had a side effect on selinux, leading it to mislabel the /proc/net inodes, thereby leading to incorrect denials. Fix security_genfs_sid to ignore extra leading / characters in the path supplied by selinux_proc_get_sid since we now get "//net/..." rather than "/net/...". Signed-off-by: Stephen Smalley <[EMAIL PROTECTED]> Signed-off-by: James Morris <[EMAIL PROTECTED]> --- security/selinux/ss/services.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/security/selinux/ss/services.c b/security/selinux/ss/services.c index f83b19d..4bf715d 100644 --- a/security/selinux/ss/services.c +++ b/security/selinux/ss/services.c @@ -1744,6 +1744,9 @@ int security_genfs_sid(const char *fstype, struct ocontext *c; int rc = 0, cmp = 0; + while (path[0] == '/' && path[1] == '/') + path++; + POLICY_RDLOCK; for (genfs = policydb.genfs; genfs; genfs = genfs->next) { - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html