1219131Srwatson##
2219131Srwatson## Copyright (c) 2008-2010 Robert N. M. Watson
3219131Srwatson## All rights reserved.
4219131Srwatson##
5219131Srwatson## This software was developed at the University of Cambridge Computer
6219131Srwatson## Laboratory with support from a grant from Google, Inc.
7219131Srwatson##
8219131Srwatson## Redistribution and use in source and binary forms, with or without
9219131Srwatson## modification, are permitted provided that the following conditions
10219131Srwatson## are met:
11219131Srwatson## 1. Redistributions of source code must retain the above copyright
12219131Srwatson##    notice, this list of conditions and the following disclaimer.
13219131Srwatson## 2. Redistributions in binary form must reproduce the above copyright
14219131Srwatson##    notice, this list of conditions and the following disclaimer in the
15219131Srwatson##    documentation and/or other materials provided with the distribution.
16219131Srwatson##
17219131Srwatson## THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18219131Srwatson## ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19219131Srwatson## IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20219131Srwatson## ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21219131Srwatson## FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22219131Srwatson## DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23219131Srwatson## OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24219131Srwatson## HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25219131Srwatson## LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26219131Srwatson## OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27219131Srwatson## SUCH DAMAGE.
28219131Srwatson##
29219131Srwatson## List of system calls enabled in capability mode, one name per line.
30219131Srwatson##
31219131Srwatson## Notes:
32219131Srwatson## - sys_exit(2), abort2(2) and close(2) are very important.
33219131Srwatson## - Sorted alphabetically, please keep it that way.
34219131Srwatson##
35219131Srwatson## $FreeBSD: releng/10.3/sys/kern/capabilities.conf 293474 2016-01-09 14:20:23Z dchagin $
36219131Srwatson##
37219131Srwatson
38219131Srwatson##
39219131Srwatson## Allow ACL and MAC label operations by file descriptor, subject to
40219131Srwatson## capability rights.  Allow MAC label operations on the current process but
41219131Srwatson## we will need to scope __mac_get_pid(2).
42219131Srwatson##
43219131Srwatson__acl_aclcheck_fd
44219131Srwatson__acl_delete_fd
45219131Srwatson__acl_get_fd
46219131Srwatson__acl_set_fd
47219131Srwatson__mac_get_fd
48219131Srwatson#__mac_get_pid
49219131Srwatson__mac_get_proc
50219131Srwatson__mac_set_fd
51219131Srwatson__mac_set_proc
52219131Srwatson
53219131Srwatson##
54219131Srwatson## Allow sysctl(2) as we scope internal to the call; this is a global
55219131Srwatson## namespace, but there are several critical sysctls required for almost
56219131Srwatson## anything to run, such as hw.pagesize.  For now that policy lives in the
57219131Srwatson## kernel for performance and simplicity, but perhaps it could move to a
58219131Srwatson## proxying daemon in userspace.
59219131Srwatson##
60219131Srwatson__sysctl
61219131Srwatson
62219131Srwatson##
63219131Srwatson## Allow umtx operations as these are scoped by address space.
64219131Srwatson##
65219131Srwatson## XXRW: Need to check this very carefully.
66219131Srwatson##
67219131Srwatson_umtx_lock
68219131Srwatson_umtx_op
69219131Srwatson_umtx_unlock
70219131Srwatson
71219131Srwatson##
72219131Srwatson## Allow process termination using abort2(2).
73219131Srwatson##
74219131Srwatsonabort2
75219131Srwatson
76219131Srwatson##
77219131Srwatson## Allow accept(2) since it doesn't manipulate namespaces directly, rather
78219131Srwatson## relies on existing bindings on a socket, subject to capability rights.
79219131Srwatson##
80219131Srwatsonaccept
81250154Sjillesaccept4
82219131Srwatson
83219131Srwatson##
84219131Srwatson## Allow AIO operations by file descriptor, subject to capability rights.
85219131Srwatson##
86219131Srwatsonaio_cancel
87219131Srwatsonaio_error
88219131Srwatsonaio_fsync
89219131Srwatsonaio_read
90219131Srwatsonaio_return
91219131Srwatsonaio_suspend
92219131Srwatsonaio_waitcomplete
93219131Srwatsonaio_write
94219131Srwatson
95219131Srwatson##
96219131Srwatson## audit(2) is a global operation, submitting to the global trail, but it is
97219131Srwatson## controlled by privilege, and it might be useful to be able to submit
98219131Srwatson## records from sandboxes.  For now, disallow, but we may want to think about
99219131Srwatson## providing some sort of proxy service for this.
100219131Srwatson##
101219131Srwatson#audit
102219131Srwatson
103219131Srwatson##
104247667Spjd## Allow bindat(2).
105219131Srwatson##
106247667Spjdbindat
107219131Srwatson
108219131Srwatson##
109219131Srwatson## Allow capability mode and capability system calls.
110219131Srwatson##
111219131Srwatsoncap_enter
112247602Spjdcap_fcntls_get
113247602Spjdcap_fcntls_limit
114219131Srwatsoncap_getmode
115247602Spjdcap_ioctls_get
116247602Spjdcap_ioctls_limit
117255219Spjd__cap_rights_get
118247602Spjdcap_rights_limit
119219131Srwatson
120219131Srwatson##
121219131Srwatson## Allow read-only clock operations.
122219131Srwatson##
123255374Spjdclock_getres
124219131Srwatsonclock_gettime
125219131Srwatson
126219131Srwatson##
127219131Srwatson## Always allow file descriptor close(2).
128219131Srwatson##
129219131Srwatsonclose
130219131Srwatsonclosefrom
131219131Srwatson
132219131Srwatson##
133247667Spjd## Allow connectat(2).
134219131Srwatson##
135247667Spjdconnectat
136219131Srwatson
137219131Srwatson##
138219131Srwatson## cpuset(2) and related calls require scoping by process, but should
139219131Srwatson## eventually be allowed, at least in the current process case.
140219131Srwatson##
141219131Srwatson#cpuset
142219131Srwatson#cpuset_getaffinity
143219131Srwatson#cpuset_getid
144219131Srwatson#cpuset_setaffinity
145219131Srwatson#cpuset_setid
146219131Srwatson
147219131Srwatson##
148219131Srwatson## Always allow dup(2) and dup2(2) manipulation of the file descriptor table.
149219131Srwatson##
150219131Srwatsondup
151219131Srwatsondup2
152219131Srwatson
153219131Srwatson##
154219131Srwatson## Allow extended attribute operations by file descriptor, subject to
155219131Srwatson## capability rights.
156219131Srwatson##
157219131Srwatsonextattr_delete_fd
158219131Srwatsonextattr_get_fd
159219131Srwatsonextattr_list_fd
160219131Srwatsonextattr_set_fd
161219131Srwatson
162219131Srwatson##
163219131Srwatson## Allow changing file flags, mode, and owner by file descriptor, subject to
164219131Srwatson## capability rights.
165219131Srwatson##
166219131Srwatsonfchflags
167219131Srwatsonfchmod
168219131Srwatsonfchown
169219131Srwatson
170219131Srwatson##
171219131Srwatson## For now, allow fcntl(2), subject to capability rights, but this probably
172219131Srwatson## needs additional scoping.
173219131Srwatson##
174219131Srwatsonfcntl
175219131Srwatson
176219131Srwatson##
177219131Srwatson## Allow fexecve(2), subject to capability rights.  We perform some scoping,
178219131Srwatson## such as disallowing privilege escalation.
179219131Srwatson##
180219131Srwatsonfexecve
181219131Srwatson
182219131Srwatson##
183219131Srwatson## Allow flock(2), subject to capability rights.
184219131Srwatson##
185219131Srwatsonflock
186219131Srwatson
187219131Srwatson##
188219131Srwatson## Allow fork(2), even though it returns pids -- some applications seem to
189219131Srwatson## prefer this interface.
190219131Srwatson##
191219131Srwatsonfork
192219131Srwatson
193219131Srwatson##
194219131Srwatson## Allow fpathconf(2), subject to capability rights.
195219131Srwatson##
196219131Srwatsonfpathconf
197219131Srwatson
198219131Srwatson##
199219131Srwatson## Allow various file descriptor-based I/O operations, subject to capability
200224852Srwatson## rights.
201219131Srwatson##
202219131Srwatsonfreebsd6_ftruncate
203219131Srwatsonfreebsd6_lseek
204219131Srwatsonfreebsd6_mmap
205219131Srwatsonfreebsd6_pread
206219131Srwatsonfreebsd6_pwrite
207219131Srwatson
208219131Srwatson##
209219131Srwatson## Allow querying file and file system state with fstat(2) and fstatfs(2),
210219131Srwatson## subject to capability rights.
211219131Srwatson##
212219131Srwatsonfstat
213219131Srwatsonfstatfs
214219131Srwatson
215219131Srwatson##
216219131Srwatson## Allow further file descriptor-based I/O operations, subject to capability
217219131Srwatson## rights.
218219131Srwatson##
219219131Srwatsonfsync
220219131Srwatsonftruncate
221219131Srwatson
222219131Srwatson##
223293474Sdchagin## Allow futimens(2) and futimes(2), subject to capability rights.
224219131Srwatson##
225293474Sdchaginfutimens
226219131Srwatsonfutimes
227219131Srwatson
228219131Srwatson##
229219131Srwatson## Allow querying process audit state, subject to normal access control.
230219131Srwatson##
231219131Srwatsongetaudit
232219131Srwatsongetaudit_addr
233219131Srwatsongetauid
234219131Srwatson
235219131Srwatson##
236219131Srwatson## Allow thread context management with getcontext(2).
237219131Srwatson##
238219131Srwatsongetcontext
239219131Srwatson
240219131Srwatson##
241219131Srwatson## Allow directory I/O on a file descriptor, subject to capability rights.
242219131Srwatson## Originally we had separate capabilities for directory-specific read
243219131Srwatson## operations, but on BSD we allow reading the raw directory data, so we just
244247602Spjd## rely on CAP_READ now.
245219131Srwatson##
246219131Srwatsongetdents
247219131Srwatsongetdirentries
248219131Srwatson
249219131Srwatson##
250219131Srwatson## Allow querying certain trivial global state.
251219131Srwatson##
252219131Srwatsongetdomainname
253219131Srwatson
254219131Srwatson##
255219131Srwatson## Allow querying current process credential state.
256219131Srwatson##
257219131Srwatsongetegid
258219131Srwatsongeteuid
259219131Srwatson
260219131Srwatson##
261219131Srwatson## Allow querying certain trivial global state.
262219131Srwatson##
263219131Srwatsongethostid
264219131Srwatsongethostname
265219131Srwatson
266219131Srwatson##
267219131Srwatson## Allow querying per-process timer.
268219131Srwatson##
269219131Srwatsongetitimer
270219131Srwatson
271219131Srwatson##
272219131Srwatson## Allow querying current process credential state.
273219131Srwatson##
274219131Srwatsongetgid
275219131Srwatsongetgroups
276219131Srwatsongetlogin
277219131Srwatson
278219131Srwatson##
279219131Srwatson## Allow querying certain trivial global state.
280219131Srwatson##
281219131Srwatsongetpagesize
282219131Srwatsongetpeername
283219131Srwatson
284219131Srwatson##
285219131Srwatson## Allow querying certain per-process scheduling, resource limit, and
286219131Srwatson## credential state.
287219131Srwatson##
288219131Srwatson## XXXRW: getpgid(2) needs scoping.  It's not clear if it's worth scoping
289219131Srwatson## getppid(2).  getpriority(2) needs scoping.  getrusage(2) needs scoping.
290219131Srwatson## getsid(2) needs scoping.
291219131Srwatson##
292219131Srwatsongetpgid
293219131Srwatsongetpgrp
294219131Srwatsongetpid
295219131Srwatsongetppid
296219131Srwatsongetpriority
297219131Srwatsongetresgid
298219131Srwatsongetresuid
299219131Srwatsongetrlimit
300219131Srwatsongetrusage
301219131Srwatsongetsid
302219131Srwatson
303219131Srwatson##
304219131Srwatson## Allow querying socket state, subject to capability rights.
305219131Srwatson##
306219131Srwatson## XXXRW: getsockopt(2) may need more attention.
307219131Srwatson##
308219131Srwatsongetsockname
309219131Srwatsongetsockopt
310219131Srwatson
311219131Srwatson##
312219131Srwatson## Allow querying the global clock.
313219131Srwatson##
314219131Srwatsongettimeofday
315219131Srwatson
316219131Srwatson##
317219131Srwatson## Allow querying current process credential state.
318219131Srwatson##
319219131Srwatsongetuid
320219131Srwatson
321219131Srwatson##
322247602Spjd## Allow ioctl(2), which hopefully will be limited by applications only to
323247602Spjd## required commands with cap_ioctls_limit(2) syscall.
324219131Srwatson##
325247602Spjdioctl
326219131Srwatson
327219131Srwatson##
328219131Srwatson## Allow querying current process credential state.
329219131Srwatson##
330219131Srwatsonissetugid
331219131Srwatson
332219131Srwatson##
333219131Srwatson## Allow kevent(2), as we will authorize based on capability rights on the
334219131Srwatson## target descriptor.
335219131Srwatson##
336219131Srwatsonkevent
337219131Srwatson
338219131Srwatson##
339243610Spjd## Allow kill(2), as we allow the process to send signals only to himself.
340243610Spjd##
341243610Spjdkill
342243610Spjd
343243610Spjd##
344219131Srwatson## Allow message queue operations on file descriptors, subject to capability
345219131Srwatson## rights.
346219131Srwatson##
347219131Srwatsonkmq_notify
348219131Srwatsonkmq_setattr
349219131Srwatsonkmq_timedreceive
350219131Srwatsonkmq_timedsend
351219131Srwatson
352219131Srwatson##
353219131Srwatson## Allow kqueue(2), we will control use.
354219131Srwatson##
355219131Srwatsonkqueue
356219131Srwatson
357219131Srwatson##
358219131Srwatson## Allow managing per-process timers.
359219131Srwatson##
360219131Srwatsonktimer_create
361219131Srwatsonktimer_delete
362219131Srwatsonktimer_getoverrun
363219131Srwatsonktimer_gettime
364219131Srwatsonktimer_settime
365219131Srwatson
366219131Srwatson##
367219131Srwatson## We can't allow ktrace(2) because it relies on a global namespace, but we
368219131Srwatson## might want to introduce an fktrace(2) of some sort.
369219131Srwatson##
370219131Srwatson#ktrace
371219131Srwatson
372219131Srwatson##
373219131Srwatson## Allow AIO operations by file descriptor, subject to capability rights.
374219131Srwatson##
375219131Srwatsonlio_listio
376219131Srwatson
377219131Srwatson##
378219131Srwatson## Allow listen(2), subject to capability rights.
379219131Srwatson##
380219131Srwatson## XXXRW: One might argue this manipulates a global namespace.
381219131Srwatson##
382219131Srwatsonlisten
383219131Srwatson
384219131Srwatson##
385219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
386219131Srwatson##
387219131Srwatsonlseek
388219131Srwatson
389219131Srwatson##
390219131Srwatson## Allow simple VM operations on the current process.
391219131Srwatson##
392219131Srwatsonmadvise
393219131Srwatsonmincore
394219131Srwatsonminherit
395219131Srwatsonmlock
396219131Srwatsonmlockall
397219131Srwatson
398219131Srwatson##
399219131Srwatson## Allow memory mapping a file descriptor, and updating protections, subject
400219131Srwatson## to capability rights.
401219131Srwatson##
402219131Srwatsonmmap
403219131Srwatsonmprotect
404219131Srwatson
405219131Srwatson##
406219131Srwatson## Allow simple VM operations on the current process.
407219131Srwatson##
408219131Srwatsonmsync
409219131Srwatsonmunlock
410219131Srwatsonmunlockall
411219131Srwatsonmunmap
412219131Srwatson
413219131Srwatson##
414219131Srwatson## Allow the current process to sleep.
415219131Srwatson##
416219131Srwatsonnanosleep
417219131Srwatson
418219131Srwatson##
419219131Srwatson## Allow querying the global clock.
420219131Srwatson##
421219131Srwatsonntp_gettime
422219131Srwatson
423219131Srwatson##
424219131Srwatson## Allow AIO operations by file descriptor, subject to capability rights.
425219131Srwatson##
426219131Srwatsonoaio_read
427219131Srwatsonoaio_write
428219131Srwatson
429219131Srwatson##
430219131Srwatson## Allow simple VM operations on the current process.
431219131Srwatson##
432219131Srwatsonobreak
433219131Srwatson
434219131Srwatson##
435219131Srwatson## Allow AIO operations by file descriptor, subject to capability rights.
436219131Srwatson##
437219131Srwatsonolio_listio
438219131Srwatson
439219131Srwatson##
440224812Sjonathan## Operations relative to directory capabilities.
441219131Srwatson##
442248599Spjdchflagsat
443224812Sjonathanfaccessat
444224812Sjonathanfchmodat
445236361Spjdfchownat
446248359Spjdfstatat
447224812Sjonathanfutimesat
448236361Spjdlinkat
449224812Sjonathanmkdirat
450224812Sjonathanmkfifoat
451224812Sjonathanmknodat
452224812Sjonathanopenat
453236361Spjdreadlinkat
454224812Sjonathanrenameat
455236361Spjdsymlinkat
456236361Spjdunlinkat
457293474Sdchaginutimensat
458219131Srwatson
459219131Srwatson##
460224812Sjonathan## Allow entry into open(2). This system call will fail, since access to the
461224812Sjonathan## global file namespace has been disallowed, but allowing entry into the
462224812Sjonathan## syscall means that an audit trail will be generated (which is also very
463224812Sjonathan## useful for debugging).
464219131Srwatson##
465224812Sjonathanopen
466219131Srwatson
467219131Srwatson##
468219131Srwatson## Allow poll(2), which will be scoped by capability rights.
469219131Srwatson##
470219131Srwatson## XXXRW: Perhaps we don't need the OpenBSD version?
471219131Srwatson## XXXRW: We don't yet do that scoping.
472219131Srwatson##
473219131Srwatsonopenbsd_poll
474219131Srwatson
475219131Srwatson##
476219131Srwatson## Process descriptor-related system calls are allowed.
477219131Srwatson##
478219131Srwatsonpdfork
479219131Srwatsonpdgetpid
480219131Srwatsonpdkill
481224987Sjonathan#pdwait4	# not yet implemented
482219131Srwatson
483219131Srwatson##
484219131Srwatson## Allow pipe(2).
485219131Srwatson##
486219131Srwatsonpipe
487250159Sjillespipe2
488219131Srwatson
489219131Srwatson##
490219131Srwatson## Allow poll(2), which will be scoped by capability rights.
491219131Srwatson## XXXRW: We don't yet do that scoping.
492219131Srwatson##
493219131Srwatsonpoll
494219131Srwatson
495219131Srwatson##
496219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
497219131Srwatson##
498219131Srwatsonpread
499219131Srwatsonpreadv
500219131Srwatson
501219131Srwatson##
502219131Srwatson## Allow access to profiling state on the current process.
503219131Srwatson##
504219131Srwatsonprofil
505219131Srwatson
506219131Srwatson##
507219131Srwatson## Disallow ptrace(2) for now, but we do need debugging facilities in
508219131Srwatson## capability mode, so we will want to revisit this, possibly by scoping its
509219131Srwatson## operation.
510219131Srwatson##
511219131Srwatson#ptrace
512219131Srwatson
513219131Srwatson##
514219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
515219131Srwatson##
516219131Srwatsonpwrite
517219131Srwatsonpwritev
518219131Srwatsonread
519219131Srwatsonreadv
520219131Srwatsonrecv
521219131Srwatsonrecvfrom
522219131Srwatsonrecvmsg
523219131Srwatson
524219131Srwatson##
525219131Srwatson## Allow real-time scheduling primitives to be used.
526219131Srwatson##
527219131Srwatson## XXXRW: These require scoping.
528219131Srwatson##
529219131Srwatsonrtprio
530219131Srwatsonrtprio_thread
531219131Srwatson
532219131Srwatson##
533219131Srwatson## Allow simple VM operations on the current process.
534219131Srwatson##
535219131Srwatsonsbrk
536219131Srwatson
537219131Srwatson##
538219131Srwatson## Allow querying trivial global scheduler state.
539219131Srwatson##
540219131Srwatsonsched_get_priority_max
541219131Srwatsonsched_get_priority_min
542219131Srwatson
543219131Srwatson##
544219131Srwatson## Allow various thread/process scheduler operations.
545219131Srwatson##
546219131Srwatson## XXXRW: Some of these require further scoping.
547219131Srwatson##
548219131Srwatsonsched_getparam
549219131Srwatsonsched_getscheduler
550283940Semastesched_rr_get_interval
551219131Srwatsonsched_setparam
552219131Srwatsonsched_setscheduler
553219131Srwatsonsched_yield
554219131Srwatson
555219131Srwatson##
556219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
557219131Srwatson##
558219131Srwatsonsctp_generic_recvmsg
559219131Srwatsonsctp_generic_sendmsg
560219131Srwatsonsctp_generic_sendmsg_iov
561219131Srwatsonsctp_peeloff
562219131Srwatson
563219131Srwatson##
564283942Semaste## Allow pselect(2) and select(2), which will be scoped by capability rights.
565219131Srwatson##
566219131Srwatson## XXXRW: But is it?
567219131Srwatson##
568283942Semastepselect
569219131Srwatsonselect
570219131Srwatson
571219131Srwatson##
572219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.  Use of
573219131Srwatson## explicit addresses here is restricted by the system calls themselves.
574219131Srwatson##
575219131Srwatsonsend
576219131Srwatsonsendfile
577219131Srwatsonsendmsg
578219131Srwatsonsendto
579219131Srwatson
580219131Srwatson##
581219131Srwatson## Allow setting per-process audit state, which is controlled separately by
582219131Srwatson## privileges.
583219131Srwatson##
584219131Srwatsonsetaudit
585219131Srwatsonsetaudit_addr
586219131Srwatsonsetauid
587219131Srwatson
588219131Srwatson##
589219131Srwatson## Allow setting thread context.
590219131Srwatson##
591219131Srwatsonsetcontext
592219131Srwatson
593219131Srwatson##
594219131Srwatson## Allow setting current process credential state, which is controlled
595219131Srwatson## separately by privilege.
596219131Srwatson##
597219131Srwatsonsetegid
598219131Srwatsonseteuid
599219131Srwatsonsetgid
600219131Srwatson
601219131Srwatson##
602219131Srwatson## Allow use of the process interval timer.
603219131Srwatson##
604219131Srwatsonsetitimer
605219131Srwatson
606219131Srwatson##
607219131Srwatson## Allow setpriority(2).
608219131Srwatson##
609219131Srwatson## XXXRW: Requires scoping.
610219131Srwatson##
611219131Srwatsonsetpriority
612219131Srwatson
613219131Srwatson##
614219131Srwatson## Allow setting current process credential state, which is controlled
615219131Srwatson## separately by privilege.
616219131Srwatson##
617219131Srwatsonsetregid
618219131Srwatsonsetresgid
619219131Srwatsonsetresuid
620219131Srwatsonsetreuid
621219131Srwatson
622219131Srwatson##
623219131Srwatson## Allow setting process resource limits with setrlimit(2).
624219131Srwatson##
625219131Srwatsonsetrlimit
626219131Srwatson
627219131Srwatson##
628219131Srwatson## Allow creating a new session with setsid(2).
629219131Srwatson##
630219131Srwatsonsetsid
631219131Srwatson
632219131Srwatson##
633219131Srwatson## Allow setting socket options with setsockopt(2), subject to capability
634219131Srwatson## rights.
635219131Srwatson##
636219131Srwatson## XXXRW: Might require scoping.
637219131Srwatson##
638219131Srwatsonsetsockopt
639219131Srwatson
640219131Srwatson##
641219131Srwatson## Allow setting current process credential state, which is controlled
642219131Srwatson## separately by privilege.
643219131Srwatson##
644219131Srwatsonsetuid
645219131Srwatson
646219131Srwatson##
647224812Sjonathan## shm_open(2) is scoped so as to allow only access to new anonymous objects.
648219131Srwatson##
649224812Sjonathanshm_open
650219131Srwatson
651219131Srwatson##
652219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
653219131Srwatson##
654219131Srwatsonshutdown
655219131Srwatson
656219131Srwatson##
657219131Srwatson## Allow signal control on current process.
658219131Srwatson##
659219131Srwatsonsigaction
660219131Srwatsonsigaltstack
661219131Srwatsonsigblock
662219131Srwatsonsigpending
663219131Srwatsonsigprocmask
664219131Srwatsonsigqueue
665219131Srwatsonsigreturn
666219131Srwatsonsigsetmask
667219131Srwatsonsigstack
668219131Srwatsonsigsuspend
669219131Srwatsonsigtimedwait
670219131Srwatsonsigvec
671219131Srwatsonsigwaitinfo
672283943Semastesigwait
673219131Srwatson
674219131Srwatson##
675219131Srwatson## Allow creating new socket pairs with socket(2) and socketpair(2).
676219131Srwatson##
677219131Srwatsonsocket
678219131Srwatsonsocketpair
679219131Srwatson
680219131Srwatson##
681219131Srwatson## Allow simple VM operations on the current process.
682219131Srwatson##
683219131Srwatson## XXXRW: Kernel doesn't implement this, so drop?
684219131Srwatson##
685219131Srwatsonsstk
686219131Srwatson
687219131Srwatson##
688219131Srwatson## Do allow sync(2) for now, but possibly shouldn't.
689219131Srwatson##
690219131Srwatsonsync
691219131Srwatson
692219131Srwatson##
693219131Srwatson## Always allow process termination with sys_exit(2).
694219131Srwatson##
695219131Srwatsonsys_exit
696219131Srwatson
697219131Srwatson##
698219131Srwatson## sysarch(2) does rather diverse things, but is required on at least i386
699219131Srwatson## in order to configure per-thread data.  As such, it's scoped on each
700219131Srwatson## architecture.
701219131Srwatson##
702219131Srwatsonsysarch
703219131Srwatson
704219131Srwatson##
705219131Srwatson## Allow thread operations operating only on current process.
706219131Srwatson##
707219131Srwatsonthr_create
708219131Srwatsonthr_exit
709219131Srwatsonthr_kill
710219131Srwatson
711219131Srwatson##
712219131Srwatson## Disallow thr_kill2(2), as it may operate beyond the current process.
713219131Srwatson##
714219131Srwatson## XXXRW: Requires scoping.
715219131Srwatson##
716219131Srwatson#thr_kill2
717219131Srwatson
718219131Srwatson##
719219131Srwatson## Allow thread operations operating only on current process.
720219131Srwatson##
721219131Srwatsonthr_new
722219131Srwatsonthr_self
723219131Srwatsonthr_set_name
724219131Srwatsonthr_suspend
725219131Srwatsonthr_wake
726219131Srwatson
727219131Srwatson##
728219131Srwatson## Allow manipulation of the current process umask with umask(2).
729219131Srwatson##
730219131Srwatsonumask
731219131Srwatson
732219131Srwatson##
733219131Srwatson## Allow submitting of process trace entries with utrace(2).
734219131Srwatson##
735219131Srwatsonutrace
736219131Srwatson
737219131Srwatson##
738219131Srwatson## Allow generating UUIDs with uuidgen(2).
739219131Srwatson##
740219131Srwatsonuuidgen
741219131Srwatson
742219131Srwatson##
743219131Srwatson## Allow I/O-related file descriptors, subject to capability rights.
744219131Srwatson##
745219131Srwatsonwrite
746219131Srwatsonwritev
747219131Srwatson
748219131Srwatson##
749219131Srwatson## Allow processes to yield(2).
750219131Srwatson##
751219131Srwatsonyield
752