freerasp-react-native 4.2.1 → 4.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -5,8 +5,22 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [4.2.2] - 2025-08-21
|
|
9
|
+
|
|
10
|
+
- iOS SDK version: 6.12.1
|
|
11
|
+
- Android SDK version: 16.0.1
|
|
12
|
+
|
|
13
|
+
### React Native
|
|
14
|
+
|
|
15
|
+
#### Changed
|
|
16
|
+
|
|
17
|
+
- Replaced deprecated `getCurrentActivity()` call on Android (compatibility with RN 0.81+)
|
|
18
|
+
|
|
8
19
|
## [4.2.1] - 2025-08-05
|
|
9
20
|
|
|
21
|
+
- iOS SDK version: 6.12.1
|
|
22
|
+
- Android SDK version: 16.0.1
|
|
23
|
+
|
|
10
24
|
### React Native
|
|
11
25
|
|
|
12
26
|
#### Fixed
|
|
@@ -33,13 +33,13 @@ class FreeraspReactNativeModule(private val reactContext: ReactApplicationContex
|
|
|
33
33
|
private val lifecycleListener = object : LifecycleEventListener {
|
|
34
34
|
override fun onHostResume() {
|
|
35
35
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE) {
|
|
36
|
-
currentActivity?.let { ScreenProtector.register(it) }
|
|
36
|
+
reactContext.currentActivity?.let { ScreenProtector.register(it) }
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
override fun onHostPause() {
|
|
41
41
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE) {
|
|
42
|
-
currentActivity?.let { ScreenProtector.unregister(it) }
|
|
42
|
+
reactContext.currentActivity?.let { ScreenProtector.unregister(it) }
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
|
|
@@ -71,7 +71,7 @@ class FreeraspReactNativeModule(private val reactContext: ReactApplicationContex
|
|
|
71
71
|
mainHandler.post {
|
|
72
72
|
talsecStarted = true
|
|
73
73
|
// This code must be called only AFTER Talsec.start
|
|
74
|
-
currentActivity?.let { activity ->
|
|
74
|
+
reactContext.currentActivity?.let { activity ->
|
|
75
75
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE) {
|
|
76
76
|
ScreenProtector.register(activity)
|
|
77
77
|
}
|
|
@@ -154,7 +154,7 @@ class FreeraspReactNativeModule(private val reactContext: ReactApplicationContex
|
|
|
154
154
|
*/
|
|
155
155
|
@ReactMethod
|
|
156
156
|
fun blockScreenCapture(enable: Boolean, promise: Promise) {
|
|
157
|
-
val activity = currentActivity ?: run {
|
|
157
|
+
val activity = reactContext.currentActivity ?: run {
|
|
158
158
|
promise.reject(
|
|
159
159
|
"NativePluginError", "Cannot block screen capture, activity is null."
|
|
160
160
|
)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "freerasp-react-native",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.2",
|
|
4
4
|
"description": "React Native plugin for improving app security and threat monitoring on Android and iOS mobile devices.",
|
|
5
5
|
"main": "lib/commonjs/index",
|
|
6
6
|
"module": "lib/module/index",
|