Top Banner
Practical Attacks against Mobile Device Management (MDM) Michael Shaulov, CEO Daniel Brodie, Security Researcher Lacoon Mobile Security March 14, 2013
42

BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Dec 05, 2014

Download

Technology

Spyphones are surveillance tools surreptitiously planted on a user’s handheld device. While malicious mobile applications, mainly phone fraud applications distributed through common application channels, target the typical consumer, spyphones are nation states tool of attacks. Why? Once installed, the software stealthy gathers information such as text messages (SMS), geo-location information, emails and even surround-recordings.

How are these mobile cyber-espionage attacks carried out? In this engaging session, we present novel proof-of-concept attack techniques - both on Android and iOS devices - which bypass traditional mobile malware detection measures- and even circumvent common Mobile Device Management (MDM) features, such as encryption.
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Practical Attacks against Mobile Device Management (MDM)

Michael Shaulov, CEO Daniel Brodie, Security Researcher

Lacoon Mobile Security

March 14, 2013

Page 2: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Security researcher for almost a decade

– From PC to Mobile

– Low level OS research

• Researcher at Lacoon Mobile Security

– Developing a dynamic analysis framework for analyzing spyphones and mobile malware

About: Daniel

Page 3: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Decade of experience researching and working in the mobile security space

– From feature-phones to smartphones

– Mobile Security Research Team leader at NICE Systems

• CEO and co-founder of Lacoon Mobile Security

About: Michael

Page 4: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Introduction to MDM and Secure Containers

Rise of the Spyphones

Bypassing secure container encryption capabilities

Recommendations and summary

Agenda

Page 5: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

MDM AND SECURE CONTAINERS 101

Page 6: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Helps enterprises manage BYOD (Bring Your Own Device) and corporate mobile devices

• Policy and configuration management tool

• Offerings include separating between business data and personal data

Mobile Device Management

Page 7: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

MDM: Penetration in the Market

“Over the next five years, 65 percent of enterprises will adopt a mobile device management (MDM) solution for their corporate liable users”

– Gartner, Inc. October 2012

Page 8: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Software management

• Network service management

• Hardware management

• Security management

– Remote wipe

– Secure configuration enforcement

– Encryption

MDM Key Capabilities

Page 9: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• All leading MDM solutions provide secure containers

– MobileIron

– AirWatch

– Fiberlink

– Zenprise

– Good Technologies

Secure Containers

Page 10: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Behind the Scenes: Secure Containers

Enterprise Application

Sandbox

Secure Container

Encrypted Storage

Secure Communication

(SSL/VPN)

Page 11: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

RISE OF THE

SPYPHONES

Page 12: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Business Impact

Complexity

Mobile Malware

Apps

Consumer-oriented. Mass. Financially motivated, e.g.: - Premium SMS - Fraudulent charges - Botnets

Spyphones

Targeted: • Personal • Organization • Cyber

espionage

The Mobile Threatscape

Page 13: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Convergence of Personal Info

• Contacts

• Emails

• Messages

• Calls

• Corporate Information

Follows us everywhere

• Office

• Meetings

• Home

• Travel

Perfect Spy Hardware

• Always Online

• Location

• Microphone

• Camera

Why Mobile?

Page 14: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Spyphone Capabilities

Eavesdropping and Surround

Recording

Extracting Call and Text Logs

Tracking Location Infiltrating

Internal LAN

Snooping on Emails and

Application Data

Collecting Passwords

Page 15: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Examples

More Than 50 Different Families in the Wild

Page 16: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

The High-End

• FinSpy

– Gamma Group

• DaVinci RCS

– Hacking Team

• LuckyCat

– Chinese

• LeoImpact

Low End

High End

Page 17: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

The Low-End Low End

High End

• Starting at $4.99 a month! What a steal!

– For iOS, Android, Blackberry, Windows Mobile/Phone, Symbian, …

• Professional worldwide support

• Very simple and mainstream

– So simple that even your mother could use it

• On your father

• Available at a reseller near you!

Page 18: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• From high-end to low-end

– Difference is in infection vector -> price

• End-result is the same

– For $5, you get nearly all the capabilities of a $350K tool

Spyphones: Varying Costs, Similar Results

Page 19: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

SPYPHONE DEMO

Page 20: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Partnered with worldwide cellular network operators:

– Sampled 250K subscribers

– Two separate sampling occasions

• Infection rates:

– March 2012: 1 in 3000 devices

– October 2012: 1 in 1000 devices

Spyphones in the Wild

Page 21: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Spyphone Distribution by OS

52% 35%

7% 6% iOS

Android

Symbian

Unknown

Page 22: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

51%

12.39%

30.79%

1.40%

3.90%

Android

Blackberry

iOS

Symbian

Windows Phone 7and WindowsMobile

Mobile OS Market Share Spyphone Distribution by OS

Comscore, March 2012

52% 35%

7% 6% iOS

Android

Symbian

Unknown

Page 23: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

IT’S ALRIGHT, IT’S OK,

“SECURE CONTAINER” IS THE WAY?

Page 24: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Secure Containers:

– Detect JailBreak/Root

– Prevent malicious application installation

– Encrypt data

– Dependent on the OS sandbox

Secure Container Re-Cap

Page 25: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• JailBreaking (iOS)/ Rooting (Android) detection mechanism

– “Let Me Google That For You”

– Usually just check features of JB/ Root devices (e.g. is Cydia/ SU installed)

• Cannot detect exploitation

Opening the Secure Container (1)

Page 26: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Prevention of malicious app installation (Android)

– Targeted towards mass malware

• Third-Party App restrictions

– Should protect against malware

• Has been bypassed

– Both for Android and iPhone

Opening the Secure Container (2)

Page 27: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

ANDROID DEMO

Page 28: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Install Malicious Application – Possible Vector

– Publish an app through the market

• Use “Two-Stage”: Download the rest of the dex later- and only for the targets we want

• Get the target to install the app through spearphishing

– Physical access to the device would also work

Android Demo: Technical Details (1)

Page 29: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Privilege Escalation

– We used the Exynos exploit. (Released Dec., 2012)

• Create a hidden ‘suid’ binary and use it for specific actions

– Place in a folder with --x--x--x permissions

– Undetected by generic root-detectors

Android Demo: Technical Details (2)

Page 30: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• We listen to events in the logs

– For <=2.3 we can just use the logging permissions

– For >4.0 we use access the logs as root

• When an email is read….

Android Demo: Technical Details (3)

Page 31: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• We dump the heap using /proc/<pid>/maps and /mem

– Then search for the email structure, extract it, and send it home

Android Demo: Technical Details (3)

Page 32: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Android Heap Searching

Page 33: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

IOS DEMO

Page 34: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Install Malicious Application – Possible Vectors

– Use the JailBreak just for the installation

• Install signed code using Enterprise/Developer certificate

• Remove any trace of the JailBreak

– Or just jailbreak and hide the jailbreak

– Repackage the original application

iOS Demo: Technical Details (1)

Page 35: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Load malicious dylib into

memory (it’s signed!)

Hook using standard

Objective-C hooking

mechanisms

Get notified when an

email is read

Pull the email from

the UI classes

Send every email loaded

home

iOS Demo: Technical Details (2)

Page 36: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• DYLD_INSERT_LIBRARIES

– Was very common previously, a bit harder now

• MACH-O editing

– Requires to resign code or leave device jailbroken

– Number of tools to do the work for you

• Objective-C Hooking

– Objc_setImplementation….

Code Injection

Page 37: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

Objective-C Hooking

Page 38: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

CONCLUSIONS

Page 39: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• “Secure” Containers depend on the integrity of the host system

1. If the host system is uncompromised: what is the added value?

2. If the host system is compromised: what is the added value?

• We’ve been through this movie before!

Secure Containers…Secure?

Page 40: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• MDM provides Management, not absolute Security

• Beneficial to separate between business and personal data

• Main use-case

– Remote wipe of enterprise content only

– Copy & Paste DLP

Infection is Inevitable

Page 41: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

• Use MDM as a baseline defense for a multi-layer approach

• Needs rethinking outside the box (mobile)

• Solutions on the network layer:

– C&C communications

– Heuristic behavioral analysis

– Sequences of events

– Data intrusion detection

Mitigating Spyphone Threats

Page 42: BlackHat Europe 2013 - Practical Attacks against Mobile Device Management (MDM)

THANK YOU! QUESTIONS?

Email us at: [email protected] [email protected]