Transaction Processing on Confidential Data using Cipherbase
Arvind Arasu, Ken Eguro, Manas Joglekar* Raghav Kaushik, Donald Kossmann, Ravi Ramamurthy Microsoft Research Stanford University*
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
Arvind Arasu, Ken Eguro, Manas Joglekar* Raghav Kaushik, Donald Kossmann, Ravi Ramamurthy Microsoft Research Stanford University*
2
Data in the cloud vulnerable to:
4/15/2015 ICDE 2015
3
Client App
4/15/2015 ICDE 2015
4
Client App
4/15/2015 ICDE 2015
– Strong column-level encryption – Decoupled from functionality – *Lightweight “trusted module” in secure hardware
– Industrial Strength Database system (SQL Server) – Concurrency, Recovery, Stored Procedures.
– 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
6
4/15/2015
ICDE 2015
7
Select Sum (Score) From Assignment Where StudentId = 1
a7be1a6997ad739bd8c9ca451f618b61 b6ff744ed2c2c9bf6c590cbf0469bf41 47f7f7bc95353e03f96c32bcfd8058df
𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒=1 𝑇𝑣𝑛 (𝑇𝑑𝑝𝑠𝑓) Assignment
4/15/2015 ICDE 2015
8
4/15/2015
ICDE 2015
9 Stud tudentId Assi signId Scor
1 1 68 1 2 71 3 4 99 … … …
select * from assignment where studentid = 1
𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒=1
4/15/2015 ICDE 2015
10 Stud tudentId_DET Assi signId Scor
bd6e7c3df2b5779e0b61216e8b10b689 1 68 bd6e7c3df2b5779e0b61216e8b10b689 2 71 7ad5fda789ef4e272bca100b3d9ff59f 4 99 … … …
select * from assignment where studentid_det = bd6e7c3df2b5779e0b61216e8b10b689
𝜏𝑇𝑢𝑣𝑒𝑓𝑜𝑢𝐽𝑒_𝑒𝑓𝑢=𝑐𝑒6…
4/15/2015 ICDE 2015
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
– SUM(L_EXTENDEDPRICE*(1-L_DISCOUNT)*(1+L_TAX))
– A + B = C
– ≈ msec for a single addition under Paillier
12
CryptDB [PRZ+11], Monomi [TFM 13], [HMH08]
4/15/2015
ICDE 2015
– Directly compute over encrypted data
– Use a “secure” location
13
4/15/2015
ICDE 2015
14
Inaccessible
4/15/2015 ICDE 2015
– Banking, Defense Applications
– Crypto co-processors – FPGAs – Intel SGX – TPM, HSM
15
4/15/2015
ICDE 2015
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
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
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
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
20
4/15/2015
ICDE 2015
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
5
4/15/2015 ICDE 2015
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
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
24
6C2AB4 BF48BC DF60B9 20B9D4 AC2DB0 FC46B0 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E C9B7F9 1DA6B5 4F3618 … … 0A183E … … … … …
4/15/2015 ICDE 2015
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
6
4/15/2015 ICDE 2015
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
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
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
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
𝜌𝐵+𝐶(𝑆) Nothing 𝐻𝑠𝑝𝑣𝑞𝑐𝑧𝐵
𝑇𝑉𝑁(𝐶) (𝑆)
The equivalence relation over R(A)
Data Security depends on the operations performed
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
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
32
4/15/2015
ICDE 2015
– Basic functionality
– Optimizations
– Unchanged: everything else
33
4/15/2015
ICDE 2015
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
Strong/Strong: All columns strongly encrypted Increasing strength of encryption
4/15/2015 ICDE 2015
– Strong encryption – Decoupled from functionality
– Industrial Strength Database system (SQL Server) – Transaction Processing
– 85% of plaintext for typical encryption – 40% of plaintext for “worst case” encryption
35
4/15/2015
ICDE 2015
36
4/15/2015 ICDE 2015