diff options
| author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-03-22 15:23:38 +0000 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-03-22 15:23:38 +0000 |
| commit | 0c79dacc8a8d4de2455d61c51724866f667ba53c (patch) | |
| tree | 5186034782b608fd13a7408b5852ad248f6bdc35 /sandbox-systrace.c | |
| parent | 02d4c2ac3daa0f36264392972709ccd7676ab3e8 (diff) | |
Notes
Diffstat (limited to 'sandbox-systrace.c')
| -rw-r--r-- | sandbox-systrace.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sandbox-systrace.c b/sandbox-systrace.c index 53fbd47cb5aa..6706c9a80536 100644 --- a/sandbox-systrace.c +++ b/sandbox-systrace.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sandbox-systrace.c,v 1.7 2013/06/01 13:15:52 dtucker Exp $ */ +/* $OpenBSD: sandbox-systrace.c,v 1.9 2014/01/31 16:39:19 tedu Exp $ */ /* * Copyright (c) 2011 Damien Miller <djm@mindrot.org> * @@ -66,6 +66,7 @@ static const struct sandbox_policy preauth_policy[] = { { SYS_munmap, SYSTR_POLICY_PERMIT }, { SYS_read, SYSTR_POLICY_PERMIT }, { SYS_select, SYSTR_POLICY_PERMIT }, + { SYS_shutdown, SYSTR_POLICY_PERMIT }, { SYS_sigprocmask, SYSTR_POLICY_PERMIT }, { SYS_write, SYSTR_POLICY_PERMIT }, { -1, -1 } @@ -141,7 +142,7 @@ ssh_sandbox_parent(struct ssh_sandbox *box, pid_t child_pid, box->systrace_fd, child_pid, strerror(errno)); /* Allocate and assign policy */ - bzero(&policy, sizeof(policy)); + memset(&policy, 0, sizeof(policy)); policy.strp_op = SYSTR_POLICY_NEW; policy.strp_maxents = SYS_MAXSYSCALL; if (ioctl(box->systrace_fd, STRIOCPOLICY, &policy) == -1) |
