AEGIS: Architecture for Tamper-Evident and Tamper-Resistant - - PowerPoint PPT Presentation

aegis
SMART_READER_LITE
LIVE PREVIEW

AEGIS: Architecture for Tamper-Evident and Tamper-Resistant - - PowerPoint PPT Presentation

AEGIS: Architecture for Tamper-Evident and Tamper-Resistant Processing G. Edward Suh, Dwaine Clarke, Blaise Gassend, Marten van Dijk, Srinivas Devadas Massachusetts Institute of Technology L C S Cases for Physical Security Applications


slide-1
SLIDE 1

L C S

AEGIS:

Architecture for Tamper-Evident and Tamper-Resistant Processing

  • G. Edward Suh, Dwaine Clarke,

Blaise Gassend, Marten van Dijk, Srinivas Devadas Massachusetts Institute of Technology

slide-2
SLIDE 2

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Cases for Physical Security

  • Applications on untrusted hosts with untrusted owners

– Digital Rights Management (DRM), Software licensing – Distributed computation on Internet – Mobile agents

  • New challenges

– Untrusted OS – Physical attacks

Make Illegal Copies Incorrect Results; Break the System Music/Movie Software Program Distributed Computing, Peer-to-Peer Network

slide-3
SLIDE 3

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Conventional Tamper-Proof Packages

  • Processing system in a tamper-proof package (IBM 4758)

– Expensive: many detecting sensors – Needs to be continuously powered: battery-backed RAM

$2,690

in 2001

Memory 99MHz 486

Source: IBM website

slide-4
SLIDE 4

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Single-Chip Secure Processors

Trusted Environment Memory I/O Check Integrity, Encrypt

  • Only trust a single chip: tamper-resistant

– Off-chip memory: verify the integrity and encrypt – Untrusted OS: identify a core part or protect against OS attacks

  • Cheap, Flexible, High Performance

Identify or Protect against Untrusted OS

slide-5
SLIDE 5

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Related Research

  • XOM (eXecution Only Memory): David Lie et al

– Stated goal: Protect integrity and privacy of code and data – Operating system is completed untrusted – Memory integrity checking does not prevent replay attacks – Privacy is expensive but not necessary for all applications

  • Palladium/NGSCB: Microsoft

– Stated goal: Protect from software attacks – Combination of hardware and software mechanisms – Adds "curtained" memory to avoid DMA attacks – Uses a security kernel (Nexus) – Memory integrity and privacy are assumed (only software attacks).

slide-6
SLIDE 6

L C S

AEGIS:

High-Level Architecture

slide-7
SLIDE 7

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Secure Execution Environments

  • Tamper-Evident (TE) environment

– Guarantees a valid execution and the identity of a program; no privacy – Any software or physical tampering to alter the program behavior should be detected

  • Private Tamper-Resistant (PTR) environment

– TE environment + privacy – Encrypt instructions and data – Assume programs do not leak information via memory access patterns

  • Implementation

– Either have a trusted part of the OS or completely untrust the OS – Secure context manager, encryption and integrity verification

slide-8
SLIDE 8

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Secure Context Manager (SCM)

  • A specialized module in the

processor

  • Assign a secure process ID

(SPID) for each secure process

  • Implements new instructions

– enter_aegis – set_aegis_mode – random – sign_msg

  • Maintains a secure table

– Even operating system cannot modify

Standard Processor SCM L1 Instruction cache On-Chip L2 Cache Processor Core L1 Data cache

Regs … … … … SPID

Off-Chip Memory

slide-9
SLIDE 9

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

SCM: Program Start-Up

  • ‘enter_aegis’: TE mode

– Start protecting the integrity of a program – Compute and store the hash of the stub code: H(Prog) Tampering of a program results in a different hash – Stub code verifies the rest

  • f the code and data
  • ‘set_aegis_mode’

– Start PTR mode on top of the TE mode

.text enter_aegis EKey1 = 0xA4523BC2E435D; EKey2 = 0xB034D2C654F32; E1Msg = … Secret=GetSecret(Challenge); Key1=Decrypt(EKey1, Secret); Key2=Decrypt(EKey2, Secret); CheckMAC(Key1, Key2, MAC); Msg = Decrypt(E1Msg, Key1); E2Msg = Encrypt(Msg, Key2); Output(E2Msg); Secret=GetSecret(Challenge); Key1=Decrypt(EKey1, Secret); Key2=Decrypt(EKey2, Secret); CheckMAC(Key1, Key2, MAC); Msg = Decrypt(E1Msg, Key1); E2Msg = Encrypt(Msg, Key2); Output(E2Msg);

enter_aegis code_end H(Prog) Protected Table SHA-1 Stub Segment Program

slide-10
SLIDE 10

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

SCM: On-Chip Protection

  • Registers on interrupts

– SCM saves Regs on interrupts, and restore on resume

  • On-chip caches

– Need to protect against software attacks – Use SPID tags and virtual memory address – Allow accesses from the cache only if both SPID and the virtual address match

Standard Processor L1 Instruction cache On-Chip L2 Cache Processor Core L1 Data cache

Regs

… … Regs … H(Prog) … SPID

SPID Tags SPID Tags SPID Tags

Interrupt Resume SCM Off-Chip Memory

slide-11
SLIDE 11

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Memory Encryption

Untrusted RAM Trusted State Processor

ENCRYPT DECRYPT

Program write read

  • Encrypt on an L2 cache block granularity

– Use symmetric key algorithms with CBC mode – Randomize initial vectors

slide-12
SLIDE 12

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Integrity Verification

Untrusted RAM Trusted State Processor

ENCRYPT DECRYPT

Program

V E R I F Y E(124), MAC(0x45, 124) Address 0x45 E(120), MAC(0x45, 120) IGNORE

write read

Cannot simply MAC on writes and check the MAC on reads Replay attacks Hash trees for integrity verification

slide-13
SLIDE 13

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Hash Trees

Processor V1 V3 V4 L2 block Data Values

Logarithmic overhead for every cache miss Low performance Cached hash trees

MISS V2 READ VERIFY h1=h(V1.V2) h2=h(V3.V4) root = h(h1.h2) VERIFY Untrusted Memory

slide-14
SLIDE 14

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Cached Hash Trees (HPCA’03)

Processor V1 V2 V3 V4

Cache hashes in L2 L2 is trusted

Stop checking earlier Less overhead

In L2 MISS In L2 h1=h(V1.V2) h2=h(V3.V4) root = h(h1.h2) VERIFY VERIFY MISS VERIFY DONE!!! Untrusted Memory

slide-15
SLIDE 15

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Message Authentication

  • Processor Other systems

– The processor signs a message for a program sign_msg M: {H(Prog), M}SKproc – Unique for each program because H(Prog) is always included

  • Other systems Processor

– Embed the user’s public key in a program – Incoming messages are signed with the user’s private key

Program with Puser {Message}Suser {H(Prog), Message}Sproc

slide-16
SLIDE 16

L C S

Applications

slide-17
SLIDE 17

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Certified Execution

  • Execution certified by the secure processor

– Dispatcher provides a program and data – Processor returns the results with the signature

  • Requires the TE environment

Job Dispatcher

Processor’s Private Key

Secure Processor

RESULT RESULT

enter_aegis Execute Get results Verify results

  • H(Prog)
  • signature

Program, Data Processor’s Public Key

slide-18
SLIDE 18

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Digital Rights Management

  • Protects digital contents from illegal copying

– Trusted software (player) on untrusted host – Content provider only gives contents to the trusted player

  • Requires the PTR environment

Processor’s Private Key

Authenticated & Encrypted Channel (SSL)

Player

Random nonce Signed nonce

Verify

  • H(Player)
  • nonce
  • signature

Run Player

  • enter_aegis
  • enter PTR

Content Processor’s Public Key

Content Provider Secure Processor

slide-19
SLIDE 19

L C S

Performance

slide-20
SLIDE 20

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Performance Implication: TE processing

  • Major performance degradation is from off-chip integrity checking

– Start-up and context switches are infrequent – no performance overhead for on-chip tagging

gcc gzip mcf twolf vortex vpr applu art swim 0.2 0.4 0.6 0.8 1 1.2

(a) 64B

Normalized IPC 256KB 1MB 4MB

Worst case 50% degradation Most cases < 25% degradation

L2 Caches with 64B blocks

slide-21
SLIDE 21

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Performance Implication: PTR processing

  • Major performance degradation is from off-chip integrity checking

and encryption

gcc gzip mcf twolf vortex vpr applu art swim 0.2 0.4 0.6 0.8 1 1.2 Normalized IPC 256KB 1MB 4MB

Worst case 60% degradation Most cases < 40% degradation

L2 Caches with 64B blocks

slide-22
SLIDE 22

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Summary

  • Physical attacks are becoming more prevalent

– DRM, software licensing, distributed computing, etc.

  • Single-chip secure processors provide trusted execution

environments with acceptable overhead

– Tamper-Evident environment, Private Tamper-Resistant environment – Simulation results show 25-50% overhead for TE, 40-60%

  • verhead for PTR processing

– New mechanisms can reduce the overhead to 5-15% for TE, and 10-25% for PTR processing (CSG Memo 465)

  • Significant development effort underway

– FPGA/ASIC implementation of AEGIS processor

slide-23
SLIDE 23

International Conference on Supercomputing — June 23-26, 2003

  • G. Edward Suh — MIT Lab for Computer Science

Questions?

More Information at www.csg.lcs.mit.edu