Skip to content
A React Native library for identifying if a phone is rooted or mocking locations
Java Objective-C JavaScript Python Ruby
Branch: master
Clone or download
GantMan Merge pull request #59 from tangnv/master
Fix bug: isDebuggedMode function does not work on iOS
Latest commit 2c27ed8 Dec 27, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
ExampleProject optimized images Oct 18, 2016
JailMonkey.xcodeproj code moved to static lib Jul 20, 2016
JailMonkey Update isDebugged key for consistent with Android Dec 27, 2019
_art optimized images Oct 18, 2016
android Check root without busybox for all devices Sep 4, 2019
.gitignore
.npmignore
LICENSE Create LICENSE Aug 11, 2017
README.md
index.js Merge branch 'master' into feature/isDebugged Mar 15, 2019
jail-monkey.podspec Adding Cocoapod integration Apr 2, 2018
jailmonkey.d.ts Improvement in general Jul 25, 2019
jailmonkey.js Improvement in general Jul 25, 2019
jailmonkey.js.flow Improvement in general Jul 25, 2019
package.json v2.3.1 Nov 3, 2019
yarn.lock

README.md

WARNING: I don't have the devices to test anymore, so testing is done by those submitting PRs bona fide.

Jail Monkey

Can you ever really trust a phone?

Why?

Are users claiming they are crossing the globe in seconds and collecting all the Pokeballs? Some apps need to protect themselves in order to protect data integrity. JailMonkey allows you to:

  • Identify if a phone has been jail-broken or rooted for iOS/Android.
  • Detect mocked locations for phones set in "developer mode".
  • (ANDROID ONLY) Detect if the application is running on external storage such as an SD card.

Use

import JailMonkey from 'jail-monkey'

// is this device JailBroken on iOS/Android?
JailMonkey.isJailBroken()

// Can this device mock location - no need to root!
JailMonkey.canMockLocation()

// Check if device violates any of the above
JailMonkey.trustFall()

// (ANDROID ONLY) Check if application is running on external storage
JailMonkey.isOnExternalStorage()

// (ANDROID ONLY) Check if the phone has some malicious apps installed
JailMonkey.hookDetected()

// Check if the application is running in debug mode
JailMonkey.isDebugged()

Circle of Trust

❗️ Since emulators are usually rooted, you might want to bypass these checks during development. Unless you're keen on constant false alarms

Install

npm i jail-monkey --save
react-native link

If you use rnpm, you may have trouble as rnpm does not link Android properly after 0.29.0!

Additional Info

This has been made public to help keep it up to date. As detection measures get better or out-dated, please send updates to this project so it can be the best method of detection.

Special thanks to this fantastic blog article: http://blog.geomoby.com/2015/01/25/how-to-avoid-getting-your-location-based-app-spoofed/

You can’t perform that action at this time.