38
Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1 , Eslam Elnikety 1 , Aastha Mehta 1 , Deepak Garg 1 , Peter Druschel 1 , Rodrigo Rodrigues 2 , Johannes Gehrke 3,4 , Ansley Post 5 1 MPI-SWS, 2 NOVA LINCS/Nova University of Lisbon, 3 Microsoft, 4 Cornell, 5 Google

Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

Embed Size (px)

Citation preview

Page 1: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

Guardat: Enforcing data policies at the storage layer

Anjo Vahldiek-Oberwagner1, Eslam Elnikety1, Aastha Mehta1, Deepak Garg1, Peter Druschel1,

Rodrigo Rodrigues2, Johannes Gehrke3,4, Ansley Post5

1MPI-SWS, 2NOVA LINCS/Nova University of Lisbon, 3Microsoft, 4Cornell, 5Google

Page 2: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

2

Web attacks and leaks

Page 3: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

3

httpd.conf .htaccess

Web Server

Content

Web Server State:

Operating SystemFile System users groups

Threat 1: Unauthorized Access

Clients Web Server Host

App

Unauthorized access due to configuration errors, bugs, attacks.

Page 4: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

4

Web Server

App

Threat 2: State Corruption

Clients

Content

Web Server State:

Web Server Host

Operating SystemFile System

.htaccess

users groups

State corruption due to configuration errors, bugs, attacks.

httpd.conf

Page 5: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

5

Threat 3: Trojans & log manipulation

Clients Web Server Host

Web Server

App

Logs Executables

Web Server State:

Operating SystemFile System

Trojans & log manipulation due to attacks.

Page 6: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

6

Web Server

Content

Web Server State:

Operating SystemFile System

Threat 4: Unaccounted Provider Access

Clients Web Server Host

App

Providers bypass application access control protections.

Provider employee

Page 7: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

7

• Confidentiality and integrity depend on large, fast evolving code base.

• Access control lists and access checks spread across system.

• Recovering corrupt persistent state is difficult.

Why is mitigation difficult?

Page 8: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

8

Per file policyFile attestation

GuardatStorageLayer

Stakeholder: User, provider, developer, privacy officer

Guardat: Storage Layer Compliance

Trusted Controller

Application

OSFile System

UNTR

USTE

D

Page 9: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

9

Outline

Declarative Policies

Enforcement File Attestation

GuardatTransaction

Implementation & Evaluation

Design Principles

1

2

Page 10: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

10

Policy language in a nutshell

Goals::• High level policy• Concise

• Easy to audit • Efficient enforcement

permission:- Boolean expression over predicates

read :- When to read a fileupdate :- When to update the filesetPolicy :- When to change policydestroy :- When to reuse the name

Page 11: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

11

Protecting files from unauthorized access

read :- sessionIs(Alice)update :- …setPolicy :- sessionIs(Alice)destroy :- sessionIs(Alice)

Assumption: Integrity of Alice’s key is maintainedGuarantee: Protected files may only be read with an authenticated

session.

Threat: Unauthorized access due to configuration error, bug or attack.

Private files:

Page 12: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

12

Protecting files from corruption

read :- …update :- sessionIs(Alice)setPolicy :- …destroy :- …

Assumption: Integrity of Alice’s key is maintained.Guarantee: Protected files may only be updated within an authenticated

session.

Threat: State corruption due to configuration error, bug or attack.

Private files:

Page 13: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

13

Protecting executables

read :- TRUEupdate :- fileNameIs(F) fileNewLenIs(L) ∧ (0, L) willHaveHash Nh ∧ keyIs(K, “Vendor”) ∧ ∧ K signs okHash(F, N, Nh) setPolicy:- FALSE

Assumption: Integrity of the vendor’s key is maintained.Guarantee: Protected files cannot be overwritten except with content signed by the vendor.

Threat: Attack installing a trojan.

Signed updates-only executables:

Page 14: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

14

Protecting log files from manipulation

read :- TRUEupdate :- [ fileCurrLenIs(Lc) fileNewLenIs(Ln) Ln ≥ Lc ∧ ∧ txUpdatedExAre(M)∧ listsAreDisjoint(M, [0, Lc])]∧ [sessionIs(Admin)]∨setPolicy :- FALSEdestroy :- FALSE

Assumption: Administrator key integrityGuarantee: Protected files cannot be overwritten, only appended.

Threat: Attack manipulating logs. Append-only log files:

Page 15: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

15

Protecting content from unaccounted provider access

read: - ((“profil”, SEQCNTLOC, _) says seqcnt(currseq)) ^ ((“acclog”, _, _) says read(currseq, _, offset, length)) ^ AccessOffIs(offset) ^ AccessLenIs(length)update:- ((“profil”, SEQCNTLOC, _) says seqcnt(currseq)) ^ ((“profil”, SEQCNTLOC, _) willSay seqcnt(nextseq)) ^ EQ(currseq + 1, nextseq) ^ ((“acclog”, gennb, _, _) says write(nextseq, _, newhash, offsetlist)) ^ ((offsetlist) willHaveHash newhash) ^ TxUpdateLocAre(offsetlist)setpolicy: FALSEdestroy: FALSE

Read :- TRUEupdate: [ FileCurrExAre(oe) ̂ FileNewExAre(ne) ̂ isPrefix(oe, ne) ̂ ((“acclog”, neo, _) willSay _(nseq, _. _. _)) ̂ ((“acclog”, neo - READENTRYLENGTH, _) says _(nseq-1, _, _, _)) ̂ FileCurrLenIs(currlen) ̂ LT(currlen, neo)] [FileCurrExAre(oe) ̂ FileNewExAre(ne) ̂ ∨ isPrefix(oe, ne) ̂ ((“acclog”, neo, _) willSays _(nseq, _. _. _)) ̂ ((“acclog”, gennb, neo - WRITEENTRYLENGTH, _) says _(nseq-1, _, _, _)) ̂ FileCurrLenIs(currlen) ̂ LT(currlen, neo) ] ∨ [ ((“acclog”, neo, nel) willSay write(nseq, _, _, _)) ̂ ((“acclog”,,neo, nel) says write(nseq, _, _, _) ̂ ((“profil”, gennb, SEQCNTLOC, _) says seqcnt(currseq)) ̂ LT(currseq, nseq) ̂ TxUpdateLocAre((neo, nel))]setpolicy:- FALSEdestroy:- FALSE

Assumption: Auditor key integrityGuarantee: Protected files cannot be accessed without corresponding log entry in the access log.

Threat: Provider accesses are not accounted for.

Private files accounting for provider access:

Log file with log entry check and append-only:

Page 16: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

16

Outline

Declarative Policies

Enforcement File Attestation

GuardatTransaction

Implementation & Evaluation

Design Principles

1

2

Page 17: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

17

Storage Layer Enforcement

Web Server

Host

App

Operating SystemFile System

VMM

Library

OS abstractionFile System

Virtual device

Storage controller Decrease risk of circumvention

Storage Layer

DiskDiskDisk

Page 18: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

18

Storage Layer Enforcement

Web Server

Host

App

Operating SystemFile System

VMM

Physically protected Machine Room

NetworkUN

TRUS

TED

UNTR

USTE

D

Storage Area Network Server

DiskDiskDiskDiskDiskDisk

Page 19: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

19

Outline

Declarative Policies

Enforcement File Attestation

GuardatTransaction

Implementation & Evaluation

Design Principles

1

2

Page 20: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

20

Per file policy

GuardatStorageLayer

Trusted Controller

Data Disk

Attests:• File name• Policy• State• Content

NVM

Application

OSFile SystemUN

TRUS

TED

File Attestation: Bridging gap between file and block level enforcement

Stakeholder: User, provider, developer, policy officer

Metadata:

Page 21: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

21

Outline

Declarative Policies

Enforcement File Attestation

GuardatTransaction

Implementation & Evaluation

Design Principles

1

2

Page 22: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

22

• Atomic update of file• Bundle multiple accesses• Delays evaluation to commit operation• Transaction caches

Introducing Guardat Transactions

1

2

Page 23: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

23

GuardatDevice

Trusted ControllerTransaction cache

Guardat Transaction by Example

Application

OSFile System

Metadata:

UNTR

USTE

D

N#

N#

N#

Shifting burden of proving complex policy compliance to untrusted code keeping policies concise and policy evaluation efficient.

Demonstrate policy compliance:1. Download binary + certificate2. Begin transaction tx (+ certificate)3. Write new binary4. Commit transaction tx`

Page 24: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

24

Outline

Declarative Policies

Enforcement File Attestation

GuardatTransaction

Implementation & Evaluation

Design Principles

1

2

Page 25: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

25

ImplementationAlternatives:1. Hybrid Disk/RAID controller2. Microcontroller on SCSI/SATA adapter 3. VMM4. Storage area Network (SAN)Trusted controller in iSCSI Enterprise Target (IET) server

Guardat IETserver

Trusted Controller(~ 20,000 LoC)

Metadata(SSD)

Data Disk(HDD/SSD)

Network

Page 26: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

SSD Throughput overhead: < 2%• 3.8 Million files• 40,000 policies

Seq. read Seq. write0

100200300400500600

iSCSIGuardat

Access type

Throughput in MB/S

Better

Page 27: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

512B Access LatencyHDD latency overhead: < 1%

SSD latency overhead

Random Sequential Random Sequential0

0.10.20.3

iSCSIGuardat

Random Sequential Random Sequential0.1

1

10

iSCSIGuardat

Latency in ms (log)

Latency in ms

Reads Writes

Reads Writes

Better

Better

Page 28: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

28

Protection:• Append-only logs• Vendor-only update

executables• Owner-only update

to content pages

Scenario:• Modified Apache (added 51 Lines of code)• Hosting 220 GB English Wikipedia (~15M files)• Replay an hourly access distribution of Wikipedia

Protected Apache Web server

600

50100150200250

iSCSIGuardat

Concurrent HTTP Clients

Requests/s

2% overhead at peak throughput.

Better

Page 29: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

29

Conclusions• Guardat guarantees confidentiality and integrity of

persistent data and state of a system.

• No need to trust higher software layers.

• Guardat protects computer systems from unauthorized access, trojans and log manipulations.

• Efficient prototype implementation in SAN server.

Page 30: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

30

Anjo [email protected]

Guardat: Enforcing data policies at the storage layer

Eslam Elnikety

Aastha Mehta

Peter Druschel

Rodrigo Rodrigues

Page 31: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

31

Backup slides

Backup slides

Page 32: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

32

Guardat: Related work• TCG storage work group spec [2012]

– Architecture for sessions, access control policies– Concrete design, evaluation left to vendors– No object attestation

• TC: Semantic attestation [Haldar 2004], Excalibur [Santos 2012], Pasture [Kotla 2012]

• Integrity/confidentiality: self-encrypting disks, capability NAS [Aguilera 2003], type-safe disks [Sivathanu 2006], Venti [Quinlan 2002], S4 [Strunk 2000], NetApp SnapVault, PCFS[Garg 2010], PFS[Walsh 2012]

• Extended disk functionality: hybrid disks, object-based storage [Mesnier 2003], active disks [Riedel 2001], semantically smart disks [Sivathanu 2003], differentiated storage [Mesnier 2011]

• VMM/OS data protection: Overshadow [Chen 2008], InkTag [Hofmann 2013], Nexus [Sirer 2011], DCAC [Xu 2014]

Page 33: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

33

Related work: Trusted Computing

Mostly complementary; can be combined, e.g.,• Remotely attested external verifier• Tamper-resident persistent storage

Property Trusted computing Guardat

Root of trust TPM TGCAuthenticates Motherboard Guardat device

Certifies HW/SW configuration(remote attestation)

Object state + policy(object attestation)

Storage propertyprovided

Confidentiality +Read integrity

Confidentiality + Write integrity

Properties expressed in Trusted software Policy languageTCB TPM + trusted SW TGC (narrow API)Persistent secure state NVRAM Entire storage device

Page 34: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

34

Threats to persistent data

• Storage media failure (deterioration, obsolescence)• Natural disasters and physical attack• Operator error and negligence• Software/hardware bugs• Cyber attack and sabotage

Problem is real: Among most frequent causes of loss• Human error is (close) second to device failure• Software errors + viruses third

This talk

Page 35: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

35

Discussion: Enforcement layer

Page 36: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

36

Legacy FS

Page 37: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

37

Transaction API

Page 38: Guardat: Enforcing data policies at the storage layer Anjo Vahldiek-Oberwagner 1, Eslam Elnikety 1, Aastha Mehta 1, Deepak Garg 1, Peter Druschel 1, Rodrigo

38

Stateful policies