
Company News
/Security News
Socket Selected for OpenAI's Cybersecurity Grant Program
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.
react-native-device-status
Advanced tools
A React Native Library to check if a device is rooted or jailbroken. It also checks if screen lock is enabled
API 16+
IOS 8+
RN 0.27+
$ npm install react-native-device-status --save
Please follow manual instructions since rnpm only help with basic linking. Note: IOS will not automatically install because I am wrapping another library via cocoapods. Please follow manual instruction. (Suggestions welcome.)
$ react-native link react-native-device-status
Libraries ➜ Add Files to [your project's name]node_modules ➜ react-native-device-status and add RNDeviceStatus.xcodeprojlibRNDeviceStatus.a to your project's Build Phases ➜ Link Binary With Libraries **$(SRCROOT)/../../React
$(SRCROOT)/../../react-native/React
${SRCROOT}/../../react-native-device-status/ios/Pods/Headers/Public
${SRCROOT}/../../react-native-device-status/ios/Pods/Headers/Public/UIDevice-PasscodeStatus**
Configure the project:
cd ios
pod init
(In case of syntax errors, open YOURApp.xcodeproj/project.pbxproj and fix them.) Edit the newly created Podfile:
#RNDeviceStatus
target "RNDeviceStatus" do
pod 'UIDevice-PasscodeStatus', '~> 0.0.2'
end
Inside your {ReactNativeProject}/ios directory add a file named Podfile with the following content
pod install
Note: If you are building inside of xcode, make sure you open the workspace file not the proejct file.
If you get the following warning.
[!] The `<YourAppName> [Debug]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods/Pods.debug.xcconfig'. This can lead to problems with the CocoaPods installation
- Use the `$(inherited)` flag, or
- Remove the build settings from the target.
[!] The `<YourAppName> [Release]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods/Pods.release.xcconfig'. This can lead to problems with the CocoaPods installation
- Use the `$(inherited)` flag, or
- Remove the build settings from the target.
Click <YourAppName>.xcodeproj in the project navigator and go the Build Settings tab. Make sure 'All' is toggled on (instead of 'Basic'). Look for Other Linker Flags and replace the value -ObjC with the value $(inherited) for your Application's Target.
If you received an libpods error for the RNDeviceStatus project, it's safe to remove under its build phases settings > Link binary with libraries
android/app/src/main/java/[...]/MainApplication.javaimport my.fin.RNDeviceStatusPackage; to the imports at the top of the filenew RNDeviceStatusPackage() to the list returned by the getPackages() methodandroid/settings.gradle:
include ':react-native-device-status'
project(':react-native-device-status').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-device-status/android/app')
android/app/build.gradle:
compile project(':react-native-device-status')
import DeviceStatus from "react-native-device-status"
// Check if device is rooted or jailbroken.
const isRooted = DeviceStatus.isRooted()
console.log(isRooted)
// Check if device has screenslock enabled.
const isLocked = await DeviceStatus.isLocked()
console.log(isLocked)
##License MIT
##Credit liamnichols - UIDevice-Password
FAQs
A React Native Library to check if a device is rooted or jailbroken. It also checks if screen lock is enabled
The npm package react-native-device-status receives a total of 1 weekly downloads. As such, react-native-device-status popularity was classified as not popular.
We found that react-native-device-status demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.

Security News
Socket CEO Feross Aboukhadijeh joins 10 Minutes or Less, a podcast by Ali Rohde, to discuss the recent surge in open source supply chain attacks.

Research
/Security News
Campaign of 108 extensions harvests identities, steals sessions, and adds backdoors to browsers, all tied to the same C2 infrastructure.