Skip to main content

REQUEST: Bypassing Android Screen Lock

I got a request recently to discuss how to bypass Android Screen lock. This makes sense, many times, authors "assume" you can unlock, or assume it is unlocked. I'd like to address the possibility you are testing your full cycle response skills and would like to know how to address bypassing this problem.

Below are a few common ways to address this obstacle:

So here is the thing, these methods are possible, only if adb debugging is enabled. Otherwise, your local machine (or technique that is not a commercial tool) won't be able to work with the phone's communication ability. So, here we go:


  • Check for adb on the phone: (sudo apt-get install android-tools-adb)

    • Connect the device to the forensic workstation and issue the adb devices command. If the device shows up, it means that USB debugging is enabled. 
  • Delete the gesture.key file:
    • adb.exe shell
    • cd /data/system rm gesture.key  
    • Reboot the device. The pattern lock may still appear, just draw any random design and the device will unlock.
    • or:
      • adb devices
      • adb shell
      • cd data/system
      • su
      • rm *.key
  • Update the settings.db file:
    • cd /data/data/com.android.providers.settings/databases/settings.db
    • replace!
  • Android Device Manager:
    1. Android Device Manager can also be used to unlock a device; however, this is possible only when you know the Google account credentials that are configured on the device. (ill let you decide how this information is obtained) If you have access to the account credentials, then follow these steps to unlock the device:
      1. Visit http://google.com/android/devicemanager on your workstation.
      2. Sign in using the Google account that is configured on the device.
      3. Select the device you need to unlock and click on Lock.
      1. Enter a temporary password and click on Lock again.
      2. Once it's successful, enter the temporary password on the device to unlock it.
Automated tools:
There are a few automated tools such as UFED that you can buy that will do this over hardware for you, but its not reasonable for amateurs or students.

I have to give credit to videos like this below!



Got any more ideas? Post below or email me!



Comments