Transaction Processing on Confidential Data using Cipherbase - - PowerPoint PPT Presentation

transaction processing on
SMART_READER_LITE
LIVE PREVIEW

Transaction Processing on Confidential Data using Cipherbase - - PowerPoint PPT Presentation

Transaction Processing on Confidential Data using Cipherbase Arvind Arasu, Ken Eguro, Manas Joglekar* Raghav Kaushik, Donald Kossmann, Ravi Ramamurthy Microsoft Research Stanford University* Cloud Data Security Concerns Data in the cloud


slide-1
SLIDE 1

Transaction Processing on Confidential Data using Cipherbase

Arvind Arasu, Ken Eguro, Manas Joglekar* Raghav Kaushik, Donald Kossmann, Ravi Ramamurthy Microsoft Research Stanford University*

slide-2
SLIDE 2

Cloud Data Security Concerns

2

Data in the cloud vulnerable to:

  • Snooping administrators
  • Hackers with illegal access
  • Compromised servers

4/15/2015 ICDE 2015

slide-3
SLIDE 3

Database Encryption

3

Client App

4/15/2015 ICDE 2015

slide-4
SLIDE 4

Database Encryption

4

Client App

4/15/2015 ICDE 2015

slide-5
SLIDE 5

Cipherbase Summary

  • Data Confidentiality:

– Strong column-level encryption – Decoupled from functionality – *Lightweight “trusted module” in secure hardware

  • Functionality:

– Industrial Strength Database system (SQL Server) – Concurrency, Recovery, Stored Procedures.

  • Performance on TPCC

– 85% of plaintext for typical encryption – 40% of plaintext for “worst case” encryption

5

No prior work with this {Confidentiality, Functionality, Performance} characteristics

4/15/2015

ICDE 2015

slide-6
SLIDE 6

Organization

  • Introduction
  • Solution Landscape & Design Choices
  • Cipherbase Design & Engineering
  • Evaluation

6

4/15/2015

ICDE 2015

slide-7
SLIDE 7

What Makes Encryption Challenging?

7

Select Sum (Score) From Assignment Where StudentId = 1

a7be1a6997ad739bd8c9ca451f618b61 b6ff744ed2c2c9bf6c590cbf0469bf41 47f7f7bc95353e03f96c32bcfd8058df

𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒=1 𝑇𝑣𝑛 (𝑇𝑑𝑝𝑠𝑓) Assignment

4/15/2015 ICDE 2015

slide-8
SLIDE 8

Solution Landscape

  • Two fundamental techniques

– Directly compute over encrypted data

  • Special homomorphic encryption schemes
  • Challenge: limited class of computations

– Use a “secure” location

  • Computations on plaintext
  • Challenge: Expensive

8

4/15/2015

ICDE 2015

slide-9
SLIDE 9

Deterministic Encryption

9 Stud tudentId Assi signId Scor

  • re

1 1 68 1 2 71 3 4 99 … … …

select * from assignment where studentid = 1

𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒=1

4/15/2015 ICDE 2015

slide-10
SLIDE 10

Deterministic Encryption

10 Stud tudentId_DET Assi signId Scor

  • re

bd6e7c3df2b5779e0b61216e8b10b689 1 68 bd6e7c3df2b5779e0b61216e8b10b689 2 71 7ad5fda789ef4e272bca100b3d9ff59f 4 99 … … …

select * from assignment where studentid_det = bd6e7c3df2b5779e0b61216e8b10b689

𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒_𝑒𝑓𝑢=𝑐𝑒6…

4/15/2015 ICDE 2015

slide-11
SLIDE 11

Homomorphic Encryption Schemes

Fully Homomorphic Encryption Order-Preserving Encryption Deterministic Encryption Non-Deterministic Encryption Paillier Cryptosystem ElGamal Cryptosystem

(∅) (==) (≤) (+) (×)

(Any function)

11

[G09, G10] [P99] [E84] [BCN11, PLZ13]

Partial Homomorphic Encryption Partial Homomorphic Encryption (PHE)

4/15/2015 ICDE 2015

slide-12
SLIDE 12

PHE Limitations

  • Limited Server Functionality

– SUM(L_EXTENDEDPRICE*(1-L_DISCOUNT)*(1+L_TAX))

  • Data Security tied to functionality
  • Lack of Composability

– A + B = C

  • Performance

– ≈ msec for a single addition under Paillier

12

CryptDB [PRZ+11], Monomi [TFM 13], [HMH08]

4/15/2015

ICDE 2015

slide-13
SLIDE 13

Solution Landscape

  • Two fundamental techniques

– Directly compute over encrypted data

  • Special homomorphic encryption schemes
  • Challenge: limited class of computations
  • Challenge: Not composable

– Use a “secure” location

  • Hardware provisioned isolation and protection
  • Computations on plaintext
  • Challenge: Expensive

13

4/15/2015

ICDE 2015

slide-14
SLIDE 14

Secure Location

14

Inaccessible

4/15/2015 ICDE 2015

slide-15
SLIDE 15

Secure Hardware Landscape

  • Long history

– Banking, Defense Applications

  • Becoming mainstream and commoditized
  • Players:

– Crypto co-processors – FPGAs – Intel SGX – TPM, HSM

15

4/15/2015

ICDE 2015

slide-16
SLIDE 16

Intel Software Guard Extensions

  • Extensions to Intel Architecture
  • Isolation to code + data within a designated region

called enclave

– Confidentiality – Integrity

Virtual Addr Space Physical Memory

Enclave code/data

Encrypted & Integrity Protected Ack: Andrew Baumann

[MAB+ 13, AGJ+ 13, HLP+ 13]

16 4/15/2015 ICDE 2015

slide-17
SLIDE 17

Design Choice: Trusted Functionality

17

Expr Eval

Secure h/w

OS DBMS

Commodity h/w

TrustedDB [BS11] Cipherbase

Secure h/w

DBMS

Embedded OS

OS DBMS

Commodity h/w

Secure h/w

DBMS

Library OS

OS

Commodity h/w

Haven [MPH14] Larger Trusted Computing Base (TCB) Smaller TCB

4/15/2015 ICDE 2015

slide-18
SLIDE 18

Design Choice: Trusted Functionality

18

Expr Eval

Secure h/w

OS DBMS

Commodity h/w

TrustedDB [BS11] Cipherbase

Secure h/w

DBMS

Embedded OS

OS DBMS

Commodity h/w

Secure h/w

DBMS

Library OS

OS

Commodity h/w

Haven [MPH14] Less secure More secure

4/15/2015 ICDE 2015

slide-19
SLIDE 19

Design Choice: Trusted Functionality

19

Expr Eval

Secure h/w

OS DBMS

Commodity h/w

TrustedDB [BS11] Cipherbase

Secure h/w

DBMS

Embedded OS

OS DBMS

Commodity h/w

Secure h/w

DBMS

Library OS

OS

Commodity h/w

Haven [MPH14] Minimal software engg.

4/15/2015 ICDE 2015

slide-20
SLIDE 20

Organization

  • Introduction
  • Solution Landscape & Design Choices
  • Cipherbase Design & Engineering
  • Evaluation

20

4/15/2015

ICDE 2015

slide-21
SLIDE 21

Life of a Query in Cipherbase I

21

App

Cipherbase Client Lib

Encryption Config

Stack Machine (Expression Evaluation)

Insecure (x86)

FPGA

Cipherbase Server Modified SQL Server PCIe

AccountId: Plaintext BranchId: AES-CBC Balance: AES-CBC …

(stateless*)

push $1 decrypt push 10 add encrypt

  • ut

5

4/15/2015 ICDE 2015

slide-22
SLIDE 22

Life of a Query in Cipherbase II

22

App

Cipherbase Client Lib

Encryption Config

Stack Machine (Expression Evaluation)

Insecure (x86)

FPGA

Cipherbase Server Modified SQL Server PCIe

AccountId: AES-CBC BranchId: AES-CBC Balance: AES-CBC …

PK:

4/15/2015 ICDE 2015

slide-23
SLIDE 23

B+-Tree Indexes over Encrypted Data

23

6C2AB4 BF48BC DF60B9 20B9D4 AC2DB0 FC46B0 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E … … … … …

1 2 3 4 5 6 7 8 9 6

4/15/2015 ICDE 2015

slide-24
SLIDE 24

B+-Tree Indexes over Encrypted Data

24

6C2AB4 BF48BC DF60B9 20B9D4 AC2DB0 FC46B0 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E … … … … …

4/15/2015 ICDE 2015

slide-25
SLIDE 25

Life of a Query in Cipherbase II

25

App

Cipherbase Client Lib

Encryption Config

Stack Machine (Expression Evaluation)

Insecure (x86)

FPGA

Cipherbase Server Modified SQL Server PCIe

AccountId: AES-CBC BranchId: AES-CBC Balance: AES-CBC …

PK:

push $1 decr push $2 decr compare

  • ut

6

4/15/2015 ICDE 2015

slide-26
SLIDE 26

B+-Tree Indexes over Encrypted Data

26

6C2AB4 BF48BC DF60B9 20B9D4 AC2DB0 FC46B0 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E C9B7F9 1DA6B5 4F3618 … … … … … … …

8DE526

FPGA

0A183E

Search key: comp(8DE526,0A183E) <

4/15/2015 ICDE 2015

slide-27
SLIDE 27

B+-Tree Indexes over Encrypted Data

27

6C2AB4 BF48BC DF60B9 20B9D4 AC2DB0 FC46B0 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E C9B7F9 1DA6B5 4F3618 … … … … … … …

8DE526

FPGA

0A183E

Search key: comp(8DE526,0A183E) <

4/15/2015 ICDE 2015

slide-28
SLIDE 28

Life of a Query in Cipherbase II

28

App

Cipherbase Client Lib

Encryption Config

Stack Machine (Expression Evaluation)

Insecure (x86)

FPGA

Cipherbase Server Modified SQL Server PCIe

AccountId: AES-CBC BranchId: AES-CBC Balance: AES-CBC …

PK:

4/15/2015 ICDE 2015

slide-29
SLIDE 29

Operational Security

29 4/15/2015 ICDE 2015

Operation Adversary Learns 𝜏

𝐵=5(R)

Unknown predicate p(A) over R tuples 𝑆 ⋈𝐵 𝑇 (hash-based) The join graph and the equivalence relation

  • ver R(A) and S(A) for joining A values

𝜌𝐵+𝐶(𝑆) Nothing 𝐻𝑠𝑝𝑣𝑞𝑐𝑧𝐵

𝑇𝑉𝑁(𝐶) (𝑆)

The equivalence relation over R(A)

Data Security depends on the operations performed

slide-30
SLIDE 30

Transaction Processing Performance Challenges

30

x86 FPGA

Life of a transaction

parsing, compilation, buffering, latching, locking, commit, … Expression evaluation 1M instrs ≈ 10 instrs x 300 TPCC New Order: Time/progress ≈ 𝜈sec

4/15/2015 ICDE 2015

slide-31
SLIDE 31

Summary of Performance Optimizations

31

Core 1 Core 2 Core 3 Core 4 Plaintext Data Cache

Batch FPGA work

Amortize communication latency

Multiple FPGA cores

Parallelism More FPGA compute

Plaintext Data Caches

Minimize network comm. Reduce decryption

Modified SQL Server Vectorize index comparisons

Minimize FPGA roundtrips

Cipherbase Client Lib

Expression folding

Minimize FPGA roundtrips

4/15/2015 ICDE 2015

slide-32
SLIDE 32

Organization

  • Introduction
  • Solution Landscape & Design Choices
  • Cipherbase Design & Engineering
  • Evaluation

32

4/15/2015

ICDE 2015

slide-33
SLIDE 33

Cipherbase Prototype

  • SQL Server code

– Basic functionality

  • ≈ 1000 LoC
  • Localized to expression evaluation module

– Optimizations

  • ≈ 5000-10000 LoC
  • Localized to FPGA driver, indexing

– Unchanged: everything else

33

4/15/2015

ICDE 2015

slide-34
SLIDE 34

Performance on TPCC

34

0.2 0.4 0.6 0.8 1 1.2 Plaintext Customer Strong/Weak Strong/Strong Opt NoOpt

Transactions per sec (relative to SQL Server) Encryption schemes: Customer: Customer PII data strongly encrypted Strong/Weak: Index columns deterministic, all

  • thers strongly encrypted

Strong/Strong: All columns strongly encrypted Increasing strength of encryption

4/15/2015 ICDE 2015

slide-35
SLIDE 35

Cipherbase Summary

  • Security:

– Strong encryption – Decoupled from functionality

  • Functionality:

– Industrial Strength Database system (SQL Server) – Transaction Processing

  • Performance on TPCC

– 85% of plaintext for typical encryption – 40% of plaintext for “worst case” encryption

  • Lightweight “trusted module” in secure hardware

35

4/15/2015

ICDE 2015

slide-36
SLIDE 36

36

http://research.microsoft.com/en-us/projects/cipherbase/

4/15/2015 ICDE 2015