SlideShare ist ein Scribd-Unternehmen logo
1 von 39
Mobile Application Security Testing
3 Angles to perform a successful security
testing
1. Client Side Checks;
2. Dynamic / Runtime / Local Storage / DB /
SD Checks &
3. Static Code Analysis (a.k.a Reverse Engg.)
By : Abhilash @ IBM
Static Code Analysis
Why Static Code Analysis is required ?
In Lay-man terms  Code analysis
of ApK file….
M1, M4, M5,
 M1 : Improper Platform Usage : Android Intents,
permissions
 M4 : Insecure Authorization : Identifying Session keys,
session mgmt. logic
 M5 – Insufficient Cryptography : covering cryptographic
keys (like Md5, SHA keys) and encryption logic
M7, M8, M9,M10
 M7 – Client Code Quality : like buffer overflows, format string
vulnerabilities, and various other code-level mistakes
 M8 – Code Tampering : covers binary patching, local resource
modification, method hooking and dynamic memory
modification.
 M9 – Reverse Engineering : analysis of libraries, algorithms,
and other assets.
 M10 – Extraneous Functionality : Hidden backdoor
functionalities , commented code (accidently left by
developer)
7/10 M’s are covered in Static Code
Analysis
Which is >50%
Fetching APK
 For enterprise / intranet Applications  Product Team
 Via Online
 https://apkpure.com/
 http://apps.evozi.com/apk-
downloader/?id=com.vng.g6.a.zombie
https://play.google.com/store/apps/details?id=com
.vng.g6.a.zombie&hl=en
Conversion of APK to Source Code
 Manual via dex2jar/Apktool
 http://stackoverflow.com/questions/12732882/reverse-engineering-from-an-apk-
file-to-a-project
 Via Online
 http://www.javadecompilers.com/apk
 Apk files are nothing but zip files.
 Zip files contains resources and assembled java code
 But unzip will miss classes.dex and resources.arsc files
ANDROID APP STRUCTURE
Methods to perform Code Analysis
 Manual
 Automated
Manual Code Analysis
Installing and Configuring Text Editors
 Android Studio (or)
 Sublime Text
Why Sublime Text ?
Goto Anything functionality
Search of Key strokes
Quick File Switching
 Demo
What needs to be looked :
Samples - hardcoded passwords
Samples - Encryption
Automated Code Analysis
 MobSF (Mobile Security Framework)
 QARK (Quick Android Review Kit)
 ApkTool
 & Many more…… both commercial and open source tools
available…
*These are open source tools
Installing and Configuring MobSF
 Demo
Installing and Configuring QARK
 Demo
Installing and Configuring ApkTool
 Demo
Android Intents
 An intent is a Messaging
Object
 which can be used to
request an Action from
an another App
Component.
 App Components can be
 Activities ; Services ;
 Broadcast Receivers ;
 Content Providers
 2 types of Intents
 Explicit
 Implicit
Some of the uses of Intents are
 Start a Service
 Launch an Activity
 Display a web page
 Display List of Contacts
 Broadcast a Message and
 Many More …………………………….
Doubt !!!
Y intents are used Y not APIs ?
API Intent
API calls are Synchronous Intent based calls are
Asynchronous
API calls are compile-time
binding
Intent based calls are run-
time binding
BUT …. Intents can similarly be
used as APIs  Explicit
Implicit Intents
 Implicit intents
are often used
to activate
components in
other
applications.
 Doesn’t Specify
the
Component…
Common Flaws
 Dangerous to send/broadcast sensitive information / data
across implicit intents
 Since unprivileged implicit intent can use the same
data
 Intercept your data
 Malicious Injection at
 Broadcast Level
 Activity Level
 Service Launch
Explicit Intents
 An explicit intent is most
commonly used when
launching an activity (from
another one) within the
same application.
 Specifies the component
Example
Next Time 
 Playing around Intents
 Deep-drive in Intent Filters
 Malicious Intents
 Intent Spoofing and intent traffic analysis
 Prevention techniques
 Self signing of Android app for reverse engg.
Thankyou….

Weitere ähnliche Inhalte

Was ist angesagt?

Pentesting Android Applications
Pentesting Android ApplicationsPentesting Android Applications
Pentesting Android ApplicationsCláudio André
 
Android reverse engineering: understanding third-party applications. OWASP EU...
Android reverse engineering: understanding third-party applications. OWASP EU...Android reverse engineering: understanding third-party applications. OWASP EU...
Android reverse engineering: understanding third-party applications. OWASP EU...Internet Security Auditors
 
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...Ajin Abraham
 
iOS Application Security
iOS Application SecurityiOS Application Security
iOS Application SecurityEgor Tolstoy
 
Hacking and securing ios applications
Hacking and securing ios applicationsHacking and securing ios applications
Hacking and securing ios applicationsSatish b
 
MobSF: Mobile Security Testing (Android/IoS)
MobSF: Mobile Security Testing (Android/IoS)MobSF: Mobile Security Testing (Android/IoS)
MobSF: Mobile Security Testing (Android/IoS)Agile Testing Alliance
 
Android Application Penetration Testing - Mohammed Adam
Android Application Penetration Testing - Mohammed AdamAndroid Application Penetration Testing - Mohammed Adam
Android Application Penetration Testing - Mohammed AdamMohammed Adam
 
Android Security & Penetration Testing
Android Security & Penetration TestingAndroid Security & Penetration Testing
Android Security & Penetration TestingSubho Halder
 
Getting started with Android pentesting
Getting started with Android pentestingGetting started with Android pentesting
Getting started with Android pentestingMinali Arora
 
Android security and penetration testing | DIVA | Yogesh Ojha
Android security and penetration testing | DIVA | Yogesh OjhaAndroid security and penetration testing | DIVA | Yogesh Ojha
Android security and penetration testing | DIVA | Yogesh OjhaYogesh Ojha
 
Pwning mobile apps without root or jailbreak
Pwning mobile apps without root or jailbreakPwning mobile apps without root or jailbreak
Pwning mobile apps without root or jailbreakAbraham Aranguren
 
IBM Security Software Solutions - Powerpoint
 IBM Security Software Solutions - Powerpoint IBM Security Software Solutions - Powerpoint
IBM Security Software Solutions - PowerpointThierry Matusiak
 
Mobile Application Penetration Testing
Mobile Application Penetration TestingMobile Application Penetration Testing
Mobile Application Penetration TestingBGA Cyber Security
 
iOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersiOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersRyanISI
 
Practical Application of the API Security Top Ten: A Tester's Perspective
Practical Application of the API Security Top Ten: A Tester's PerspectivePractical Application of the API Security Top Ten: A Tester's Perspective
Practical Application of the API Security Top Ten: A Tester's PerspectiveRajniHatti
 
Android security
Android securityAndroid security
Android securityMobile Rtpl
 

Was ist angesagt? (20)

Pentesting Android Apps
Pentesting Android AppsPentesting Android Apps
Pentesting Android Apps
 
Pentesting Android Applications
Pentesting Android ApplicationsPentesting Android Applications
Pentesting Android Applications
 
Android reverse engineering: understanding third-party applications. OWASP EU...
Android reverse engineering: understanding third-party applications. OWASP EU...Android reverse engineering: understanding third-party applications. OWASP EU...
Android reverse engineering: understanding third-party applications. OWASP EU...
 
OWASP Top 10 for Mobile
OWASP Top 10 for MobileOWASP Top 10 for Mobile
OWASP Top 10 for Mobile
 
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...
Nullcon Goa 2016 - Automated Mobile Application Security Testing with Mobile ...
 
iOS Application Security
iOS Application SecurityiOS Application Security
iOS Application Security
 
Hacking and securing ios applications
Hacking and securing ios applicationsHacking and securing ios applications
Hacking and securing ios applications
 
MobSF: Mobile Security Testing (Android/IoS)
MobSF: Mobile Security Testing (Android/IoS)MobSF: Mobile Security Testing (Android/IoS)
MobSF: Mobile Security Testing (Android/IoS)
 
iOS Application Penetration Testing
iOS Application Penetration TestingiOS Application Penetration Testing
iOS Application Penetration Testing
 
Android Application Penetration Testing - Mohammed Adam
Android Application Penetration Testing - Mohammed AdamAndroid Application Penetration Testing - Mohammed Adam
Android Application Penetration Testing - Mohammed Adam
 
Android Security & Penetration Testing
Android Security & Penetration TestingAndroid Security & Penetration Testing
Android Security & Penetration Testing
 
Mobile security
Mobile securityMobile security
Mobile security
 
Getting started with Android pentesting
Getting started with Android pentestingGetting started with Android pentesting
Getting started with Android pentesting
 
Android security and penetration testing | DIVA | Yogesh Ojha
Android security and penetration testing | DIVA | Yogesh OjhaAndroid security and penetration testing | DIVA | Yogesh Ojha
Android security and penetration testing | DIVA | Yogesh Ojha
 
Pwning mobile apps without root or jailbreak
Pwning mobile apps without root or jailbreakPwning mobile apps without root or jailbreak
Pwning mobile apps without root or jailbreak
 
IBM Security Software Solutions - Powerpoint
 IBM Security Software Solutions - Powerpoint IBM Security Software Solutions - Powerpoint
IBM Security Software Solutions - Powerpoint
 
Mobile Application Penetration Testing
Mobile Application Penetration TestingMobile Application Penetration Testing
Mobile Application Penetration Testing
 
iOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for BeginnersiOS Application Penetration Testing for Beginners
iOS Application Penetration Testing for Beginners
 
Practical Application of the API Security Top Ten: A Tester's Perspective
Practical Application of the API Security Top Ten: A Tester's PerspectivePractical Application of the API Security Top Ten: A Tester's Perspective
Practical Application of the API Security Top Ten: A Tester's Perspective
 
Android security
Android securityAndroid security
Android security
 

Andere mochten auch

Gursev kalra _mobile_application_security_testing - ClubHack2009
Gursev kalra _mobile_application_security_testing - ClubHack2009Gursev kalra _mobile_application_security_testing - ClubHack2009
Gursev kalra _mobile_application_security_testing - ClubHack2009ClubHack
 
Anonymous Security Scanning and Browsing
Anonymous Security Scanning and BrowsingAnonymous Security Scanning and Browsing
Anonymous Security Scanning and BrowsingAbhilash Venkata
 
Mobile application security – effective methodology, efficient testing! hem...
Mobile application security – effective methodology, efficient testing!   hem...Mobile application security – effective methodology, efficient testing!   hem...
Mobile application security – effective methodology, efficient testing! hem...owaspindia
 
IBM AppScan Standard - The Web Application Security Solution
IBM AppScan Standard - The Web Application Security SolutionIBM AppScan Standard - The Web Application Security Solution
IBM AppScan Standard - The Web Application Security Solutionhearme limited company
 
Mathematics ppt on trigonometry
Mathematics ppt on trigonometryMathematics ppt on trigonometry
Mathematics ppt on trigonometryniks957
 
How to scale mobile application security testing
How to scale mobile application security testingHow to scale mobile application security testing
How to scale mobile application security testingNowSecure
 
Cybersecurity Best Practices in Financial Services
Cybersecurity Best Practices in Financial ServicesCybersecurity Best Practices in Financial Services
Cybersecurity Best Practices in Financial ServicesJohn Rapa
 
Static Application Security Testing Strategies for Automation and Continuous ...
Static Application Security Testing Strategies for Automation and Continuous ...Static Application Security Testing Strategies for Automation and Continuous ...
Static Application Security Testing Strategies for Automation and Continuous ...Kevin Fealey
 
Web and Mobile Application Security
Web and Mobile Application SecurityWeb and Mobile Application Security
Web and Mobile Application SecurityPrateek Jain
 
Basic Guide For Mobile Application Testing
Basic Guide For Mobile Application TestingBasic Guide For Mobile Application Testing
Basic Guide For Mobile Application TestingSourabh Kasliwal
 
Security Testing Mobile Applications
Security Testing Mobile ApplicationsSecurity Testing Mobile Applications
Security Testing Mobile ApplicationsDenim Group
 
The curious case of mobile app security.pptx
The curious case of mobile app security.pptxThe curious case of mobile app security.pptx
The curious case of mobile app security.pptxAnkit Giri
 
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.com
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.comMobile Application Security Testing, Testing for Mobility App | www.idexcel.com
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.comIdexcel Technologies
 
Mobile Application Security
Mobile Application SecurityMobile Application Security
Mobile Application Securitycclark_isec
 
Some application of trignometry
Some application of trignometrySome application of trignometry
Some application of trignometryshivujagga
 
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...Alexis May
 
Encuentro de directores: Acoso escolar
Encuentro de directores: Acoso escolarEncuentro de directores: Acoso escolar
Encuentro de directores: Acoso escolarEducación Innovación
 
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human Beings
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human BeingsHOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human Beings
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human BeingsAzamat Abdoullaev
 

Andere mochten auch (20)

Gursev kalra _mobile_application_security_testing - ClubHack2009
Gursev kalra _mobile_application_security_testing - ClubHack2009Gursev kalra _mobile_application_security_testing - ClubHack2009
Gursev kalra _mobile_application_security_testing - ClubHack2009
 
Anonymous Security Scanning and Browsing
Anonymous Security Scanning and BrowsingAnonymous Security Scanning and Browsing
Anonymous Security Scanning and Browsing
 
Mobile application security – effective methodology, efficient testing! hem...
Mobile application security – effective methodology, efficient testing!   hem...Mobile application security – effective methodology, efficient testing!   hem...
Mobile application security – effective methodology, efficient testing! hem...
 
IBM AppScan Standard - The Web Application Security Solution
IBM AppScan Standard - The Web Application Security SolutionIBM AppScan Standard - The Web Application Security Solution
IBM AppScan Standard - The Web Application Security Solution
 
Mathematics ppt on trigonometry
Mathematics ppt on trigonometryMathematics ppt on trigonometry
Mathematics ppt on trigonometry
 
How to scale mobile application security testing
How to scale mobile application security testingHow to scale mobile application security testing
How to scale mobile application security testing
 
Cybersecurity Best Practices in Financial Services
Cybersecurity Best Practices in Financial ServicesCybersecurity Best Practices in Financial Services
Cybersecurity Best Practices in Financial Services
 
Mobile Apps Security Testing -1
Mobile Apps Security Testing -1Mobile Apps Security Testing -1
Mobile Apps Security Testing -1
 
Static Application Security Testing Strategies for Automation and Continuous ...
Static Application Security Testing Strategies for Automation and Continuous ...Static Application Security Testing Strategies for Automation and Continuous ...
Static Application Security Testing Strategies for Automation and Continuous ...
 
Web and Mobile Application Security
Web and Mobile Application SecurityWeb and Mobile Application Security
Web and Mobile Application Security
 
Basic Guide For Mobile Application Testing
Basic Guide For Mobile Application TestingBasic Guide For Mobile Application Testing
Basic Guide For Mobile Application Testing
 
Security Testing Mobile Applications
Security Testing Mobile ApplicationsSecurity Testing Mobile Applications
Security Testing Mobile Applications
 
The curious case of mobile app security.pptx
The curious case of mobile app security.pptxThe curious case of mobile app security.pptx
The curious case of mobile app security.pptx
 
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.com
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.comMobile Application Security Testing, Testing for Mobility App | www.idexcel.com
Mobile Application Security Testing, Testing for Mobility App | www.idexcel.com
 
Mobile Application Security
Mobile Application SecurityMobile Application Security
Mobile Application Security
 
Some application of trignometry
Some application of trignometrySome application of trignometry
Some application of trignometry
 
SMAC
SMACSMAC
SMAC
 
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...
Martin Peat and Dawn Jordan, Strategic Projects Team - Open Forum Events' NHS...
 
Encuentro de directores: Acoso escolar
Encuentro de directores: Acoso escolarEncuentro de directores: Acoso escolar
Encuentro de directores: Acoso escolar
 
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human Beings
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human BeingsHOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human Beings
HOMO SAPIENS or HOMO BRUTUS: HUMAN ONTOLOGY: On the Essence of Human Beings
 

Ähnlich wie Mobile Application Security Testing (Static Code Analysis) of Android App

Android Penetration testing - Day 2
 Android Penetration testing - Day 2 Android Penetration testing - Day 2
Android Penetration testing - Day 2Mohammed Adam
 
Droidcon mobile security
Droidcon   mobile securityDroidcon   mobile security
Droidcon mobile securityJudy Ngure
 
Mobile application security
Mobile application securityMobile application security
Mobile application securityShubhneet Goel
 
Mobile Application Security
Mobile Application SecurityMobile Application Security
Mobile Application SecurityIshan Girdhar
 
COVERT app
COVERT appCOVERT app
COVERT appitba9
 
Reading Group Presentation: Why Eve and Mallory Love Android
Reading Group Presentation: Why Eve and Mallory Love AndroidReading Group Presentation: Why Eve and Mallory Love Android
Reading Group Presentation: Why Eve and Mallory Love AndroidMichael Rushanan
 
Dynamic Analysis of Windows Phone 7 Apps
Dynamic Analysis of Windows Phone 7 AppsDynamic Analysis of Windows Phone 7 Apps
Dynamic Analysis of Windows Phone 7 AppsSensePost
 
How to Test Security and Vulnerability of Your Android and iOS Apps
How to Test Security and Vulnerability of Your Android and iOS AppsHow to Test Security and Vulnerability of Your Android and iOS Apps
How to Test Security and Vulnerability of Your Android and iOS AppsBitbar
 
Internet security evaluation system documentation nikitha
Internet security evaluation system documentation nikithaInternet security evaluation system documentation nikitha
Internet security evaluation system documentation nikithaSusmitha Reddy
 
Security testing of mobile applications
Security testing of mobile applicationsSecurity testing of mobile applications
Security testing of mobile applicationsGTestClub
 
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...apidays
 
Software Analytics: Data Analytics for Software Engineering and Security
Software Analytics: Data Analytics for Software Engineering and SecuritySoftware Analytics: Data Analytics for Software Engineering and Security
Software Analytics: Data Analytics for Software Engineering and SecurityTao Xie
 
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case StudyFinding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case StudyDevOps.com
 
Security of LLM APIs by Ankita Gupta, Akto.io
Security of LLM APIs by Ankita Gupta, Akto.ioSecurity of LLM APIs by Ankita Gupta, Akto.io
Security of LLM APIs by Ankita Gupta, Akto.ioNordic APIs
 
Top 10 static code analysis tool
Top 10 static code analysis toolTop 10 static code analysis tool
Top 10 static code analysis toolscmGalaxy Inc
 
MobSecCon 2015 - Dynamic Analysis of Android Apps
MobSecCon 2015 - Dynamic Analysis of Android AppsMobSecCon 2015 - Dynamic Analysis of Android Apps
MobSecCon 2015 - Dynamic Analysis of Android AppsRon Munitz
 

Ähnlich wie Mobile Application Security Testing (Static Code Analysis) of Android App (20)

Android Penetration testing - Day 2
 Android Penetration testing - Day 2 Android Penetration testing - Day 2
Android Penetration testing - Day 2
 
Droidcon mobile security
Droidcon   mobile securityDroidcon   mobile security
Droidcon mobile security
 
Mobile application security
Mobile application securityMobile application security
Mobile application security
 
Mobile Application Security
Mobile Application SecurityMobile Application Security
Mobile Application Security
 
mobsf.pdf
mobsf.pdfmobsf.pdf
mobsf.pdf
 
COVERT app
COVERT appCOVERT app
COVERT app
 
Reading Group Presentation: Why Eve and Mallory Love Android
Reading Group Presentation: Why Eve and Mallory Love AndroidReading Group Presentation: Why Eve and Mallory Love Android
Reading Group Presentation: Why Eve and Mallory Love Android
 
Untitled 1
Untitled 1Untitled 1
Untitled 1
 
Dynamic Analysis of Windows Phone 7 Apps
Dynamic Analysis of Windows Phone 7 AppsDynamic Analysis of Windows Phone 7 Apps
Dynamic Analysis of Windows Phone 7 Apps
 
How to Test Security and Vulnerability of Your Android and iOS Apps
How to Test Security and Vulnerability of Your Android and iOS AppsHow to Test Security and Vulnerability of Your Android and iOS Apps
How to Test Security and Vulnerability of Your Android and iOS Apps
 
Internet security evaluation system documentation nikitha
Internet security evaluation system documentation nikithaInternet security evaluation system documentation nikitha
Internet security evaluation system documentation nikitha
 
Security testing of mobile applications
Security testing of mobile applicationsSecurity testing of mobile applications
Security testing of mobile applications
 
Owasp m7-m8-shivang nullmeetblr 21june2015
Owasp m7-m8-shivang nullmeetblr 21june2015Owasp m7-m8-shivang nullmeetblr 21june2015
Owasp m7-m8-shivang nullmeetblr 21june2015
 
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...
apidays Hong Kong - Attack API Architecture, Alvin Tam, Hong Kong Computer So...
 
API SECURITY
API SECURITYAPI SECURITY
API SECURITY
 
Software Analytics: Data Analytics for Software Engineering and Security
Software Analytics: Data Analytics for Software Engineering and SecuritySoftware Analytics: Data Analytics for Software Engineering and Security
Software Analytics: Data Analytics for Software Engineering and Security
 
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case StudyFinding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
 
Security of LLM APIs by Ankita Gupta, Akto.io
Security of LLM APIs by Ankita Gupta, Akto.ioSecurity of LLM APIs by Ankita Gupta, Akto.io
Security of LLM APIs by Ankita Gupta, Akto.io
 
Top 10 static code analysis tool
Top 10 static code analysis toolTop 10 static code analysis tool
Top 10 static code analysis tool
 
MobSecCon 2015 - Dynamic Analysis of Android Apps
MobSecCon 2015 - Dynamic Analysis of Android AppsMobSecCon 2015 - Dynamic Analysis of Android Apps
MobSecCon 2015 - Dynamic Analysis of Android Apps
 

Mobile Application Security Testing (Static Code Analysis) of Android App

  • 1. Mobile Application Security Testing 3 Angles to perform a successful security testing 1. Client Side Checks; 2. Dynamic / Runtime / Local Storage / DB / SD Checks & 3. Static Code Analysis (a.k.a Reverse Engg.) By : Abhilash @ IBM
  • 2. Static Code Analysis Why Static Code Analysis is required ? In Lay-man terms  Code analysis of ApK file….
  • 3. M1, M4, M5,  M1 : Improper Platform Usage : Android Intents, permissions  M4 : Insecure Authorization : Identifying Session keys, session mgmt. logic  M5 – Insufficient Cryptography : covering cryptographic keys (like Md5, SHA keys) and encryption logic
  • 4. M7, M8, M9,M10  M7 – Client Code Quality : like buffer overflows, format string vulnerabilities, and various other code-level mistakes  M8 – Code Tampering : covers binary patching, local resource modification, method hooking and dynamic memory modification.  M9 – Reverse Engineering : analysis of libraries, algorithms, and other assets.  M10 – Extraneous Functionality : Hidden backdoor functionalities , commented code (accidently left by developer)
  • 5. 7/10 M’s are covered in Static Code Analysis Which is >50%
  • 6. Fetching APK  For enterprise / intranet Applications  Product Team  Via Online  https://apkpure.com/  http://apps.evozi.com/apk- downloader/?id=com.vng.g6.a.zombie https://play.google.com/store/apps/details?id=com .vng.g6.a.zombie&hl=en
  • 7. Conversion of APK to Source Code  Manual via dex2jar/Apktool  http://stackoverflow.com/questions/12732882/reverse-engineering-from-an-apk- file-to-a-project  Via Online  http://www.javadecompilers.com/apk  Apk files are nothing but zip files.  Zip files contains resources and assembled java code  But unzip will miss classes.dex and resources.arsc files
  • 9. Methods to perform Code Analysis  Manual  Automated
  • 11. Installing and Configuring Text Editors  Android Studio (or)  Sublime Text Why Sublime Text ? Goto Anything functionality Search of Key strokes Quick File Switching  Demo
  • 12.
  • 13. What needs to be looked :
  • 14. Samples - hardcoded passwords
  • 15.
  • 17.
  • 18.
  • 19.
  • 21.  MobSF (Mobile Security Framework)  QARK (Quick Android Review Kit)  ApkTool  & Many more…… both commercial and open source tools available… *These are open source tools
  • 22. Installing and Configuring MobSF  Demo
  • 23.
  • 24.
  • 25. Installing and Configuring QARK  Demo
  • 26.
  • 27.
  • 28. Installing and Configuring ApkTool  Demo
  • 29.
  • 30.
  • 31. Android Intents  An intent is a Messaging Object  which can be used to request an Action from an another App Component.  App Components can be  Activities ; Services ;  Broadcast Receivers ;  Content Providers  2 types of Intents  Explicit  Implicit
  • 32. Some of the uses of Intents are  Start a Service  Launch an Activity  Display a web page  Display List of Contacts  Broadcast a Message and  Many More …………………………….
  • 33. Doubt !!! Y intents are used Y not APIs ? API Intent API calls are Synchronous Intent based calls are Asynchronous API calls are compile-time binding Intent based calls are run- time binding BUT …. Intents can similarly be used as APIs  Explicit
  • 34. Implicit Intents  Implicit intents are often used to activate components in other applications.  Doesn’t Specify the Component…
  • 35. Common Flaws  Dangerous to send/broadcast sensitive information / data across implicit intents  Since unprivileged implicit intent can use the same data  Intercept your data  Malicious Injection at  Broadcast Level  Activity Level  Service Launch
  • 36. Explicit Intents  An explicit intent is most commonly used when launching an activity (from another one) within the same application.  Specifies the component
  • 38. Next Time   Playing around Intents  Deep-drive in Intent Filters  Malicious Intents  Intent Spoofing and intent traffic analysis  Prevention techniques  Self signing of Android app for reverse engg.

Hinweis der Redaktion

  1. side-channel data leakage - vulnerabilities from the OS, frameworks, compiler environment, new hardware, etc
  2. https://github.com/androguard/androguard
  3. https://www.appvigil.co/blog/2015/04/intent-spoofing-vulnerability-in-android-apps/ https://github.com/pwntester/OWASP-GoatDroid-Dolphis