SlideShare a Scribd company logo
Rapid Android Application
Security Testing
Agenda
• Introduction to Android Testing
– Static Analysis
– Dynamic Analysis
– Local Storage Inspection
• Challenge.txt
Android Security Testing
• Can install apps on device and go hack the
network.
• Can install the application in the
emulator and test it.
What’s inside?
• Android is a Linux kernel based OS.
• Dalvik VM (Dalvik Virtual Machine) makes the
dex file (Dalvik Executables) reach execution.
• APK (Android Application Package) contains all
the resources, i.e. manifest file, signatures,
dex file, and other resources in a zipped
manner.
So what happens.
• Java source code is compiled to Java byte
Code using Java Compiler
• Byte code is converted into Dalvik Code using
Dex compiler
• Dalvik Executable (Dex file) goes to “Dalvik
VM” and executes within it.
…..Continued.
Dalvik VM
Dalvik
Executable
(Dex File)
Java Source
Code
Java Byte
CodeJava Compiler
Dalvik Code
Dex Compiler
Pentest. How to do?
• Break the testing into
three parts:
– Static Testing
– Dynamic Testing
– Local Storage
• Try to uncover issues in
every phase.
Static Analysis
• Get the .apk file.
• Reverse Engineer it.
• Decompile / Dis-assemble it.
• Dis-assemble it using
– Dedexer gives assembly like output) or
– Baksmali (based on dedexer and gives code more easy to understand.
• Decompile it using
– Dex2jar (dalvik code turns to Java byte code (jar file).
– Use jd-gui to view the java source codes.h
What to look for?
• Look for api information, database connection strings, internal
/ external IP disclosures and ports, etc.
• If you are lucky, you might get a password too, Believe me
developers are crazy.
• If you can go for social engineering stuff, lot of emails can be
found.
• Tip: A pair of /* and */ holds a lot of information.
m0bLiz3r Demo
https://github.com/nkpanda/Android-Testing
Dynamic Analysis
• Load emulator.
• Set up an Interception Proxy
• Figure out SSL issues.
• And follow the generic logic test cases you
follow in web applications.
Proxy Setup
Continued…
Local Storage Inspection
• Check for sensitive data getting stored on client side.
• XML files, database files are most commonly found
culprits.
• Inspect memory for information sensitive
information > memdump
• Inspect generated logs for sensitive information >
logcat.
• Uninstall and check if things remain in application
folder.
Where to look?
How it look?
Tools Of Trade
• Android SDK
• ADB
• BurpSuite
• APKtools
• Smali/baksmali
• Dex2jar
• Genymotion
• Appuse/Android Tamer.
Challenges
• AppUse is quite slow:
– Save time in loading your Emulator.
– Save time in installing app.
• ADB always run behind device. If you are idle, adb don’t work, or restart your
emulator.
– Keep your ADB attached to device constantly.
• Commands for every push, apk installation, etc.
– Get Drag and Drop feature.
• Organization might ask you to get application from play store.
– Get Play Store.
• Genymotion
– give you all the above sweet cake.
– Supports Webcam, mike, GPS, etc. as well --------- Haven’t tested them however
– Not stable. --------- One bad out of six is never a bad.
Time UP : What next?
• OWASP mobile TOP 10
• Drozer (for Inter
Process
Communication)
• Explore new tools all
the time.
• Keep sharing.
Questions?

More Related Content

PPTX
Web application attacks
PPTX
Website hacking and prevention (All Tools,Topics & Technique )
PPTX
Cyber ppt
PPTX
Web & Cloud Security in the real world
PPT
Hacking A Web Site And Secure Web Server Techniques Used
PDF
[Wroclaw #6] Introduction to desktop browser add-ons
PPT
Writing Secure Code – Threat Defense
Web application attacks
Website hacking and prevention (All Tools,Topics & Technique )
Cyber ppt
Web & Cloud Security in the real world
Hacking A Web Site And Secure Web Server Techniques Used
[Wroclaw #6] Introduction to desktop browser add-ons
Writing Secure Code – Threat Defense

What's hot (20)

PPTX
Web Hacking Intro
PPTX
Hack and Slash: Secure Coding
PPTX
Vulnerabilities in modern web applications
PPTX
Presentation on Web Attacks
PPTX
[OWASP Poland Day] Application frameworks' vulnerabilities
PPT
PDF
Introduction to Web Application Security - Blackhoodie US 2018
PDF
Javacro 2014 Spring Security 3 Speech
PPTX
ASP.NET security vulnerabilities
PPTX
Web Security Attacks
PDF
Persistant Cookies and LDAP Injection
PPTX
3. backup file artifacts - mazin ahmed
PPTX
MS Innovation Day: A Lap Around Web Application Vulnerabilities by MVP Walter...
PDF
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
PPTX
Injection flaw teaser
PPT
Top 10 Web Security Vulnerabilities (OWASP Top 10)
PDF
Shellcoding in linux
PPTX
Microsoft Fakes, Unit Testing the (almost) Untestable Code
PPTX
SANS @Night Talk: SQL Injection Exploited
PDF
Secuirty News Bytes-Bangalore may 2014
Web Hacking Intro
Hack and Slash: Secure Coding
Vulnerabilities in modern web applications
Presentation on Web Attacks
[OWASP Poland Day] Application frameworks' vulnerabilities
Introduction to Web Application Security - Blackhoodie US 2018
Javacro 2014 Spring Security 3 Speech
ASP.NET security vulnerabilities
Web Security Attacks
Persistant Cookies and LDAP Injection
3. backup file artifacts - mazin ahmed
MS Innovation Day: A Lap Around Web Application Vulnerabilities by MVP Walter...
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
Injection flaw teaser
Top 10 Web Security Vulnerabilities (OWASP Top 10)
Shellcoding in linux
Microsoft Fakes, Unit Testing the (almost) Untestable Code
SANS @Night Talk: SQL Injection Exploited
Secuirty News Bytes-Bangalore may 2014
Ad

Viewers also liked (20)

PDF
Browser Exploit Framework
PPTX
The Shellshocker
PDF
Demystifying captcha Bangalore Meet April 18
PPTX
IE Memory Protector
PDF
Owasp Mobile Top 10 – 2014
PPTX
Recon ng null meet April 2015
PDF
Owasp m7-m8-shivang nullmeetblr 21june2015
PPTX
Venom vulnerability Overview and a basic demo
PDF
Metasploit Humla for Beginner
PPTX
Security Monitoring using SIEM null bangalore meet april 2015
PPTX
Android Performance Tips & Tricks
PPTX
Testing for Android: When, Where, and How to Successfully Use Test Automation
PPTX
Unit Testing Android Applications
PDF
Introduction to android testing - oscon 2012
PDF
Android Testing: An Overview
PPTX
Testing Android Application, Droidcon Torino
PDF
Inside Android Testing
PDF
Android Building, Testing and reversing
Browser Exploit Framework
The Shellshocker
Demystifying captcha Bangalore Meet April 18
IE Memory Protector
Owasp Mobile Top 10 – 2014
Recon ng null meet April 2015
Owasp m7-m8-shivang nullmeetblr 21june2015
Venom vulnerability Overview and a basic demo
Metasploit Humla for Beginner
Security Monitoring using SIEM null bangalore meet april 2015
Android Performance Tips & Tricks
Testing for Android: When, Where, and How to Successfully Use Test Automation
Unit Testing Android Applications
Introduction to android testing - oscon 2012
Android Testing: An Overview
Testing Android Application, Droidcon Torino
Inside Android Testing
Android Building, Testing and reversing
Ad

Similar to Rapid Android Application Security Testing (20)

PDF
Android "Fight Club" : In pursuit of APPiness -- null Humla Delhi Chapter
PDF
Android pentesting
PDF
Getting started with Android pentesting
PPTX
Mobile application security
PPTX
Mobile Application Security
PPTX
Android Penetration testing - Day 2
PPTX
Getting started with android
PDF
MobSecCon 2015 - Dynamic Analysis of Android Apps
PPTX
Mobile security part 1(Android Apps Pentesting)- Romansh yadav
PPTX
Dynamic Security Analysis & Static Security Analysis for Android Apps.
PPTX
Droidcon mobile security
PDF
us-19-Stone-Securing-The-System-A-Deep-Dive-Into-Reversing-Android-Preinstall...
PDF
Introduction to Android Development and Security
PDF
Android security and penetration testing | DIVA | Yogesh Ojha
PDF
Null Dubai Humla_Romansh_Yadav_Android_app_pentesting
PPTX
[Wroclaw #1] Android Security Workshop
PPTX
Pentesting Android Apps
PPTX
Android pentesting
PPTX
Android security by ravi-rai
PDF
Reading Group Presentation: Why Eve and Mallory Love Android
Android "Fight Club" : In pursuit of APPiness -- null Humla Delhi Chapter
Android pentesting
Getting started with Android pentesting
Mobile application security
Mobile Application Security
Android Penetration testing - Day 2
Getting started with android
MobSecCon 2015 - Dynamic Analysis of Android Apps
Mobile security part 1(Android Apps Pentesting)- Romansh yadav
Dynamic Security Analysis & Static Security Analysis for Android Apps.
Droidcon mobile security
us-19-Stone-Securing-The-System-A-Deep-Dive-Into-Reversing-Android-Preinstall...
Introduction to Android Development and Security
Android security and penetration testing | DIVA | Yogesh Ojha
Null Dubai Humla_Romansh_Yadav_Android_app_pentesting
[Wroclaw #1] Android Security Workshop
Pentesting Android Apps
Android pentesting
Android security by ravi-rai
Reading Group Presentation: Why Eve and Mallory Love Android

More from Nutan Kumar Panda (15)

PPTX
Pentesting ReST API
PPTX
Dark Arts Of Social Engineering
PPTX
OSINT Black Magic: Listen who whispers your name in the dark!!!
PDF
Win 8 password cracking
DOCX
Backtrack Manual Part10
DOCX
Backtrack Manual Part9
DOCX
Backtrack Manual Part8
DOCX
Backtrack Manual Part7
DOCX
Backtrack Manual Part6
DOCX
Backtrack Manual Part5
DOCX
Backtrack Manual Part4
DOCX
Backtrack Manual Part3
DOCX
Backtrack Manual Part2
DOCX
Backtrack manual Part1
DOCX
Google Hack
Pentesting ReST API
Dark Arts Of Social Engineering
OSINT Black Magic: Listen who whispers your name in the dark!!!
Win 8 password cracking
Backtrack Manual Part10
Backtrack Manual Part9
Backtrack Manual Part8
Backtrack Manual Part7
Backtrack Manual Part6
Backtrack Manual Part5
Backtrack Manual Part4
Backtrack Manual Part3
Backtrack Manual Part2
Backtrack manual Part1
Google Hack

Recently uploaded (6)

DOC
证书学历UoA毕业证,澳大利亚中汇学院毕业证国外大学毕业证
PPTX
PURCOM-MEDIATED-CCCOMMUNICATION-PPT.pptx
PDF
Buy Verified Stripe Accounts – Instant Access & Fully Approved.pdf
PDF
Manitou Teleskoplader Original Ersatzteilkatalog
PDF
heheheueueyeyeyegehehehhehshMedia-Literacy.pdf
PDF
6-UseCfgfhgfhgfhgfhgfhfhhaseActivity.pdf
证书学历UoA毕业证,澳大利亚中汇学院毕业证国外大学毕业证
PURCOM-MEDIATED-CCCOMMUNICATION-PPT.pptx
Buy Verified Stripe Accounts – Instant Access & Fully Approved.pdf
Manitou Teleskoplader Original Ersatzteilkatalog
heheheueueyeyeyegehehehhehshMedia-Literacy.pdf
6-UseCfgfhgfhgfhgfhgfhfhhaseActivity.pdf

Rapid Android Application Security Testing

  • 2. Agenda • Introduction to Android Testing – Static Analysis – Dynamic Analysis – Local Storage Inspection • Challenge.txt
  • 3. Android Security Testing • Can install apps on device and go hack the network. • Can install the application in the emulator and test it.
  • 4. What’s inside? • Android is a Linux kernel based OS. • Dalvik VM (Dalvik Virtual Machine) makes the dex file (Dalvik Executables) reach execution. • APK (Android Application Package) contains all the resources, i.e. manifest file, signatures, dex file, and other resources in a zipped manner.
  • 5. So what happens. • Java source code is compiled to Java byte Code using Java Compiler • Byte code is converted into Dalvik Code using Dex compiler • Dalvik Executable (Dex file) goes to “Dalvik VM” and executes within it.
  • 6. …..Continued. Dalvik VM Dalvik Executable (Dex File) Java Source Code Java Byte CodeJava Compiler Dalvik Code Dex Compiler
  • 7. Pentest. How to do? • Break the testing into three parts: – Static Testing – Dynamic Testing – Local Storage • Try to uncover issues in every phase.
  • 8. Static Analysis • Get the .apk file. • Reverse Engineer it. • Decompile / Dis-assemble it. • Dis-assemble it using – Dedexer gives assembly like output) or – Baksmali (based on dedexer and gives code more easy to understand. • Decompile it using – Dex2jar (dalvik code turns to Java byte code (jar file). – Use jd-gui to view the java source codes.h
  • 9. What to look for? • Look for api information, database connection strings, internal / external IP disclosures and ports, etc. • If you are lucky, you might get a password too, Believe me developers are crazy. • If you can go for social engineering stuff, lot of emails can be found. • Tip: A pair of /* and */ holds a lot of information.
  • 11. Dynamic Analysis • Load emulator. • Set up an Interception Proxy • Figure out SSL issues. • And follow the generic logic test cases you follow in web applications.
  • 14. Local Storage Inspection • Check for sensitive data getting stored on client side. • XML files, database files are most commonly found culprits. • Inspect memory for information sensitive information > memdump • Inspect generated logs for sensitive information > logcat. • Uninstall and check if things remain in application folder.
  • 17. Tools Of Trade • Android SDK • ADB • BurpSuite • APKtools • Smali/baksmali • Dex2jar • Genymotion • Appuse/Android Tamer.
  • 18. Challenges • AppUse is quite slow: – Save time in loading your Emulator. – Save time in installing app. • ADB always run behind device. If you are idle, adb don’t work, or restart your emulator. – Keep your ADB attached to device constantly. • Commands for every push, apk installation, etc. – Get Drag and Drop feature. • Organization might ask you to get application from play store. – Get Play Store. • Genymotion – give you all the above sweet cake. – Supports Webcam, mike, GPS, etc. as well --------- Haven’t tested them however – Not stable. --------- One bad out of six is never a bad.
  • 19. Time UP : What next? • OWASP mobile TOP 10 • Drozer (for Inter Process Communication) • Explore new tools all the time. • Keep sharing.