Trusted Browsers for Uncertain Times David Kohlbrenner and Hovav - - PowerPoint PPT Presentation

trusted browsers for uncertain times
SMART_READER_LITE
LIVE PREVIEW

Trusted Browsers for Uncertain Times David Kohlbrenner and Hovav - - PowerPoint PPT Presentation

Trusted Browsers for Uncertain Times David Kohlbrenner and Hovav Shacham UC San Diego Building a browser that can provably mitigate timing attacks Trusted Browsers Time and web browsers Mitigating attacks for A trusted browser


slide-1
SLIDE 1

Trusted Browsers for Uncertain Times

David Kohlbrenner and Hovav Shacham UC San Diego

slide-2
SLIDE 2

Building a browser that can provably mitigate timing attacks

slide-3
SLIDE 3

Trusted Browsers for Uncertain Times

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-4
SLIDE 4

Timing attacks

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-5
SLIDE 5

Browsers and timing attacks

  • Browser has multiple privilege levels

○ User secrets ○ System secrets ○ Origin secrets

  • Browsers expose detailed information

○ performance.now() ○ getAnimationFrame()

  • Browsers compute and communicate between levels
slide-6
SLIDE 6

Timing attacks in web browsers

  • SVG Filter cross-origin pixel stealing
  • JavaScript cache timing attacks
  • Fingerprinting
  • History Sniffing
slide-7
SLIDE 7

What is being done about it? - SVG attack

slide-8
SLIDE 8

What is being done about it? - Cache attack

slide-9
SLIDE 9

What is being done about it? - Cache attack

slide-10
SLIDE 10

Unfortunately, this doesn’t work.

slide-11
SLIDE 11

Better clocks with edges

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-12
SLIDE 12

Rounding down the clock

slide-13
SLIDE 13

Clock-edge technique

slide-14
SLIDE 14

Clock-edge technique - performance.now()

slide-15
SLIDE 15

Clock-edge technique - performance.now()

slide-16
SLIDE 16

Implicit clocks in the browser

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-17
SLIDE 17

Implicit clocks - Techniques

  • <video> frames
  • Web Speech
  • <video> played
  • setTimeout()
  • CSS Animations
  • WebVTT API
  • XHRs with cooperating server
slide-18
SLIDE 18

Implicit clocks - Techniques

  • <video> frames
  • Web Speech
  • <video> played
  • setTimeout()
  • CSS Animations
  • WebVTT API
  • XHRs with cooperating server

Probably many many more!

slide-19
SLIDE 19

Implicit clocks - WebVTT

  • Subtitles for <video> elements
  • Specified in a .vtt file

○ WEBVTT 00:00:00.000 --> 00:00:00.001 A very short duration subtitle

  • Specifies arbitrary subtitles with 1ms granularity
  • track.activeCues returns all displayed subtitles
slide-20
SLIDE 20

Implicit clocks - WebVTT

slide-21
SLIDE 21

Implicit clocks - WebVTT and clock-edge

slide-22
SLIDE 22

How to mitigate timing attacks

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-23
SLIDE 23

Degrade all clocks available to the attacker.

slide-24
SLIDE 24

Fuzzy time for the VAX security kernel

  • “[A] collection of techniques that reduces the bandwidths of covert timing

channels by making all clocks available to a process noisy.”

  • “Reducing Timing Channels with Fuzzy Time”

○ Hu at Oakland 1991!

slide-25
SLIDE 25

Covert channels

  • Two clocks
  • Modulated

○ The channel

  • Reference

○ Wall clock, etc

slide-26
SLIDE 26

Fuzzy time for the VAX security kernel

  • VAX VMM

○ Single thread per VM ○ Clean VM interface

  • All I/O is asynchronous
slide-27
SLIDE 27

Fuzzy time - Problem

  • Ineffective countermeasures to disk covert channel

○ Cannot be closed ○ Not auditable ○ Added noise impractical ○ No hardware solution

  • Plenty of other potential ‘shared buses’
slide-28
SLIDE 28

Fuzzy time - Solution

  • “reduce the accuracy and precision of system clocks”
  • “randomly alter the timings of I/O operations”
slide-29
SLIDE 29

Fuzzy time - Solution

  • Explicit clocks

○ “make the interval-timer interrupt random”

slide-30
SLIDE 30

Fuzzy time - Solution

  • Explicit clocks

○ “make the interval-timer interrupt random”

slide-31
SLIDE 31

Fuzzy time - Solution

  • Explicit clocks

○ “make the interval-timer interrupt random”

  • Implicit clocks

○ “[use] random clock ticks … to make fuzzy the clocks derived from I/O operations” ○ “Add new buffers … for all I/O operations”

slide-32
SLIDE 32

Fuzzy time - Solution guarantees

  • Degraded clocks

○ Limit the bandwidth

  • Time granularity

○ g

  • Bounded channel bandwidth

○ For any timing covert channel ○ ~

slide-33
SLIDE 33

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Active Active

Response queue

slide-34
SLIDE 34

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Todo Active Active

Response queue

slide-35
SLIDE 35

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Todo Active Active

Response queue

slide-36
SLIDE 36

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Todo Active

Response queue

Done Todo

slide-37
SLIDE 37

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Todo

Response queue

Done Todo Done Todo

slide-38
SLIDE 38

Next queue Currently queued

Fuzzy time - I/O queuing

Active Todo Todo

Response queue

Done Todo Done Todo Active Active

slide-39
SLIDE 39

Next queue Currently queued

Fuzzy time - I/O queuing

Active

Response queue

Done Todo Done Todo Active Active

slide-40
SLIDE 40

Next queue Currently queued

Fuzzy time - I/O queuing

Active

Response queue

Done Todo Done Todo Active Active

slide-41
SLIDE 41

Next queue Currently queued

Fuzzy time - I/O queuing

Active

Response queue

Done Done Active Active

slide-42
SLIDE 42

Fermata

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-43
SLIDE 43

Fermata - Why adapt fuzzy time?

  • Degrade clocks

○ Slow down attacks

  • Verifiability
  • Browsers are uniquely well suited
slide-44
SLIDE 44

Fermata - Fuzzy time for browsers

  • Adapt the VAX fuzzy time model to JS etc!
  • Put all I/O operations into queues
  • Make all the explicit clocks fuzzy
  • Prove everything falls into a fuzzy time defense

B u t w i t h J a v a S c r i p t !

slide-45
SLIDE 45

Fermata - Fuzzy time for browsers

  • Adapt the VAX fuzzy time model to JS etc!
  • Put all I/O operations into queues
  • Make all the explicit clocks fuzzy
  • Prove everything falls into a fuzzy time defense
  • Change all DOM accesses to be asynchronous!

B u t w i t h J a v a S c r i p t !

slide-46
SLIDE 46

Fuzzyfox

Rationale and design

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-47
SLIDE 47

Why we didn’t build Fermata

1. We didn’t know if it would work 2. We didn’t know what to start with 3. We want to push mitigations to real browsers

slide-48
SLIDE 48

Fuzzyfox

  • Patch set on trunk Mozilla Firefox
  • Supports multiple clock granularities

○ Tested 0.5ms to 100ms

  • Fully fuzzes explicit clocks
  • Breaks main thread into ‘ticks’
  • Delays outgoing HTTP request start
slide-49
SLIDE 49

Next queue Current queue

Fuzzyfox - Main thread queuing

slide-50
SLIDE 50

Next queue Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo

slide-51
SLIDE 51

Next queue Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Todo

slide-52
SLIDE 52

Next queue Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Todo

slide-53
SLIDE 53

Next queue Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Todo Pause

slide-54
SLIDE 54

Next queue Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Todo Pause

slide-55
SLIDE 55

Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Todo Pause

slide-56
SLIDE 56

Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Pause Done

slide-57
SLIDE 57

Current queue

Fuzzyfox - Main thread queuing

Done Done Active Todo Todo Todo Todo Pause Done Done

slide-58
SLIDE 58

Current queue

Fuzzyfox - Main thread queuing

Done Done Todo Todo Todo Todo Pause Done Done Done

slide-59
SLIDE 59

Current queue

Fuzzyfox - Main thread queuing

Done Done Todo Todo Todo Todo Pause Done Done Done Pause

slide-60
SLIDE 60

Current queue

Fuzzyfox - Main thread queuing

Done Done Todo Todo Todo Pause Done Done Done Pause Active

slide-61
SLIDE 61

Current queue

Fuzzyfox - Main thread queuing

Done Done Todo Todo Todo Pause Done Done Done Pause Active Done

slide-62
SLIDE 62

Queue 3 Queue 2 Queue 1

Fuzzyfox - Main thread queuing

Done Done Todo Todo Todo Done Done Done Active Done Pause Pause

slide-63
SLIDE 63

Current queue

Fuzzyfox - Main thread queuing

Done Todo Done Done Done Active Done

Epoch

Todo Pause Done Todo Pause

Epoch Epoch

slide-64
SLIDE 64

Current queue

Fuzzyfox - Main thread queuing

Done Todo Done Done Done Active Done

Epoch

Todo Pause Done Todo Pause

Epoch Epoch

slide-65
SLIDE 65

Current queue

Fuzzyfox - Main thread queuing

Done Todo Done Done Done Active Done

Epoch

Todo Pause Done Todo Pause

Epoch Epoch

  • Sleep
  • Update clocks
  • Flush queues
  • Schedule next pause
slide-66
SLIDE 66

Fuzzyfox

Effectiveness

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-67
SLIDE 67

Fuzzyfox - Effectiveness - Explicit - performance.now()

Firefox Fuzzyfox

slide-68
SLIDE 68

Fuzzyfox - Effectiveness - Implicit - WebVTT clock

Firefox Fuzzyfox

slide-69
SLIDE 69

Fuzzyfox

Performance

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-70
SLIDE 70

Fuzzyfox - Performance

  • “Micro” performance

○ Synthetic microbenchmark page load times

  • “Macro” performance

○ Real website load times

  • Interactivity

○ User study

slide-71
SLIDE 71

Fuzzyfox - Performance

  • “Micro” performance

○ Synthetic microbenchmark page load times

  • “Macro” performance

○ Real website load times

  • Interactivity

○ User study

slide-72
SLIDE 72

Fuzzyfox - Performance - Micro benchmarks

  • Page load times

○ As reported by onload()

  • Measured effects of

○ Sequential resource loads ○ Parallel resource loads

slide-73
SLIDE 73

Fuzzyfox - Performance - Sequential loads

slide-74
SLIDE 74

Fuzzyfox - Performance vs Tor Browser

slide-75
SLIDE 75

Takeaways

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-76
SLIDE 76

Timing attacks

Rounding clocks doesn’t work

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-77
SLIDE 77

Fuzzy time

Secure operating systems tech

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-78
SLIDE 78

Fermata

A different design for the browser

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-79
SLIDE 79

Fuzzyfox

Defenses that can work and that we can deploy

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser
slide-80
SLIDE 80

Takeaways

  • Time and web browsers
  • Mitigating attacks
  • A trusted browser
  • A (less) trusted browser

This material is based upon work supported by the National Science Foundation and by a gift from Mozilla. We thank Kyle Huey, Patrick McManus, Eric Rescorla, and Martin Thomson at Mozilla for helpful discussions about this work, and for sharing their insights with us about Firefox internals.

slide-81
SLIDE 81

Fuzzyfox - Effectiveness - Explicit - performance.now()

Firefox Fuzzyfox

slide-82
SLIDE 82

Fuzzyfox - Effectiveness - Implicit - WebVTT clock

Firefox Fuzzyfox

slide-83
SLIDE 83

Performance - Micro benchmarks - Sequential loads

slide-84
SLIDE 84

Performance - Micro benchmarks - Tor Browser

slide-85
SLIDE 85

Performance - Load times* - Google search