Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(61)

Side by Side Diff: src/trusted/sandbox/mac/nacl-sandbox.sb

Issue 379019: NaCl mac sandbox file. To be used with sandbox-exec. Base URL: http://nativeclient.googlecode.com/svn/trunk/src/native_client/
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
1 ;;
Mark Mentovai 2009/11/10 02:12:44 Needs lice: Copyright 2009 blahblah blah blah.
2 ;; nacl-sandbox.sb
3 ;; Policy to sandbox NaCl.
4 ;;
5 ;; Run with sandbox-exec -f ./nacl-sandbox.sb -- sel_ldr -f module.nexe
jeremy 2009/11/10 08:26:24 In the rest of Chrome we turn on the Sandbox progr
6
7 (version 1)
8 (debug deny)
Mark Mentovai 2009/11/10 02:12:44 Is this going to be loaded by Chrome? Jeremy put
jeremy 2009/11/10 08:26:24 Like Mark said, this is why I think it's best you
9 (deny default)
10 (allow file-read-data (regex #"Frameworks/SDL.framework"))
Mark Mentovai 2009/11/10 02:12:44 Anchor the beginning and end with leading and trai
jeremy 2009/11/10 08:26:24 Are you sure you need this? Can you load this pro
11 (allow file-read-data (regex #".nexe$"))
Mark Mentovai 2009/11/10 02:12:44 Backslash the dot.
12 (allow process-exec (regex #"^.*sel_ldr$"))
Mark Mentovai 2009/11/10 02:12:44 What's up with ^.*? Seems like you don't want to
13
14 ;; provides basic access to devices, symlinks, and libraries.
15 (import "/usr/share/sandbox/bsd.sb")
jeremy 2009/11/10 08:26:24 Do you need all of this? in Chrome we don't and w
16
17 ;; bsd.sb allows write access to these paths. We need read access, but there's
18 ;; no reason to write here.
19 (deny file-write-data
20 (regex #"^(/private)?/etc/localtime$"
Mark Mentovai 2009/11/10 02:12:44 There are other things that bsd.sb allows writes t
21 #"^/usr/share/nls/"
22 #"^/usr/share/zoneinfo/"))
23
24 (deny ipc-posix-shm)
25 (allow sysctl-read)
26
27 ; allow mach-lookups to Apple stuff
28 (allow mach-lookup (global-name
jeremy 2009/11/10 08:26:24 Why do you need all of these? we make do without
29 "com.apple.CoreServices.coreservicesd"
30 "com.apple.DiskArbitration.diskarbitrationd"
31 "com.apple.SecurityServer"
32 "com.apple.SystemConfiguration.configd"
33 "com.apple.bsd.dirhelper"
34 "com.apple.FontObjectsServer"
35 "com.apple.windowserver.session"
36 "com.apple.windowserver.active"
37 "com.apple.audio.coreaudiod"
38 "com.apple.audio.systemsoundserver"
39 ))
40
41 (deny network*)
42 (allow network-outbound (to unix-socket))
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698