UBUNTU: SAUCE: SECCOMP: seccomp: Add SECCOMP_RET_TRAP
authorWill Drewry <wad@chromium.org>
Thu, 9 Feb 2012 18:01:37 +0000 (12:01 -0600)
committerLeann Ogasawara <leann.ogasawara@canonical.com>
Mon, 2 Apr 2012 20:23:06 +0000 (13:23 -0700)
commitd9157b09c8e02b0ad2c484378029d56210474ebb
treeb118b1c7baa2cf0140ec3d470445b6564d623e91
parent815c5afcc6bd59a60d8035a9a3c9c177c89eda75
UBUNTU: SAUCE: SECCOMP: seccomp: Add SECCOMP_RET_TRAP

Adds a new return value to seccomp filters that triggers a SIGSYS to be
delivered with the new SYS_SECCOMP si_code.

This allows in-process system call emulation, including just specifying
an errno or cleanly dumping core, rather than just dying.

v15: - use audit_seccomp/skip
     - pad out error spacing; clean up switch (indan@nul.nu)
v14: - n/a
v13: - rebase on to 88ebdda6159ffc15699f204c33feb3e431bf9bdc
v12: - rebase on to linux-next
v11: - clarify the comment (indan@nul.nu)
     - s/sigtrap/sigsys
v10: - use SIGSYS, syscall_get_arch, updates arch/Kconfig
       note suggested-by (though original suggestion had other behaviors)
v9:  - changes to SIGILL
v8:  - clean up based on changes to dependent patches
v7:  - introduction

Suggested-by: Markus Gutschke <markus@chromium.org>
Suggested-by: Julien Tinnes <jln@chromium.org>
Signed-off-by: Will Drewry <wad@chromium.org>
Signed-off-by: Kees Cook <kees@ubuntu.com>
arch/Kconfig
include/asm-generic/siginfo.h
include/linux/seccomp.h
kernel/seccomp.c