Files
rockchip-kernel/fs
Andy Lutomirski 94702e5561 UPSTREAM: 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 <tytso@mit.edu>
Cc: Serge Hallyn <serge.hallyn@ubuntu.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Dave Chinner <david@fromorbit.com>
Cc: stable@vger.kernel.org
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

BUG=chromium:427055
TEST=kernel compiles and boots

(cherry picked from commit 23adbe12ef)
Signed-off-by: Stephen Barber <smbarber@chromium.org>

Change-Id: Iff4e262160fe3b05783bff1c8cf08825792c97d7
Reviewed-on: https://chromium-review.googlesource.com/235422
Trybot-Ready: Stephen Barber <smbarber@chromium.org>
Tested-by: Stephen Barber <smbarber@chromium.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Commit-Queue: Stephen Barber <smbarber@chromium.org>
2014-12-13 01:17:25 +00:00
..
2013-10-24 23:43:27 -04:00
2014-02-17 12:37:13 -08:00
2014-01-25 03:13:02 -05:00
2014-01-25 03:13:02 -05:00
2014-01-23 18:54:14 +02:00
2014-01-26 11:51:09 +01:00
2014-02-02 16:24:07 -08:00
2013-12-04 12:27:46 +01:00
2014-02-13 15:56:05 -06:00
2014-02-25 07:37:52 -08:00
2013-09-16 18:20:25 -07:00
2014-01-25 03:14:05 -05:00
2014-01-25 03:13:03 -05:00
2014-02-25 07:37:52 -08:00
2013-12-22 11:03:49 -08:00
2013-10-24 23:34:54 -04:00
2013-11-23 22:33:47 -08:00
2013-09-10 18:56:31 -04:00
2013-10-24 23:34:54 -04:00
2013-11-09 00:16:20 -05:00
2013-10-24 23:34:54 -04:00
2014-01-26 08:26:40 -05:00
2014-03-30 19:18:51 -04:00
2013-11-23 22:33:47 -08:00
2014-03-30 19:18:51 -04:00
2014-03-30 19:18:51 -04:00
2013-10-24 23:34:54 -04:00
2014-01-22 19:36:57 +01:00
2013-11-09 00:16:31 -05:00