cellular networks and mobile computing coms 6998-8, spring 2012

78
Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012 Instructor: Li Erran Li ([email protected]) http:// www.cs.columbia.edu /~coms6998-8 / Lecture 12: Mobile Security 4/16/12 Cellular Networks and Mobile Computing (COMS 6998-8) 1

Upload: kylee

Post on 24-Feb-2016

34 views

Category:

Documents


0 download

DESCRIPTION

Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012. Instructor: Li Erran Li ( [email protected] ) http:// www.cs.columbia.edu /~coms6998-8 / Lecture 12: Mobile Security. Mobile Security. Inter application communication related Permission re-delegation - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

1

Cellular Networks and Mobile ComputingCOMS 6998-8, Spring 2012

Instructor: Li Erran Li ([email protected])

http://www.cs.columbia.edu/~coms6998-8/Lecture 12: Mobile Security

4/16/12

Page 2: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

2

Mobile Security

• Inter application communication related– Permission re-delegation– other inter app attacks

• ComDroid detection tool

• Rootkits

4/16/12

Page 3: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

3

Permission Re-delegation: Attacks and Defenses

Adrienne Porter Felt1, Helen J Wang2, Alexander Moshchuk2, Steve Hanna1, Erika Chin1

1University of California, Berkeley2Microsoft Research

4/16/12

Page 4: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4

modern client platforms• Applications are untrusted, or partially trusted

– Isolated from each other, except for IPC– By default, denied access to private devices and data

• Users explicitly grant permissions for devices, data

• Each application may have its own set of permissions

4/16/12 Courtesy: Felt et. al

Page 5: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

5

permissions

Android, iOS, HTML5, browser extensions…

4/16/12 Courtesy: Felt et. al

Page 6: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

6

permission re-delegation

• Permission re-delegation occurs when an application without a permission gains additional privileges through another application

• A special case of the confused deputy problem– Privilege obtained through user permissions

4/16/12 Courtesy: Felt et. al

Page 7: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

7

API

Settings

Demo malware

toggleWifi()

pressButton(0)

Permission System

4/16/12 Courtesy: Felt et. al

Page 8: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

8

Outline

• Threat model

• Permission re-delegation is a real problem, andsystems should not permit permission re-delegation

• We propose IPC Inspection as a defense mechanism

4/16/12 Courtesy: Felt et. al

Page 9: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

9

API

The permission system

• Permission system enforces user’s permission policy

Malware

Deputy

toggleWifi()

Permission System

toggleWifi()

4/16/12 Courtesy: Felt et. al

Page 10: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

10

The deputy

• Has user authorization

• Not malicious, but not a security watchdog

• Exposes public services Confused? Careless?

Malware

Deputy

Malware

APIPermission System

toggleWifi()

4/16/12 Courtesy: Felt et. al

Page 11: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

11

The attacker

• User installs/runs it, but doesn’t trust it

• Exploits a deputy to access a resource

Malware

API

Deputy

Malware

toggleWifi()

pressButton(0)

Permission System

4/16/12 Courtesy: Felt et. al

Page 12: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

12

Real world permission re-delegation

attacks

Android case study,precautionary for the future of the web

4/16/12 Courtesy: Felt et. al

Page 13: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

13

Identifying candidates

• Two necessary preconditions for an attack: – Has a dangerous permission– Has a public interface

• Analyzed manifests of 872 Android applications– 16 system apps, 756 most popular, 100 recently

uploaded

• 320 apps (37%) are candidates for attacks

4/16/12 Courtesy: Felt et. al

Page 14: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

14

Finding exploits

• Built tool for finding attacks

• Call graph analysis:find paths from public entry points to protected API calls

• Manually verified all exploits

Public entry points

API calls

4/16/12 Courtesy: Felt et. al

Page 15: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

15

attacks

• Built attacks using 5 of the 16 system apps

• Found 15 attacks in the 5 applications

• Several confirmed and fixed

• This is a lower bound; likely more exist

4/16/12 Courtesy: Felt et. al

Page 16: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

16

API

Settings

Demo malware

wifiManager.setWifiEnabled(true)

Message:0://0#0

Permission System

Attack on the settings app

com.android.settings.widget.SettingsAppWidgetProvider

User pressed

button[0]

4/16/12 Courtesy: Felt et. al

Page 17: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

17

More example attacks• DeskClock:

– Start an internal service– Tell it to infinitely vibrate with a WAKE_LOCK on

• Phone:– Trigger the “phone call answered” message

receiver– Phone call will be silenced, vibrate cancelled

4/16/12 Courtesy: Felt et. al

Page 18: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

18

Preventing permission re-delegation

4/16/12 Courtesy: Felt et. al

Page 19: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

19

Our goals

• We don’t want to rely on application developers for prevention

• Enable the system to prevent permission re-delegation

• We don’t want to break applications

4/16/12 Courtesy: Felt et. al

Page 20: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

20

IPC Inspection• When a deputy receives a message, system reduces

deputy’s permissions (for the session) to: {requester’s permissions} {deputy’s permissions}

• A deputy’s current set of permissions captures its communication history

• Deputy can specify who can(not) send it messages

• Generalizes stack inspection to IPC calls

4/16/12 Courtesy: Felt et. al

Page 21: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

21

Handling a potential attack• Time-of-use system

– Add a new runtime prompt for permission re-delegation

• Install-time system– Requester must statically ask for necessary

permissions– Permission re-delegation is simply blocked at

runtime

4/16/12 Courtesy: Felt et. al

Page 22: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

22

Application instances

• Deputy might need to service user and multiple app requesters simultaneously

• Solution: create one instance per request– User interacts with primary instance– When new interaction starts, create a new

“application instance”– Each instance has its own set of current permissions– However, instances share app storage, etc.

4/16/12 Courtesy: Felt et. al

Page 23: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

23

implementation

• Android implementation: modify PackageManager, ActivityManager– PackageManager installs applications, stores

permissions, enforces permission requirements– ActivityManager notifies PackageManager when

relevant events happen, e.g. starting Activity, receiving Broadcast Intent

• A few hundred lines of code

4/16/12 Courtesy: Felt et. al

Page 24: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

24

evaluation

Do we break applications?Do we stop attacks?

4/16/12 Courtesy: Felt et. al

Page 25: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

25

Broken applications

Intentional Deputy 5 applications (25%)

Requester 6 applications (30%)One application is both an intentional deputy and a requester

Developers might need to make changes to these applications:

Of those requesters:2 of 6 requesters (10% of apps) need to add permissions

20 Android applications

4/16/12 Courtesy: Felt et. al

Page 26: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

26

Effectiveness at Attack prevention

Unintentional Deputy 4 applications (20%)IPC Inspection prevents these from being exploited:

Also stops all the attacks on the built-in system applications

20 Android applications

4/16/12 Courtesy: Felt et. al

Page 27: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

27

Conclusion• Real world permission re-delegation vulnerabilities exist

– A third of Android system applications contain permission re-delegation attacks

• Future systems should be designed to prevent permission re-delegation

• IPC Inspection: an OS mechanism that prevents permission re-delegation– Install-time: some requesters will need to add permissions

4/16/12 Courtesy: Felt et. al

Page 28: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

28

Analyzing Inter-Application Communication in Android

Erika ChinAdrienne Porter Felt

Kate GreenwoodDavid WagnerUC Berkeley

4/16/12

Page 29: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Inter-Application Communication

29

Yelp App

Maps App Dialer App Malicious App

•Eavesdropping Attacks

Inter-Application Communication

Other App

•Injection Attacks

4/16/12 Courtesy: Chin et. al

Page 30: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Organization

• Android communication model

• Security analysis of Android

• ComDroid

• Analysis of third-party applications

• Recommendations

304/16/12 Courtesy: Chin et. al

Page 31: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Android Overview

• Intents = Android IPC

• Applications are divided into components

• Intents can be sent between components

• Intents can be used for intra- and inter-application communication

31

Sender Receiver

Intent

4/16/12 Courtesy: Chin et. al

Page 32: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Explicit Intents

32

Yelp MapApp

Name: MapActivity

To: MapActivity

Only the specified destination receives this message

4/16/12 Courtesy: Chin et. al

Page 33: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Implicit Intents

33

Yelp

ClockApp

MapApp

Handles Action: VIEW

Handles Action: DISPLAYTIME

Implicit IntentAction: VIEW

4/16/12 Courtesy: Chin et. al

Page 34: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Implicit Intents

34

Yelp

BrowserApp

MapApp

Handles Action: VIEW

Handles Action: VIEW

Implicit IntentAction: VIEW

4/16/12 Courtesy: Chin et. al

Page 35: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Security Analysis Of Android

354/16/12 Courtesy: Chin et. al

Page 36: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Common Developer Pattern:Unique Action Strings

36

ShowtimeSearch

Results UI

IMDb App

Handles Actions: willUpdateShowtimes,showtimesNoLocationError

Implicit IntentAction: willUpdateShowtimes

4/16/12 Courtesy: Chin et. al

Page 37: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

374/16/12 Courtesy: Chin et. al

Page 38: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Common Developer Pattern:Unique Action Strings

38

ShowtimeSearch

Results UI

IMDb App

Handles Actions: willUpdateShowtimes,showtimesNoLocationError

Implicit IntentAction: willUpdateShowtimes

4/16/12 Cellular Networks and Mobile Computing (COMS 6998-8) Courtesy: Chin et. al

Page 39: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

ATTACK #1: Eavesdropping

39

ShowtimeSearch

Malicious Receiver

IMDb App

Handles Action: willUpdateShowtimes,showtimesNoLocationError

Implicit IntentAction: willUpdateShowtimes

Eavesdropping App

Sending Implicit Intents makes communication public4/16/12 Cellular Networks and Mobile Computing

(COMS 6998-8) Courtesy: Chin et. al

Page 40: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

ATTACK #2: Intent Spoofing

40

Malicious Component

Results UI

IMDb App

Handles Action: willUpdateShowtimes,showtimesNoLocationError

Action: showtimesNoLocationError

Malicious Injection App

Receiving Implicit Intents makes the component public4/16/12 Cellular Networks and Mobile Computing

(COMS 6998-8) Courtesy: Chin et. al

Page 41: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

41Typical caseAttack case

4/16/12 Courtesy: Chin et. al

Page 42: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

42

ATTACK #3: Man in the Middle

ShowtimeSearch

Results UI

IMDb App

Handles Action: willUpdateShowtimes,showtimesNoLocation Error

Malicious Receiver

Handles Action: willUpdateShowtimes,showtimesNoLocationError

Man-in-the-Middle App

Action: willUpdateShowtimes

Action: showtimesNoLocationError

4/16/12 Courtesy: Chin et. alCellular Networks and Mobile Computing

(COMS 6998-8)

Page 43: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

ATTACK #4: System Intent Spoofing

• Background – System Broadcast– Event notifications sent by the system– Some can only be sent by the system

• Receivers become accessible to all applications when listening for system broadcast

434/16/12 Courtesy: Chin et. al

Page 44: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

System Broadcast

44

Component

App 1

Handles Action: BootCompleted

Component

App 2

Handles Action: BootCompleted

Component

App 3

Handles Action: BootCompleted

SystemNotifier

Action:BootCompleted

4/16/12 Cellular Networks and Mobile Computing (COMS 6998-8) Courtesy: Chin et. al

Page 45: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

System Intent Spoofing: Failed Attack

45

Handles Action: BootCompleted

MaliciousComponent

Malicious App

Action: BootCompleted

Component

App 1

4/16/12 Courtesy: Chin et. al

Page 46: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

System Intent Spoofing: Successful Attack

46

Handles Action: BootCompleted

MaliciousComponent

Malicious App

Component

App 1

To: App1.Component

4/16/12 Courtesy: Chin et. al

Page 47: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Real World Example: ICE App

• ICE App: Allows doctors access to medical information on phones

• Contains a component that listens for the BootCompleted system broadcast

• On receipt of the Intent, it exits the application and locks the screen

474/16/12 Courtesy: Chin et. al

Page 48: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Real World Example: ICE

484/16/12 Courtesy: Chin et. al

Page 49: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

ComDroid

49

ComDroidAndroid Executable File

Security Warnings for Exposed Communication

ComDroid analyzes applications to detect Intent-based attack surfaces

4/16/12 Courtesy: Chin et. al

Page 50: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Evaluation

• Manually verified ComDroid’s warnings for 20 applications

• 60% of applications examined have at least 1 exploitable IPC vulnerability

50

Type # of Warnings # of AppsSevere Vulnerability 34 12

Bad Practice 16 6

Spurious Warning 6 6

4/16/12 Courtesy: Chin et. al

Page 51: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Recommendations

• Treat inter- and intra-application communication as different cases

• Prevent public internal communication– 21% of severe vulnerabilities– 63% of bugs due to bad practice

• Verify system broadcasts– 6% of severe vulnerabilities– 13% of bugs due to bad practice

• Can be fixed by either developers or platform514/16/12 Courtesy: Chin et. al

Page 52: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Conclusion• Applications may be vulnerable to other

applications through Android Intent communication

• Many developers misuse Intents or do not realize the consequences of their program design

• 60% of applications examined had at least 1 vulnerability

• ComDroid tool to be publically accessible soon atwww.comdroid.org

524/16/12 Courtesy: Chin et. al

Page 53: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

53

Rootkits on Smart Phones:Attacks, Implications and Opportunities

Jeffrey Bickford, Ryan O’Hare, Arati Baliga, Vinod Ganapathy, and Liviu Iftode

Department of Computer Science, Rutgers University

4/16/12

Page 54: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Smart Phone Operating Systems

OS Lines of CodeLinux 2.6 Kernel 10 million

Android 20 millionSymbian 20 million

Complexity comparable to desktops

4/16/12 54Courtesy: Bickford et. al

Page 55: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 55

The Rise of Mobile Malware

2004

Cabir

• spreads via Bluetooth• drains battery

Receive message via Bluetooth?

Yes No

Courtesy: Bickford et. al

Page 56: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

56

The Rise of Mobile Malware

2004

• first J2ME malware• sends texts to premium numbers

RedBrowser

2006

Courtesy: Bickford et. alCellular Networks and Mobile Computing

(COMS 6998-8)4/16/12

Page 57: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

57

The Rise of Mobile Malware

2004

• Kaspersky Labs report:106 types of mobile malware514 modifications

2006 2009

4/16/12 Cellular Networks and Mobile Computing (COMS 6998-8)

Page 58: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 58

Contributions

• Introduce rootkits into the space of mobile malware

• Demonstrate with three proof-of concept rootkits

• Explore the design space for detection

Page 59: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 59

Rootkits

App App App

User Space

Kernel Space

Libraries

Kernel Code

SystemCall

TableDrivers Process

Lists

VirusAntiVirus

Page 60: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 60

Rootkits

App App App

User Space

Kernel Space

Libraries

Kernel Code

SystemCall

TableDrivers Process

Lists

AntiVirus

Rootkit

Virus

Page 61: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Proof of Concept Rootkits

4/16/12 61

Note: We did not exploit vulnerabilities

• 1. Conversation Snooping Attack

• 2. Location Attack

• 3. Battery Depletion Attack

Openmoko Freerunner

Page 62: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 62

1. Conversation Snooping Attack

Attacker Send SMSRootkit Infected

Dial me “666-6666”

Call AttackerTurn on Mic

Delete SMS

Rootkit stops if user tries to dial

Page 63: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 63

1. Conversation Snooping Attack

Attacker Rootkit Infected

Call AttackerTurn on Mic

Calendar Notification

Page 64: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Attacker Send SMSRootkit Infected

Send Location “666-6666”

2. Location Attack

Query GPS

4/16/12 64

N40°28', W074°26SMS Response

Delete SMS

Page 65: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

3. Battery Depletion Attack• Rootkit turns on high powered devices• Rootkit shows original device status

Battery Life For Different Smartphones

52 51

44

4 52

0

10

20

30

40

50

60

70

Verizon Touch ATT Tilt Neo FreeRunner

Phone Make and Model

Hour

s of

Bat

tery

Life

(idl

e)

Normal IdleOperation

All PeripheralsActive

4/16/12 65

Attack :

Page 66: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 66

Rootkit Detection

App App App

User Space

Kernel Space

Libraries

Kernel Code

SystemCall

TableDrivers Process

Lists

Rootkit Detector

RootkitDOES NOT WORK!

Page 67: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 67

Memory Introspection

Kernel

Sys CallTable

Monitor

Fetchand

Copy

Monitor Machine Target Machine

Training Phase

Page 68: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 68

Memory Introspection

KernelMonitor

Fetch

Monitor Machine Target Machine

Compare

System OK

Detection Phase

Page 69: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 69

Memory Introspection

KernelMonitor

Fetch

Monitor Machine Target Machine

Compare

Rootkit Detected

Rootkit

mal_write()

Detection Phase

Page 70: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 70

Monitoring Approaches

1. Hardware Approach

Monitor Machine Target Machine

Rootkit InfectedNIC with remote

DMA support

Page 71: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Smart Phone Challenge

Monitor Machine Rootkit Infected

4/16/12 71

Problem:• Need interface allowing memory access

without OS intervention (FireWire?)

Page 72: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 72

Monitoring Approaches

Host Machine

Hypervisor

Dom0 OS

2. VMM-based Approach

Detector

Page 73: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Smart Phone Challenge

4/16/12 73

Problem: CPU-intensive detection algorithms exhaust phone battery

Solution: Offload detection work to the service provider

Send Pages

Response

CPU intensive work

Page 74: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Optimizations for Energy-Efficiency

4/16/12 74

Page TableMonitor

Fetch

Problem: Too many memory pages may have to be transferred

Page 75: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Optimizations for Energy-Efficiency

4/16/12 75

Page Table000000

Monitor1

1Fetch

Solution: Only fetch and scan pages that have been recently modified

Page 76: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

4/16/12 76

Related Work (1/2)

Rootkit Detection • Enforcement of Kernel Data Structure Invariants [Baliga, et al., ACSAC 2008]• Virtual Machine Introspection [Garfinkel and Rosenblum, NDSS 2003] Mobile Security and Detection• Semantically Rich Application-Centric Security in Android [Ongtang, et al., ACSAC 2009]• Detecting Energy-Greedy Anomalies [Kim, et al., MobiSys 2008]

Page 77: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Related Work (2/2)

Mobile Malware• Cellular Botnets: Impact on Network Core [Traynor, et al., CCS 2009]• Exploiting MMS Vulnerabilities to Exhaust Battery [Racic, et al., SecureComm 2006]• Exploiting SMS-Capable Cellular Network [Enck, et al., CCS 2005]

4/16/12 77

Page 78: Cellular Networks and Mobile Computing COMS 6998-8, Spring 2012

Cellular Networks and Mobile Computing (COMS 6998-8)

Conclusion and Future Work

Conclusions:• Rootkits are now a threat to smart phones

Future Work:• Energy efficient rootkit detection techniques

• Develop a rootkit detector for smart phone

4/16/12 78