@onekeyfe/react-native-bundle-update 1.1.43 → 1.1.44
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/android/src/main/java/com/margelo/nitro/reactnativebundleupdate/ReactNativeBundleUpdate.kt
CHANGED
|
@@ -296,7 +296,8 @@ object BundleUpdateStoreAndroid {
|
|
|
296
296
|
val appVersion = payload.optString("appVersion")
|
|
297
297
|
val bundleVersion = payload.optString("bundleVersion")
|
|
298
298
|
val signature = payload.optString("signature")
|
|
299
|
-
if (appVersion.isEmpty() || bundleVersion.isEmpty()) return
|
|
299
|
+
if (appVersion.isEmpty() || bundleVersion.isEmpty() || signature.isEmpty()) return
|
|
300
|
+
if (!isSafeVersionString(appVersion) || !isSafeVersionString(bundleVersion)) return
|
|
300
301
|
|
|
301
302
|
// 5. Verify bundle directory and entry file exist
|
|
302
303
|
val folderName = "$appVersion-$bundleVersion"
|
|
@@ -254,7 +254,8 @@ public class BundleUpdateStore: NSObject {
|
|
|
254
254
|
let appVersion = payload["appVersion"] as? String,
|
|
255
255
|
let bundleVersion = payload["bundleVersion"] as? String,
|
|
256
256
|
let signature = payload["signature"] as? String,
|
|
257
|
-
!appVersion.isEmpty, !bundleVersion.isEmpty
|
|
257
|
+
!appVersion.isEmpty, !bundleVersion.isEmpty, !signature.isEmpty,
|
|
258
|
+
appVersion.isSafeVersionString, bundleVersion.isSafeVersionString
|
|
258
259
|
else { return }
|
|
259
260
|
|
|
260
261
|
// 5. Verify bundle directory and entry file exist
|