[PATCH 0/1] [trusty / lts-utopic] seccomp: cap SECCOMP_RET_ERRNO data to MAX_ERRNO

Brad Figg brad.figg at canonical.com
Tue Mar 1 17:47:04 UTC 2016


BugLink: http://bugs.launchpad.net/bugs/1496073

The value resulting from the SECCOMP_RET_DATA mask could exceed MAX_ERRNO
when setting errno during a SECCOMP_RET_ERRNO filter action.  This makes
sure we have a reliable value being set, so that an invalid errno will not
be ignored by userspace.

Signed-off-by: Kees Cook <keescook at chromium.org>
Reported-by: Dmitry V. Levin <ldv at altlinux.org>
Cc: Andy Lutomirski <luto at amacapital.net>
Cc: Will Drewry <wad at chromium.org>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Brad Figg <brad.figg at canonical.com>

Kees Cook (1):
  seccomp: cap SECCOMP_RET_ERRNO data to MAX_ERRNO

 kernel/seccomp.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

-- 
2.7.0





More information about the kernel-team mailing list