linux-stable/tools/testing/selftests/seccomp
Sargun Dhillon e4ab5ccc35 selftests/seccomp: Catch garbage on SECCOMP_IOCTL_NOTIF_RECV
This adds logic to the user_notification_basic test to set a member
of struct seccomp_notif to an invalid value to ensure that the kernel
returns EINVAL if any of the struct seccomp_notif members are set to
invalid values.

Signed-off-by: Sargun Dhillon <sargun@sargun.me>
Suggested-by: Christian Brauner <christian.brauner@ubuntu.com>
Link: https://lore.kernel.org/r/20191230203811.4996-1-sargun@sargun.me
Fixes: 6a21cc50f0 ("seccomp: add a return code to trap to userspace")
Cc: stable@vger.kernel.org
Signed-off-by: Kees Cook <keescook@chromium.org>
2020-01-02 13:15:45 -08:00
..
.gitignore selftests: seccomp: update .gitignore with newly added tests 2017-11-15 08:01:42 -07:00
Makefile selftests: seccomp: use LDLIBS instead of LDFLAGS 2019-01-16 11:41:44 -07:00
config selftests: create test-specific kconfig fragments 2016-02-25 09:47:52 -07:00
seccomp_benchmark.c selftests/seccomp: Add simple seccomp overhead benchmark 2017-08-14 13:46:41 -07:00
seccomp_bpf.c selftests/seccomp: Catch garbage on SECCOMP_IOCTL_NOTIF_RECV 2020-01-02 13:15:45 -08:00