From 1c093acd5f0121d4ee58e3e4d47351f88390842c Mon Sep 17 00:00:00 2001 From: Philipp Walter Date: Mon, 25 Nov 2024 15:53:44 +0100 Subject: [PATCH] chore: upgrade react-native-keychain --- .../react-native-keychain/index.ts | 34 ------ __mocks__/react-native-keychain/index.ts | 71 +++++++++++ ios/Podfile.lock | 12 +- ios/bitkit.xcodeproj/project.pbxproj | 110 +++++++++--------- package.json | 2 +- src/components/SlashtagsProvider.tsx | 7 +- src/hooks/pin.tsx | 17 +-- src/utils/keychain.ts | 44 +++---- src/utils/lightning/index.ts | 34 ++---- src/utils/settings/index.ts | 2 +- src/utils/startup/index.ts | 10 +- src/utils/types/index.ts | 5 - src/utils/wallet/index.ts | 44 +++---- yarn.lock | 16 +-- 14 files changed, 202 insertions(+), 206 deletions(-) delete mode 100644 __mocks__/@synonymdev/react-native-keychain/index.ts create mode 100644 __mocks__/react-native-keychain/index.ts diff --git a/__mocks__/@synonymdev/react-native-keychain/index.ts b/__mocks__/@synonymdev/react-native-keychain/index.ts deleted file mode 100644 index eee430a05..000000000 --- a/__mocks__/@synonymdev/react-native-keychain/index.ts +++ /dev/null @@ -1,34 +0,0 @@ -let mockKeychainPasswords = {}; - -const getGenericPassword = jest.fn( - ({ service }) => - new Promise((resolve, reject) => { - const password = mockKeychainPasswords[service]; - if (password) { - return resolve({ - password, - }); - } - - return resolve({ password: '' }); - }), -); - -const setGenericPassword = jest.fn( - (key, value, args) => - new Promise((resolve, reject) => { - mockKeychainPasswords[key] = value; - resolve(true); - }), -); - -const keychainMock = { - SECURITY_LEVEL_ANY: 'MOCK_SECURITY_LEVEL_ANY', - SECURITY_LEVEL_SECURE_SOFTWARE: 'MOCK_SECURITY_LEVEL_SECURE_SOFTWARE', - SECURITY_LEVEL_SECURE_HARDWARE: 'MOCK_SECURITY_LEVEL_SECURE_HARDWARE', - setGenericPassword, - getGenericPassword, - resetGenericPassword: jest.fn().mockResolvedValue(true), -}; - -export default keychainMock; diff --git a/__mocks__/react-native-keychain/index.ts b/__mocks__/react-native-keychain/index.ts new file mode 100644 index 000000000..e867251fd --- /dev/null +++ b/__mocks__/react-native-keychain/index.ts @@ -0,0 +1,71 @@ +const mockKeychainPasswords = {}; + +const getGenericPassword = jest.fn(({ service }) => { + return { password: mockKeychainPasswords[service] }; +}); + +const setGenericPassword = jest.fn((key, value) => { + mockKeychainPasswords[key] = value; +}); + +const keychainMock = { + SECURITY_LEVEL: { + SECURE_SOFTWARE: 'MOCK_SECURITY_LEVEL_SECURE_SOFTWARE', + SECURE_HARDWARE: 'MOCK_SECURITY_LEVEL_SECURE_HARDWARE', + ANY: 'MOCK_SECURITY_LEVEL_ANY', + }, + ACCESSIBLE: { + WHEN_UNLOCKED: 'MOCK_AccessibleWhenUnlocked', + AFTER_FIRST_UNLOCK: 'MOCK_AccessibleAfterFirstUnlock', + ALWAYS: 'MOCK_AccessibleAlways', + WHEN_PASSCODE_SET_THIS_DEVICE_ONLY: + 'MOCK_AccessibleWhenPasscodeSetThisDeviceOnly', + WHEN_UNLOCKED_THIS_DEVICE_ONLY: 'MOCK_AccessibleWhenUnlockedThisDeviceOnly', + AFTER_FIRST_UNLOCK_THIS_DEVICE_ONLY: + 'MOCK_AccessibleAfterFirstUnlockThisDeviceOnly', + }, + ACCESS_CONTROL: { + USER_PRESENCE: 'MOCK_UserPresence', + BIOMETRY_ANY: 'MOCK_BiometryAny', + BIOMETRY_CURRENT_SET: 'MOCK_BiometryCurrentSet', + DEVICE_PASSCODE: 'MOCK_DevicePasscode', + APPLICATION_PASSWORD: 'MOCK_ApplicationPassword', + BIOMETRY_ANY_OR_DEVICE_PASSCODE: 'MOCK_BiometryAnyOrDevicePasscode', + BIOMETRY_CURRENT_SET_OR_DEVICE_PASSCODE: + 'MOCK_BiometryCurrentSetOrDevicePasscode', + }, + AUTHENTICATION_TYPE: { + DEVICE_PASSCODE_OR_BIOMETRICS: + 'MOCK_AuthenticationWithBiometricsDevicePasscode', + BIOMETRICS: 'MOCK_AuthenticationWithBiometrics', + }, + STORAGE_TYPE: { + FB: 'MOCK_FacebookConceal', + AES: 'MOCK_KeystoreAESCBC', + RSA: 'MOCK_KeystoreRSAECB', + KC: 'MOCK_keychain', + }, + getGenericPassword, + setGenericPassword, + resetGenericPassword: jest.fn().mockResolvedValue(true), + hasGenericPassword: jest.fn().mockResolvedValue(true), + getAllGenericPasswordServices: jest + .fn() + .mockResolvedValue(['mockService1', 'mockService2']), + setInternetCredentials: jest.fn().mockResolvedValue({ + service: 'mockService', + storage: 'mockStorage', + }), + getInternetCredentials: jest.fn().mockResolvedValue({ + username: 'mockUser', + password: 'mockPassword', + service: 'mockService', + storage: 'mockStorage', + }), + resetInternetCredentials: jest.fn().mockResolvedValue(true), + getSupportedBiometryType: jest.fn().mockResolvedValue('MOCK_TouchID'), + canImplyAuthentication: jest.fn().mockResolvedValue(true), + getSecurityLevel: jest.fn().mockResolvedValue('MOCK_SECURE_SOFTWARE'), +}; + +export default keychainMock; diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 4c902b837..fda58a58f 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -1740,7 +1740,7 @@ PODS: - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - Yoga - - RNKeychain (9.1.1): + - RNKeychain (9.2.2): - DoubleConversion - glog - hermes-engine @@ -1987,7 +1987,7 @@ DEPENDENCIES: - RNDeviceInfo (from `../node_modules/react-native-device-info`) - RNFS (from `../node_modules/react-native-fs`) - RNGestureHandler (from `../node_modules/react-native-gesture-handler`) - - "RNKeychain (from `../node_modules/@synonymdev/react-native-keychain`)" + - RNKeychain (from `../node_modules/react-native-keychain`) - RNLocalize (from `../node_modules/react-native-localize`) - "RNNotifee (from `../node_modules/@notifee/react-native`)" - RNPermissions (from `../node_modules/react-native-permissions`) @@ -2178,7 +2178,7 @@ EXTERNAL SOURCES: RNGestureHandler: :path: "../node_modules/react-native-gesture-handler" RNKeychain: - :path: "../node_modules/@synonymdev/react-native-keychain" + :path: "../node_modules/react-native-keychain" RNLocalize: :path: "../node_modules/react-native-localize" RNNotifee: @@ -2293,7 +2293,7 @@ SPEC CHECKSUMS: RNDeviceInfo: b899ce37a403a4dea52b7cb85e16e49c04a5b88e RNFS: 4ac0f0ea233904cb798630b3c077808c06931688 RNGestureHandler: e80cae4246813ee7f667a2552012a6b7da5550a1 - RNKeychain: 3ac3a44294d0b18492667ff87e4c50829cb35505 + RNKeychain: 4cfd0dc8634c2dd81a4607c8299ed424bfdee1a7 RNLocalize: dbea38dcb344bf80ff18a1757b1becf11f70cae4 RNNotifee: 8e2d3df3f0e9ce8f5d1fe4c967431138190b6175 RNPermissions: 2c0eec471f4de66d04d226c339898d10a6e123c4 @@ -2308,9 +2308,9 @@ SPEC CHECKSUMS: SocketRocket: abac6f5de4d4d62d24e11868d7a2f427e0ef940d sodium-react-native-direct: 8feb9a6d0d88ce65efa305d6cc774c11c62d9a15 SSZipArchive: c69881e8ac5521f0e622291387add5f60f30f3c4 - Yoga: 2a45d7e59592db061217551fd3bbe2dd993817ae + Yoga: a1d7895431387402a674fd0d1c04ec85e87909b8 ZXingObjC: 8898711ab495761b2dbbdec76d90164a6d7e14c5 PODFILE CHECKSUM: cb153cb4a39e6c92c8b869eafab65a4bba7b869f -COCOAPODS: 1.15.2 +COCOAPODS: 1.16.2 diff --git a/ios/bitkit.xcodeproj/project.pbxproj b/ios/bitkit.xcodeproj/project.pbxproj index 45193403a..d4c3012ed 100644 --- a/ios/bitkit.xcodeproj/project.pbxproj +++ b/ios/bitkit.xcodeproj/project.pbxproj @@ -14,14 +14,14 @@ 17074219BB5847259EAFC7A6 /* InterTight-Black.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 3815D562618543E7A9BC191E /* InterTight-Black.ttf */; }; 57072143CA0F49089AE64F61 /* InterTight-ExtraBold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = A223BA795CEB4CB2B344FBAF /* InterTight-ExtraBold.ttf */; }; 6980B602E6DC4429841BE5EE /* InterTight-Medium.ttf in Resources */ = {isa = PBXBuildFile; fileRef = D67AECF5F543462F90EC89AD /* InterTight-Medium.ttf */; }; + 7B98D2EB65CFC041113931A2 /* libPods-bitkit-bitkitTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 653856A32F428EE2C28E3A96 /* libPods-bitkit-bitkitTests.a */; }; 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; 8BD8301E3A1B44DDA3C8A10D /* Damion-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = DEC74C5375A34FFCAEBA0781 /* Damion-Regular.ttf */; }; 925570EA7B1D43CC8AD07B91 /* InterTight-Bold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = CA37793F82F144678099A00D /* InterTight-Bold.ttf */; }; 9952E811473D46FB9003A56D /* InterTight-SemiBold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 50A8DA09F2974D05A3C58E87 /* InterTight-SemiBold.ttf */; }; B3BE07A9843E4B7DA375B877 /* InterTight-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 79DFAC55B0D745DE815EC2E0 /* InterTight-Regular.ttf */; }; - B4B2FBEB8D77B877589E2875 /* libPods-bitkit-bitkitTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 21215BC72A8D690106A1F4C8 /* libPods-bitkit-bitkitTests.a */; }; - B7A9D79C59CD6FE254A31111 /* libPods-bitkit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3490F59034293BB1555C7477 /* libPods-bitkit.a */; }; E2F35FC226645CE623C61C03 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 919FE2A2B4A7605C9F606896 /* PrivacyInfo.xcprivacy */; }; + F1E150FC6BA3D279F2DFA9DE /* libPods-bitkit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A1E71C62B79795551E15D38 /* libPods-bitkit.a */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -45,21 +45,21 @@ 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = bitkit/Info.plist; sourceTree = ""; }; 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = bitkit/main.m; sourceTree = ""; }; 13B07FB81A68108700A75B9A /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = PrivacyInfo.xcprivacy; path = bitkit/PrivacyInfo.xcprivacy; sourceTree = ""; }; - 21215BC72A8D690106A1F4C8 /* libPods-bitkit-bitkitTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-bitkit-bitkitTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - 3490F59034293BB1555C7477 /* libPods-bitkit.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-bitkit.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 1A1E71C62B79795551E15D38 /* libPods-bitkit.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-bitkit.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 3815D562618543E7A9BC191E /* InterTight-Black.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-Black.ttf"; path = "../src/assets/fonts/InterTight-Black.ttf"; sourceTree = ""; }; + 494310D695EE135B7B1B7996 /* Pods-bitkit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit.debug.xcconfig"; path = "Target Support Files/Pods-bitkit/Pods-bitkit.debug.xcconfig"; sourceTree = ""; }; 50A8DA09F2974D05A3C58E87 /* InterTight-SemiBold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-SemiBold.ttf"; path = "../src/assets/fonts/InterTight-SemiBold.ttf"; sourceTree = ""; }; + 653856A32F428EE2C28E3A96 /* libPods-bitkit-bitkitTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-bitkit-bitkitTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 79DFAC55B0D745DE815EC2E0 /* InterTight-Regular.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-Regular.ttf"; path = "../src/assets/fonts/InterTight-Regular.ttf"; sourceTree = ""; }; 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = bitkit/LaunchScreen.storyboard; sourceTree = ""; }; 919FE2A2B4A7605C9F606896 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xml; name = PrivacyInfo.xcprivacy; path = bitkit/PrivacyInfo.xcprivacy; sourceTree = ""; }; + 97811DD6E320FC8F3A6F8986 /* Pods-bitkit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit.release.xcconfig"; path = "Target Support Files/Pods-bitkit/Pods-bitkit.release.xcconfig"; sourceTree = ""; }; + 9C3FCE6AE94B6C974F28C559 /* Pods-bitkit-bitkitTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit-bitkitTests.debug.xcconfig"; path = "Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests.debug.xcconfig"; sourceTree = ""; }; A223BA795CEB4CB2B344FBAF /* InterTight-ExtraBold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-ExtraBold.ttf"; path = "../src/assets/fonts/InterTight-ExtraBold.ttf"; sourceTree = ""; }; - A2F7CEE079CC5248F6B33A93 /* Pods-bitkit.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit.debug.xcconfig"; path = "Target Support Files/Pods-bitkit/Pods-bitkit.debug.xcconfig"; sourceTree = ""; }; - A46FC25FD9F4D111BF9A0601 /* Pods-bitkit-bitkitTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit-bitkitTests.release.xcconfig"; path = "Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests.release.xcconfig"; sourceTree = ""; }; - B629938C36E49CBDCB4AEB6B /* Pods-bitkit.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit.release.xcconfig"; path = "Target Support Files/Pods-bitkit/Pods-bitkit.release.xcconfig"; sourceTree = ""; }; + C4E4FBF74A36838EC0ECDFCA /* Pods-bitkit-bitkitTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit-bitkitTests.release.xcconfig"; path = "Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests.release.xcconfig"; sourceTree = ""; }; CA37793F82F144678099A00D /* InterTight-Bold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-Bold.ttf"; path = "../src/assets/fonts/InterTight-Bold.ttf"; sourceTree = ""; }; D67AECF5F543462F90EC89AD /* InterTight-Medium.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "InterTight-Medium.ttf"; path = "../src/assets/fonts/InterTight-Medium.ttf"; sourceTree = ""; }; DEC74C5375A34FFCAEBA0781 /* Damion-Regular.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Damion-Regular.ttf"; path = "../src/assets/fonts/Damion-Regular.ttf"; sourceTree = ""; }; - ECD2915CC024DFC280EA9D36 /* Pods-bitkit-bitkitTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-bitkit-bitkitTests.debug.xcconfig"; path = "Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests.debug.xcconfig"; sourceTree = ""; }; ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ @@ -68,7 +68,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - B4B2FBEB8D77B877589E2875 /* libPods-bitkit-bitkitTests.a in Frameworks */, + 7B98D2EB65CFC041113931A2 /* libPods-bitkit-bitkitTests.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -76,7 +76,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - B7A9D79C59CD6FE254A31111 /* libPods-bitkit.a in Frameworks */, + F1E150FC6BA3D279F2DFA9DE /* libPods-bitkit.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -119,8 +119,8 @@ isa = PBXGroup; children = ( ED297162215061F000B7C4FE /* JavaScriptCore.framework */, - 3490F59034293BB1555C7477 /* libPods-bitkit.a */, - 21215BC72A8D690106A1F4C8 /* libPods-bitkit-bitkitTests.a */, + 1A1E71C62B79795551E15D38 /* libPods-bitkit.a */, + 653856A32F428EE2C28E3A96 /* libPods-bitkit-bitkitTests.a */, ); name = Frameworks; sourceTree = ""; @@ -183,10 +183,10 @@ BBD78D7AC51CEA395F1C20DB /* Pods */ = { isa = PBXGroup; children = ( - A2F7CEE079CC5248F6B33A93 /* Pods-bitkit.debug.xcconfig */, - B629938C36E49CBDCB4AEB6B /* Pods-bitkit.release.xcconfig */, - ECD2915CC024DFC280EA9D36 /* Pods-bitkit-bitkitTests.debug.xcconfig */, - A46FC25FD9F4D111BF9A0601 /* Pods-bitkit-bitkitTests.release.xcconfig */, + 494310D695EE135B7B1B7996 /* Pods-bitkit.debug.xcconfig */, + 97811DD6E320FC8F3A6F8986 /* Pods-bitkit.release.xcconfig */, + 9C3FCE6AE94B6C974F28C559 /* Pods-bitkit-bitkitTests.debug.xcconfig */, + C4E4FBF74A36838EC0ECDFCA /* Pods-bitkit-bitkitTests.release.xcconfig */, ); path = Pods; sourceTree = ""; @@ -198,12 +198,12 @@ isa = PBXNativeTarget; buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "bitkitTests" */; buildPhases = ( - 56BF42F472B303D57D46E037 /* [CP] Check Pods Manifest.lock */, + AA18EAFFC3FFA647AD9D2C9B /* [CP] Check Pods Manifest.lock */, 00E356EA1AD99517003FC87E /* Sources */, 00E356EB1AD99517003FC87E /* Frameworks */, 00E356EC1AD99517003FC87E /* Resources */, - 46F19816695E357A393273DB /* [CP] Embed Pods Frameworks */, - 6A5FDE07E4B6516CDE097A92 /* [CP] Copy Pods Resources */, + 92CFC26A8566E781770124E3 /* [CP] Embed Pods Frameworks */, + 478A73F26127205833072041 /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -219,13 +219,13 @@ isa = PBXNativeTarget; buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "bitkit" */; buildPhases = ( - 6770E49FE657611B05C08044 /* [CP] Check Pods Manifest.lock */, + 4CD5B3F172A0F1E4418A21A9 /* [CP] Check Pods Manifest.lock */, 13B07F871A680F5B00A75B9A /* Sources */, 13B07F8C1A680F5B00A75B9A /* Frameworks */, 13B07F8E1A680F5B00A75B9A /* Resources */, 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, - 88EABE63936485F2EB3E8CCC /* [CP] Embed Pods Frameworks */, - 79E4B444E97232CB604BAA01 /* [CP] Copy Pods Resources */, + 36C8D7231651405035FBA99C /* [CP] Embed Pods Frameworks */, + 706A92543EEBB40418BD08DF /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -316,46 +316,41 @@ shellPath = /bin/sh; shellScript = "set -e\n\nWITH_ENVIRONMENT=\"$REACT_NATIVE_PATH/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"$REACT_NATIVE_PATH/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n"; }; - 46F19816695E357A393273DB /* [CP] Embed Pods Frameworks */ = { + 36C8D7231651405035FBA99C /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); name = "[CP] Embed Pods Frameworks"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; - 56BF42F472B303D57D46E037 /* [CP] Check Pods Manifest.lock */ = { + 478A73F26127205833072041 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources-${CONFIGURATION}-input-files.xcfilelist", ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; + name = "[CP] Copy Pods Resources"; outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-bitkit-bitkitTests-checkManifestLockResult.txt", + "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources.sh\"\n"; showEnvVarsInLog = 0; }; - 6770E49FE657611B05C08044 /* [CP] Check Pods Manifest.lock */ = { + 4CD5B3F172A0F1E4418A21A9 /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -377,55 +372,60 @@ shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; - 6A5FDE07E4B6516CDE097A92 /* [CP] Copy Pods Resources */ = { + 706A92543EEBB40418BD08DF /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources-${CONFIGURATION}-input-files.xcfilelist", ); name = "[CP] Copy Pods Resources"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-resources.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources.sh\"\n"; showEnvVarsInLog = 0; }; - 79E4B444E97232CB604BAA01 /* [CP] Copy Pods Resources */ = { + 92CFC26A8566E781770124E3 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Copy Pods Resources"; + name = "[CP] Embed Pods Frameworks"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-resources.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit-bitkitTests/Pods-bitkit-bitkitTests-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; - 88EABE63936485F2EB3E8CCC /* [CP] Embed Pods Frameworks */ = { + AA18EAFFC3FFA647AD9D2C9B /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Embed Pods Frameworks"; + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-bitkit-bitkitTests-checkManifestLockResult.txt", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-bitkit/Pods-bitkit-frameworks.sh\"\n"; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; /* End PBXShellScriptBuildPhase section */ @@ -461,7 +461,7 @@ /* Begin XCBuildConfiguration section */ 00E356F61AD99517003FC87E /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = ECD2915CC024DFC280EA9D36 /* Pods-bitkit-bitkitTests.debug.xcconfig */; + baseConfigurationReference = 9C3FCE6AE94B6C974F28C559 /* Pods-bitkit-bitkitTests.debug.xcconfig */; buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; BUNDLE_LOADER = "$(TEST_HOST)"; @@ -489,7 +489,7 @@ }; 00E356F71AD99517003FC87E /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = A46FC25FD9F4D111BF9A0601 /* Pods-bitkit-bitkitTests.release.xcconfig */; + baseConfigurationReference = C4E4FBF74A36838EC0ECDFCA /* Pods-bitkit-bitkitTests.release.xcconfig */; buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; BUNDLE_LOADER = "$(TEST_HOST)"; @@ -514,7 +514,7 @@ }; 13B07F941A680F5B00A75B9A /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = A2F7CEE079CC5248F6B33A93 /* Pods-bitkit.debug.xcconfig */; + baseConfigurationReference = 494310D695EE135B7B1B7996 /* Pods-bitkit.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIconOrange; ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = YES; @@ -546,7 +546,7 @@ }; 13B07F951A680F5B00A75B9A /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = B629938C36E49CBDCB4AEB6B /* Pods-bitkit.release.xcconfig */; + baseConfigurationReference = 97811DD6E320FC8F3A6F8986 /* Pods-bitkit.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIconOrange; ASSETCATALOG_COMPILER_INCLUDE_ALL_APPICON_ASSETS = YES; diff --git a/package.json b/package.json index a622855dd..0bcb511cb 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,6 @@ "@synonymdev/blocktank-lsp-http-client": "2.0.0", "@synonymdev/feeds": "3.0.0", "@synonymdev/ledger": "0.0.5", - "@synonymdev/react-native-keychain": "9.1.1", "@synonymdev/react-native-ldk": "0.0.153", "@synonymdev/react-native-lnurl": "0.0.10", "@synonymdev/react-native-pubky": "^0.3.0", @@ -94,6 +93,7 @@ "react-native-haptic-feedback": "2.2.0", "react-native-image-picker": "7.1.2", "react-native-keyboard-accessory": "0.1.16", + "react-native-keychain": "9.2.2", "react-native-localize": "3.0.2", "react-native-mmkv": "2.12.2", "react-native-modal": "13.0.1", diff --git a/src/components/SlashtagsProvider.tsx b/src/components/SlashtagsProvider.tsx index 6ec7f984e..ff3324928 100644 --- a/src/components/SlashtagsProvider.tsx +++ b/src/components/SlashtagsProvider.tsx @@ -51,10 +51,7 @@ export const SlashtagsProvider = ({ (async (): Promise => { const primaryKeyRes = await getSlashtagsPrimaryKey(seedHash); - if ( - primaryKeyRes.error || - (primaryKeyRes.data && primaryKeyRes.data.length === 0) - ) { + if (primaryKeyRes.isErr() || primaryKeyRes.value.length === 0) { showToast({ type: 'warning', title: i18n.t('other:error_keychain'), @@ -62,7 +59,7 @@ export const SlashtagsProvider = ({ }); return; } - const primaryKey = b4a.from(primaryKeyRes.data, 'hex'); + const primaryKey = b4a.from(primaryKeyRes.value, 'hex'); const keyPair = KeyChain.createKeyPair(primaryKey); webRelayClient = new Client({ diff --git a/src/hooks/pin.tsx b/src/hooks/pin.tsx index 92c4a5620..9693c686d 100644 --- a/src/hooks/pin.tsx +++ b/src/hooks/pin.tsx @@ -66,11 +66,12 @@ const usePIN = (onSuccess?: () => void): UsePIN => { (async (): Promise => { setLoading(true); // wait for initial keychain read - const attemptsRemainingResponse = await getKeychainValue({ - key: 'pinAttemptsRemaining', - }); - setAttemptsRemaining(Number(attemptsRemainingResponse.data)); - // get available biometrics + const attemptsResult = await getKeychainValue('pinAttemptsRemaining'); + if (attemptsResult.isErr()) { + setLoading(false); + return; + } + setAttemptsRemaining(Number(attemptsResult.value)); setLoading(false); })(); }, []); @@ -82,10 +83,10 @@ const usePIN = (onSuccess?: () => void): UsePIN => { return; } - const realPIN = await getKeychainValue({ key: 'pin' }); + const pinResult = await getKeychainValue('pin'); // error getting pin - if (realPIN.error) { + if (pinResult.isErr()) { await reducePinAttemptsRemaining(); vibrate(); setPin(''); @@ -93,7 +94,7 @@ const usePIN = (onSuccess?: () => void): UsePIN => { } // incorrect pin - if (pin !== realPIN?.data) { + if (pin !== pinResult.value) { if (attemptsRemaining <= 1) { vibrate({ type: 'default' }); await wipeApp(); diff --git a/src/utils/keychain.ts b/src/utils/keychain.ts index 04fa73f4a..aa4818be3 100644 --- a/src/utils/keychain.ts +++ b/src/utils/keychain.ts @@ -1,20 +1,17 @@ -import Keychain from '@synonymdev/react-native-keychain'; +import Keychain from 'react-native-keychain'; import { err, ok, Result } from '@synonymdev/result'; -import { IResponse } from './types'; -export const getKeychainValue = async ({ - key, -}: { - key: string; -}): Promise> => { +export const getKeychainValue = async ( + key: string, +): Promise> => { try { const result = await Keychain.getGenericPassword({ service: key }); if (!result || !result.password) { - return { error: true, data: '' }; + return err('No password found'); } - return { error: false, data: result.password }; + return ok(result.password); } catch (e) { - return { error: true, data: e }; + return err(e); } }; @@ -24,29 +21,20 @@ export const setKeychainValue = async ({ }: { key: string; value: string; -}): Promise> => { +}): Promise> => { try { await Keychain.setGenericPassword(key, value, { service: key }); - return { error: false, data: '' }; + return ok(''); } catch (e) { - return { error: true, data: e }; + console.error('Error storing credentials:', e); + return err(e); } }; -/** - * Returns an array of all known Keychain keys. - * @returns {Promise} - */ -export const getAllKeychainKeys = async (): Promise => { - return await Keychain.getAllGenericPasswordServices(); -}; - //WARNING: This will wipe the specified key's value from storage -export const resetKeychainValue = async ({ - key, -}: { - key: string; -}): Promise> => { +export const resetKeychainValue = async ( + key: string, +): Promise> => { try { const result = await Keychain.resetGenericPassword({ service: key }); return ok(result); @@ -61,6 +49,6 @@ export const resetKeychainValue = async ({ * @returns {Promise} */ export const wipeKeychain = async (): Promise => { - const allServices = await getAllKeychainKeys(); - await Promise.all(allServices.map((key) => resetKeychainValue({ key }))); + const services = await Keychain.getAllGenericPasswordServices(); + await Promise.all(services.map((key) => resetKeychainValue(key))); }; diff --git a/src/utils/lightning/index.ts b/src/utils/lightning/index.ts index ca555516f..5c72782ce 100644 --- a/src/utils/lightning/index.ts +++ b/src/utils/lightning/index.ts @@ -1,5 +1,5 @@ import { EmitterSubscription } from 'react-native'; -import Keychain from '@synonymdev/react-native-keychain'; +import Keychain from 'react-native-keychain'; import * as bitcoin from 'bitcoinjs-lib'; import ecc from '@bitcoinerlab/secp256k1'; import RNFS from 'react-native-fs'; @@ -100,6 +100,7 @@ import { __TRUSTED_ZERO_CONF_PEERS__, } from '../../constants/env'; import { showToast } from '../notifications'; +import { setKeychainValue } from '../keychain'; import i18n from '../i18n'; import { bitkitLedger, syncLedger } from '../ledger'; import { sendNavigation } from '../../navigation/bottom-sheet/SendNavigation'; @@ -730,29 +731,16 @@ export const setAccount = async ({ name, seed, }: TAccount): Promise => { - try { - if (!name) { - name = getSelectedWallet(); - name = `${name}${LDK_ACCOUNT_SUFFIX_V3}`; - } - const account: TAccount = { - name, - seed, - }; - const setRes = await Keychain.setGenericPassword( - name, - JSON.stringify(account), - { - service: name, - }, - ); - if (!setRes) { - return false; - } - return true; - } catch { - return false; + if (!name) { + name = getSelectedWallet(); + name = `${name}${LDK_ACCOUNT_SUFFIX_V3}`; } + const account: TAccount = { name, seed }; + const result = await setKeychainValue({ + key: name, + value: JSON.stringify(account), + }); + return result.isOk() ? true : false; }; /** diff --git a/src/utils/settings/index.ts b/src/utils/settings/index.ts index de7639197..304095375 100644 --- a/src/utils/settings/index.ts +++ b/src/utils/settings/index.ts @@ -43,6 +43,6 @@ export const removePin = async (): Promise => { // reset PIN keychain data await Promise.all([ setKeychainValue({ key: 'pinAttemptsRemaining', value: PIN_ATTEMPTS }), - resetKeychainValue({ key: 'pin' }), + resetKeychainValue('pin'), ]); }; diff --git a/src/utils/startup/index.ts b/src/utils/startup/index.ts index dd829ebf5..0b1a658d6 100644 --- a/src/utils/startup/index.ts +++ b/src/utils/startup/index.ts @@ -110,15 +110,15 @@ export const startWalletServices = async ({ setupLedger({ selectedWallet, selectedNetwork }); - const mnemonicResponse = await getMnemonicPhrase(); - if (mnemonicResponse.isErr()) { - return err(mnemonicResponse.error.message); - } - const mnemonic = mnemonicResponse.value; const bip39Passphrase = await getBip39Passphrase(); const walletExists = getWalletStore()?.walletExists; if (!walletExists) { + const mnemonicResponse = await getMnemonicPhrase(); + if (mnemonicResponse.isErr()) { + return err(mnemonicResponse.error.message); + } + const mnemonic = mnemonicResponse.value; const createRes = await createWalletThunk({ mnemonic, bip39Passphrase }); if (createRes.isErr()) { return err(createRes.error.message); diff --git a/src/utils/types/index.ts b/src/utils/types/index.ts index b797ce9a2..9bdd77303 100644 --- a/src/utils/types/index.ts +++ b/src/utils/types/index.ts @@ -5,11 +5,6 @@ import { } from '../../store/types/wallet'; import { EAddressType, IKeyDerivationPath } from 'beignet'; -export interface IResponse { - error: boolean; - data: T; -} - export interface IGetAddress { path: string; selectedNetwork?: EAvailableNetwork; diff --git a/src/utils/wallet/index.ts b/src/utils/wallet/index.ts index a64ae8e00..9dc19d099 100644 --- a/src/utils/wallet/index.ts +++ b/src/utils/wallet/index.ts @@ -344,13 +344,15 @@ export const getPrivateKeyFromPath = async ({ }); }; -const slashtagsPrimaryKeyKeyChainName = (seedHash: string = ''): string => - 'SLASHTAGS_PRIMARYKEY/' + seedHash; +const slashtagsPrimaryKeyKeyChainName = (seedHash: string): string => { + return `SLASHTAGS_PRIMARYKEY/${seedHash}`; +}; export const getSlashtagsPrimaryKey = async ( seedHash: string, -): Promise<{ error: boolean; data: string }> => { - return getKeychainValue({ key: slashtagsPrimaryKeyKeyChainName(seedHash) }); +): Promise> => { + const key = slashtagsPrimaryKeyKeyChainName(seedHash); + return getKeychainValue(key); }; export const slashtagsPrimaryKey = async (seed: Buffer): Promise => { @@ -414,15 +416,7 @@ export const getKeyDerivationAccount = ( export const getMnemonicPhrase = async ( selectedWallet: TWalletName = getSelectedWallet(), ): Promise> => { - try { - const response = await getKeychainValue({ key: selectedWallet }); - if (response.error) { - return err(response.data); - } - return ok(response.data); - } catch (e) { - return err(e); - } + return getKeychainValue(selectedWallet); }; /** @@ -434,16 +428,9 @@ export const getMnemonicPhrase = async ( export const getBip39Passphrase = async ( selectedWallet: TWalletName = getSelectedWallet(), ): Promise => { - try { - const key = `${selectedWallet}passphrase`; - const bip39PassphraseResult = await getKeychainValue({ key }); - if (!bip39PassphraseResult.error && bip39PassphraseResult.data) { - return bip39PassphraseResult.data; - } - return ''; - } catch { - return ''; - } + const key = `${selectedWallet}passphrase`; + const result = await getKeychainValue(key); + return result.isOk() ? result.value : ''; }; /** @@ -861,10 +848,13 @@ export const createDefaultWallet = async ({ return err(msg); } await setKeychainValue({ key: walletName, value: mnemonic }); - await setKeychainValue({ - key: `${walletName}passphrase`, - value: bip39Passphrase, - }); + + if (bip39Passphrase) { + await setKeychainValue({ + key: `${walletName}passphrase`, + value: bip39Passphrase, + }); + } const seed = await bip39.mnemonicToSeed(mnemonic, bip39Passphrase); await setKeychainSlashtagsPrimaryKey(seed); diff --git a/yarn.lock b/yarn.lock index 9308674bf..b0e481f4d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4931,13 +4931,6 @@ __metadata: languageName: node linkType: hard -"@synonymdev/react-native-keychain@npm:9.1.1": - version: 9.1.1 - resolution: "@synonymdev/react-native-keychain@npm:9.1.1" - checksum: ec92ee34d1e61035bbbea8f7df93a0310cad6f55e4f2f23441b64e1092d00df5ff50d706318b8d45b16a6d300d2789ba7d651634313099bc356847f015529cfb - languageName: node - linkType: hard - "@synonymdev/react-native-ldk@npm:0.0.153": version: 0.0.153 resolution: "@synonymdev/react-native-ldk@npm:0.0.153" @@ -6605,7 +6598,6 @@ __metadata: "@synonymdev/blocktank-lsp-http-client": 2.0.0 "@synonymdev/feeds": 3.0.0 "@synonymdev/ledger": 0.0.5 - "@synonymdev/react-native-keychain": 9.1.1 "@synonymdev/react-native-ldk": 0.0.153 "@synonymdev/react-native-lnurl": 0.0.10 "@synonymdev/react-native-pubky": ^0.3.0 @@ -6675,6 +6667,7 @@ __metadata: react-native-haptic-feedback: 2.2.0 react-native-image-picker: 7.1.2 react-native-keyboard-accessory: 0.1.16 + react-native-keychain: 9.2.2 react-native-localize: 3.0.2 react-native-mmkv: 2.12.2 react-native-modal: 13.0.1 @@ -14351,6 +14344,13 @@ __metadata: languageName: node linkType: hard +"react-native-keychain@npm:9.2.2": + version: 9.2.2 + resolution: "react-native-keychain@npm:9.2.2" + checksum: e361df1e792766bb4d3f60b850608979667357365328d36e1665a077728b8d68f7d33de0d31e3c666f115a0f9e1f53be48b4e678bf73f07aecefcca35766d98d + languageName: node + linkType: hard + "react-native-localize@npm:3.0.2": version: 3.0.2 resolution: "react-native-localize@npm:3.0.2"