A First Step Towards Leveraging Commodity Trusted Execu;on - - PowerPoint PPT Presentation

a first step towards leveraging commodity trusted execu
SMART_READER_LITE
LIVE PREVIEW

A First Step Towards Leveraging Commodity Trusted Execu;on - - PowerPoint PPT Presentation

A First Step Towards Leveraging Commodity Trusted Execu;on Environments for Network Applica;ons Seongmin Kim Youjung Shin Jaehyung Ha


slide-1
SLIDE 1

A ¡First ¡Step ¡Towards ¡Leveraging ¡ Commodity ¡Trusted ¡Execu;on ¡ Environments ¡for ¡Network ¡Applica;ons ¡

Seongmin ¡Kim ¡ ¡ ¡ ¡Youjung ¡Shin ¡ ¡ ¡ ¡ ¡Jaehyung ¡Ha ¡ ¡ Taesoo ¡Kim* ¡ ¡ ¡ ¡ ¡Dongsu ¡Han ¡ ¡

¡

¡KAIST ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡* ¡Georgia ¡Tech ¡

1 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-2
SLIDE 2

Trend ¡1: ¡Security ¡and ¡Privacy ¡ Cri;cal ¡Factors ¡in ¡Technology ¡Adop;on ¡

  • Demands ¡for ¡“security” ¡and ¡“privacy” ¡are ¡increasing ¡

– Widespread ¡use ¡of ¡Transport ¡Layer ¡Security ¡(TLS) ¡ – Popularity ¡of ¡anonymity ¡networks ¡(e.g., ¡Tor) ¡ – Use ¡of ¡strong ¡authenRcaRon/encrypRon ¡in ¡WiFi ¡

  • ExpectaRon ¡on ¡security ¡and ¡privacy ¡impacts ¡design ¡

decisions: ¡

– OperaRng ¡system ¡(iOS, ¡Android) ¡ – Apps/services ¡(e.g., ¡messenger, ¡adblocker) ¡ – Network ¡infrastructure ¡(inter-­‑domain ¡SDN) ¡

2 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-3
SLIDE 3
  • Demands ¡for ¡“security” ¡and ¡“privacy” ¡are ¡increasing ¡

– Widespread ¡use ¡of ¡Transport ¡Layer ¡Security ¡(TLS) ¡ – Popularity ¡of ¡anonymity ¡networks ¡(e.g., ¡Tor) ¡ – Use ¡of ¡strong ¡authenRcaRon/encrypRon ¡in ¡WiFi ¡

  • ExpectaRon ¡on ¡security ¡and ¡privacy ¡impacts ¡design ¡

decisions: ¡

– OperaRng ¡system ¡(iOS, ¡Android) ¡ – Apps/services ¡(e.g., ¡messenger, ¡adblocker) ¡ – Network ¡infrastructure ¡(inter-­‑domain ¡SDN) ¡

Trend ¡1: ¡Security ¡and ¡Privacy ¡ Cri;cal ¡Factors ¡in ¡Technology ¡Adop;on ¡

3 ¡

slide-4
SLIDE 4

Trend ¡2: ¡Commodi;za;on ¡of ¡ ¡ Trusted ¡Execu;on ¡Environment ¡

  • Trusted ¡ExecuRon ¡Environment ¡(TEE) ¡

– Isolated ¡execuRon: ¡integrity ¡of ¡code, ¡confidenRality ¡ ¡ – Remote ¡a^estaRon ¡

  • CommodiRzaRon ¡of ¡TEE ¡

– Trusted ¡Plaaorm ¡Module ¡(TPM) ¡: ¡Slow ¡performance ¡ – ARM ¡TrustZone ¡: ¡Only ¡available ¡for ¡embedded ¡devices ¡ – Intel ¡Sodware ¡Guard ¡Extension ¡(SGX) ¡ ¡ ¡ ¡ ¡ ¡ ¡1. ¡NaRve ¡performance ¡ ¡ ¡ ¡ ¡ ¡ ¡2. ¡CompaRbility ¡with ¡x86 ¡

4 ¡

The commoditization of TEE brings new

  • pportunities for network applications.

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-5
SLIDE 5

Network ¡Applica;ons ¡+ ¡TEE ¡= ¡? ¡

  • What ¡impact ¡does ¡TEE ¡have ¡on ¡networking? ¡
  • Previous ¡efforts: ¡AdopRng ¡TEE ¡to ¡cloud ¡plaaorm ¡

– Haven ¡[OSDI’14] ¡: ¡Protects ¡applicaRons ¡from ¡an ¡untrusted ¡cloud ¡ – VC3 ¡[S&P’15] ¡: ¡Trustworthy ¡data ¡analyRcs ¡in ¡the ¡cloud ¡

5 ¡

Network ¡ Applica;ons

TEE

Intel ¡SGX Enhanced ¡security ¡ New ¡design ¡space ¡ New ¡func;onality ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-6
SLIDE 6

SGX ¡: ¡Isolated ¡Execu;on ¡

  • ApplicaRon ¡keeps ¡its ¡data/code ¡inside ¡the ¡“enclave” ¡

– Smallest ¡a^ack ¡surface ¡by ¡reducing ¡TCB ¡(App ¡+ ¡processor) ¡ – Protect ¡app’s ¡secret ¡from ¡untrusted ¡privilege ¡sodware ¡(e.g., ¡ OS, ¡VMM) ¡

6 ¡

CPU ¡Package System ¡Memory Enclave ¡ ¡ ¡ ¡ Memory ¡ EncrypRon ¡ Engine ¡(MEE) ¡ Snooping ¡ Access ¡from ¡ ¡ OS/VMM ¡

Encrypted ¡ code/data ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-7
SLIDE 7

SGX ¡: ¡Remote ¡AQesta;on ¡

  • A^est ¡an ¡applicaRon ¡on ¡remote ¡plaaorm ¡
  • Check ¡the ¡idenRty ¡of ¡enclave ¡(hash ¡of ¡code/data ¡

pages) ¡

  • Can ¡establish ¡a ¡“secure ¡channel” ¡between ¡enclaves ¡ ¡

7 ¡

Target ¡ Enclave

Quo;ng ¡ Enclave Challenger ¡ Enclave SGX ¡CPU

Host ¡plaaorm ¡ Remote ¡plaaorm ¡

SGX ¡CPU

  • 1. ¡Request ¡
  • 2. ¡Calculate ¡ ¡

¡ ¡ ¡ ¡MAC ¡

  • 3. ¡Send ¡MAC ¡
  • 6. ¡Send ¡signature ¡

CMAC Hash ¡

  • 4. ¡Verify ¡
  • 5. ¡Sign ¡with ¡group ¡key ¡[EPID]

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-8
SLIDE 8

Case ¡Studies: ¡Three ¡Applica;ons ¡

  • 1. Network ¡infrastructure: ¡Sodware-­‑defined ¡inter-­‑

domain ¡rouRng ¡

  • 2. Peer-­‑to-­‑peer ¡systems: ¡Tor ¡anonymity ¡network ¡
  • 3. Middlebox: ¡TLS ¡and ¡“secure” ¡middleboxes ¡ ¡

8 ¡

Network ¡ Applica;ons

TEE

Intel ¡SGX Enhanced ¡security ¡ New ¡design ¡space ¡ New ¡func;onality ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-9
SLIDE 9

SDN-­‑based ¡Inter-­‑domain ¡Rou;ng ¡

  • Offers ¡new ¡properRes ¡ ¡

– Fast ¡convergence, ¡applicaRon-­‑specific ¡peering, ¡ flexibility, ¡what-­‑if ¡analysis ¡[hotnets2011] ¡

  • Reveals ¡private ¡informaRon: ¡topology ¡and ¡policy ¡

AS ¡A AS ¡C AS ¡D AS ¡B

9 ¡

Inter-­‑domain ¡ Controller

1) ¡Topology ¡ 2) ¡Policies ¡ ¡(e.g., ¡export ¡policy) ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-10
SLIDE 10

AS ¡A

SDN-­‑based ¡Inter-­‑domain ¡Rou;ng ¡

AS ¡C AS ¡D AS ¡B Inter-­‑domain ¡ Controllers

10 ¡

Prior ¡work ¡[hotnets2011] ¡uses ¡Secure ¡MulR-­‑Party ¡ ComputaRon ¡(SMPC) ¡to ¡solve ¡this, ¡but ¡the ¡ computaRonal ¡complexity ¡is ¡prohibiRve. ¡ ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-11
SLIDE 11

SDN-­‑based ¡Inter-­‑domain ¡Rou;ng ¡

Inter-­‑domain ¡ Controller

AS ¡A ¡

AS-­‑local ¡ Controller

Router

SDN ¡ Switch

AS ¡B ¡

AS-­‑local ¡ Controller

11 ¡

Enclave Enclave Enclave

  • Enclose ¡private ¡informaRon ¡inside ¡the ¡enclave ¡
  • CommunicaRon ¡through ¡a ¡secure ¡channel ¡ader ¡

a^estaRon ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-12
SLIDE 12

SDN-­‑based ¡Inter-­‑domain ¡Rou;ng ¡

Inter-­‑domain ¡ Controller

AS ¡A ¡

AS-­‑local ¡ Controller

Router

SDN ¡ Switch

AS ¡B ¡

AS-­‑local ¡ Controller

12 ¡

ASes ¡agree ¡upon ¡a ¡common ¡code ¡base. ¡ Makes ¡sure ¡that ¡it ¡does ¡not ¡leak ¡private ¡informaRon ¡[Moat]. ¡ It ¡becomes ¡the ¡TCB ¡of ¡the ¡inter-­‑domain ¡rouRng ¡infrastructure. ¡ ¡

Enclave Enclave Enclave

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-13
SLIDE 13

SDN-­‑based ¡Inter-­‑domain ¡Rou;ng ¡

Inter-­‑domain ¡ Controller

AS ¡A ¡

AS-­‑local ¡ Controller

Router

SDN ¡ Switch

AS ¡B ¡

AS-­‑local ¡ Controller

  • 1. ¡Mutually ¡aQest/authen;cate ¡using ¡remote ¡aQesta;on ¡
  • 2. ¡Collect ¡policy ¡and ¡topology ¡through ¡a ¡secure ¡channel ¡
  • 3. ¡Main ¡controller ¡computes ¡rou;ng ¡path ¡
  • 4. ¡Sends ¡routes ¡for ¡each ¡AS ¡through ¡a ¡secure ¡channel ¡

13 ¡

Agreed ¡upon ¡code Enclave Enclave Enclave

AQesta;on Collect ¡info Send ¡routes

slide-14
SLIDE 14

Extending ¡Features: ¡Policy ¡verifica;on ¡

  • Enabling ¡verificaRon ¡on ¡rouRng ¡decisions ¡ ¡

– Want ¡to ¡verify ¡whether ¡the ¡promise ¡is ¡being ¡kept ¡[SPIDeR] ¡

AS ¡A AS ¡C AS ¡D AS ¡B

14 ¡

I will give you my shortest route to Google! [SPIDeR]

Inter-­‑domain ¡ Controller

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-15
SLIDE 15

Extending ¡Features: ¡Policy ¡verifica;on ¡

  • Enabling ¡verificaRon ¡on ¡rouRng ¡decisions ¡ ¡

– Want ¡to ¡verify ¡whether ¡the ¡promise ¡is ¡being ¡kept ¡[SPIDeR] ¡

AS ¡A AS ¡C AS ¡D AS ¡B Inter-­‑domain ¡ Controller

15 ¡

I will give you my shortest route to Google! [SPIDeR] Predicate ¡ Predicate

Enclave

  • Verify only the predicates

agreed upon by A and B Among ¡all ¡routes ¡to ¡Google ¡ from ¡B, ¡is ¡the ¡one ¡B ¡ adver;sing ¡to ¡A ¡the ¡ shortest?

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-16
SLIDE 16

Tor: ¡Anonymity ¡Network ¡

  • Tor ¡network ¡: ¡uses ¡3-­‑hop ¡onion ¡rouRng ¡

– Directory ¡servers ¡: ¡AdverRse ¡available ¡onion ¡routers ¡(ORs), ¡ vote ¡for ¡bad ¡exit ¡nodes ¡ – Relies ¡on ¡volunteer ¡provided ¡hosts ¡

Entry Relay Exit

When ¡exit ¡node ¡is ¡compromised, ¡ (unless ¡end-­‑to-­‑end ¡encryp;on ¡is ¡used) ¡

  • 1. Snooping ¡or ¡tampering ¡of ¡the ¡plain-­‑text ¡
  • 2. Break ¡of ¡anonymity ¡: ¡Bad ¡apple ¡aQack ¡

16 ¡

Directory ¡servers Tor ¡client Des;na;on

Tor ¡network

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-17
SLIDE 17

Tor: ¡Anonymity ¡Network ¡

  • Tor ¡network ¡: ¡uses ¡3-­‑hop ¡onion ¡rouRng ¡

– Directory ¡servers ¡: ¡AdverRse ¡available ¡onion ¡routers, ¡vote ¡ for ¡bad ¡exit ¡nodes ¡ – Relies ¡on ¡volunteer ¡provided ¡hosts ¡ Directory ¡servers Tor ¡client Des;na;on

Entry Relay Exit

When ¡directory ¡servers ¡are ¡compromised, ¡

  • 1. Tie-­‑breaking ¡aQacks ¡while ¡vo;ng ¡
  • 2. Admission ¡of ¡malicious ¡ORs ¡

17 ¡

Tor ¡network

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-18
SLIDE 18

Tor ¡network

Applica;on ¡of ¡TEE ¡to ¡Tor ¡

1) ¡SGX-­‑enabled ¡directory ¡servers 2) ¡SGX-­‑enabled ¡directory ¡servers ¡& ¡ORs

18 ¡

Directory ¡servers Tor ¡client Des;na;on

Entry Relay Exit

Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡

Remote ¡aQesta;on

  • ­‑ ¡Detect ¡problemaRc ¡exit ¡nodes ¡ ¡

¡ ¡through ¡integrity ¡check ¡

  • ­‑ ¡Keep ¡sensiRve ¡data ¡in ¡enclave ¡

1) Authority ¡keys ¡ 2) List ¡of ¡available ¡ORs ¡

  • ­‑ ¡Integrity ¡check ¡each ¡other ¡
  • ­‑ ¡AutomaRc ¡admission ¡of ¡new ¡ORs

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-19
SLIDE 19

Applica;on ¡of ¡TEE ¡to ¡Tor ¡

1) ¡SGX-­‑enabled ¡directory ¡servers 2) ¡SGX-­‑enabled ¡directory ¡servers ¡& ¡ORs 3) ¡Fully ¡SGX-­‑enabled ¡secng

Remote ¡aQesta;on

19 ¡

Tor ¡client Des;na;on

Entry Relay Exit

Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡ Enclave ¡ ¡ ¡

à à ¡Eliminate ¡directory ¡servers ¡altogether

Tor ¡network

Each ¡Tor ¡components ¡can ¡check ¡the ¡integrity ¡of ¡ target ¡program ¡(Tor ¡binary) ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-20
SLIDE 20

Implementa;on

  • OpenSGX ¡[NDSS’16] ¡: ¡Open ¡source ¡SGX ¡emulator ¡

– Fully ¡funcRonal, ¡instrucRon-­‑compaRble ¡emulator ¡of ¡SGX ¡ build ¡on ¡top ¡of ¡QEMU ¡ – Emulates ¡system ¡sodware ¡and ¡provide ¡SGX ¡libraries ¡

20 ¡

SGX ¡OS ¡Emula;on ¡ QEMU ¡SGX ¡ ¡ ¡ ¡ ¡

Code Data Stack

Enclave ¡Program User ¡process ¡(single ¡address ¡space)

SGX ¡System ¡call ¡ SGX ¡instrucRon ¡ Enclave ¡ ¡ mode ¡switch

Package ¡Info ¡ (Key, ¡Entry ¡point) SGX ¡Libraries

Trampoline

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-21
SLIDE 21

Preliminary ¡Evalua;on: ¡Overhead ¡

  • EsRmate ¡the ¡overhead ¡in ¡terms ¡of ¡addiRonal ¡CPU ¡cycles ¡

– Each ¡SGX ¡instruc/on ¡= ¡10 ¡k ¡cycles ¡[Haven] ¡ <Cost ¡of ¡remote ¡aQesta;on>

21 ¡

0 ¡ 5 ¡ 10 ¡

Target ¡ QuoRng ¡ Challenger ¡

without ¡DH ¡ with ¡DH ¡

CPU ¡Cycles ¡(B) Cost ¡of ¡remote ¡aQesta;on: ¡ 3% ¡of ¡1024-­‑bit ¡Diffie-­‑Hellman ¡ For ¡each ¡I/O ¡operaRons, ¡ ¡ ¡ ¡2 ¡Mode ¡switches ¡ ¡ ¡ ¡+ ¡SGX ¡library ¡calls ¡ <Cost ¡of ¡packet ¡transmission>

SGX ¡library Enclave

… ¡ send() ¡ ... ¡

User ¡space OS

Trampoline

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-22
SLIDE 22

SDN-­‑based ¡inter-­‑domain ¡rou;ng ¡

– 30 ¡ASes ¡with ¡the ¡centralized ¡inter-­‑domain ¡controller ¡ – Inter-­‑domain ¡controller ¡: ¡90% ¡more ¡CPU ¡cycles ¡ – AS-­‑local ¡controllers ¡: ¡70% ¡more ¡CPU ¡cycles ¡ ¡

<# ¡of ¡CPU ¡cycles ¡consumed ¡in ¡the ¡inter-­‑domain ¡controller>

22 ¡

0 ¡ 100 ¡ 200 ¡ 300 ¡

Without ¡SGX ¡ With ¡SGX ¡

(M)

CPU Cycles Number of participating ASes : 30

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-23
SLIDE 23

Conclusion ¡

  • CommodiRzaRon ¡of ¡TEE ¡brings ¡new ¡
  • pportuniRes ¡for ¡network ¡applicaRons ¡
  • Cases ¡studies ¡show ¡wide ¡range ¡of ¡impact: ¡

– Policy ¡privacy ¡of ¡SDN-­‑based ¡inter-­‑domain ¡rouRng ¡ – New ¡design ¡space ¡of ¡Tor ¡anonymity ¡network ¡ – Secure ¡in-­‑network ¡funcRons ¡

  • SDN-­‑based ¡inter-­‑domain ¡rouRng: ¡

– Characterize ¡and ¡measure ¡the ¡overhead ¡of ¡using ¡SGX ¡ – Consumes ¡70-­‑90% ¡more ¡CPU ¡cycles ¡ ¡

23 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-24
SLIDE 24

24 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-25
SLIDE 25

SDN-­‑based ¡inter-­‑domain ¡rou;ng ¡

– 30 ¡ASes ¡with ¡the ¡centralized ¡inter-­‑domain ¡controller ¡ – Inter-­‑domain ¡controller ¡: ¡90% ¡more ¡CPU ¡cycles ¡ – AS-­‑local ¡controllers ¡: ¡70% ¡more ¡CPU ¡cycles ¡ ¡

<# ¡of ¡CPU ¡cycles ¡consumed ¡in ¡the ¡inter-­‑domain ¡controller>

25 ¡

CPU ¡Cycles Number ¡of ¡participating ¡ASes

0 ¡ 100 ¡ 200 ¡ 300 ¡ 2 ¡ 5 ¡ 10 ¡ 15 ¡ 20 ¡ 25 ¡ 30 ¡ (M)

without ¡SGX ¡ with ¡SGX ¡

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-26
SLIDE 26

Secure ¡MulR-­‑party ¡ExecuRon ¡

  • SGX ¡Program ¡owner ¡can ¡remotely ¡verify ¡the ¡integrity ¡of ¡code ¡
  • Publicly ¡available ¡programs ¡(e.g., ¡git) ¡can ¡validate ¡the ¡integrity ¡
  • f ¡project ¡by ¡sharing ¡the ¡private ¡key ¡for ¡the ¡a^estaRon ¡
  • Creates ¡signature ¡of ¡program ¡through ¡shared ¡private ¡key ¡ ¡

Public ¡ repo

a^estaRon Example) ¡ ¡1. ¡Tor ¡binary ¡for ¡OR ¡ ¡2. ¡SDN-­‑based ¡controller ¡program

26 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-27
SLIDE 27

Enclave ¡ ¡ ¡ ¡ ¡ ¡ ¡

In-­‑network ¡FuncRons ¡(Middleboxes) ¡

  • Use ¡of ¡TLS ¡protocol ¡disrupts ¡in-­‑network ¡processing ¡

¡ ¡ ¡ ¡ ¡à ¡Only ¡endpoints ¡of ¡communicaRon ¡can ¡access ¡the ¡plain-­‑text ¡

  • SGX ¡enables ¡opportunity ¡for ¡secure ¡in-­‑network ¡funcRons ¡

Middlebox

Proxy Firewall IDS

  • 2. ¡Gives ¡session ¡keys ¡through ¡ ¡

¡ ¡ ¡ ¡a ¡secure ¡channel ¡

  • 1. ¡AuthenRcate ¡middlebox ¡ ¡

¡ ¡ ¡ ¡through ¡remote ¡a^estaion ¡

27 ¡

Server ¡

Can ¡be ¡done ¡unilaterally ¡or ¡bilaterally. ¡

Enclav e Enclav e

HotNets ¡2015, ¡Dongsu ¡Han ¡

slide-28
SLIDE 28

Trend ¡2: ¡Commodi;za;on ¡of ¡ ¡ Trusted ¡Execu;on ¡Environment ¡

  • Trusted ¡ExecuRon ¡Environment ¡(TEE) ¡

– Isolated ¡execuRon: ¡integrity ¡of ¡code, ¡confidenRality ¡ ¡ – Remote ¡a^estaRon ¡

  • CommodiRzaRon ¡of ¡TEE ¡

– Trusted ¡Plaaorm ¡Module ¡(TPM) ¡: ¡Slow ¡performance ¡ – ARM ¡TrustZone ¡: ¡Only ¡available ¡for ¡embedded ¡devices ¡ – Intel ¡Sodware ¡Guard ¡Extension ¡(SGX) ¡ ¡ ¡ ¡ ¡ ¡ ¡1. ¡NaRve ¡performance ¡ ¡ ¡ ¡ ¡ ¡ ¡2. ¡CompaRbility ¡with ¡x86 ¡

The commoditization of TEE brings new

  • pportunities for network applications.

28 ¡ HotNets ¡2015, ¡Dongsu ¡Han ¡