]> git.ipfire.org Git - thirdparty/systemd.git/commit
seccomp: move brk+mmap+mmap2 into @default syscall filter set
authorLennart Poettering <lennart@poettering.net>
Thu, 19 Nov 2020 10:14:41 +0000 (11:14 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 19 Nov 2020 15:44:50 +0000 (16:44 +0100)
commit5abede3247591248718026cb8be6cd231de7728b
tree69335003eb7e0802cf8c93bb9c8e12d45a455d89
parentbca0618705d01ccac84523f4ddfe293fc1d44f66
seccomp: move brk+mmap+mmap2 into @default syscall filter set

These three syscalls are internally used by libc's memory allocation
logic, i.e. ultimately back malloc(). Allocating a bit of memory is so
basic, it should just be in the default set.

This fixes a couple of issues with asan/msan and the seccomp tests: when
asan/msan is used some additional, large memory allocations take place
in the background, and unless mmap/mmap2/brk are allowlisted these will
fail, aborting the test prematurely.
src/shared/seccomp-util.c