react-native-security-suite 0.5.7 → 0.5.9
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/README.md +4 -9
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -23,9 +23,7 @@ npm install react-native-security-suite
|
|
|
23
23
|
|
|
24
24
|
## Usage
|
|
25
25
|
|
|
26
|
-
\
|
|
27
|
-
|
|
28
|
-
1. Android Root or iOS Jailbreak devices detection example:
|
|
26
|
+
\1. Android Root or iOS Jailbreak devices detection example:
|
|
29
27
|
|
|
30
28
|
```js
|
|
31
29
|
import { deviceHasSecurityRisk } from 'react-native-security-suite';
|
|
@@ -34,8 +32,7 @@ const isRiskyDevice = await deviceHasSecurityRisk();
|
|
|
34
32
|
console.log('Root/Jailbreak detection result: ', isRiskyDevice);
|
|
35
33
|
```
|
|
36
34
|
|
|
37
|
-
\
|
|
38
|
-
2. Text Encryption/Decryption example:
|
|
35
|
+
\2. Text Encryption/Decryption example:
|
|
39
36
|
|
|
40
37
|
```js
|
|
41
38
|
//
|
|
@@ -55,8 +52,7 @@ SecureStorage.setItem('key', 'value');
|
|
|
55
52
|
console.log(await SecureStorage.getItem('key'));
|
|
56
53
|
```
|
|
57
54
|
|
|
58
|
-
\
|
|
59
|
-
4. Diffie–Hellman key exchange:
|
|
55
|
+
\4. Diffie–Hellman key exchange:
|
|
60
56
|
|
|
61
57
|
```js
|
|
62
58
|
import {
|
|
@@ -85,8 +81,7 @@ const hardDecrypted = await decryptBySharedKey('STR_FOR_DECRYPT');
|
|
|
85
81
|
console.log('Decrypted result: ', hardDecrypted);
|
|
86
82
|
```
|
|
87
83
|
|
|
88
|
-
\
|
|
89
|
-
5. SSL Pinning example:
|
|
84
|
+
\5. SSL Pinning example:
|
|
90
85
|
|
|
91
86
|
```js
|
|
92
87
|
import { fetch } from 'react-native-security-suite';
|