From patchwork Thu Jul 18 13:57:03 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Moore X-Patchwork-Id: 260063 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id D87272C008E for ; Thu, 18 Jul 2013 23:57:50 +1000 (EST) Received: from localhost ([::1]:35069 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UzoiK-0007iI-N1 for incoming@patchwork.ozlabs.org; Thu, 18 Jul 2013 09:57:48 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38539) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uzohh-0007Q8-2k for qemu-devel@nongnu.org; Thu, 18 Jul 2013 09:57:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uzohf-0006dV-PQ for qemu-devel@nongnu.org; Thu, 18 Jul 2013 09:57:09 -0400 Received: from mx1.redhat.com ([209.132.183.28]:58824) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uzohf-0006dJ-Fb; Thu, 18 Jul 2013 09:57:07 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r6IDv48Y010010 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 18 Jul 2013 09:57:04 -0400 Received: from [127.0.0.1] (vpn-56-139.rdu2.redhat.com [10.10.56.139]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id r6IDv3gl000817; Thu, 18 Jul 2013 09:57:03 -0400 To: qemu-devel@nongnu.org, qemu-stable@nongnu.org From: Paul Moore Date: Thu, 18 Jul 2013 09:57:03 -0400 Message-ID: <20130718135703.8247.19213.stgit@localhost> User-Agent: StGit/0.16 MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.67 on 10.5.11.11 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: coreyb@linux.vnet.ibm.com, otubo@linux.vnet.ibm.com Subject: [Qemu-devel] [PATCH] seccomp: add arch_prctl() to the syscall whitelist X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org It appears that even a very simple /etc/qemu-ifup configuration can require the arch_prctl() syscall, see the example below: #!/bin/sh /sbin/ifconfig $1 0.0.0.0 up /usr/sbin/brctl addif $1 Signed-off-by: Paul Moore Reviewed-by: Eduardo Otubo --- qemu-seccomp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qemu-seccomp.c b/qemu-seccomp.c index 173d185..9e91c73 100644 --- a/qemu-seccomp.c +++ b/qemu-seccomp.c @@ -234,7 +234,8 @@ static const struct QemuSeccompSyscall seccomp_whitelist[] = { { SCMP_SYS(waitid), 241 }, { SCMP_SYS(io_cancel), 241 }, { SCMP_SYS(io_setup), 241 }, - { SCMP_SYS(io_destroy), 241 } + { SCMP_SYS(io_destroy), 241 }, + { SCMP_SYS(arch_prctl), 240 } }; int seccomp_start(void)