From: Andy Lutomirski Date: Tue, 10 Jun 2014 19:45:42 +0000 (-0700) Subject: fs,userns: Change inode_capable to capable_wrt_inode_uidgid X-Git-Tag: omap-for-v3.16/fixes-against-rc1~66 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=23adbe12ef7d3d4195e80800ab36b37bee28cd03;p=pandora-kernel.git fs,userns: Change inode_capable to capable_wrt_inode_uidgid The kernel has no concept of capabilities with respect to inodes; inodes exist independently of namespaces. For example, inode_capable(inode, CAP_LINUX_IMMUTABLE) would be nonsense. This patch changes inode_capable to check for uid and gid mappings and renames it to capable_wrt_inode_uidgid, which should make it more obvious what it does. Fixes CVE-2014-4014. Cc: Theodore Ts'o Cc: Serge Hallyn Cc: "Eric W. Biederman" Cc: Dave Chinner Cc: stable@vger.kernel.org Signed-off-by: Andy Lutomirski Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed