Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
Binary file not shown.
65 changes: 65 additions & 0 deletions .yarn/patches/@walletconnect-core-npm-2.16.1-42d08707e6.patch

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
diff --git a/package.json b/package.json
index e203182cf9b033d8553f0c52f1f9f73c4c7badc6..cdf6d136d1b078516ff2d1eccbe9879fc7b6bcb1 100644
--- a/package.json
+++ b/package.json
@@ -53,5 +53,35 @@
"@walletconnect/jsonrpc-provider": "1.0.14",
"@walletconnect/jsonrpc-ws-connection": "1.0.14",
"@walletconnect/relay-api": "1.0.11"
+ },
+ "react-native": {
+ "zlib": "browserify-zlib",
+ "http": "@tradle/react-native-http",
+ "https": "https-browserify",
+ "os": "react-native-os",
+ "path": "path-browserify",
+ "fs": "react-native-level-fs",
+ "_stream_transform": "readable-stream/transform",
+ "_stream_readable": "readable-stream/readable",
+ "_stream_writable": "readable-stream/writable",
+ "_stream_duplex": "readable-stream/duplex",
+ "_stream_passthrough": "readable-stream/passthrough",
+ "stream": "stream-browserify",
+ "vm": "vm-browserify"
+ },
+ "browser": {
+ "zlib": "browserify-zlib",
+ "http": "@tradle/react-native-http",
+ "https": "https-browserify",
+ "os": "react-native-os",
+ "path": "path-browserify",
+ "fs": "react-native-level-fs",
+ "_stream_transform": "readable-stream/transform",
+ "_stream_readable": "readable-stream/readable",
+ "_stream_writable": "readable-stream/writable",
+ "_stream_duplex": "readable-stream/duplex",
+ "_stream_passthrough": "readable-stream/passthrough",
+ "stream": "stream-browserify",
+ "vm": "vm-browserify"
}
}
83 changes: 83 additions & 0 deletions .yarn/patches/@walletconnect-utils-npm-2.17.2-43f96abc05.patch

Large diffs are not rendered by default.

103 changes: 103 additions & 0 deletions .yarn/patches/jail-monkey-npm-2.8.0-77e4d06b40.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
diff --git a/android/src/main/java/com/gantix/JailMonkey/JailMonkeyModule.java b/android/src/main/java/com/gantix/JailMonkey/JailMonkeyModule.java
index 018d7051a57a2250c738e018ba8e1518d1b9525a..e89a135c10edc50174315c5cf0a3c9871fe65e6a 100644
--- a/android/src/main/java/com/gantix/JailMonkey/JailMonkeyModule.java
+++ b/android/src/main/java/com/gantix/JailMonkey/JailMonkeyModule.java
@@ -74,11 +74,7 @@ public class JailMonkeyModule extends ReactContextBaseJavaModule {
final Map<String, Object> constants = new HashMap<>();

constants.put("isJailBroken", rootedCheck.isJailBroken());
- constants.put("rootedDetectionMethods", rootedCheck.getResultByDetectionMethod());
- constants.put("hookDetected", hookDetected(context));
- constants.put("canMockLocation", isMockLocationOn(context));
- constants.put("isOnExternalStorage", isOnExternalStorage(context));
- constants.put("AdbEnabled", AdbEnabled(context));
return constants;
}
}
+
diff --git a/android/src/main/java/com/gantix/JailMonkey/Rooted/RootedCheck.java b/android/src/main/java/com/gantix/JailMonkey/Rooted/RootedCheck.java
index bf75f27fd11293205bf6d58de4f8069ea0a155fe..2151858623d5be0f58aa752a1d8b16bafc133dd0 100644
--- a/android/src/main/java/com/gantix/JailMonkey/Rooted/RootedCheck.java
+++ b/android/src/main/java/com/gantix/JailMonkey/Rooted/RootedCheck.java
@@ -4,6 +4,7 @@ import android.content.Context;
import com.scottyab.rootbeer.RootBeer;
import java.util.HashMap;
import java.util.Map;
+import java.util.concurrent.CountDownLatch;

public class RootedCheck {
private static boolean checkWithJailMonkeyMethod() {
@@ -17,12 +18,23 @@ public class RootedCheck {
return check.checkRooted();
}

- private final boolean jailMonkeyResult;
- private final RootBeerResults rootBeerResults;
+ private static boolean jailMonkeyResult;
+ private static RootBeerResults rootBeerResults;
+ private static CountDownLatch latch = new CountDownLatch(1);
+ public static void precompute(Context context) {
+ new Thread(() -> {
+ jailMonkeyResult = checkWithJailMonkeyMethod();
+ rootBeerResults = new RootBeerResults(context);
+ latch.countDown();
+ }).start();
+ }

public RootedCheck(Context context) {
- jailMonkeyResult = checkWithJailMonkeyMethod();
- rootBeerResults = new RootBeerResults(context);
+ try {
+ latch.await();
+ } catch (InterruptedException e) {
+ throw new RuntimeException(e);
+ }
}

public boolean isJailBroken() {
@@ -87,3 +99,4 @@ public class RootedCheck {
}
}
}
+
diff --git a/package.json b/package.json
index 31d682cd52b478e9de01b09838f19975a87352d1..0049a8b91762f6208d3b2e6256895da6c034b727 100644
--- a/package.json
+++ b/package.json
@@ -61,5 +61,35 @@
"ts-check": "npx tsc jailmonkey.d.ts --noEmit"
},
"typings": "./jailmonkey.d.ts",
- "version": "2.8.0"
+ "version": "2.8.0",
+ "react-native": {
+ "zlib": "browserify-zlib",
+ "http": "@tradle/react-native-http",
+ "https": "https-browserify",
+ "os": "react-native-os",
+ "path": "path-browserify",
+ "fs": "react-native-level-fs",
+ "_stream_transform": "readable-stream/transform",
+ "_stream_readable": "readable-stream/readable",
+ "_stream_writable": "readable-stream/writable",
+ "_stream_duplex": "readable-stream/duplex",
+ "_stream_passthrough": "readable-stream/passthrough",
+ "stream": "stream-browserify",
+ "vm": "vm-browserify"
+ },
+ "browser": {
+ "zlib": "browserify-zlib",
+ "http": "@tradle/react-native-http",
+ "https": "https-browserify",
+ "os": "react-native-os",
+ "path": "path-browserify",
+ "fs": "react-native-level-fs",
+ "_stream_transform": "readable-stream/transform",
+ "_stream_readable": "readable-stream/readable",
+ "_stream_writable": "readable-stream/writable",
+ "_stream_duplex": "readable-stream/duplex",
+ "_stream_passthrough": "readable-stream/passthrough",
+ "stream": "stream-browserify",
+ "vm": "vm-browserify"
+ }
}
6 changes: 3 additions & 3 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
checksumBehavior: update

enableScripts: false

enableTelemetry: false
Expand All @@ -6,12 +8,10 @@ nmHoistingLimits: workspaces

nmSelfReferences: false

checksumBehavior: update

nodeLinker: node-modules

plugins:
- path: .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs
spec: '@yarnpkg/plugin-workspace-tools'
spec: "@yarnpkg/plugin-workspace-tools"

yarnPath: .yarn/releases/yarn-3.6.4.cjs
24 changes: 23 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,29 @@
"@scure/bip39/@noble/hashes": "1.8.0",
"@scure/btc-signer/@noble/hashes": "1.8.0",
"lodash@4.17.3": "4.17.21",
"@ledgerhq/hw-transport": "6.31.0"
"@ledgerhq/hw-transport": "6.31.0",
"jail-monkey@2.8.0": "patch:jail-monkey@npm%3A2.8.0#./.yarn/patches/jail-monkey-npm-2.8.0-77e4d06b40.patch",
"@walletconnect/core@2.16.1": "patch:@walletconnect/core@npm%3A2.16.1#./.yarn/patches/@walletconnect-core-npm-2.16.1-42d08707e6.patch",
"@walletconnect/sign-client@2.16.1": "patch:@walletconnect/sign-client@npm%3A2.16.1#./.yarn/patches/@walletconnect-sign-client-npm-2.16.1-b9bdaa2d98.patch",
"@walletconnect/utils@2.17.2": "patch:@walletconnect/utils@npm%3A2.17.2#./.yarn/patches/@walletconnect-utils-npm-2.17.2-43f96abc05.patch",
"@walletconnect/utils@2.16.1": "patch:@walletconnect/utils@npm%3A2.17.2#./.yarn/patches/@walletconnect-utils-npm-2.17.2-43f96abc05.patch",
"@noble/curves@1.9.7": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@^1.7.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@1.3.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@^1.6.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@1.2.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@1.6.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@1.4.2": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@~1.3.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@^1.4.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@~1.4.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@~1.6.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@1.1.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@~1.2.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@~1.1.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@noble/curves@^1.8.0": "patch:@noble/curves@npm%3A1.9.7#./.yarn/patches/@noble-curves-npm-1.9.7-2b9efc8ab4.patch",
"@bitcoinerlab/secp256k1@1.2.0": "patch:@bitcoinerlab/secp256k1@npm%3A1.2.0#./.yarn/patches/@bitcoinerlab-secp256k1-npm-1.2.0-1098d4b329.patch",
"@bitcoinerlab/secp256k1@^1.0.5": "patch:@bitcoinerlab/secp256k1@npm%3A1.2.0#./.yarn/patches/@bitcoinerlab-secp256k1-npm-1.2.0-1098d4b329.patch"
},
"engines": {
"node": ">=20.18.0",
Expand Down
Loading