diff options
author | Andi Kleen <ak@linux.intel.com> | 2011-04-21 17:23:19 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-04-22 16:17:29 -0700 |
commit | 8c9e80ed276fc4b9c9fadf29d8bf6b3576112f1a (patch) | |
tree | 7595dd217545593675d40f85cfb11d69697a8300 /include/linux/security.h | |
parent | 8d082f8f3fb89e8a1fcb5120ad98cd9860c8a3e8 (diff) | |
download | op-kernel-dev-8c9e80ed276fc4b9c9fadf29d8bf6b3576112f1a.zip op-kernel-dev-8c9e80ed276fc4b9c9fadf29d8bf6b3576112f1a.tar.gz |
SECURITY: Move exec_permission RCU checks into security modules
Right now all RCU walks fall back to reference walk when CONFIG_SECURITY
is enabled, even though just the standard capability module is active.
This is because security_inode_exec_permission unconditionally fails
RCU walks.
Move this decision to the low level security module. This requires
passing the RCU flags down the security hook. This way at least
the capability module and a few easy cases in selinux/smack work
with RCU walks with CONFIG_SECURITY=y
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Acked-by: Eric Paris <eparis@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/security.h')
-rw-r--r-- | include/linux/security.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/security.h b/include/linux/security.h index ca02f17..8ce59ef 100644 --- a/include/linux/security.h +++ b/include/linux/security.h @@ -1456,7 +1456,7 @@ struct security_operations { struct inode *new_dir, struct dentry *new_dentry); int (*inode_readlink) (struct dentry *dentry); int (*inode_follow_link) (struct dentry *dentry, struct nameidata *nd); - int (*inode_permission) (struct inode *inode, int mask); + int (*inode_permission) (struct inode *inode, int mask, unsigned flags); int (*inode_setattr) (struct dentry *dentry, struct iattr *attr); int (*inode_getattr) (struct vfsmount *mnt, struct dentry *dentry); int (*inode_setxattr) (struct dentry *dentry, const char *name, |