]> asedeno.scripts.mit.edu Git - linux.git/commit
samples/seccomp: Support programs with >256 instructions
authorRicky Zhou <rickyz@chromium.org>
Thu, 13 Oct 2016 17:37:28 +0000 (10:37 -0700)
committerKees Cook <keescook@chromium.org>
Tue, 1 Nov 2016 15:58:17 +0000 (08:58 -0700)
commitd881d25cf5bc2fafbbfb383a475278977e1bd55a
tree59831f33afc57b1979b4869f93944abb6febc446
parent1ff120504f8c322a03fbce035d99e29e741da725
samples/seccomp: Support programs with >256 instructions

Previously, the program size was incorrectly truncated to 8 bits,
resulting in broken labels in large programs. Also changes the jump
resolution loop to not rely on undefined behavior (making a pointer
point before the filter array).

Signed-off-by: Ricky Zhou <rickyz@chromium.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
samples/seccomp/bpf-helper.c