From 90856dc24fe932519beaa68534b17305039b4b53 Mon Sep 17 00:00:00 2001 From: virusdefender Date: Wed, 20 Jan 2016 15:25:48 +0800 Subject: [PATCH] add extra syscalls to enable glibc init --- runner.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/runner.c b/runner.c index 37bc9f0..3949c66 100644 --- a/runner.c +++ b/runner.c @@ -33,8 +33,10 @@ int run(struct config *config, struct result *result) { int return_code; int i; int syscalls_whitelist[] = {SCMP_SYS(read), SCMP_SYS(write), SCMP_SYS(fstat), - SCMP_SYS(mmap), SCMP_SYS(mprotect), SCMP_SYS(munmap), - SCMP_SYS(brk), SCMP_SYS(access), SCMP_SYS(exit_group)}; + SCMP_SYS(mmap), SCMP_SYS(mprotect), SCMP_SYS(munmap), + SCMP_SYS(open), SCMP_SYS(arch_prctl), SCMP_SYS(brk), + SCMP_SYS(access), SCMP_SYS(exit_group), SCMP_SYS(execve), + SCMP_SYS(close)}; int syscalls_whitelist_length = sizeof(syscalls_whitelist) / sizeof(int); scmp_filter_ctx ctx = NULL;