Thread (4 messages) 4 messages, 2 authors, 2020-06-19

Re: [PATCH] seccomp: Use -1 marker for end of mode 1 syscall list

From: Andy Lutomirski <luto@kernel.org>
Date: 2020-06-19 19:42:29
Also in: linux-mips, lkml

On Fri, Jun 19, 2020 at 12:37 PM Kees Cook [off-list ref] wrote:
The terminator for the mode 1 syscalls list was a 0, but that could be
a valid syscall number (e.g. x86_64 __NR_read). By luck, __NR_read was
listed first and the loop construct would not test it, so there was no
bug. However, this is fragile. Replace the terminator with -1 instead,
and make the variable name for mode 1 syscall lists more descriptive.
Could the architecture instead supply the length of the list?

--Andy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help