@procivis/react-native-one-core 1.75488.0 → 1.81885.0
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 +15 -14
- package/android/build.gradle +0 -11
- package/android/src/main/java/ch/procivis/one/core/DeserializeSpecific.kt +1 -15
- package/android/src/main/java/ch/procivis/one/core/ProcivisOneCoreModule.kt +4 -4
- package/android/src/main/java/ch/procivis/one/core/Serialize.kt +0 -2
- package/android/src/main/java/ch/procivis/one/core/SerializeSpecific.kt +124 -107
- package/android/src/main/java/ch/procivis/one/core/ubiqu/PinPadViewManager.kt +5 -8
- package/android/src/main/java/ch/procivis/one/core/ubiqu/UbiquKeyStorage.kt +17 -222
- package/core-sdk.json +6 -6
- package/dist/index.d.ts +3 -0
- package/dist/index.js +2 -0
- package/dist/src/config.d.ts +3 -2
- package/dist/src/config.js +5 -0
- package/dist/src/core.d.ts +9 -182
- package/dist/src/core.js +9 -20
- package/dist/src/nfc.d.ts +0 -5
- package/dist/src/one-core-uniffi-intf.d.ts +1773 -0
- package/dist/src/one-core-uniffi-intf.js +356 -0
- package/ios/Deserialize.swift +0 -28
- package/ios/ProcivisOneCoreModule.m +4 -4
- package/ios/ProcivisOneCoreModule.swift +10 -10
- package/ios/RSEKeyStorage.swift +17 -571
- package/ios/RSEPinPad.swift +3 -56
- package/ios/Serialize.swift +80 -44
- package/package.json +4 -2
- package/react-native-one-core.podspec +1 -1
- package/android/build.gradle_opensource +0 -122
- package/android/libs/core-reactnative-compatible-2025.0305.1.aar +0 -0
- package/android/src/main/java/ch/procivis/one/core/ubiqu/PinPadRunner.kt +0 -123
- package/android/src/main/java/ch/procivis/one/core/ubiqu/PinPadViewManager.kt_opensource +0 -20
- package/android/src/main/java/ch/procivis/one/core/ubiqu/PinPadWrapper.kt +0 -396
- package/android/src/main/java/ch/procivis/one/core/ubiqu/RegistrationManager.kt +0 -59
- package/android/src/main/java/ch/procivis/one/core/ubiqu/TokenManager.kt +0 -48
- package/android/src/main/java/ch/procivis/one/core/ubiqu/UbiquKeyStorage.kt_opensource +0 -63
- package/android/src/main/java/ch/procivis/one/core/ubiqu/Util.kt +0 -74
- package/android/src/main/java/ch/procivis/one/core/ubiqu/dataformats/CreateIdentityRequest.kt +0 -9
- package/android/src/main/java/ch/procivis/one/core/ubiqu/dataformats/CreateIdentityResponse.kt +0 -9
- package/android/src/main/java/ch/procivis/one/core/ubiqu/dataformats/RegisterRSEResponse.kt +0 -10
- package/dist/src/backup.d.ts +0 -22
- package/dist/src/backup.js +0 -1
- package/dist/src/cache.d.ts +0 -11
- package/dist/src/cache.js +0 -12
- package/dist/src/credential.d.ts +0 -201
- package/dist/src/credential.js +0 -44
- package/dist/src/credentialSchema.d.ts +0 -135
- package/dist/src/credentialSchema.js +0 -34
- package/dist/src/did.d.ts +0 -63
- package/dist/src/did.js +0 -27
- package/dist/src/history.d.ts +0 -101
- package/dist/src/history.js +0 -63
- package/dist/src/identifier.d.ts +0 -133
- package/dist/src/identifier.js +0 -29
- package/dist/src/key.d.ts +0 -17
- package/dist/src/key.js +0 -1
- package/dist/src/list.d.ts +0 -14
- package/dist/src/list.js +0 -5
- package/dist/src/organisation.d.ts +0 -9
- package/dist/src/organisation.js +0 -1
- package/dist/src/proof.d.ts +0 -234
- package/dist/src/proof.js +0 -43
- package/dist/src/proofSchema.d.ts +0 -116
- package/dist/src/proofSchema.js +0 -9
- package/dist/src/trust.d.ts +0 -173
- package/dist/src/trust.js +0 -44
- package/dist/src/walletUnit.d.ts +0 -30
- package/dist/src/walletUnit.js +0 -11
- package/ios/RSEKeyStorage.swift_opensource +0 -61
- package/ios/RSEPinPad.swift_opensource +0 -21
- package/ios/UBQKit.xcframework/Info.plist +0 -44
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Assets.car +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFCompatibilityMacros.h +0 -37
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFHTTPSessionManager.h +0 -304
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFNetworkReachabilityManager.h +0 -216
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFNetworking.h +0 -41
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFPlainTextRequestSerializer.h +0 -16
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFSecurityPolicy.h +0 -156
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFURLRequestSerialization.h +0 -479
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFURLResponseSerialization.h +0 -310
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/AFURLSessionManager.h +0 -501
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/CardRequestProtocol.h +0 -72
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/Constants.h +0 -222
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/DeviceBindProtocol.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/DomainSecurityModule.h +0 -43
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/ErrorDomains.h +0 -68
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/FreeAssetProtocol.h +0 -40
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/GDataXMLNode.h +0 -214
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/NSDictionary+Utilities.h +0 -23
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/NSFileManager+Utilities.h +0 -20
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/NSString+Utilities.h +0 -23
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/NSURL+Utilities.h +0 -12
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/ProtocolBase.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/ResetPinProtocol.h +0 -45
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/Settings.h +0 -120
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequest.h +0 -58
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestBaseProcessor.h +0 -37
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestBindProcessor.h +0 -34
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestNullProcessor.h +0 -28
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestResetPinProcessor.h +0 -35
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestUnlockProcessor.h +0 -31
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQCardRequestUseProcessor.h +0 -34
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQKit-Swift.h +0 -761
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQKit.h +0 -56
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Headers/UBQPacket.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Info.plist +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios.abi.json +0 -89006
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios.private.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/Modules/module.modulemap +0 -11
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/UBQKit +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/_CodeSignature/CodeResources +0 -597
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/certs +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/checksums +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/pinning_pub +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/static +0 -0
- package/ios/UBQKit.xcframework/ios-arm64/UBQKit.framework/stream +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Assets.car +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFCompatibilityMacros.h +0 -37
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFHTTPSessionManager.h +0 -304
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFNetworkReachabilityManager.h +0 -216
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFNetworking.h +0 -41
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFPlainTextRequestSerializer.h +0 -16
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFSecurityPolicy.h +0 -156
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFURLRequestSerialization.h +0 -479
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFURLResponseSerialization.h +0 -310
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/AFURLSessionManager.h +0 -501
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/CardRequestProtocol.h +0 -72
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/Constants.h +0 -222
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/DeviceBindProtocol.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/DomainSecurityModule.h +0 -43
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/ErrorDomains.h +0 -68
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/FreeAssetProtocol.h +0 -40
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/GDataXMLNode.h +0 -214
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/NSDictionary+Utilities.h +0 -23
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/NSFileManager+Utilities.h +0 -20
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/NSString+Utilities.h +0 -23
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/NSURL+Utilities.h +0 -12
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/ProtocolBase.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/ResetPinProtocol.h +0 -45
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/Settings.h +0 -120
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequest.h +0 -58
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestBaseProcessor.h +0 -37
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestBindProcessor.h +0 -34
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestNullProcessor.h +0 -28
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestResetPinProcessor.h +0 -35
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestUnlockProcessor.h +0 -31
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQCardRequestUseProcessor.h +0 -34
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQKit-Swift.h +0 -1522
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQKit.h +0 -56
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Headers/UBQPacket.h +0 -38
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Info.plist +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios-simulator.abi.json +0 -89006
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/arm64-apple-ios-simulator.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/x86_64-apple-ios-simulator.abi.json +0 -89006
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/UBQKit.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +0 -1099
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/Modules/module.modulemap +0 -11
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/UBQKit +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/_CodeSignature/CodeResources +0 -652
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/certs +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/checksums +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/pinning_pub +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/static +0 -0
- package/ios/UBQKit.xcframework/ios-arm64_x86_64-simulator/UBQKit.framework/stream +0 -0
package/README.md
CHANGED
|
@@ -34,10 +34,10 @@ See the [key features][key] and complete solution [architecture][archi].
|
|
|
34
34
|
|
|
35
35
|
### Trial
|
|
36
36
|
|
|
37
|
-
The fastest way to get started with the
|
|
37
|
+
The fastest way to get started with the _Procivis One Wallet_ is to download the app
|
|
38
38
|
from the iOS or Android app stores and [join our Trial Environment][trial].
|
|
39
39
|
In the trial environment, you are given control of an organization on our server
|
|
40
|
-
solution, the
|
|
40
|
+
solution, the _Procivis One Desk_, and can quickly begin issuing and verifying credentials.
|
|
41
41
|
|
|
42
42
|
### Documentation
|
|
43
43
|
|
|
@@ -65,9 +65,10 @@ allprojects {
|
|
|
65
65
|
|
|
66
66
|
## Usage
|
|
67
67
|
|
|
68
|
-
```
|
|
69
|
-
import
|
|
68
|
+
```typescript
|
|
69
|
+
import { initializeCore } from "react-native-one-core";
|
|
70
70
|
...
|
|
71
|
+
const ONE = await initializeCore();
|
|
71
72
|
await ONE.getVersion();
|
|
72
73
|
```
|
|
73
74
|
|
|
@@ -83,7 +84,7 @@ often referred to as Self-Sovereign Identity, or SSI.
|
|
|
83
84
|
|
|
84
85
|
## eIDAS 2.0
|
|
85
86
|
|
|
86
|
-
If you want to provide an **EUDI Wallet**,
|
|
87
|
+
If you want to provide an **EUDI Wallet**, _Procivis One_ provides production grade open
|
|
87
88
|
source components to get certified and connect your organization to the eIDAS 2.0 ecosystem.
|
|
88
89
|
|
|
89
90
|

|
|
@@ -97,17 +98,17 @@ use the [Procivis One Core][core].
|
|
|
97
98
|
|
|
98
99
|
## Interoperability and conformance
|
|
99
100
|
|
|
100
|
-
|
|
101
|
+
_Procivis One_ is built using [open standards](#supported-standards) and tested to ensure
|
|
101
102
|
interoperability with different software vendors and across different international
|
|
102
103
|
regulatory ecosystems.
|
|
103
104
|
|
|
104
105
|
- W3C standards
|
|
105
106
|
- The W3C offers several test suites for standards conformance. See
|
|
106
|
-
the latest test results for
|
|
107
|
+
the latest test results for _Procivis One_ at [canivc.com][canivc].
|
|
107
108
|
- ISO/IEC 18013-5 mDL
|
|
108
|
-
-
|
|
109
|
-
OpenWallet Foundation's verifier:
|
|
110
|
-
credentials to a
|
|
109
|
+
- _Procivis One_'s implementation of the ISO mDL standard is compatible with the
|
|
110
|
+
OpenWallet Foundation's verifier: _Procivis One_ can successfully issue mDL
|
|
111
|
+
credentials to a _Procivis One Wallet_, and these credentials can successfully
|
|
111
112
|
be verified by the OpenWallet Foundation's verifier. See the [OpenWallet Foundation libraries][owf].
|
|
112
113
|
- eIDAS 2.0; EUDI Wallet
|
|
113
114
|
- The EU Digital Wallet is developing [issuer][eudiwi] and [verifier][eudiwv] testing for
|
|
@@ -125,10 +126,10 @@ and regulations mature and harden.
|
|
|
125
126
|
|
|
126
127
|
- [W3C Verifiable Credentials Data Model 2.0][vcdm] in the following variations:
|
|
127
128
|
|
|
128
|
-
| Securing mechanism | Supported representations | Supported proof/signature types
|
|
129
|
-
| -------------------------------------------- |
|
|
130
|
-
| [W3C Data Integrity Proofs][vcdi] (embedded) | [JSON-LD][jld] in Compacted Document Form
|
|
131
|
-
| [W3C VC-JOSE-COSE][jose] (enveloping) | <ul><li>[SD-JWT][sdjwt]</li><li>[JWT][jw]</li></ul> | <ul><li>JOSE / ECDSA [ES256][es2]</li><li>JOSE / EdDSA [Ed25519][ed255]</li><li>JOSE / CRYSTALS-DILITHIUM 3 [CRYDI3][crydi3]
|
|
129
|
+
| Securing mechanism | Supported representations | Supported proof/signature types |
|
|
130
|
+
| -------------------------------------------- | --------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
131
|
+
| [W3C Data Integrity Proofs][vcdi] (embedded) | [JSON-LD][jld] in Compacted Document Form | <ul><li>[W3C Data Integrity ECDSA Cryptosuites v1.0][ecd] / [ecdsa-rdfc-2019][ecd2019]</li><li>[W3C Data Integrity EdDSA Cryptosuites v1.0][edd] / [eddsa-rdfc-2022][edd2022]</li><li>[W3C Data Integrity BBS Cryptosuites v1.0][bbs] / [bbs-2023][bbs2023]</li></ul> |
|
|
132
|
+
| [W3C VC-JOSE-COSE][jose] (enveloping) | <ul><li>[SD-JWT][sdjwt]</li><li>[JWT][jw]</li></ul> | <ul><li>JOSE / ECDSA [ES256][es2]</li><li>JOSE / EdDSA [Ed25519][ed255]</li><li>JOSE / CRYSTALS-DILITHIUM 3 [CRYDI3][crydi3]\* |
|
|
132
133
|
|
|
133
134
|
\* CRYSTALS-DILITHIUM is a post-quantum resistant signature scheme, selected by NIST for [Post-Quantum Cryptography Standardization][pqc].
|
|
134
135
|
Support for the recently published [FIPS-204][fips] is planned for the near future.
|
package/android/build.gradle
CHANGED
|
@@ -75,17 +75,6 @@ dependencies {
|
|
|
75
75
|
implementation 'net.java.dev.jna:jna:5.17.0@aar'
|
|
76
76
|
implementation 'org.greenrobot:eventbus:3.3.1'
|
|
77
77
|
implementation("org.jetbrains.kotlin:kotlin-reflect:${safeExtGet('kotlinVersion', '1.9.0')}")
|
|
78
|
-
|
|
79
|
-
implementation(name: 'core-reactnative-compatible-2025.0305.1', ext: 'aar')
|
|
80
|
-
implementation("com.google.android.material:material:1.9.0")
|
|
81
|
-
implementation("com.squareup.retrofit2:retrofit:2.11.0")
|
|
82
|
-
implementation("com.squareup.retrofit2:converter-scalars:2.11.0")
|
|
83
|
-
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.0")
|
|
84
|
-
implementation("com.jakewharton.retrofit:retrofit2-kotlinx-serialization-converter:1.0.0")
|
|
85
|
-
implementation("com.jakewharton.timber:timber:5.0.1")
|
|
86
|
-
implementation("org.apache.commons:commons-math3:3.6.1")
|
|
87
|
-
implementation 'androidx.appcompat:appcompat:1.6.1'
|
|
88
|
-
implementation 'androidx.biometric:biometric:1.1.0'
|
|
89
78
|
}
|
|
90
79
|
|
|
91
80
|
def downloadFile = { url, file ->
|
|
@@ -6,7 +6,7 @@ import kotlin.reflect.KClass
|
|
|
6
6
|
|
|
7
7
|
object DeserializeSpecific {
|
|
8
8
|
object Obj {
|
|
9
|
-
private val CustomConversionTypes = arrayOf(
|
|
9
|
+
private val CustomConversionTypes = arrayOf(OptionalString::class)
|
|
10
10
|
|
|
11
11
|
fun isCustomConversionType(type: KClass<*>): Boolean {
|
|
12
12
|
return CustomConversionTypes.contains(type)
|
|
@@ -14,8 +14,6 @@ object DeserializeSpecific {
|
|
|
14
14
|
|
|
15
15
|
fun convertCustom(type: KClass<*>, input: ReadableMap, field: String): Any? {
|
|
16
16
|
return when (type) {
|
|
17
|
-
CredentialSchemaTypeBindingEnum::class -> input.getString(field)
|
|
18
|
-
?.let { credentialSchemaType(it) }
|
|
19
17
|
OptionalString::class -> {
|
|
20
18
|
val value = input.getString(field)
|
|
21
19
|
if (value == null) {
|
|
@@ -31,18 +29,6 @@ object DeserializeSpecific {
|
|
|
31
29
|
}
|
|
32
30
|
}
|
|
33
31
|
|
|
34
|
-
private fun credentialSchemaType(
|
|
35
|
-
credentialSchemaType: String
|
|
36
|
-
): CredentialSchemaTypeBindingEnum {
|
|
37
|
-
return when (credentialSchemaType) {
|
|
38
|
-
"PROCIVIS_ONE_SCHEMA2024" -> CredentialSchemaTypeBindingEnum.ProcivisOneSchema2024
|
|
39
|
-
"FALLBACK_SCHEMA2024" -> CredentialSchemaTypeBindingEnum.FallbackSchema2024
|
|
40
|
-
"MDOC" -> CredentialSchemaTypeBindingEnum.Mdoc
|
|
41
|
-
"SD_JWT_VC" -> CredentialSchemaTypeBindingEnum.SdJwtVc
|
|
42
|
-
else -> CredentialSchemaTypeBindingEnum.Other(credentialSchemaType)
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
|
|
46
32
|
fun ids(ids: ReadableArray): List<String> {
|
|
47
33
|
val result = mutableListOf<String>()
|
|
48
34
|
for (n in 0 until ids.size()) {
|
|
@@ -161,7 +161,7 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
|
|
|
161
161
|
}
|
|
162
162
|
|
|
163
163
|
@ReactMethod
|
|
164
|
-
fun
|
|
164
|
+
fun listIdentifiers(query: ReadableMap, promise: Promise) {
|
|
165
165
|
asyncCall(promise, scope) {
|
|
166
166
|
val identifiers = getCore().listIdentifiers(construct(query))
|
|
167
167
|
return@asyncCall convertToRN(identifiers)
|
|
@@ -482,7 +482,7 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
|
|
|
482
482
|
}
|
|
483
483
|
|
|
484
484
|
@ReactMethod
|
|
485
|
-
fun
|
|
485
|
+
fun getHistoryList(query: ReadableMap, promise: Promise) {
|
|
486
486
|
asyncCall(promise, scope) {
|
|
487
487
|
val history = getCore().getHistoryList(construct(query))
|
|
488
488
|
return@asyncCall convertToRN(history)
|
|
@@ -520,7 +520,7 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
|
|
|
520
520
|
}
|
|
521
521
|
|
|
522
522
|
@ReactMethod
|
|
523
|
-
fun
|
|
523
|
+
fun listTrustAnchors(query: ReadableMap, promise: Promise) {
|
|
524
524
|
asyncCall(promise, scope) {
|
|
525
525
|
val trustAnchors = getCore().listTrustAnchors(construct(query))
|
|
526
526
|
return@asyncCall convertToRN(trustAnchors)
|
|
@@ -543,7 +543,7 @@ class ProcivisOneCoreModule(reactContext: ReactApplicationContext) :
|
|
|
543
543
|
}
|
|
544
544
|
|
|
545
545
|
@ReactMethod
|
|
546
|
-
fun
|
|
546
|
+
fun listTrustEntities(query: ReadableMap, promise: Promise) {
|
|
547
547
|
asyncCall(promise, scope) {
|
|
548
548
|
val trustEntity = getCore().listTrustEntities(construct(query))
|
|
549
549
|
return@asyncCall convertToRN(trustEntity)
|
|
@@ -54,8 +54,6 @@ object Serialize {
|
|
|
54
54
|
return Pair(RNType.DOUBLE, input as Double)
|
|
55
55
|
} else if (type == Char::class.java || type == java.lang.Character::class.java) {
|
|
56
56
|
return Pair(RNType.STRING, (input as Char).toString())
|
|
57
|
-
} else if (SerializeSpecific.Str.isCustomConversionType(input)) {
|
|
58
|
-
return Pair(RNType.STRING, SerializeSpecific.Str.convertCustom(input))
|
|
59
57
|
} else if (SerializeSpecific.Arr.isCustomConversionType(input)) {
|
|
60
58
|
return Pair(RNType.ARRAY, SerializeSpecific.Arr.convertCustom(input))
|
|
61
59
|
} else {
|
|
@@ -10,10 +10,11 @@ object SerializeSpecific {
|
|
|
10
10
|
private val CustomConversionTypes =
|
|
11
11
|
arrayOf(
|
|
12
12
|
HistoryMetadataBinding::class.java,
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
ClaimValueBindingDto::class.java,
|
|
14
|
+
ProofRequestClaimValueBindingDto::class.java,
|
|
15
|
+
ApplicableCredentialOrFailureHintBindingEnum::class.java,
|
|
16
|
+
PresentationDefinitionV2ClaimValueBindingDto::class.java,
|
|
17
|
+
HandleInvitationResponseBindingEnum::class.java,
|
|
17
18
|
)
|
|
18
19
|
|
|
19
20
|
fun isCustomConversionType(input: Any?): Boolean {
|
|
@@ -29,65 +30,87 @@ object SerializeSpecific {
|
|
|
29
30
|
if (input is HistoryMetadataBinding) {
|
|
30
31
|
return historyMetadata(input)
|
|
31
32
|
}
|
|
32
|
-
if (input is
|
|
33
|
-
return
|
|
33
|
+
if (input is ClaimValueBindingDto) {
|
|
34
|
+
return claimValue(input)
|
|
34
35
|
}
|
|
35
|
-
if (input is
|
|
36
|
-
return
|
|
36
|
+
if (input is ProofRequestClaimValueBindingDto) {
|
|
37
|
+
return proofClaimValue(input)
|
|
37
38
|
}
|
|
38
|
-
if (input is
|
|
39
|
+
if (input is ApplicableCredentialOrFailureHintBindingEnum) {
|
|
39
40
|
return credentialQuery(input)
|
|
40
41
|
}
|
|
41
|
-
if (input is
|
|
42
|
-
return
|
|
42
|
+
if (input is PresentationDefinitionV2ClaimValueBindingDto) {
|
|
43
|
+
return presentationDefinitionV2ClaimValue(input)
|
|
44
|
+
}
|
|
45
|
+
if (input is HandleInvitationResponseBindingEnum) {
|
|
46
|
+
return invitationResponse(input)
|
|
43
47
|
}
|
|
44
48
|
throw IllegalArgumentException("Invalid map conversion: $input")
|
|
45
49
|
}
|
|
46
50
|
|
|
47
51
|
private fun historyMetadata(metadata: HistoryMetadataBinding): ReadableMap {
|
|
52
|
+
val result = Arguments.createMap()
|
|
48
53
|
when (metadata) {
|
|
49
|
-
is HistoryMetadataBinding.UnexportableEntities ->
|
|
50
|
-
|
|
54
|
+
is HistoryMetadataBinding.UnexportableEntities -> {
|
|
55
|
+
result.putString("type_", "UNEXPORTABLE_ENTITIES")
|
|
56
|
+
result.putMap(
|
|
57
|
+
"value",
|
|
58
|
+
convertToRN(metadata.value) as ReadableMap
|
|
59
|
+
)
|
|
60
|
+
}
|
|
51
61
|
|
|
52
|
-
is HistoryMetadataBinding.ErrorMetadata ->
|
|
53
|
-
|
|
62
|
+
is HistoryMetadataBinding.ErrorMetadata -> {
|
|
63
|
+
result.putString("type_", "ERROR_METADATA")
|
|
64
|
+
result.putMap(
|
|
65
|
+
"value",
|
|
66
|
+
convertToRN(metadata.value) as ReadableMap
|
|
67
|
+
)
|
|
68
|
+
}
|
|
54
69
|
|
|
55
70
|
is HistoryMetadataBinding.WalletUnitJwt -> {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
71
|
+
result.putString("type_", "WALLET_UNIT_JWT")
|
|
72
|
+
val values = Arguments.createArray()
|
|
73
|
+
values.pushString(metadata.v1)
|
|
74
|
+
result.putArray("value", values)
|
|
59
75
|
}
|
|
60
|
-
|
|
61
76
|
}
|
|
77
|
+
return result
|
|
62
78
|
}
|
|
63
79
|
|
|
64
|
-
private fun credentialQuery(
|
|
80
|
+
private fun credentialQuery(query: ApplicableCredentialOrFailureHintBindingEnum): ReadableMap {
|
|
65
81
|
val result = Arguments.createMap()
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
82
|
+
when (query) {
|
|
83
|
+
is ApplicableCredentialOrFailureHintBindingEnum.ApplicableCredentials -> {
|
|
84
|
+
result.putString("type_", "APPLICABLE_CREDENTIALS")
|
|
85
|
+
result.putArray(
|
|
86
|
+
"applicableCredentials",
|
|
87
|
+
convertToRN(query.applicableCredentials) as ReadableArray
|
|
88
|
+
)
|
|
89
|
+
}
|
|
72
90
|
|
|
73
91
|
is ApplicableCredentialOrFailureHintBindingEnum.FailureHint -> {
|
|
74
|
-
result.
|
|
92
|
+
result.putString("type_", "FAILURE_HINT")
|
|
93
|
+
result.putMap("failureHint", convertToRN(query.failureHint) as ReadableMap)
|
|
75
94
|
}
|
|
76
95
|
}
|
|
77
96
|
return result
|
|
78
97
|
}
|
|
79
98
|
|
|
80
|
-
private fun
|
|
99
|
+
private fun claimValue(value: ClaimValueBindingDto): ReadableMap {
|
|
81
100
|
val result = Arguments.createMap()
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
is ClaimValueBindingDto.
|
|
89
|
-
|
|
101
|
+
when (value) {
|
|
102
|
+
is ClaimValueBindingDto.Boolean -> {
|
|
103
|
+
result.putString("type_", "BOOLEAN")
|
|
104
|
+
result.putBoolean("value", value.value)
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
is ClaimValueBindingDto.Float -> {
|
|
108
|
+
result.putString("type_", "FLOAT")
|
|
109
|
+
result.putDouble("value", value.value)
|
|
110
|
+
}
|
|
111
|
+
|
|
90
112
|
is ClaimValueBindingDto.Integer -> {
|
|
113
|
+
result.putString("type_", "INTEGER")
|
|
91
114
|
if (value.value < Int.MIN_VALUE || value.value > Int.MAX_VALUE) {
|
|
92
115
|
result.putDouble("value", value.value.toDouble())
|
|
93
116
|
} else {
|
|
@@ -95,50 +118,50 @@ object SerializeSpecific {
|
|
|
95
118
|
}
|
|
96
119
|
}
|
|
97
120
|
|
|
98
|
-
is ClaimValueBindingDto.String ->
|
|
99
|
-
|
|
121
|
+
is ClaimValueBindingDto.String -> {
|
|
122
|
+
result.putString("type_", "STRING")
|
|
123
|
+
result.putString("value", value.value)
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
is ClaimValueBindingDto.Nested -> {
|
|
127
|
+
result.putString("type_", "NESTED")
|
|
100
128
|
result.putArray("value", convertToRN(value.value) as ReadableArray)
|
|
129
|
+
}
|
|
101
130
|
}
|
|
102
|
-
|
|
103
131
|
return result
|
|
104
132
|
}
|
|
105
133
|
|
|
106
|
-
private fun
|
|
134
|
+
private fun proofClaimValue(value: ProofRequestClaimValueBindingDto): ReadableMap {
|
|
107
135
|
val result = Arguments.createMap()
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
result.putString("value", value.value)
|
|
136
|
+
when (value) {
|
|
137
|
+
is ProofRequestClaimValueBindingDto.Value -> {
|
|
138
|
+
result.putString("type_", "VALUE")
|
|
139
|
+
result.putString("value", value.value)
|
|
140
|
+
}
|
|
114
141
|
|
|
115
|
-
|
|
116
|
-
|
|
142
|
+
is ProofRequestClaimValueBindingDto.Claims -> {
|
|
143
|
+
result.putString("type_", "CLAIMS")
|
|
144
|
+
result.putArray("value", convertToRN(value.value) as ReadableArray)
|
|
117
145
|
}
|
|
118
146
|
}
|
|
119
|
-
|
|
120
147
|
return result
|
|
121
148
|
}
|
|
122
149
|
|
|
123
|
-
private fun
|
|
150
|
+
private fun presentationDefinitionV2ClaimValue(value: PresentationDefinitionV2ClaimValueBindingDto): ReadableMap {
|
|
124
151
|
val result = Arguments.createMap()
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
is PresentationDefinitionV2ClaimValueBindingDto.
|
|
132
|
-
"
|
|
133
|
-
value.value
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
is PresentationDefinitionV2ClaimValueBindingDto.Float -> result.putDouble(
|
|
137
|
-
"value",
|
|
138
|
-
value.value
|
|
139
|
-
)
|
|
152
|
+
when (value) {
|
|
153
|
+
is PresentationDefinitionV2ClaimValueBindingDto.Boolean -> {
|
|
154
|
+
result.putString("type_", "BOOLEAN")
|
|
155
|
+
result.putBoolean("value", value.value)
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
is PresentationDefinitionV2ClaimValueBindingDto.Float -> {
|
|
159
|
+
result.putString("type_", "FLOAT")
|
|
160
|
+
result.putDouble("value", value.value)
|
|
161
|
+
}
|
|
140
162
|
|
|
141
163
|
is PresentationDefinitionV2ClaimValueBindingDto.Integer -> {
|
|
164
|
+
result.putString("type_", "INTEGER")
|
|
142
165
|
if (value.value < Int.MIN_VALUE || value.value > Int.MAX_VALUE) {
|
|
143
166
|
result.putDouble("value", value.value.toDouble())
|
|
144
167
|
} else {
|
|
@@ -146,58 +169,52 @@ object SerializeSpecific {
|
|
|
146
169
|
}
|
|
147
170
|
}
|
|
148
171
|
|
|
149
|
-
is PresentationDefinitionV2ClaimValueBindingDto.String ->
|
|
150
|
-
"
|
|
151
|
-
value.value
|
|
152
|
-
|
|
172
|
+
is PresentationDefinitionV2ClaimValueBindingDto.String -> {
|
|
173
|
+
result.putString("type_", "STRING")
|
|
174
|
+
result.putString("value", value.value)
|
|
175
|
+
}
|
|
153
176
|
|
|
154
|
-
is PresentationDefinitionV2ClaimValueBindingDto.Nested ->
|
|
177
|
+
is PresentationDefinitionV2ClaimValueBindingDto.Nested -> {
|
|
178
|
+
result.putString("type_", "NESTED")
|
|
155
179
|
result.putArray("value", convertToRN(value.value) as ReadableArray)
|
|
180
|
+
}
|
|
156
181
|
}
|
|
157
|
-
|
|
158
182
|
return result
|
|
159
183
|
}
|
|
160
|
-
}
|
|
161
184
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
185
|
+
private fun invitationResponse(value: HandleInvitationResponseBindingEnum): ReadableMap {
|
|
186
|
+
val result = Arguments.createMap()
|
|
187
|
+
when (value) {
|
|
188
|
+
is HandleInvitationResponseBindingEnum.CredentialIssuance -> {
|
|
189
|
+
result.putString("type_", "CREDENTIAL_ISSUANCE")
|
|
190
|
+
result.putString("interactionId", value.interactionId)
|
|
191
|
+
value.keyStorageSecurityLevels?.let {
|
|
192
|
+
result.putArray(
|
|
193
|
+
"keyStorageSecurityLevels",
|
|
194
|
+
convertToRN(it) as ReadableArray
|
|
195
|
+
)
|
|
196
|
+
}
|
|
197
|
+
value.keyAlgorithms?.let {
|
|
198
|
+
result.putArray("keyAlgorithms", convertToRN(it) as ReadableArray)
|
|
199
|
+
}
|
|
200
|
+
value.txCode?.let {
|
|
201
|
+
result.putMap("txCode", convertToRN(it) as ReadableMap)
|
|
202
|
+
}
|
|
172
203
|
}
|
|
173
|
-
}
|
|
174
|
-
return false
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
fun convertCustom(input: Any): String {
|
|
178
|
-
if (input is CredentialSchemaTypeBindingEnum) {
|
|
179
|
-
return credentialSchemaType(input)
|
|
180
|
-
}
|
|
181
|
-
throw IllegalArgumentException("Invalid string conversion: $input")
|
|
182
|
-
}
|
|
183
204
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
"
|
|
188
|
-
|
|
189
|
-
is CredentialSchemaTypeBindingEnum.FallbackSchema2024 ->
|
|
190
|
-
"FALLBACK_SCHEMA2024"
|
|
191
|
-
|
|
192
|
-
is CredentialSchemaTypeBindingEnum.Mdoc ->
|
|
193
|
-
"MDOC"
|
|
194
|
-
|
|
195
|
-
is CredentialSchemaTypeBindingEnum.SdJwtVc ->
|
|
196
|
-
"SD_JWT_VC"
|
|
205
|
+
is HandleInvitationResponseBindingEnum.AuthorizationCodeFlow -> {
|
|
206
|
+
result.putString("type_", "AUTHORIZATION_CODE_FLOW")
|
|
207
|
+
result.putString("interactionId", value.interactionId)
|
|
208
|
+
result.putString("authorizationCodeFlowUrl", value.authorizationCodeFlowUrl)
|
|
209
|
+
}
|
|
197
210
|
|
|
198
|
-
is
|
|
199
|
-
|
|
211
|
+
is HandleInvitationResponseBindingEnum.ProofRequest -> {
|
|
212
|
+
result.putString("type_", "PROOF_REQUEST")
|
|
213
|
+
result.putString("interactionId", value.interactionId)
|
|
214
|
+
result.putString("proofId", value.proofId)
|
|
215
|
+
}
|
|
200
216
|
}
|
|
217
|
+
return result
|
|
201
218
|
}
|
|
202
219
|
}
|
|
203
220
|
|
|
@@ -1,23 +1,20 @@
|
|
|
1
1
|
package ch.procivis.one.core.ubiqu
|
|
2
2
|
|
|
3
|
+
import android.view.View
|
|
4
|
+
import ch.procivis.one.core.NativeKeyStorageException
|
|
3
5
|
import com.facebook.react.bridge.ReactApplicationContext
|
|
4
6
|
import com.facebook.react.uimanager.SimpleViewManager
|
|
5
7
|
import com.facebook.react.uimanager.ThemedReactContext
|
|
6
|
-
import com.ubiqu.eid.sdk.components.UbqInternalPad
|
|
7
|
-
import com.ubiqu.eid.sdk.components.UbqPinPad
|
|
8
8
|
|
|
9
9
|
class PinPadViewManager(private val callerContext: ReactApplicationContext) :
|
|
10
|
-
SimpleViewManager<
|
|
10
|
+
SimpleViewManager<View>() {
|
|
11
11
|
companion object {
|
|
12
12
|
const val REACT_CLASS = "RCTProcivisRSEPinPad"
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
override fun getName() = REACT_CLASS
|
|
16
16
|
|
|
17
|
-
override fun createViewInstance(context: ThemedReactContext):
|
|
18
|
-
|
|
19
|
-
val activeFlow = PinPadRunner.getActiveFlow()
|
|
20
|
-
PinPadWrapper(callerContext, pinPad, activeFlow.flow, activeFlow.type)
|
|
21
|
-
return pinPad
|
|
17
|
+
override fun createViewInstance(context: ThemedReactContext): View {
|
|
18
|
+
throw NativeKeyStorageException.Unsupported()
|
|
22
19
|
}
|
|
23
20
|
}
|