Computer Science 161 Fall 2016 Popa and Weaver
Lecture #4: OS Security Concepts
1
Lecture #4: OS Security Concepts 1 Administrivia Computer - - PowerPoint PPT Presentation
Computer Science 161 Fall 2016 Popa and Weaver Lecture #4: OS Security Concepts 1 Administrivia Computer Science 161 Fall 2016 Popa and Weaver Project 1 is out now Start now: Dont wait for the last minute 2 Access Control
Computer Science 161 Fall 2016 Popa and Weaver
1
Computer Science 161 Fall 2016 Popa and Weaver
2
Computer Science 161 Fall 2016 Popa and Weaver
is forbidden from accessing something
3
Computer Science 161 Fall 2016 Popa and Weaver
(something who is accessing resources)
(a resource that can be accessed)
if subject S is allowed to access object O
if subject S is forbidden to access object O
deny)
4
Knows Secret # 123456
Computer Science 161 Fall 2016 Popa and Weaver
5
Computer Science 161 Fall 2016 Popa and Weaver
6
Alice’s wall Bob’s wall Charlie’s wall … Alice true true false Bob false true false …
Computer Science 161 Fall 2016 Popa and Weaver
7
/cs161/grades/alice nweaver read, write alice read bob
Computer Science 161 Fall 2016 Popa and Weaver
database
8
Computer Science 161 Fall 2016 Popa and Weaver
9
My Luggage Combination is #12345
Computer Science 161 Fall 2016 Popa and Weaver
If both “factors” are something you know, its not two-factor!
The second factor is bound to the site: A phishing link can not use the second factor
10
Computer Science 161 Fall 2016 Popa and Weaver
Make sure your phone requires ID in person to change Make sure your master email is well secured
11
Computer Science 161 Fall 2016 Popa and Weaver
12
Computer Science 161 Fall 2016 Popa and Weaver
13
(code)
/login.php
(code)
/friends.php
(code)
/search.php
(code)
/viewwall.php . . . database controller
How should we implement access control policy?
Computer Science 161 Fall 2016 Popa and Weaver
14
(code)
/login.php
(code)
/friends.php
(code)
/search.php
(code)
/viewwall.php . . . database controller
access check access check access check
Record username. Check policy at each place in code that accesses data.
record username
Computer Science 161 Fall 2016 Popa and Weaver
15
(code)
/login.php
(code)
/friends.php
(code)
/search.php
(code)
/viewwall.php . . . database controller
record username access check
Record username. Database checks policy for each data access.
Computer Science 161 Fall 2016 Popa and Weaver
to forget a check (and app will work fine in normal usage, until someone tries to access something they shouldn’t)
16
Computer Science 161 Fall 2016 Popa and Weaver
group
17
Computer Science 161 Fall 2016 Popa and Weaver
group
18
Computer Science 161 Fall 2016 Popa and Weaver
permissions allowed or denied
about things
19
Computer Science 161 Fall 2016 Popa and Weaver
20
Computer Science 161 Fall 2016 Popa and Weaver
21
Computer Science 161 Fall 2016 Popa and Weaver
bypassed
22
Computer Science 161 Fall 2016 Popa and Weaver
23
subject reference monitor
Computer Science 161 Fall 2016 Popa and Weaver
24
Computer Science 161 Fall 2016 Popa and Weaver
25
VPN
V R W D tag PPN
physical address
PPN
virtual address
hit?
(VPN = virtual page number) (PPN = physical page number)
Computer Science 161 Fall 2016 Popa and Weaver
testing systems
26
Computer Science 161 Fall 2016 Popa and Weaver
kernel and filesystem drivers
the more code -> the more you have to trust -> the more bugs
27
Computer Science 161 Fall 2016 Popa and Weaver
monitor
…
28
Computer Science 161 Fall 2016 Popa and Weaver
weaker)
29
Computer Science 161 Fall 2016 Popa and Weaver
30
Computer Science 161 Fall 2016 Popa and Weaver
Enclave”
telling the device to accept a new reader using a key only Apple possess
31
Computer Science 161 Fall 2016 Popa and Weaver
data is inaccessible
32
Computer Science 161 Fall 2016 Popa and Weaver
requests to enable decryption of memory
key
33
Computer Science 161 Fall 2016 Popa and Weaver
Why does Apple do what they do? What would you do differently? What tradeoffs are involved?
34
Computer Science 161 Fall 2016 Popa and Weaver
35
Computer Science 161 Fall 2016 Popa and Weaver
36
Computer Science 161 Fall 2016 Popa and Weaver
Computing Base (TCB).
37
Computer Science 161 Fall 2016 Popa and Weaver
38
Web Browser Web Site Browser Kernel Rendering Engine
“Drive-by malware”: malicious web page exploits a browser bug to read/write local files or infect them with a virus
Trusted Computing Base
Computer Science 161 Fall 2016 Popa and Weaver
39
Goal: prevent “drive-by malware”, where a malicious web page exploits a browser bug to read/write local files
TCB (for this property)
Computer Science 161 Fall 2016 Popa and Weaver
40
700K lines of code 1000K lines of code 70% of vulnerabilities are in the rendering engine.
Example: PNG, WMF, GDI+ rendering vulnerabilities in Windows OS
Computer Science 161 Fall 2016 Popa and Weaver
escape from the sandbox to impact the program
41
Computer Science 161 Fall 2016 Popa and Weaver
before the action happens
42
Computer Science 161 Fall 2016 Popa and Weaver
write to a particular file
such as the /etc/sudoers file
43
if (!access_ok(file) abort();
write(file);
Computer Science 161 Fall 2016 Popa and Weaver
44