RootBeer Root Detection Bypass | irsyadsec

Irsyad Muhammad Fawwaz
3 min readJun 21, 2024

--

A few months ago, I conducted penetration testing on an application and discovered that it was protected by the RootBeer library, which is used to detect rooted devices. In this article, I will demonstrate how to bypass the RootBeer library. For this demonstration, I will use a sample RootBeer application.

Before we start, I assume you are already familiar with using Frida Server and ADB.

Step-by-Step Guide to Bypass RootBeer Library

1. Setting Up the Environment

Ensure you have the following tools installed:

  • ADB (Android Debug Bridge): Used for communicating with your Android device.
  • Frida Server: A dynamic instrumentation toolkit for developers, reverse-engineers, and security researchers.
  • Emulator: in this case im using ldplayer

2. Preparing Devices

Download the appropriate Frida Server binary for your device’s architecture from the frida release page

connect to emulator

adb devices -l
adb root

Push the binary to your device using ADB:

adb push frida-server-16.0.10-android-x86_64 /data/local/tmp

give permission to thefile

adb shell
cd /data/local/tmp
chmod +x frida-server-16.0.10-android-x86_64

start frida server

./frida-server-16.0.10-android-x86_64 -D

3. Bypassing root

Here, I will use the fastest method by using an exploit file that is already available on GitHub. I am using an exploit from pich4ya, and you can download it from there. big applause for him👏👏👏👏

After downloading the file, navigate to the folder where you saved it and open the Command Prompt.

Find the name of the application package.

frida-ps -Uai

Since I am using the sample Rootbeer application, the package name is com.scottyab.rootbeer.sample

After that, run this command

frida -l root.js -U -f com.example.app --pause

after hit enter you can type again

%resume

andddd Voilaaaa your apk seharusnya sudah terbaypass

And voila! Your APK should be bypassed.

Would you like to see more insightful articles like this? Your support enables me to create valuable content. Consider buying me a coffee to fuel the creation of more free prompts. Your contribution is greatly appreciated! ❤️❤️❤️

--

--

No responses yet