UNPKG

react-native-safeguard

Version:

A comprehensive security library for React Native applications that helps protect against various security threats including root detection, malware, tampering, and more.

64 lines (63 loc) 1.84 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.checkAll = checkAll; exports.checkApplicationSpoofing = checkApplicationSpoofing; exports.checkDeveloperOptions = checkDeveloperOptions; exports.checkKeyLogger = checkKeyLogger; exports.checkMalware = checkMalware; exports.checkNetwork = checkNetwork; exports.checkRoot = checkRoot; exports.checkScreenMirroring = checkScreenMirroring; exports.default = void 0; exports.initialize = initialize; var _reactNative = require("react-native"); const LINKING_ERROR = `The package 'react-native-safeguard' doesn't seem to be linked. Make sure: \n\n` + _reactNative.Platform.select({ ios: "- You have run 'pod install'\n", default: '' }) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo Go\n'; const Safeguard = _reactNative.NativeModules.Safeguard ? _reactNative.NativeModules.Safeguard : new Proxy({}, { get() { throw new Error(LINKING_ERROR); } }); function initialize(config = {}) { return Safeguard.initialize(config); } function checkAll() { return Safeguard.checkAll(); } function checkRoot() { return Safeguard.checkRoot(); } function checkDeveloperOptions() { return Safeguard.checkDeveloperOptions(); } function checkMalware() { return Safeguard.checkMalware(); } function checkNetwork() { return Safeguard.checkNetwork(); } function checkScreenMirroring() { return Safeguard.checkScreenMirroring(); } function checkApplicationSpoofing() { return Safeguard.checkApplicationSpoofing(); } function checkKeyLogger() { return Safeguard.checkKeyLogger(); } var _default = exports.default = { initialize, checkAll, checkRoot, checkDeveloperOptions, checkMalware, checkNetwork, checkScreenMirroring, checkApplicationSpoofing, checkKeyLogger }; //# sourceMappingURL=index.js.map