From owner-svn-src-all@FreeBSD.ORG Tue Jan 28 01:49:50 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0A8B6597; Tue, 28 Jan 2014 01:49:50 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id D0D3B1752; Tue, 28 Jan 2014 01:49:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id s0S1nnF1016891; Tue, 28 Jan 2014 01:49:49 GMT (envelope-from csjp@svn.freebsd.org) Received: (from csjp@localhost) by svn.freebsd.org (8.14.7/8.14.7/Submit) id s0S1nn2K016889; Tue, 28 Jan 2014 01:49:49 GMT (envelope-from csjp@svn.freebsd.org) Message-Id: <201401280149.s0S1nn2K016889@svn.freebsd.org> From: "Christian S.J. Peron" Date: Tue, 28 Jan 2014 01:49:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r261220 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Jan 2014 01:49:50 -0000 Author: csjp Date: Tue Jan 28 01:49:49 2014 New Revision: 261220 URL: http://svnweb.freebsd.org/changeset/base/261220 Log: Allow sigwait(2) in capabilities mode. It's common for multi-threaded processes to create a thread for the purpose of synchronously processing signals. Allow such processes to utilize a capabilities sandbox. Discussed with: rwatson, pjd MFC after: 2 weeks Modified: head/sys/kern/capabilities.conf head/sys/kern/init_sysent.c Modified: head/sys/kern/capabilities.conf ============================================================================== --- head/sys/kern/capabilities.conf Tue Jan 28 00:31:48 2014 (r261219) +++ head/sys/kern/capabilities.conf Tue Jan 28 01:49:49 2014 (r261220) @@ -667,6 +667,7 @@ sigsuspend sigtimedwait sigvec sigwaitinfo +sigwait ## ## Allow creating new socket pairs with socket(2) and socketpair(2). Modified: head/sys/kern/init_sysent.c ============================================================================== --- head/sys/kern/init_sysent.c Tue Jan 28 00:31:48 2014 (r261219) +++ head/sys/kern/init_sysent.c Tue Jan 28 01:49:49 2014 (r261220) @@ -463,7 +463,7 @@ struct sysent sysent[] = { { AS(__acl_set_link_args), (sy_call_t *)sys___acl_set_link, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 426 = __acl_set_link */ { AS(__acl_delete_link_args), (sy_call_t *)sys___acl_delete_link, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 427 = __acl_delete_link */ { AS(__acl_aclcheck_link_args), (sy_call_t *)sys___acl_aclcheck_link, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 428 = __acl_aclcheck_link */ - { AS(sigwait_args), (sy_call_t *)sys_sigwait, AUE_SIGWAIT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 429 = sigwait */ + { AS(sigwait_args), (sy_call_t *)sys_sigwait, AUE_SIGWAIT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 429 = sigwait */ { AS(thr_create_args), (sy_call_t *)sys_thr_create, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 430 = thr_create */ { AS(thr_exit_args), (sy_call_t *)sys_thr_exit, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 431 = thr_exit */ { AS(thr_self_args), (sy_call_t *)sys_thr_self, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 432 = thr_self */