Skip to content

asecurityguru/Android-InsecureBankv2

Repository files navigation

InsecureBankv2 and Diva Vulnerable Apps - Mobile Security Testing Repo by ASG and Raghu

To understand the vulnerabilities on the mobile platform as growing number of users are using a personal smartphones and such devices have complex operations that we might not understand the vulnerability behind it. Today's lesson will be based on using Top 10 Mobile Vulnerabilities provided by OWASP as a guideline.

Resources

Useful Links

Genymotion With VirtualBox - https://dl.genymotion.com/releases/genymotion-3.5.0/genymotion-3.5.0-vbox.exe

VirtualBox - https://www.virtualbox.org/wiki/Downloads

MobSF - https://github.com/MobSF/Mobile-Security-Framework-MobSF

MobSF Guide https://mobsf.github.io/docs/#/mobsf_docker

OWASP Mobile Application Securityhttps://mas.owasp.org/

OWASP Mobile Testing Checklisthttps://docs.google.com/spreadsheets/d/1MZIvJ5Aze-zpyzLvQZVwyzF0bKWRPfnEd7nqFeH2PfA/edit#gid=997157040

Learning

Vulnerable Tools

  1. https://github.com/payatu/diva-android
  2. https://github.com/dineshshetty/Android-InsecureBankv2

Decompilers

Obfuscators

Attacking Tools

Securing Tools

Debugging Compiled APK

Top 10 Vulnerabilities 2023

  • M1: Improper Credential Usage
  • M2: Inadequate Supply Chain Security
  • M3: Insecure Authentication/Authorization
  • M4: Insufficient Input/Output Validation
  • M5: Insecure Communication
  • M6: Inadequate Privacy Controls
  • M7: Insufficient Binary Protections
  • M8: Security Misconfiguration
  • M9: Insecure Data Storage
  • M10: Insufficient Cryptography

Android App Security Checklist

A checklist with security considerations for designing, testing, and releasing secure Android apps. It is based on the OWASP Mobile Application Security Verification Standard, Mobile Application Security Testing Guide and others. Follow the links on each checklist item for detailed instructions and recommendations.


Data Storage

Platform Interaction

Cryptography

Authentication

WebViews

Network

Code Quality

Defense-in-Depth

Programs Required

Steps

Reverse Engineer APK Files

  1. Run the following command in terminal on the APK
sh dex2jar.sh diva-beta.apk
  1. Once done, a jar file should be generated.
  2. Open the jar file using JD-GUI
  3. Now you have all the Java Files

Find AndroidManifest.xml

AndroidManifest.xml contains all Android intents (pages) and permissions that the application provides.

  1. Run the following command in terminal
java -jar apktool_2.0.3.jar d diva-beta.apk -o output
  1. Now you should see the XML Document!

Challenge 1 - Insecure Logging (DIVA Android)

Sometimes developers keeps sensitive data logged into the developer console. Find a way to extract the information keyed in by the user

Hint: logcat

Solution

  1. Run the following command in terminal
$ adb logcat
  1. Look for the following line in terminal
E/diva-log( 1695): Error while processing transaction with credit card: 0000000000
  1. Open up JD-GUI to see the code causing this vulnerability

Android Storage Options

https://developer.android.com/guide/topics/data/data-storage.html

  • Shared Preferences
  • SQLite Databases
  • Internal Storage
  • External Storage
  • Network Connection

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published