]> git.baikalelectronics.ru Git - kernel.git/commit
seccomp: add tests for ptrace hole
authorKees Cook <keescook@chromium.org>
Thu, 26 May 2016 18:47:01 +0000 (11:47 -0700)
committerKees Cook <keescook@chromium.org>
Tue, 14 Jun 2016 17:54:38 +0000 (10:54 -0700)
commit40d2a482567881f732771e09ab858dd43c059277
tree7d7f4c5ad0c47c9353da6a4528aeaab1f4d2088d
parentd3777c3dac341079f7eeb65ba57c12f4c15d1aea
seccomp: add tests for ptrace hole

One problem with seccomp was that ptrace could be used to change a
syscall after seccomp filtering had completed. This was a well documented
limitation, and it was recommended to block ptrace when defining a filter
to avoid this problem. This can be quite a limitation for containers or
other places where ptrace is desired even under seccomp filters.

This adds tests for both SECCOMP_RET_TRACE and PTRACE_SYSCALL manipulations.

Signed-off-by: Kees Cook <keescook@chromium.org>
Cc: Andy Lutomirski <luto@kernel.org>
tools/testing/selftests/seccomp/seccomp_bpf.c