Search packages, repositories and app categories

Package detailsv1.0.4

trust_fall

A Flutter plugin for detecting the trust fall of the device(Jailbroken, root, emulator and mock location detection).

30-day downloads
57
Likes
88
Pub points
35

Install package

flutter pub add trust_fall

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

TrustFall is a Flutter plugin designed to detect whether a device is compromised or in an insecure state. It identifies jailbroken or rooted devices, emulator environments, and the presence of mock location services—common indicators of potential security risks. By leveraging platform-specific checks, it helps applications safeguard sensitive operations by preventing execution on untrusted devices. The plugin integrates seamlessly into Flutter projects via pub.dev and is particularly useful for apps requiring high security standards.

Use cases

  • Securing financial applications
  • Preventing fraud on mobile platforms
  • Protecting premium content access
  • Detecting emulated testing environments
  • Enforcing device integrity in enterprise apps

Key features

  • Jailbreak/root detection
  • Emulator detection
  • Mock location detection
  • Cross-platform compatibility
  • Simple integration with Flutter

Suitable for

  • High-security apps
  • Financial and banking apps
  • Enterprise mobile solutions
  • Apps with premium content
  • Testing and development validation

Considerations

  • Does not guarantee 100% detection accuracy
  • May trigger false positives on some devices
  • Requires careful handling of user privacy
  • Limited to basic device integrity checks
  • Not a substitute for comprehensive security measures

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

trust_fall

A Flutter plugin for detecting the trust fall of the device(Jailbroken, root, emulator and mock location detection).

Uses RootBeer for Android root detection and DTTJailbreakDetection for iOS jailbreak detection. Inspired by jail-monkey and this blog article

Getting Started

In your flutter project add the dependency:

dependencies:
  ...
  trust_fall: ^1.0.4

Usage

Importing package
import 'package:trust_fall/trust_fall.dart';
Using it

Checks whether device JailBroken on iOS/Android?

bool isJailBroken = await TrustFall.isJailBroken;

Checks whether device is real or emulator

bool isRealDevice = await TrustFall.isRealDevice;

Can this device mock location - no need to root!

bool canMockLocation = await TrustFall.canMockLocation;

(ANDROID ONLY) Check if application is running on external storage

bool isOnExternalStorage = await TrustFall.isOnExternalStorage;

Check if device violates any of the above

bool isTrustFall = await TrustFall.isTrustFall;

Note:

Mock location detection
  • Android - Location permission needs to be granted in app in order to detect mock location properly
  • iOS - For now we are checking if device is Jail Broken or if it's not real device. There is no strong detection of mock location in iOS (Open the PR if you have better way for mock location detection in iOS)

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

Categories

Source repository

Projects using this package

No data available yet.