Connecting the Dot Dots
Model Checking Concurrency in Capsicum ASA-4 21 July 2010 Robert N. M. Watson Jonathan Anderson
Connecting the Dot Dots Model Checking Concurrency in Capsicum - - PowerPoint PPT Presentation
Connecting the Dot Dots Model Checking Concurrency in Capsicum ASA-4 21 July 2010 Robert N. M. Watson Jonathan Anderson Introduction UNIX File System (UFS) Capsicum: practical capabilities for UNIX Whoops, a concurrency
Model Checking Concurrency in Capsicum ASA-4 21 July 2010 Robert N. M. Watson Jonathan Anderson
2
3
4
int open(char *path, int flags, ...);
int chdir(char *path);
int rename(char *from, char *to);
5
6
root tmp .. tmp .. etc etc .. passwd passwd hard link
root etc passwd etc passwd File descriptor array Process Root directory Current working directory
7
CVEs in Jan-Aug Jan-Aug 2009 Firefox 85 Safari 59 IE 48 Chrome 39 Flash 35
source; Justin Fo n Foster, OWASP 8
UNIX process ambient authority Browser process ambient authority Renderer process capability mode Renderer process capability mode ... Kernel Traditional UNIX application Capsicum logical application becomes
9
Apache Apache Worker 1 Apache Worker 2
Logical Application
/ etc var apache passwd www site1 site2
10
11
root tmp .. tmp .. etc etc .. passwd passwd hard link File descriptor array Process Root directory Current working directory
! !
File capability READ
int renameat(int fromfd, char *from, int tofd, char *to);
12
13
root tmp .. tmp .. sandbox foo .. ..
sandbox
foo bar .. bar File descriptor array Process Root directory Current working directory
! !
Directory capability ATBASE, FCHDIR, FSTAT, CREATE, DELETE, LOOKUP...
!
14
root tmp .. tmp .. sandbox foo .. ..
sandbox
foo bar .. bar File descriptor array Process Root directory Current working directory
! !
Directory capability ATBASE, FCHDIR, FSTAT, CREATE, DELETE, LOOKUP...
!
Directory capability ATBASE, FCHDIR, FSTAT, CREATE, DELETE, LOOKUP...
!
15
16
17
18
19
20
21
root tmp .. tmp .. .. bar bar
renameat(foofd, "bar", sandboxfd, "bar");
..
!
tmp sandbox foo bar .. rename File descriptor array Process Root directory Current working directory
" "
Directory capability ATBASE, FCHDIR, FSTAT, CREATE, DELETE, LOOKUP...
"
Directory capability ATBASE, FCHDIR, FSTAT, CREATE, DELETE, LOOKUP...
"
22
23
24
25
26
27
28
Approach Performance Functionality Security Remove subtree delegation ✔ ✘ ✔ Namespace walk ✘ ✔ ✘ Limit namespace concurrency ✘ ✔ ✔ (NFS: ✘) Limit “..” ✔ ✘ ✔
29
30
31