DroidScope: Seamlessly Reconstructing the OS and Dalvik Semantic Views for Dynamic Android Malware Analysis Lok Kwong Yan, and Heng Yin Syracuse University.

Slides:



Advertisements
Similar presentations
Android Application Development A Tutorial Driven Course.
Advertisements

© 2010 VMware Inc. All rights reserved Application-level mobile virtualization Harvey Tuch, Staff Engineer, Mobile Virtualization Platform January 25 th.
Secure In-VM Monitoring Using Hardware Virtualization Monirul Sharif, Wenke Lee, Weidong Cui, and Andrea Lanzi Presented by Tyler Bletsch.
Ensuring Operating System Kernel Integrity with OSck By Owen S. Hofmann Alan M. Dunn Sangman Kim Indrajit Roy Emmett Witchel Kent State University College.
Android architecture overview
Aurasium: Practical Policy Enforcement for Android Applications By Yaoqi USENIX Security Symposium 2012.
OS Fall ’ 02 Introduction Operating Systems Fall 2002.
OS Spring’03 Introduction Operating Systems Spring 2003.
JVM-1 Introduction to Java Virtual Machine. JVM-2 Outline Java Language, Java Virtual Machine and Java Platform Organization of Java Virtual Machine Garbage.
Rage Against The Virtual Machine: Hindering Dynamic Analysis of Android Malware Thanasis Petsas, Giannis Voyatzis, Elias Athanasopoulos, Sotiris Ioannidis,
Asst.Prof.Dr.Ahmet Ünveren SPRING Computer Engineering Department Asst.Prof.Dr.Ahmet Ünveren SPRING Computer Engineering Department.
CSc 453 Interpreters & Interpretation Saumya Debray The University of Arizona Tucson.
Efficient Protection of Kernel Data Structures via Object Partitioning Abhinav Srivastava, Jonathon Giffin AT&T Labs-Research, HP Fortify ACSAC 2012.
Intro to Java The Java Virtual Machine. What is the JVM  a software emulation of a hypothetical computing machine that runs Java bytecodes (Java compiler.
Jarhead Analysis and Detection of Malicious Java Applets Johannes Schlumberger, Christopher Kruegel, Giovanni Vigna University of California Annual Computer.
Android Introduction Platform Overview.
VMM Based Rootkit Detection on Android Class Presentation Pete Bohman, Adam Kunk, Erik Shaw.
Introduction to Android Swapnil Pathak Advanced Malware Analysis Training Series.
A Portable Virtual Machine for Program Debugging and Directing Camil Demetrescu University of Rome “La Sapienza” Irene Finocchi University of Rome “Tor.
D2Taint: Differentiated and Dynamic Information Flow Tracking on Smartphones for Numerous Data Sources Boxuan Gu, Xinfeng Li, Gang Li, Adam C. Champion,
Authors: William Enck The Pennsylvania State University Peter Gilbert Duke University Byung-Gon Chun Intel Labs Landon P. Cox Duke University Jaeyeon Jung.
Secure Virtual Architecture John Criswell, Arushi Aggarwal, Andrew Lenharth, Dinakar Dhurjati, and Vikram Adve University of Illinois at Urbana-Champaign.
Arpit Jain Mtech1. Outline Introduction Dalvik VM Java VM Examples Comparisons Experimental Evaluation.
@2011 Mihail L. Sichitiu1 Android Introduction Platform Overview.
Android Programming By Mohsen Biglari Android Programming, Part1: Introduction 1 Part1: Introduction By Mohsen Biglari.
Operating System Support for Virtual Machines Samuel T. King, George W. Dunlap,Peter M.Chen Presented By, Rajesh 1 References [1] Virtual Machines: Supporting.
Three fundamental concepts in computer security: Reference Monitors: An access control concept that refers to an abstract machine that mediates all accesses.
Lecture 10 : Introduction to Java Virtual Machine
Android for Java Developers Denver Java Users Group Jan 11, Mike
Cellular Networks and Mobile Computing COMS , Spring 2014
University of Central Florida TaintDroid: An Information-Flow Tracking System for Realtime Privacy Monitoring on Smartphones Written by Enck, Gilbert,
Roopa.T PESIT, Bangalore. Source and Credits Dalvik VM, Dan Bornstein Google IO 2008 The Dalvik virtual machine Architecture by David Ehringer.
Ether: Malware Analysis via Hardware Virtualization Extensions Author: Artem Dinaburg, Paul Royal, Monirul Sharif, Wenke Lee Presenter: Yi Yang Presenter:
Processes and Threads CS550 Operating Systems. Processes and Threads These exist only at execution time They have fast state changes -> in memory and.
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Christopher Kruegel University of California Engin Kirda Institute Eurecom Clemens Kolbitsch Thorsten Holz Secure Systems Lab Vienna University of Technology.
VMM Based Rootkit Detection on Android Class Presentation Pete Bohman, Adam Kunk, Erik Shaw.
Instrumentation in Software Dynamic Translators for Self-Managed Systems Bruce R. Childers Naveen Kumar, Jonathan Misurda and Mary.
Midterm Meeting Pete Bohman, Adam Kunk, Erik Shaw.
Cellular Networks and Mobile Computing COMS , Fall 2012 Instructor: Li Erran Li
Processes and Virtual Memory
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Dynamic Taint Analysis for Automatic Detection, Analysis, and Signature Generation of Exploits on Commodity Software Paper by: James Newsome and Dawn Song.
VMM Based Rootkit Detection on Android
What is a Process ? A program in execution.
QEMU, a Fast and Portable Dynamic Translator Fabrice Bellard (affiliation?) CMSC 691 talk by Charles Nicholas.
1 Android Workshop Platform Overview. 2 What is Android?  Android is a software stack for mobile devices that includes an operating system, middleware.
Java & The Android Stack: A Security Analysis Pragati Ogal Rai Mobile Technology Evangelist PayPal, eBay Java.
CSCI/CMPE 4334 Operating Systems Review: Exam 1 1.
Accelerometer based motion gestures for mobile devices Presented by – Neel Parikh Advisor Committee members Dr. Chris Pollett Dr. Robert Chun Dr. Mark.
Better Performance Through Thread-local Emulation Ali Razeen, Valentin Pistol, Alexander Meijer, and Landon P. Cox Duke University.
Software, IEE Proceedings, Vol.152, Num.3, June 2005,Page(s): Prasanthi.S March, Java-based component framework for dynamic reconfiguration.
CopperDroid Logan Horton. Android - Background Android is complicated to analyse due to having 2 places to check for code execution Normally, code is.
Computer System Structures
Chapter 4: Threads Modified by Dr. Neerja Mhaskar for CS 3SH3.
Android Mobile Application Development
Ultrascale Systems Research Center, Los Alamos National Laboratory2
Chapter 2: Operating-System Structures
DroidScope: Seamlessly Reconstructing the OS and Dalvik Semantic Views for Dynamic Android Malware Analysis Lok Yan Heng Yin August 10, 2012.
CASE STUDY 1: Linux and Android
MobiSys 2017 Symbolic Execution of Android Framework with Applications to Vulnerability Discovery and Exploit Generation Qiang Zeng joint work with Lannan.
CMPE419 Mobile Application Development
Improving java performance using Dynamic Method Migration on FPGAs
OS Virtualization.
Chapter 2: The Linux System Part 2
Android Introduction Platform Mihail L. Sichitiu.
Android Platform, Android App Basic Components
Mobile Programming Dr. Mohsin Ali Memon.
CMPE419 Mobile Application Development
Dynamic Binary Translators and Instrumenters
Presentation transcript:

DroidScope: Seamlessly Reconstructing the OS and Dalvik Semantic Views for Dynamic Android Malware Analysis Lok Kwong Yan, and Heng Yin Syracuse University Air Force Research Laboratory USENIX Presentation: 曾毓傑

Outline Introduction Background Architecture Interface & Plugins Evaluation Discussion & Conclusion 2

INTRODUCTION 3

Introduction Malicious applications exist in official and unofficial marketplace with a rate of 0.02% and 0.2% respectively Virtualization-based analysis approach Analysis runs underneath the entire virtual machine Difficult for an attack within VM to disrupt the analysis Loss the semantic contextual information when the analysis component is moved out of the box We need to intercept certain kernel events and parse kernel data structure to reconstruct the semantic knowledge 4

DroidScope Reconstruct two levels of semantic knowledge OS-level: to understand the activities of the malware process and its native components Java-level: comprehend the behaviors in the Java components Built on top of QEMU emulator Build tools for analysis Native instruction tracer Dalvik instruction tracer API tracer Taint tracker 5

BACKGROUND 6

Android System Overview 7 Android System Parent process for all Android processes libdvm.so provide Java-level abstraction Kernel data structure

DroidScope Overview 8

ARCHITECTURE 9

Architecture Integrating the changes into the QEMU emulator Came from Android SDK Leave Android system unchanged For different virtual devices can be loaded Reconstruct OS-level and Java-level views Monitors how malware’s Java components communicate with Android Java Framework Monitors how malware’s native components interact with the Linux Kernel Monitors how malware’s Java components and native components communicate through the JNI interface 10

Reconstructing OS-level View Basic Instrumentation Insert extra instructions during the code translation phase for system status 11 Target Instructions Tiny Code Generator(TCG) Native Instructions Add additional code for detection

Reconstructing OS-level View (Cont.) For example, context switch in ARM architecture would change the c2_base0 and c2_base1 registers, which stores the page table address Extract semantic knowledge System calls Running processes, threads Memory maps 12

Reconstructing OS-level View (Cont.) System calls ARM architecture use service zero instruction svc #0 as making system calls, and system call number is in register R7 Processes and Threads Read task_struct structure for process information pid, tgid, pgd, uid, gid, euid, egid, comm, cmdline, thread_info sys_fork, sys_execve, sys_clone, and sys_prctl system calls trigger the information update Memory maps mm_struct sys_mmap2 triggers the information update 13

Reconstructing Java-level View Dalvik Instructions Knowing which instruction is executing right now Register R15 points to the currently executing Dalvik instruction 14

Reconstructing Java-level View (Cont.) Just-In-Time Compiler Some hot, heavily used instructions are compiled into native machine code Those code execution would skip the mterp component 15 Call dvmGetCodeAddr() for address of compiled code Flush JIT cache, return NULL and reset counter to disable JIT function

Reconstructing Java-level View (Cont.) Dalvik Virtual Machine States Record Register R4 to R8 for storing DVM states 16 R4 : Program Counter R5 : Stack Frame Pointer R6 : InterpState Structure R7 : Instruction Counter R8 : mterp Base Address

Reconstructing Java-level View (Cont.) Java Objects Obtaining data inside Java objects such as string data 17

Symbol Information Native library symbols Use objdump to retrieve symbol information Some malwares often stripped of all symbol information Dalvik or Java symbols Use dexdump to retrieve symbol information Data structures of DVM also contains some symbol information InterpState Structure (Register R6 ) has a method field points to the Method structure for the currently executing method Method structure has a name field points to method name 18

INTERFACE & PLUGINS 19

Interface & Plugins APIs for analysis customization The instrumentation logic in DroidScope is complex and dynamic An event based interface to facilitate custom analysis tool developement 20

Sample Plugin Setup which program to be analyzed and print all Dalvik opcode information 21

API Implementation API tracer Instrument the invoke* and execute* Dalvik bytecodes to identify and log method invocations Native instruction tracer Gather each instruction including the raw instruction, its operands, and their values Dalvik instruction tracer Decode instructions into dexdump format, including values and all available symbol information Taint Tracker Monitor sensitive information and keep track data propagation 22

EVALUATION 23

Evaluation Benchmark checking efficiency and capability 7 benchmark apps AnTuTu Benchmark AnTuTu CaffeineMark CaffeineMark CF-Bench Mobile Processor Benchmark Benchmark by Softweg Linpack 24

Evaluation Performance Capability Analysis of DroidKongFu Analysis of DroidDream 25

DISCUSSION & CONCLUSION 26

Discussion Limited Code Coverage One drawback of dynamic analysis By manipulating the return value of function call, we may increase the code coverage Other Dalvik Analysis Tools Dalvik/Java Static Analysis: Woodpecker, DroidMoss Native Static Analysis: IDA, binutils, BAP Android Dynamic Analysis: TaintDroid, DroidRanger Linux Kernel Dynamic Analysis: logcat, adb 27

Conclusion We presented DroidScope, a fine grained dynamic binary instrumentation tool for Android that rebuilds two levels of semantic information 28