@seams/wallet 0.7.3 → 0.8.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 +4 -5
- package/THIRD_PARTY_NOTICES.md +1 -9
- package/dist/.build-inputs.sha256 +1 -1
- package/dist/esm/SeamsWeb/SeamsWeb.js +2 -2
- package/dist/esm/SeamsWeb/assembly/browserSigningSurfaceAssembly.js +2 -2
- package/dist/esm/SeamsWeb/assembly/createBrowserRecoveryPublicDeps.js +1 -1
- package/dist/esm/SeamsWeb/assembly/createBrowserSigningStores.js +1 -1
- package/dist/esm/SeamsWeb/assembly/createBrowserWarmSessionPublicDeps.js +0 -2
- package/dist/esm/SeamsWeb/operations/auth/login.js +18 -43
- package/dist/esm/SeamsWeb/operations/auth/walletUnlockSubject.js +2 -8
- package/dist/esm/SeamsWeb/operations/authMethods/emailOtp/addEmailOtp.js +1 -1
- package/dist/esm/SeamsWeb/operations/authMethods/emailOtp/googleEmailOtpWalletAuthFlow.js +5 -9
- package/dist/esm/SeamsWeb/operations/authMethods/passkey/addPasskey.js +1 -1
- package/dist/esm/SeamsWeb/operations/authMethods/revokeAuthMethod.js +1 -1
- package/dist/esm/SeamsWeb/operations/devices/deviceLinkingResume.js +1 -4
- package/dist/esm/SeamsWeb/operations/devices/linkDeviceFlow.js +38 -13
- package/dist/esm/SeamsWeb/operations/devices/scanDevice.js +1 -1
- package/dist/esm/SeamsWeb/operations/near/signNEP413.js +0 -1
- package/dist/esm/SeamsWeb/operations/recovery/syncAccount.js +2 -4
- package/dist/esm/SeamsWeb/operations/recovery/walletRecovery.js +1 -2
- package/dist/esm/SeamsWeb/operations/recovery/walletRecoveryCommit.js +4 -5
- package/dist/esm/SeamsWeb/operations/recovery/walletRecoveryDurablePayload.js +1 -2
- package/dist/esm/SeamsWeb/operations/recovery/walletRecoveryRotation.js +1 -2
- package/dist/esm/SeamsWeb/operations/registration/pendingRegistrationRecovery.js +3 -12
- package/dist/esm/SeamsWeb/operations/registration/registration.js +5 -5
- package/dist/esm/SeamsWeb/operations/registration/registrationStrictEcdsa.js +1 -1
- package/dist/esm/SeamsWeb/operations/registration/registrationTerminalCommit.js +1 -1
- package/dist/esm/SeamsWeb/operations/session/thresholdEcdsaProvisioning.js +2 -6
- package/dist/esm/SeamsWeb/publicApi/near.js +1 -1
- package/dist/esm/SeamsWeb/publicApi/transactionReview.js +4 -1
- package/dist/esm/SeamsWeb/signingSurface/BrowserSigningSurface.js +4 -4
- package/dist/esm/SeamsWeb/walletIframe/client/router.js +1 -2
- package/dist/esm/SeamsWeb/walletIframe/client/surface/domain.js +0 -2
- package/dist/esm/SeamsWeb/walletIframe/client/transport/IframeTransport.js +0 -4
- package/dist/esm/SeamsWeb/walletIframe/client/transport/iframe-transport-handshake.js +1 -1
- package/dist/esm/SeamsWeb/walletIframe/host/ui/auth-menu/AuthMenuFooter.js +64 -0
- package/dist/esm/SeamsWeb/walletIframe/host/ui/auth-menu/AuthMenuSurface.js +165 -222
- package/dist/esm/SeamsWeb/walletIframe/host/ui/auth-menu/icons.js +136 -0
- package/dist/esm/SeamsWeb/walletIframe/shared/messages.js +6 -6
- package/dist/esm/SeamsWeb/walletIframe/shared/transactionReview.js +11 -1
- package/dist/esm/advanced.js +0 -1
- package/dist/esm/base-styles.js +2 -2
- package/dist/esm/core/accountData/near/accountProjection.js +0 -1
- package/dist/esm/core/accountData/near/keyMaterial.js +0 -1
- package/dist/esm/core/browser/walletIframe/events.js +1 -5
- package/dist/esm/core/browser/walletIframe/host-mode.js +0 -10
- package/dist/esm/core/config/chains.js +1 -2
- package/dist/esm/core/config/configBuilder.js +0 -1
- package/dist/esm/core/config/configHelpers.js +0 -1
- package/dist/esm/core/indexedDB/accountKeyMaterial.js +0 -1
- package/dist/esm/core/indexedDB/index.js +3 -4
- package/dist/esm/core/indexedDB/pendingWalletRecoveryCommit.js +1 -4
- package/dist/esm/core/indexedDB/schemaNames.js +0 -22
- package/dist/esm/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestRecords.js +3 -3
- package/dist/esm/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestStore.js +3 -3
- package/dist/esm/core/indexedDB/seamsWalletDB/ecdsaClientPresignatures.js +1 -1
- package/dist/esm/core/indexedDB/seamsWalletDB/pendingWalletRecoveryCodeBackup.js +0 -1
- package/dist/esm/core/indexedDB/seamsWalletDB/registrationSetup.js +103 -0
- package/dist/esm/core/indexedDB/seamsWalletDB/repositories.js +2 -3
- package/dist/esm/core/indexedDB/seamsWalletDB/signingSessionSeals.js +0 -35
- package/dist/esm/core/indexedDB/seamsWalletDB/walletCustodyEcdsaContinuity.js +4 -4
- package/dist/esm/core/indexedDB/seamsWalletDB/walletSessionAuthorizationStore.js +37 -19
- package/dist/esm/core/indexedDB/unifiedIndexedDBManager.js +10 -3
- package/dist/esm/core/indexedDB/walletCustodyEd25519MaterialRecord.js +1 -1
- package/dist/esm/core/platform/browser/createBrowserPlatformRuntime.js +8 -25
- package/dist/esm/core/rpcClients/near/rpcCalls.js +39 -1
- package/dist/esm/core/rpcClients/relayer/passkeyCustodyEnvelope.js +3 -13
- package/dist/esm/core/rpcClients/relayer/thresholdEcdsa.js +0 -2
- package/dist/esm/core/rpcClients/relayer/walletRecoveryPrepare.js +3 -4
- package/dist/esm/core/rpcClients/relayer/walletRegistration.js +21 -15
- package/dist/esm/core/rpcClients/relayer/walletRegistrationTerminalResponse.js +1 -2
- package/dist/esm/core/signingEngine/assembly/createManagers.js +1 -1
- package/dist/esm/core/signingEngine/assembly/ports/shared.js +1 -2
- package/dist/esm/core/signingEngine/assembly/warmup.js +1 -5
- package/dist/esm/core/signingEngine/chains/near/nearSignerWasm.js +2 -33
- package/dist/esm/core/signingEngine/flows/recovery/ecdsaDerivationExport.js +0 -1
- package/dist/esm/core/signingEngine/flows/recovery/ecdsaExportMaterial.js +0 -1
- package/dist/esm/core/signingEngine/flows/recovery/passkeyEd25519YaoRecovery.js +1 -1
- package/dist/esm/core/signingEngine/flows/recovery/stepUpAuthorization.js +1 -1
- package/dist/esm/core/signingEngine/flows/registration/accountLifecycle.js +3 -8
- package/dist/esm/core/signingEngine/flows/registration/services/passkeyEd25519YaoAddSigner.js +1 -2
- package/dist/esm/core/signingEngine/flows/shared/signingStateMachine.js +2 -5
- package/dist/esm/core/signingEngine/flows/signEvmFamily/readySecp256k1Material.js +0 -2
- package/dist/esm/core/signingEngine/flows/signEvmFamily/signingFlow.js +1 -1
- package/dist/esm/core/signingEngine/flows/signEvmFamily/transactionExecutor.js +1 -2
- package/dist/esm/core/signingEngine/flows/signNear/implicitAccountFunding.js +1 -1
- package/dist/esm/core/signingEngine/flows/signNear/shared/ed25519YaoNormalSigning.js +33 -42
- package/dist/esm/core/signingEngine/flows/signNear/shared/signatureOnlySigning.js +0 -2
- package/dist/esm/core/signingEngine/flows/signNear/shared/signingMaterials.js +1 -7
- package/dist/esm/core/signingEngine/flows/signNear/shared/signingSessionAuthMode.js +4 -14
- package/dist/esm/core/signingEngine/flows/signNear/signDelegate.js +2 -6
- package/dist/esm/core/signingEngine/flows/signNear/signNep413.js +2 -6
- package/dist/esm/core/signingEngine/nonce/NonceCoordinator.js +1 -1
- package/dist/esm/core/signingEngine/nonce/nearNonceLane.js +1 -1
- package/dist/esm/core/signingEngine/nonce/nonceDiagnostics.js +1 -1
- package/dist/esm/core/signingEngine/routerAb/ecdsaDerivation/poolFillRoutes.js +0 -1
- package/dist/esm/core/signingEngine/routerAb/ecdsaDerivation/presignaturePool.js +0 -1
- package/dist/esm/core/signingEngine/routerAb/ecdsaDerivation/signingMaterialRef.js +0 -3
- package/dist/esm/core/signingEngine/session/SigningSessionCoordinator.js +1 -4
- package/dist/esm/core/signingEngine/session/authority/authorityOperationResolver.js +17 -68
- package/dist/esm/core/signingEngine/session/emailOtp/EmailOtpWalletSessionCoordinator.js +0 -1
- package/dist/esm/core/signingEngine/session/emailOtp/ecdsaBootstrapCommit.js +1 -1
- package/dist/esm/core/signingEngine/session/emailOtp/ecdsaLifecycleRuntime.js +0 -3
- package/dist/esm/core/signingEngine/session/emailOtp/ecdsaLogin.js +1 -7
- package/dist/esm/core/signingEngine/session/emailOtp/ecdsaRecovery.js +10 -14
- package/dist/esm/core/signingEngine/session/emailOtp/ed25519ExportContext.js +0 -3
- package/dist/esm/core/signingEngine/session/emailOtp/exportRecovery.js +0 -2
- package/dist/esm/core/signingEngine/session/identity/clientSessionPersistenceState.js +5 -16
- package/dist/esm/core/signingEngine/session/identity/evmFamilyEcdsaIdentity.js +0 -1
- package/dist/esm/core/signingEngine/session/identity/exactSigningLaneIdentity.js +1 -1
- package/dist/esm/core/signingEngine/session/identity/exactWalletSessionCredential.js +0 -2
- package/dist/esm/core/signingEngine/session/material/activeWalletAuthorityEcdsaRuntime.js +1 -2
- package/dist/esm/core/signingEngine/session/material/ecdsaCapabilityManifest.js +1 -1
- package/dist/esm/core/signingEngine/session/material/ecdsaRoleLocalMaterialResolver.js +1 -14
- package/dist/esm/core/signingEngine/session/operationState/preparedOperation.js +1 -5
- package/dist/esm/core/signingEngine/session/passkey/ecdsaBootstrap.js +3 -6
- package/dist/esm/core/signingEngine/session/passkey/ecdsaKeyFactsInventory.js +0 -1
- package/dist/esm/core/signingEngine/session/passkey/ecdsaRecovery.js +1 -4
- package/dist/esm/core/signingEngine/session/passkey/ed25519SessionProvision.js +0 -1
- package/dist/esm/core/signingEngine/session/passkey/ed25519YaoLocalMaterial.js +2 -3
- package/dist/esm/core/signingEngine/session/passkey/ed25519YaoWarmRecovery.js +12 -45
- package/dist/esm/core/signingEngine/session/persistence/clientSessionPersistence.js +8 -16
- package/dist/esm/core/signingEngine/session/persistence/sealedSessionRecords.js +0 -2
- package/dist/esm/core/signingEngine/session/postconditions/runtimePostconditions.js +0 -2
- package/dist/esm/core/signingEngine/session/routerAbSigningWalletSession.js +2 -8
- package/dist/esm/core/signingEngine/session/warmCapabilities/readModel.js +2 -8
- package/dist/esm/core/signingEngine/session/warmCapabilities/routerAbWalletSessionCredential.js +1 -12
- package/dist/esm/core/signingEngine/session/warmCapabilities/transitions.js +7 -11
- package/dist/esm/core/signingEngine/stepUpConfirmation/otpPrompt/authLane.js +0 -1
- package/dist/esm/core/signingEngine/stepUpConfirmation/passkeyPrompt/touchIdPrompt.js +6 -30
- package/dist/esm/core/signingEngine/stepUpConfirmation/passkeyPrompt/webauthnPromptCoordinator.js +0 -3
- package/dist/esm/core/signingEngine/stepUpConfirmation/requireStepUpAuth.js +1 -5
- package/dist/esm/core/signingEngine/threshold/crypto/ed25519YaoLaneWasm.js +0 -3
- package/dist/esm/core/signingEngine/threshold/ecdsa/bootstrapSession.js +1 -5
- package/dist/esm/core/signingEngine/threshold/ed25519/walletSession.js +1 -1
- package/dist/esm/core/signingEngine/threshold/ed25519/yaoClient.js +1 -35
- package/dist/esm/core/signingEngine/threshold/sessionPolicy.js +0 -1
- package/dist/esm/core/signingEngine/uiConfirm/PasskeyMpcSessionDurableState.js +1 -4
- package/dist/esm/core/signingEngine/uiConfirm/PasskeyMpcSessionManager.js +1 -1
- package/dist/esm/core/signingEngine/uiConfirm/UiConfirmManager.js +0 -1
- package/dist/esm/core/signingEngine/uiConfirm/handlers/flows/adapters/adapters.js +1 -1
- package/dist/esm/core/signingEngine/uiConfirm/handlers/flows/localOnly.js +0 -1
- package/dist/esm/core/signingEngine/uiConfirm/ui/preact/TransactionReceipt.js +7 -0
- package/dist/esm/core/signingEngine/uiConfirm/ui/transaction-display/abi/abiDecode.js +3 -13
- package/dist/esm/core/signingEngine/walletCustody/activateEd25519Capability.js +0 -1
- package/dist/esm/core/signingEngine/walletCustody/emailOtpLink.js +10 -13
- package/dist/esm/core/signingEngine/walletCustody/openCustodyCache.js +2 -6
- package/dist/esm/core/signingEngine/walletCustody/passkeyLink.js +7 -10
- package/dist/esm/core/signingEngine/walletCustody/registrationCeremony.js +0 -1
- package/dist/esm/core/signingEngine/walletCustody/walletRecoveryCredential.js +0 -1
- package/dist/esm/core/signingEngine/walletCustody/walletRecoveryEcdsa.js +0 -1
- package/dist/esm/core/signingEngine/walletCustody/walletRecoveryEd25519.js +1 -1
- package/dist/esm/core/signingEngine/walletCustody/walletRecoveryManifest.js +0 -2
- package/dist/esm/core/signingEngine/walletCustody/walletRecoveryRotation.js +0 -1
- package/dist/esm/core/signingEngine/webauthnAuth/walletOriginWebAuthn.js +109 -0
- package/dist/esm/core/signingEngine/workerManager/SignerWorkerManager.js +0 -2
- package/dist/esm/core/signingEngine/workerManager/ecdsaClientWorkerChannels.js +0 -4
- package/dist/esm/core/signingEngine/workerManager/validation.js +1 -1
- package/dist/esm/core/signingEngine/workerManager/workerTransport.js +3 -42
- package/dist/esm/core/signingEngine/workerManager/workerTypes.js +0 -2
- package/dist/esm/core/types/accountIds.js +0 -1
- package/dist/esm/core/types/sdkSentEvents.js +1 -2
- package/dist/esm/core/types/signer-worker.js +1 -36
- package/dist/esm/core/walletRuntimePaths/base.js +11 -1
- package/dist/esm/plugins/headers.js +0 -1
- package/dist/esm/plugins/next.js +0 -1
- package/dist/esm/plugins/plugin-utils.js +0 -1
- package/dist/esm/plugins/shared-ts/src/utils/normalize.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/AccountsSection.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/AuthenticationMethodsModal.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/ExportKeysSection.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/LinkedDevicesModal.js +4 -4
- package/dist/esm/react/components/AccountMenuButton/LockMenuItem.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/ProfileDropdown.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/WalletSettingsLayout.css +8 -0
- package/dist/esm/react/components/AccountMenuButton/WalletSettingsLayout.js +14 -6
- package/dist/esm/react/components/AccountMenuButton/icons/TouchIcon.js +1 -1
- package/dist/esm/react/components/AccountMenuButton/index.js +5 -5
- package/dist/esm/react/components/HostedSeamsAuthMenu/SeamsAuthMenuMock.js +1 -1
- package/dist/esm/react/components/HostedSeamsAuthMenu/shell.js +1 -1
- package/dist/esm/react/components/QRCodeScanner.js +2 -2
- package/dist/esm/react/components/ShowQRCode.js +4 -4
- package/dist/esm/react/components/theme/design-tokens.js +1 -2
- package/dist/esm/react/context/index.js +1 -1
- package/dist/esm/react/context/reactLoginStateBuilders.js +1 -1
- package/dist/esm/react/context/seamsManagerSingleton.js +2 -2
- package/dist/esm/react/context/useLoginStateRefresher.js +2 -5
- package/dist/esm/react/context/useSeamsContextValue.js +1 -1
- package/dist/esm/react/context/useSeamsWithSdkFlow.js +1 -1
- package/dist/esm/react/context/useWalletIframeLifecycle.js +1 -1
- package/dist/esm/react/hooks/useAccountInput.js +4 -4
- package/dist/esm/react/hooks/useNearClient.js +3 -3
- package/dist/esm/react/hooks/usePreconnectWalletAssets.js +1 -1
- package/dist/esm/react/hooks/useQRCamera.js +2 -2
- package/dist/esm/react/hooks/useWallet.js +1 -1
- package/dist/esm/react/index.js +10 -10
- package/dist/esm/react/styles/styles.css +8 -0
- package/dist/esm/react/transactionReview/TransactionReviewHost.js +1 -1
- package/dist/esm/react/transactionReview/boundCalls.js +2 -2
- package/dist/esm/react/transactionReview/contract.js +1 -1
- package/dist/esm/react/transactionReview/controller.js +2 -2
- package/dist/esm/react/transactionReview/snapshot.js +2 -2
- package/dist/esm/sdk/ConfirmationDrawer-DrsREojk.js +1 -0
- package/dist/esm/sdk/EvmClient-DoxytQaJ.js +1 -0
- package/dist/esm/sdk/NearClient-vJ65Wjrq.js +1 -0
- package/dist/esm/sdk/NonceCoordinator-BBeadCSq.js +1 -0
- package/dist/esm/sdk/accountIds-C3Ihsd2c.js +1 -0
- package/dist/esm/sdk/accountLifecycle-EyfYPnuT.js +1 -0
- package/dist/esm/sdk/actions-DZLxCcrU.js +1 -0
- package/dist/esm/sdk/adapters-DtAyuoiA.js +2 -0
- package/dist/esm/sdk/base-Xtd32asf.js +1 -0
- package/dist/esm/sdk/base64-ojm5DKcF.js +1 -0
- package/dist/esm/sdk/browser-CsOGMbMy.js +8 -0
- package/dist/esm/sdk/bytes-t5S5mkat.js +1 -0
- package/dist/esm/sdk/canonicalPrimitives-MPGET2cl.js +1 -0
- package/dist/esm/sdk/canonicalSignerErrorCode-C0hh_SVi.js +1 -0
- package/dist/esm/sdk/capabilityKinds-XaXXiD2B.js +1 -0
- package/dist/esm/sdk/chains-yAls2d9X.js +1 -0
- package/dist/esm/sdk/challengeDelivery-cAsaUC6U.js +1 -0
- package/dist/esm/sdk/chunk-dVx5-UGu.js +1 -0
- package/dist/esm/sdk/configHelpers-CseiVoZD.js +1 -0
- package/dist/esm/sdk/csp-stylesheet-B1fAhrGB.js +2 -0
- package/dist/esm/sdk/defaultConfigs-CWpApkMq.js +1 -0
- package/dist/esm/sdk/display-jK7_hYho.js +1 -0
- package/dist/esm/sdk/domainIds-GDzjOs6i.js +1 -0
- package/dist/esm/sdk/ecdsaCapabilityManifest-CHFu-QrV.js +1 -0
- package/dist/esm/sdk/ecdsaChainTarget-CRcRR78w.js +1 -0
- package/dist/esm/sdk/ecdsaPresignLifecycle-CQnCxSlq.js +1 -0
- package/dist/esm/sdk/ecdsaPresignPoolIdentity-Ci-ovDlv.js +1 -0
- package/dist/esm/sdk/ecdsaWalletRecords-Cm1DdexN.js +1 -0
- package/dist/esm/sdk/enrichDisplayModelWithAbi-CR-4ebuU.js +1 -0
- package/dist/esm/sdk/enrichDisplayModelWithAbi-CwHKFqF4.js +569 -0
- package/dist/esm/sdk/errors-DfbnsXjO.js +1 -0
- package/dist/esm/sdk/events-BJyVcnsn.js +1 -0
- package/dist/esm/sdk/evmCryptoWasm-CwEXiLrC.js +1 -0
- package/dist/esm/sdk/evmFamilyEcdsaIdentity-Br3iFdQx.js +1 -0
- package/dist/esm/sdk/exactSessionState-CjD8gekO.js +210 -0
- package/dist/esm/sdk/exactSigningLaneIdentity-olheZx_n.js +1 -0
- package/dist/esm/sdk/executeWorkerOperation-CrFf3FkL.js +1 -0
- package/dist/esm/sdk/export-viewer-host-jo7h_0wl.js +1 -0
- package/dist/esm/sdk/helpers-D4QckQhq.js +1 -0
- package/dist/esm/sdk/host-BAqOYnju.js +1 -0
- package/dist/esm/sdk/intentDigest-CB6zy3lN.js +1 -0
- package/dist/esm/sdk/jsonRpc-C85RYR0A.js +1 -0
- package/dist/esm/sdk/jsxRuntime.module-CoHsKD_3.js +1 -0
- package/dist/esm/sdk/keccak-zexutGfG.js +1 -0
- package/dist/esm/sdk/keyMaterialBrands-uVZHfAh3.js +1 -0
- package/dist/esm/sdk/localOnly-DBQRG6Qh.js +1 -0
- package/dist/esm/sdk/messages-Cv2j4SKI.js +1 -0
- package/dist/esm/sdk/mountExportPrivateKeySurface-G7Z_9JMQ.js +1 -0
- package/dist/esm/sdk/mountRecoveryCodeBackupSurface-BBCTaQsu.js +2 -0
- package/dist/esm/sdk/nearEd25519YaoMaterialActivation-DQIw8ho3.js +1 -0
- package/dist/esm/sdk/nearEd25519YaoSigningPreparation-Bp_CvWRz.js +1 -0
- package/dist/esm/sdk/nearRpcResults--cBcfmp4.js +1 -0
- package/dist/esm/sdk/nonceLaneKeys-BBYi4g51.js +1 -0
- package/dist/esm/sdk/normalization-BGPR6osg.js +1 -0
- package/dist/esm/sdk/operationFingerprint-5-wH2Ht8.js +1 -0
- package/dist/esm/sdk/operationFingerprint-DtQb0pdp.js +1 -0
- package/dist/esm/sdk/passkey-custody-LP4UTFbn.js +1 -0
- package/dist/esm/sdk/pendingWalletRecoveryCodeBackup-BNk4ebsY.js +1 -0
- package/dist/esm/sdk/prfCache-Mbo7_USg.js +1 -0
- package/dist/esm/sdk/profileAccountProjection-DHCaMtOu.js +1 -0
- package/dist/esm/sdk/promptText-s8TQ6ckX.js +1 -0
- package/dist/esm/sdk/recovery-entrypoint-DkT8sFO5.js +1 -0
- package/dist/esm/sdk/registration-Btozh7uh.js +1 -0
- package/dist/esm/sdk/registration-CSAG_h4Y.js +1 -0
- package/dist/esm/sdk/registrationAccounts-DIeEVy6W.js +1 -0
- package/dist/esm/sdk/registrationIds-BIel5S0i.js +1 -0
- package/dist/esm/sdk/registrationIntent-DV1GYZ3K.js +1 -0
- package/dist/esm/sdk/registrationPreparationPreload-vOCqNuG4.js +1 -0
- package/dist/esm/sdk/registrationSignerPlan-FzD3TwxB.js +1 -0
- package/dist/esm/sdk/relayerHttp-DaPeS929.js +1 -0
- package/dist/esm/sdk/routePlan-B_KJaPtm.js +1 -0
- package/dist/esm/sdk/router-Dd3fFHk3.js +1 -0
- package/dist/esm/sdk/routerAbNormalSigning-D_fHjq5l.js +1 -0
- package/dist/esm/sdk/router_ab_ed25519_yao_client_bg.wasm +0 -0
- package/dist/esm/sdk/runtime-auth-B2M91rSx.js +1 -0
- package/dist/esm/sdk/runtime-device-link-ojjPSRaG.js +1 -0
- package/dist/esm/sdk/runtime-ecdsa-tempo-CE4JLgmn.js +1 -0
- package/dist/esm/sdk/runtime-email-otp-DDwtKVAe.js +1 -0
- package/dist/esm/sdk/runtime-export-JXYk8sQ-.js +1 -0
- package/dist/esm/sdk/runtime-near-BB8AG6dV.js +1 -0
- package/dist/esm/sdk/runtime-preferences-DKFZYccW.js +1 -0
- package/dist/esm/sdk/runtime-recovery-C_XjsDBg.js +1 -0
- package/dist/esm/sdk/runtime-recovery-codes-CWp839mH.js +1 -0
- package/dist/esm/sdk/runtimeContext-BpObgzbj.js +6 -0
- package/dist/esm/sdk/runtimeLoader-DjgBf_yF.js +1 -0
- package/dist/esm/sdk/sdkSentEvents-_RGAEeld.js +1 -0
- package/dist/esm/sdk/secp256k1-B_6W9QDJ.js +1 -0
- package/dist/esm/sdk/secureRandomId-CTdlJ5Mx.js +1 -0
- package/dist/esm/sdk/sessionPolicy-CNVK7nJ6.js +1 -0
- package/dist/esm/sdk/shared-j_KsFbCT.js +1 -0
- package/dist/esm/sdk/signEvmFamily-CcLVBm0f.js +1 -0
- package/dist/esm/sdk/signEvmFamilyWithUiConfirmForTempo-DgTbh6jX.js +1 -0
- package/dist/esm/sdk/signEvmWithUiConfirm-ChreN7aZ.js +1 -0
- package/dist/esm/sdk/signNear-mWbTE2Dl.js +1 -0
- package/dist/esm/sdk/signatureUses-CQkkUcwT.js +1 -0
- package/dist/esm/sdk/signerDomain-BhUTzDmF.js +1 -0
- package/dist/esm/sdk/signerLoader-By0IY24G.js +1 -0
- package/dist/esm/sdk/signerSlot-BQ1g5JNV.js +1 -0
- package/dist/esm/sdk/signingFlow-LUWrZi2d.js +2 -0
- package/dist/esm/sdk/signingSessionSeal-Mr2Xp44o.js +1 -0
- package/dist/esm/sdk/surface-measurement-reporter-OICExWKE.js +1 -0
- package/dist/esm/sdk/trace-M34pNGuF.js +1 -0
- package/dist/esm/sdk/transaction-activity-BbDod7ji.js +1 -0
- package/dist/esm/sdk/transactionReview-CBE5oH4c.js +1 -0
- package/dist/esm/sdk/transactionReviewAdmission-0ZgWs6q3.js +1 -0
- package/dist/esm/sdk/transactionState-9d7f3xVj.js +1 -0
- package/dist/esm/sdk/tx-confirm-ui.js +12 -158
- package/dist/esm/sdk/types-M7vxrYtJ.js +1 -0
- package/dist/esm/sdk/validation-dC1-_uyG.js +1 -0
- package/dist/esm/sdk/wallet-iframe-host-ecdsa.js +1 -13
- package/dist/esm/sdk/wallet-iframe-host-full.js +1 -6
- package/dist/esm/sdk/wallet-iframe-host-near.js +1 -13
- package/dist/esm/sdk/wallet-iframe-host-runtime.js +1 -4
- package/dist/esm/sdk/wallet-recovery-CcDZ1hMH.js +1 -0
- package/dist/esm/sdk/wallet-ui.css +1 -5874
- package/dist/esm/sdk/walletAuthority-CoWSeqvQ.js +1 -0
- package/dist/esm/sdk/walletCustodyEcdsaContinuity-B7xi7nwh.js +1 -0
- package/dist/esm/sdk/walletIframeIdentity-C0b0XMQF.js +1 -0
- package/dist/esm/sdk/walletRecoveryCommit-ljxVeo-d.js +1 -0
- package/dist/esm/sdk/walletRecoveryRotate-HztDcDaY.js +1 -0
- package/dist/esm/sdk/warmSessionHydration-BPGM0YRU.js +1 -0
- package/dist/esm/sdk/webauthnP256-qu06GNFm.js +1 -0
- package/dist/esm/sdk/webauthnPromptCoordinator-DO-qfECu.js +1 -0
- package/dist/esm/shared-ts/src/device-linking/parsers.js +41 -1
- package/dist/esm/shared-ts/src/device-linking/sourceContribution.js +1 -1
- package/dist/esm/shared-ts/src/near/actions.js +10 -1
- package/dist/esm/shared-ts/src/near/nearClient.js +0 -2
- package/dist/esm/shared-ts/src/signing-lanes/evmFamilySigningKeySlotId.js +1 -1
- package/dist/esm/shared-ts/src/signing-lanes/index.js +1 -4
- package/dist/esm/shared-ts/src/signing-lanes/ownerContinuity.js +0 -1
- package/dist/esm/shared-ts/src/signing-lanes/participantDigest.js +0 -1
- package/dist/esm/shared-ts/src/signing-lanes/participants.js +1 -1
- package/dist/esm/shared-ts/src/signing-lanes/recordParsers.js +1 -1
- package/dist/esm/shared-ts/src/threshold/ecdsaDerivationRoleLocalBootstrap.js +0 -1
- package/dist/esm/shared-ts/src/threshold/participants.js +0 -1
- package/dist/esm/shared-ts/src/threshold/signingRootScope.js +0 -1
- package/dist/esm/shared-ts/src/utils/domainIds.js +1 -7
- package/dist/esm/shared-ts/src/utils/ecdsaKeyFactsInventory.js +0 -1
- package/dist/esm/shared-ts/src/utils/encoders.js +1 -1
- package/dist/esm/shared-ts/src/utils/errors.js +0 -1
- package/dist/esm/shared-ts/src/utils/index.js +4 -5
- package/dist/esm/shared-ts/src/utils/registrationEstablishedSession.js +1 -1
- package/dist/esm/shared-ts/src/utils/registrationIds.js +1 -5
- package/dist/esm/shared-ts/src/utils/registrationIntent.js +0 -1
- package/dist/esm/shared-ts/src/utils/registrationSetupOperation.js +12 -0
- package/dist/esm/shared-ts/src/utils/registrationSignerPlan.js +1 -1
- package/dist/esm/shared-ts/src/utils/routerAbEcdsaDerivation.js +1 -2
- package/dist/esm/shared-ts/src/utils/validation.js +0 -1
- package/dist/esm/shared-ts/src/utils/walletAuthAuthority.js +0 -1
- package/dist/esm/shared-ts/src/utils/walletCapabilityBindings.js +10 -1
- package/dist/esm/shared-ts/src/utils/walletManagementProtocol.js +6 -0
- package/dist/esm/shared-ts/src/wallet-recovery/index.js +1 -1
- package/dist/esm/shared-ts/src/wallet-recovery/recoveryCodeLocator.js +0 -1
- package/dist/esm/shared-ts/src/wallet-recovery/recoveryKeyId.js +0 -2
- package/dist/esm/theme/base-styles.js +11 -11
- package/dist/esm/utils/deviceDetection.js +16 -1
- package/dist/esm/utils/qrScanner.js +288 -0
- package/dist/esm/wasm/near_signer/pkg/wasm_signer_worker.d.ts +12 -753
- package/dist/esm/wasm/near_signer/pkg/wasm_signer_worker.js +126 -3701
- package/dist/esm/wasm/near_signer/pkg/wasm_signer_worker_bg.wasm +0 -0
- package/dist/esm/wasm/router_ab_ecdsa_client/pkg/router_ab_ecdsa_client.d.ts +0 -42
- package/dist/esm/wasm/router_ab_ecdsa_client/pkg/router_ab_ecdsa_client.js +2 -106
- package/dist/esm/wasm/router_ab_ecdsa_client/pkg/router_ab_ecdsa_client_bg.wasm +0 -0
- package/dist/esm/wasm/router_ab_ed25519_yao_client/pkg/router_ab_ed25519_yao_client.d.ts +3 -158
- package/dist/esm/wasm/router_ab_ed25519_yao_client/pkg/router_ab_ed25519_yao_client.js +2 -452
- package/dist/esm/wasm/router_ab_ed25519_yao_client/pkg/router_ab_ed25519_yao_client_bg.wasm +0 -0
- package/dist/public/headers.manifest.json +1 -1
- package/dist/public/sdk/ConfirmationDrawer-DrsREojk.js +1 -0
- package/dist/public/sdk/EvmClient-DoxytQaJ.js +1 -0
- package/dist/public/sdk/NearClient-vJ65Wjrq.js +1 -0
- package/dist/public/sdk/NonceCoordinator-BBeadCSq.js +1 -0
- package/dist/public/sdk/accountIds-C3Ihsd2c.js +1 -0
- package/dist/public/sdk/accountLifecycle-EyfYPnuT.js +1 -0
- package/dist/public/sdk/actions-DZLxCcrU.js +1 -0
- package/dist/public/sdk/adapters-DtAyuoiA.js +2 -0
- package/dist/public/sdk/base-Xtd32asf.js +1 -0
- package/dist/public/sdk/base64-ojm5DKcF.js +1 -0
- package/dist/public/sdk/browser-CsOGMbMy.js +8 -0
- package/dist/public/sdk/bytes-t5S5mkat.js +1 -0
- package/dist/public/sdk/canonicalPrimitives-MPGET2cl.js +1 -0
- package/dist/public/sdk/canonicalSignerErrorCode-C0hh_SVi.js +1 -0
- package/dist/public/sdk/capabilityKinds-XaXXiD2B.js +1 -0
- package/dist/public/sdk/chains-yAls2d9X.js +1 -0
- package/dist/public/sdk/challengeDelivery-cAsaUC6U.js +1 -0
- package/dist/public/sdk/chunk-dVx5-UGu.js +1 -0
- package/dist/public/sdk/configHelpers-CseiVoZD.js +1 -0
- package/dist/public/sdk/csp-stylesheet-B1fAhrGB.js +2 -0
- package/dist/public/sdk/defaultConfigs-CWpApkMq.js +1 -0
- package/dist/public/sdk/display-jK7_hYho.js +1 -0
- package/dist/public/sdk/domainIds-GDzjOs6i.js +1 -0
- package/dist/public/sdk/ecdsaCapabilityManifest-CHFu-QrV.js +1 -0
- package/dist/public/sdk/ecdsaChainTarget-CRcRR78w.js +1 -0
- package/dist/public/sdk/ecdsaPresignLifecycle-CQnCxSlq.js +1 -0
- package/dist/public/sdk/ecdsaPresignPoolIdentity-Ci-ovDlv.js +1 -0
- package/dist/public/sdk/ecdsaWalletRecords-Cm1DdexN.js +1 -0
- package/dist/public/sdk/enrichDisplayModelWithAbi-CR-4ebuU.js +1 -0
- package/dist/public/sdk/enrichDisplayModelWithAbi-CwHKFqF4.js +569 -0
- package/dist/public/sdk/errors-DfbnsXjO.js +1 -0
- package/dist/public/sdk/events-BJyVcnsn.js +1 -0
- package/dist/public/sdk/evmCryptoWasm-CwEXiLrC.js +1 -0
- package/dist/public/sdk/evmFamilyEcdsaIdentity-Br3iFdQx.js +1 -0
- package/dist/public/sdk/exactSessionState-CjD8gekO.js +210 -0
- package/dist/public/sdk/exactSigningLaneIdentity-olheZx_n.js +1 -0
- package/dist/public/sdk/executeWorkerOperation-CrFf3FkL.js +1 -0
- package/dist/public/sdk/export-viewer-host-jo7h_0wl.js +1 -0
- package/dist/public/sdk/helpers-D4QckQhq.js +1 -0
- package/dist/public/sdk/host-BAqOYnju.js +1 -0
- package/dist/public/sdk/intentDigest-CB6zy3lN.js +1 -0
- package/dist/public/sdk/jsonRpc-C85RYR0A.js +1 -0
- package/dist/public/sdk/jsxRuntime.module-CoHsKD_3.js +1 -0
- package/dist/public/sdk/keccak-zexutGfG.js +1 -0
- package/dist/public/sdk/keyMaterialBrands-uVZHfAh3.js +1 -0
- package/dist/public/sdk/localOnly-DBQRG6Qh.js +1 -0
- package/dist/public/sdk/messages-Cv2j4SKI.js +1 -0
- package/dist/public/sdk/mountExportPrivateKeySurface-G7Z_9JMQ.js +1 -0
- package/dist/public/sdk/mountRecoveryCodeBackupSurface-BBCTaQsu.js +2 -0
- package/dist/public/sdk/nearEd25519YaoMaterialActivation-DQIw8ho3.js +1 -0
- package/dist/public/sdk/nearEd25519YaoSigningPreparation-Bp_CvWRz.js +1 -0
- package/dist/public/sdk/nearRpcResults--cBcfmp4.js +1 -0
- package/dist/public/sdk/nonceLaneKeys-BBYi4g51.js +1 -0
- package/dist/public/sdk/normalization-BGPR6osg.js +1 -0
- package/dist/public/sdk/operationFingerprint-5-wH2Ht8.js +1 -0
- package/dist/public/sdk/operationFingerprint-DtQb0pdp.js +1 -0
- package/dist/public/sdk/passkey-custody-LP4UTFbn.js +1 -0
- package/dist/public/sdk/pendingWalletRecoveryCodeBackup-BNk4ebsY.js +1 -0
- package/dist/public/sdk/prfCache-Mbo7_USg.js +1 -0
- package/dist/public/sdk/profileAccountProjection-DHCaMtOu.js +1 -0
- package/dist/public/sdk/promptText-s8TQ6ckX.js +1 -0
- package/dist/public/sdk/recovery-entrypoint-DkT8sFO5.js +1 -0
- package/dist/public/sdk/registration-Btozh7uh.js +1 -0
- package/dist/public/sdk/registration-CSAG_h4Y.js +1 -0
- package/dist/public/sdk/registrationAccounts-DIeEVy6W.js +1 -0
- package/dist/public/sdk/registrationIds-BIel5S0i.js +1 -0
- package/dist/public/sdk/registrationIntent-DV1GYZ3K.js +1 -0
- package/dist/public/sdk/registrationPreparationPreload-vOCqNuG4.js +1 -0
- package/dist/public/sdk/registrationSignerPlan-FzD3TwxB.js +1 -0
- package/dist/public/sdk/relayerHttp-DaPeS929.js +1 -0
- package/dist/public/sdk/routePlan-B_KJaPtm.js +1 -0
- package/dist/public/sdk/router-Dd3fFHk3.js +1 -0
- package/dist/public/sdk/routerAbNormalSigning-D_fHjq5l.js +1 -0
- package/dist/public/sdk/router_ab_ed25519_yao_client_bg.wasm +0 -0
- package/dist/public/sdk/runtime-auth-B2M91rSx.js +1 -0
- package/dist/public/sdk/runtime-device-link-ojjPSRaG.js +1 -0
- package/dist/public/sdk/runtime-ecdsa-tempo-CE4JLgmn.js +1 -0
- package/dist/public/sdk/runtime-email-otp-DDwtKVAe.js +1 -0
- package/dist/public/sdk/runtime-export-JXYk8sQ-.js +1 -0
- package/dist/public/sdk/runtime-near-BB8AG6dV.js +1 -0
- package/dist/public/sdk/runtime-preferences-DKFZYccW.js +1 -0
- package/dist/public/sdk/runtime-recovery-C_XjsDBg.js +1 -0
- package/dist/public/sdk/runtime-recovery-codes-CWp839mH.js +1 -0
- package/dist/public/sdk/runtimeContext-BpObgzbj.js +6 -0
- package/dist/public/sdk/runtimeLoader-DjgBf_yF.js +1 -0
- package/dist/public/sdk/sdkSentEvents-_RGAEeld.js +1 -0
- package/dist/public/sdk/secp256k1-B_6W9QDJ.js +1 -0
- package/dist/public/sdk/secureRandomId-CTdlJ5Mx.js +1 -0
- package/dist/public/sdk/sessionPolicy-CNVK7nJ6.js +1 -0
- package/dist/public/sdk/shared-j_KsFbCT.js +1 -0
- package/dist/public/sdk/signEvmFamily-CcLVBm0f.js +1 -0
- package/dist/public/sdk/signEvmFamilyWithUiConfirmForTempo-DgTbh6jX.js +1 -0
- package/dist/public/sdk/signEvmWithUiConfirm-ChreN7aZ.js +1 -0
- package/dist/public/sdk/signNear-mWbTE2Dl.js +1 -0
- package/dist/public/sdk/signatureUses-CQkkUcwT.js +1 -0
- package/dist/public/sdk/signerDomain-BhUTzDmF.js +1 -0
- package/dist/public/sdk/signerLoader-By0IY24G.js +1 -0
- package/dist/public/sdk/signerSlot-BQ1g5JNV.js +1 -0
- package/dist/public/sdk/signingFlow-LUWrZi2d.js +2 -0
- package/dist/public/sdk/signingSessionSeal-Mr2Xp44o.js +1 -0
- package/dist/public/sdk/surface-measurement-reporter-OICExWKE.js +1 -0
- package/dist/public/sdk/trace-M34pNGuF.js +1 -0
- package/dist/public/sdk/transaction-activity-BbDod7ji.js +1 -0
- package/dist/public/sdk/transactionReview-CBE5oH4c.js +1 -0
- package/dist/public/sdk/transactionReviewAdmission-0ZgWs6q3.js +1 -0
- package/dist/public/sdk/transactionState-9d7f3xVj.js +1 -0
- package/dist/public/sdk/tx-confirm-ui.js +12 -158
- package/dist/public/sdk/types-M7vxrYtJ.js +1 -0
- package/dist/public/sdk/validation-dC1-_uyG.js +1 -0
- package/dist/public/sdk/wallet-iframe-host-ecdsa.js +1 -13
- package/dist/public/sdk/wallet-iframe-host-full.js +1 -6
- package/dist/public/sdk/wallet-iframe-host-near.js +1 -13
- package/dist/public/sdk/wallet-iframe-host-runtime.js +1 -4
- package/dist/public/sdk/wallet-recovery-CcDZ1hMH.js +1 -0
- package/dist/public/sdk/wallet-ui.css +1 -5874
- package/dist/public/sdk/walletAuthority-CoWSeqvQ.js +1 -0
- package/dist/public/sdk/walletCustodyEcdsaContinuity-B7xi7nwh.js +1 -0
- package/dist/public/sdk/walletIframeIdentity-C0b0XMQF.js +1 -0
- package/dist/public/sdk/walletRecoveryCommit-ljxVeo-d.js +1 -0
- package/dist/public/sdk/walletRecoveryRotate-HztDcDaY.js +1 -0
- package/dist/public/sdk/warmSessionHydration-BPGM0YRU.js +1 -0
- package/dist/public/sdk/webauthnP256-qu06GNFm.js +1 -0
- package/dist/public/sdk/webauthnPromptCoordinator-DO-qfECu.js +1 -0
- package/dist/public/sdk/workers/device-linking-key.worker.js +387 -1952
- package/dist/public/sdk/workers/ecdsa-derivation-client.worker.js +1523 -2668
- package/dist/public/sdk/workers/ecdsa-online-client.worker.js +1 -273
- package/dist/public/sdk/workers/ecdsa-presign-client.worker.js +1 -273
- package/dist/public/sdk/workers/email-otp.worker.js +228 -2103
- package/dist/public/sdk/workers/email_otp_runtime_bg.wasm +0 -0
- package/dist/public/sdk/workers/evm-crypto.worker.js +0 -188
- package/dist/public/sdk/workers/evm_crypto.wasm +0 -0
- package/dist/public/sdk/workers/evm_crypto_bg.wasm +0 -0
- package/dist/public/sdk/workers/near-signer.worker.js +16 -718
- package/dist/public/sdk/workers/near_signer.wasm +0 -0
- package/dist/public/sdk/workers/passkey-confirm.worker.js +0 -134
- package/dist/public/sdk/workers/passkey-mpc-export.worker.js +149 -506
- package/dist/public/sdk/workers/passkey-mpc-session.worker.js +0 -134
- package/dist/public/sdk/workers/router_ab_ecdsa_client_bg.wasm +0 -0
- package/dist/public/sdk/workers/router_ab_ed25519_yao_client_bg.wasm +0 -0
- package/dist/public/sdk/workers/shamir3pass.worker.js +0 -134
- package/dist/public/sdk/workers/shamir3pass_runtime_bg.wasm +0 -0
- package/dist/public/sdk/workers/tempo-signer.worker.js +0 -134
- package/dist/public/sdk/workers/tempo_signer.wasm +0 -0
- package/dist/public/sdk/workers/tempo_signer_bg.wasm +0 -0
- package/dist/public/sdk/workers/wallet-custody-ceremony.worker.js +135 -1635
- package/dist/public/sdk/workers/wallet_custody_ceremony.js +0 -14
- package/dist/public/sdk/workers/wallet_custody_ceremony_bg.wasm +0 -0
- package/dist/public/sdk/workers/wasm_signer_worker_bg.wasm +0 -0
- package/dist/public/wallet-assets.manifest.json +234 -258
- package/dist/public/wallet-service/index.html +4 -4
- package/dist/types/shared-ts/src/authorization/capabilityKinds.d.ts +0 -4
- package/dist/types/shared-ts/src/device-linking/contracts.d.ts +1 -0
- package/dist/types/shared-ts/src/signing-lanes/evmFamilySigningKeySlotId.d.ts +0 -2
- package/dist/types/shared-ts/src/signing-lanes/execution.d.ts +0 -11
- package/dist/types/shared-ts/src/signing-lanes/ids.d.ts +2 -7
- package/dist/types/shared-ts/src/signing-lanes/index.d.ts +0 -4
- package/dist/types/shared-ts/src/signing-lanes/ownerContinuity.d.ts +0 -1
- package/dist/types/shared-ts/src/signing-lanes/participantDigest.d.ts +0 -18
- package/dist/types/shared-ts/src/signing-lanes/participants.d.ts +6 -35
- package/dist/types/shared-ts/src/signing-lanes/rotation.d.ts +6 -843
- package/dist/types/shared-ts/src/threshold/keyMaterialBrands.d.ts +0 -10
- package/dist/types/shared-ts/src/threshold/participants.d.ts +1 -1
- package/dist/types/shared-ts/src/utils/addWalletAuthMethod.d.ts +1 -133
- package/dist/types/shared-ts/src/utils/addWalletAuthMethod.typecheck.d.ts +4 -18
- package/dist/types/shared-ts/src/utils/domainIds.d.ts +0 -12
- package/dist/types/shared-ts/src/utils/errors.d.ts +0 -4
- package/dist/types/shared-ts/src/utils/near.d.ts +0 -20
- package/dist/types/shared-ts/src/utils/normalize.d.ts +0 -2
- package/dist/types/shared-ts/src/utils/registrationSetupOperation.d.ts +3 -0
- package/dist/types/shared-ts/src/utils/validation.d.ts +1 -3
- package/dist/types/shared-ts/src/utils/walletCapabilityBindings.d.ts +0 -1
- package/dist/types/shared-ts/src/utils/walletManagementProtocol.d.ts +3 -0
- package/dist/types/shared-ts/src/utils/wireSchema.d.ts +0 -2
- package/dist/types/shared-ts/src/wallet-recovery/backupAcknowledgement.d.ts +0 -1
- package/dist/types/shared-ts/src/wallet-recovery/recoveryCodeReservation.d.ts +1 -10
- package/dist/types/shared-ts/src/wallet-recovery/recoveryCodes.d.ts +1 -3
- package/dist/types/shared-ts/src/wallet-recovery/recoveryKeyId.d.ts +5 -21
- package/dist/types/wallet/src/SeamsWeb/operations/auth/walletUnlockEcdsaSubject.d.ts +1 -1
- package/dist/types/wallet/src/SeamsWeb/operations/auth/walletUnlockSubject.d.ts +0 -3
- package/dist/types/wallet/src/SeamsWeb/operations/authMethods/emailOtp/challenge.d.ts +0 -4
- package/dist/types/wallet/src/SeamsWeb/operations/devices/deviceLinkingResume.d.ts +0 -1
- package/dist/types/wallet/src/SeamsWeb/operations/devices/linkDeviceFlow.d.ts +2 -0
- package/dist/types/wallet/src/SeamsWeb/operations/registration/pendingRegistrationRecovery.d.ts +0 -10
- package/dist/types/wallet/src/SeamsWeb/operations/session/thresholdEcdsaProvisioning.d.ts +1 -2
- package/dist/types/wallet/src/SeamsWeb/signingSurface/ports.d.ts +0 -2
- package/dist/types/wallet/src/SeamsWeb/signingSurface/types.d.ts +1 -1
- package/dist/types/wallet/src/SeamsWeb/walletIframe/client/surface/domain.d.ts +0 -8
- package/dist/types/wallet/src/SeamsWeb/walletIframe/client/transport/iframe-transport-handshake.d.ts +1 -2
- package/dist/types/wallet/src/SeamsWeb/walletIframe/host/auth-menu/domain.d.ts +9 -0
- package/dist/types/wallet/src/SeamsWeb/walletIframe/host/hostedWalletSeamsSession.d.ts +0 -1
- package/dist/types/wallet/src/SeamsWeb/walletIframe/host/ui/auth-menu/AuthMenuFooter.d.ts +17 -0
- package/dist/types/wallet/src/SeamsWeb/walletIframe/host/ui/auth-menu/AuthMenuSurface.d.ts +11 -3
- package/dist/types/wallet/src/SeamsWeb/walletIframe/host/ui/auth-menu/icons.d.ts +15 -0
- package/dist/types/wallet/src/SeamsWeb/walletIframe/shared/exactSessionReconciliation.d.ts +3 -3
- package/dist/types/wallet/src/advanced.d.ts +1 -1
- package/dist/types/wallet/src/core/browser/walletIframe/events.d.ts +0 -2
- package/dist/types/wallet/src/core/indexedDB/index.d.ts +3 -5
- package/dist/types/wallet/src/core/indexedDB/passkeyClientDB.types.d.ts +0 -30
- package/dist/types/wallet/src/core/indexedDB/pendingWalletRecoveryCommit.d.ts +1 -4
- package/dist/types/wallet/src/core/indexedDB/schemaNames.d.ts +0 -22
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestRecords.d.ts +1 -1
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestStore.d.ts +1 -1
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/pendingWalletRecoveryCodeBackup.d.ts +0 -1
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/registrationSetup.d.ts +42 -0
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/signingSessionSeals.d.ts +1 -5
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/walletSessionAuthorizationStore.d.ts +5 -1
- package/dist/types/wallet/src/core/indexedDB/unifiedIndexedDBManager.d.ts +1 -0
- package/dist/types/wallet/src/core/platform/browser/createBrowserPlatformRuntime.d.ts +1 -6
- package/dist/types/wallet/src/core/platform/ecdsaRoleLocalRecords.d.ts +0 -15
- package/dist/types/wallet/src/core/platform/index.d.ts +4 -4
- package/dist/types/wallet/src/core/platform/ports.d.ts +1 -51
- package/dist/types/wallet/src/core/platform/runtime.d.ts +0 -2
- package/dist/types/wallet/src/core/platform/secretSources.d.ts +0 -29
- package/dist/types/wallet/src/core/rpcClients/near/NearClient.d.ts +1 -1
- package/dist/types/wallet/src/core/rpcClients/relayer/passkeyCustodyEnvelope.d.ts +0 -6
- package/dist/types/wallet/src/core/rpcClients/relayer/thresholdEcdsa.d.ts +0 -1
- package/dist/types/wallet/src/core/rpcClients/relayer/walletRegistration.d.ts +2 -19
- package/dist/types/wallet/src/core/signingEngine/assembly/ports/shared.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/assembly/ports/warmSigning.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/assembly/warmup.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/chains/near/nearSignerWasm.d.ts +0 -10
- package/dist/types/wallet/src/core/signingEngine/flows/recovery/keyExportConfirmation.d.ts +0 -15
- package/dist/types/wallet/src/core/signingEngine/flows/registration/accountLifecycle.d.ts +1 -11
- package/dist/types/wallet/src/core/signingEngine/flows/registration/public.d.ts +1 -9
- package/dist/types/wallet/src/core/signingEngine/flows/registration/services/passkeyEd25519YaoAddSigner.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/flows/shared/signingStateMachine.d.ts +0 -6
- package/dist/types/wallet/src/core/signingEngine/flows/signEvmFamily/readySecp256k1Material.d.ts +2 -10
- package/dist/types/wallet/src/core/signingEngine/flows/signNear/shared/ed25519YaoCapabilityResolution.d.ts +1 -4
- package/dist/types/wallet/src/core/signingEngine/flows/signNear/shared/ed25519YaoNormalSigning.d.ts +0 -5
- package/dist/types/wallet/src/core/signingEngine/flows/signNear/shared/signingMaterials.d.ts +0 -4
- package/dist/types/wallet/src/core/signingEngine/flows/signNear/shared/signingSessionAuthMode.d.ts +0 -9
- package/dist/types/wallet/src/core/signingEngine/interfaces/index.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/nonce/NonceCoordinator.d.ts +1 -1
- package/dist/types/wallet/src/core/signingEngine/nonce/nonceTypes.d.ts +0 -9
- package/dist/types/wallet/src/core/signingEngine/routerAb/ecdsaDerivation/signingMaterialRef.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/authority/authorityOperationResolver.d.ts +1 -24
- package/dist/types/wallet/src/core/signingEngine/session/availability/readiness.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/emailOtp/ecdsaLogin.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/emailOtp/ecdsaRecovery.d.ts +0 -5
- package/dist/types/wallet/src/core/signingEngine/session/emailOtp/ed25519ExportContext.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/session/emailOtp/secretEscrow.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/session/identity/clientSessionPersistenceState.d.ts +0 -6
- package/dist/types/wallet/src/core/signingEngine/session/identity/emailOtpEcdsaDerivationIdentity.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/identity/evmFamilyEcdsaIdentity.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/identity/exactSigningLaneIdentity.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/identity/exactWalletSessionCredential.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/identity/laneIdentity.d.ts +0 -6
- package/dist/types/wallet/src/core/signingEngine/session/identity/walletUnlockSubject.d.ts +0 -8
- package/dist/types/wallet/src/core/signingEngine/session/keyMaterialBrands.d.ts +1 -4
- package/dist/types/wallet/src/core/signingEngine/session/material/activeWalletAuthorityEcdsaRuntime.d.ts +1 -1
- package/dist/types/wallet/src/core/signingEngine/session/material/ecdsaRoleLocalMaterialResolver.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/session/operationState/authorizationAdmission.d.ts +1 -1
- package/dist/types/wallet/src/core/signingEngine/session/operationState/preparedOperation.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/passkey/ed25519YaoLocalMaterial.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/session/passkey/ed25519YaoWarmRecovery.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/persistence/ecdsaRoleLocalRecords.d.ts +1 -10
- package/dist/types/wallet/src/core/signingEngine/session/persistence/sealedSessionRecords.d.ts +2 -2
- package/dist/types/wallet/src/core/signingEngine/session/persistence/sealedSessionTransportAuth.d.ts +0 -5
- package/dist/types/wallet/src/core/signingEngine/session/postconditions/runtimePostconditions.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/routerAbSigningWalletSession.d.ts +1 -1
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/ecdsaProvisionPlan.d.ts +0 -105
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/public.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/routerAbWalletSessionCredential.d.ts +0 -12
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/transitions.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/types.typecheck.d.ts +1 -10
- package/dist/types/wallet/src/core/signingEngine/stepUpConfirmation/methodRunners.d.ts +1 -5
- package/dist/types/wallet/src/core/signingEngine/stepUpConfirmation/passkeyPrompt/touchIdPrompt.d.ts +1 -2
- package/dist/types/wallet/src/core/signingEngine/stepUpConfirmation/passkeyPrompt/webauthnPromptCoordinator.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/stepUpConfirmation/requireStepUpAuth.d.ts +1 -19
- package/dist/types/wallet/src/core/signingEngine/stepUpConfirmation/types.d.ts +0 -10
- package/dist/types/wallet/src/core/signingEngine/threshold/crypto/ed25519YaoLaneWasm.d.ts +1 -15
- package/dist/types/wallet/src/core/signingEngine/threshold/ecdsa/activation.d.ts +0 -4
- package/dist/types/wallet/src/core/signingEngine/threshold/ecdsa/bootstrapSession.d.ts +0 -4
- package/dist/types/wallet/src/core/signingEngine/threshold/ed25519/connectSession.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/threshold/ed25519/yaoClient.d.ts +1 -8
- package/dist/types/wallet/src/core/signingEngine/uiConfirm/handlers/flows/requestRegistrationCredentialConfirmation.d.ts +1 -4
- package/dist/types/wallet/src/core/signingEngine/uiConfirm/ui/transaction-display/abi/abiDecode.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/walletCustody/emailOtpLink.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/walletCustody/openCustodyCache.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/walletCustody/passkeyLink.d.ts +0 -3
- package/dist/types/wallet/src/core/signingEngine/walletCustody/registrationCeremony.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/webauthnAuth/walletOriginWebAuthn.d.ts +8 -0
- package/dist/types/wallet/src/core/signingEngine/workerManager/SignerWorkerManager.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/workerManager/ecdsaClientWorkerChannels.d.ts +0 -8
- package/dist/types/wallet/src/core/signingEngine/workerManager/validation.d.ts +1 -1
- package/dist/types/wallet/src/core/signingEngine/workerManager/workerTypes.d.ts +6 -109
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/device-linking-key/requests.d.ts +0 -5
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/crypto.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/custodyRestore.d.ts +0 -8
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/otpVerification.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/payloadParsing.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/unlock.d.ts +0 -1
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/near-signer.worker.d.ts +3 -31
- package/dist/types/wallet/src/core/types/accountIds.d.ts +1 -1
- package/dist/types/wallet/src/core/types/index.d.ts +0 -18
- package/dist/types/wallet/src/core/types/sdkSentEvents.d.ts +1 -2
- package/dist/types/wallet/src/core/types/secure-confirm-worker.d.ts +0 -5
- package/dist/types/wallet/src/core/types/signer-worker.d.ts +75 -134
- package/dist/types/wallet/src/react/components/AccountMenuButton/Toggle.d.ts +0 -15
- package/dist/types/wallet/src/react/components/theme/design-tokens.d.ts +0 -19
- package/dist/types/wallet/src/utils/qrScanner.d.ts +1 -21
- package/dist/workers/device-linking-key.worker.js +387 -1952
- package/dist/workers/ecdsa-derivation-client.worker.js +1523 -2668
- package/dist/workers/ecdsa-online-client.worker.js +1 -273
- package/dist/workers/ecdsa-presign-client.worker.js +1 -273
- package/dist/workers/email-otp.worker.js +228 -2103
- package/dist/workers/email_otp_runtime_bg.wasm +0 -0
- package/dist/workers/evm-crypto.worker.js +0 -188
- package/dist/workers/evm_crypto.wasm +0 -0
- package/dist/workers/evm_crypto_bg.wasm +0 -0
- package/dist/workers/near-signer.worker.js +16 -718
- package/dist/workers/near_signer.wasm +0 -0
- package/dist/workers/passkey-confirm.worker.js +0 -134
- package/dist/workers/passkey-mpc-export.worker.js +149 -506
- package/dist/workers/passkey-mpc-session.worker.js +0 -134
- package/dist/workers/router_ab_ecdsa_client_bg.wasm +0 -0
- package/dist/workers/router_ab_ed25519_yao_client_bg.wasm +0 -0
- package/dist/workers/shamir3pass.worker.js +0 -134
- package/dist/workers/shamir3pass_runtime_bg.wasm +0 -0
- package/dist/workers/tempo-signer.worker.js +0 -134
- package/dist/workers/tempo_signer.wasm +0 -0
- package/dist/workers/tempo_signer_bg.wasm +0 -0
- package/dist/workers/wallet-custody-ceremony.worker.js +135 -1635
- package/dist/workers/wallet_custody_ceremony.js +0 -14
- package/dist/workers/wallet_custody_ceremony_bg.wasm +0 -0
- package/dist/workers/wasm_signer_worker_bg.wasm +0 -0
- package/package.json +1 -14
- package/dist/esm/SeamsWeb/walletIframe/client/transport/webauthn-bridge.js +0 -99
- package/dist/esm/components/AccountMenuButton/AccountsSection.css +0 -81
- package/dist/esm/components/AccountMenuButton/ExportKeysSection.css +0 -96
- package/dist/esm/components/AccountMenuButton/LinkedDevicesModal.css +0 -612
- package/dist/esm/components/AccountMenuButton/MenuItem.css +0 -198
- package/dist/esm/components/AccountMenuButton/ProfileDropdown.css +0 -80
- package/dist/esm/components/AccountMenuButton/TransactionSettingsSection.css +0 -107
- package/dist/esm/components/AccountMenuButton/UserAccountButton.css +0 -177
- package/dist/esm/components/AccountMenuButton/WalletSettingsLayout.css +0 -456
- package/dist/esm/components/AccountMenuButton/Web3AuthProfileButton.css +0 -23
- package/dist/esm/components/AccountMenuButton/icons/TouchIcon.css +0 -46
- package/dist/esm/components/QRCodeScanner.css +0 -487
- package/dist/esm/components/ShowQRCode.css +0 -331
- package/dist/esm/core/indexedDB/seamsWalletDB/laneHolderMaterialStore.js +0 -236
- package/dist/esm/core/signingEngine/webauthnAuth/fallbacks/safari-fallbacks.js +0 -171
- package/dist/esm/core/signingEngine/workerManager/nearKeyOps/createNearKeyOps.js +0 -32
- package/dist/esm/plugins/shared-ts/src/utils/base58.js +0 -1
- package/dist/esm/plugins/shared-ts/src/utils/near.js +0 -1
- package/dist/esm/plugins/shared-ts/src/utils/validation.js +0 -2
- package/dist/esm/react/SeamsWeb/SeamsWeb.js +0 -1918
- package/dist/esm/react/SeamsWeb/assembly/browserSigningSurfaceAssembly.js +0 -817
- package/dist/esm/react/SeamsWeb/assembly/browserWorkerWarmupPolicy.js +0 -31
- package/dist/esm/react/SeamsWeb/assembly/configureBrowserIndexedDB.js +0 -10
- package/dist/esm/react/SeamsWeb/assembly/createBrowserRecoveryPublicDeps.js +0 -95
- package/dist/esm/react/SeamsWeb/assembly/createBrowserSigningRuntime.js +0 -34
- package/dist/esm/react/SeamsWeb/assembly/createBrowserSigningStores.js +0 -39
- package/dist/esm/react/SeamsWeb/assembly/createBrowserStepUpRuntime.js +0 -34
- package/dist/esm/react/SeamsWeb/assembly/createBrowserWarmSessionPublicDeps.js +0 -31
- package/dist/esm/react/SeamsWeb/assembly/createWalletIframeOverlayState.js +0 -9
- package/dist/esm/react/SeamsWeb/assembly/createWalletIframeRouter.js +0 -44
- package/dist/esm/react/SeamsWeb/assembly/initializeBrowserSigningRuntime.js +0 -19
- package/dist/esm/react/SeamsWeb/assembly/runtimeConfig.js +0 -12
- package/dist/esm/react/SeamsWeb/operations/auth/login.js +0 -4408
- package/dist/esm/react/SeamsWeb/operations/auth/scheduleEcdsaSessionPresignaturePrefill.js +0 -41
- package/dist/esm/react/SeamsWeb/operations/auth/scheduleLinkedDevicePresignaturePrefill.js +0 -64
- package/dist/esm/react/SeamsWeb/operations/auth/walletAuth.js +0 -142
- package/dist/esm/react/SeamsWeb/operations/auth/walletUnlockEcdsaSubject.js +0 -33
- package/dist/esm/react/SeamsWeb/operations/auth/walletUnlockSubject.js +0 -294
- package/dist/esm/react/SeamsWeb/operations/authMethods/addAuthMethodSourceClaim.js +0 -72
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/addEmailOtp.js +0 -191
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/challenge.js +0 -247
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/googleEmailOtpWalletAuthFlow.js +0 -572
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/localEmailOtpProjection.js +0 -69
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/registrationAuthority.js +0 -62
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/registrationOffer.js +0 -69
- package/dist/esm/react/SeamsWeb/operations/authMethods/emailOtp/walletActivation.js +0 -95
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/addPasskey.js +0 -260
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/ecdsaBootstrap.js +0 -17
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/exactPasskeyAuthority.js +0 -34
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/localPasskeyProjection.js +0 -117
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/localUnlock.js +0 -16
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/loginAssertion.js +0 -25
- package/dist/esm/react/SeamsWeb/operations/authMethods/passkey/registrationAuthority.js +0 -84
- package/dist/esm/react/SeamsWeb/operations/authMethods/revokeAuthMethod.js +0 -205
- package/dist/esm/react/SeamsWeb/operations/authMethods/sourcePasskeyProof.js +0 -12
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingAuthorityInstallation.js +0 -444
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingComposition.js +0 -106
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingEd25519ExportRoot.js +0 -194
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingHttpTransport.js +0 -524
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingOwnerTransport.js +0 -135
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingResume.js +0 -215
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingTargetCredential.js +0 -63
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingTargetEd25519ExportRoot.js +0 -61
- package/dist/esm/react/SeamsWeb/operations/devices/deviceLinkingWorkerChannels.js +0 -337
- package/dist/esm/react/SeamsWeb/operations/devices/linkDevice.js +0 -75
- package/dist/esm/react/SeamsWeb/operations/devices/linkDeviceFlow.js +0 -1358
- package/dist/esm/react/SeamsWeb/operations/devices/linkDeviceFlowSupport.js +0 -143
- package/dist/esm/react/SeamsWeb/operations/devices/linkDeviceTargetActivation.js +0 -119
- package/dist/esm/react/SeamsWeb/operations/devices/scanDevice.js +0 -384
- package/dist/esm/react/SeamsWeb/operations/devices/walletHostComposition.js +0 -130
- package/dist/esm/react/SeamsWeb/operations/devices/walletHostOwnerAuthority.js +0 -191
- package/dist/esm/react/SeamsWeb/operations/evm/index.js +0 -35
- package/dist/esm/react/SeamsWeb/operations/near/actions.js +0 -484
- package/dist/esm/react/SeamsWeb/operations/near/commandSubject.js +0 -14
- package/dist/esm/react/SeamsWeb/operations/near/delegateAction.js +0 -247
- package/dist/esm/react/SeamsWeb/operations/near/index.js +0 -37
- package/dist/esm/react/SeamsWeb/operations/near/signNEP413.js +0 -117
- package/dist/esm/react/SeamsWeb/operations/near/signingEventHelpers.js +0 -15
- package/dist/esm/react/SeamsWeb/operations/recovery/accountSync.js +0 -21
- package/dist/esm/react/SeamsWeb/operations/recovery/recoveryWalletBinding.js +0 -43
- package/dist/esm/react/SeamsWeb/operations/recovery/syncAccount.js +0 -914
- package/dist/esm/react/SeamsWeb/operations/recovery/walletRecoveryCodeBackup.js +0 -100
- package/dist/esm/react/SeamsWeb/operations/recovery/walletRecoveryCommit.js +0 -477
- package/dist/esm/react/SeamsWeb/operations/recovery/walletRecoveryDurablePayload.js +0 -383
- package/dist/esm/react/SeamsWeb/operations/recovery/walletRecoveryJournal.js +0 -118
- package/dist/esm/react/SeamsWeb/operations/recovery/walletRecoveryRotation.js +0 -214
- package/dist/esm/react/SeamsWeb/operations/registration/pendingEcdsaRegistrationRecovery.js +0 -184
- package/dist/esm/react/SeamsWeb/operations/registration/pendingEcdsaRegistrationRecoveryUnlock.js +0 -247
- package/dist/esm/react/SeamsWeb/operations/registration/pendingEcdsaRegistrationRecoveryValidation.js +0 -134
- package/dist/esm/react/SeamsWeb/operations/registration/pendingRegistrationRecovery.js +0 -363
- package/dist/esm/react/SeamsWeb/operations/registration/registration.js +0 -3818
- package/dist/esm/react/SeamsWeb/operations/registration/registrationEd25519Yao.js +0 -166
- package/dist/esm/react/SeamsWeb/operations/registration/registrationSignerSet.js +0 -60
- package/dist/esm/react/SeamsWeb/operations/registration/registrationStrictEcdsa.js +0 -343
- package/dist/esm/react/SeamsWeb/operations/registration/registrationTerminalCommit.js +0 -296
- package/dist/esm/react/SeamsWeb/operations/registration/registrationTiming.js +0 -682
- package/dist/esm/react/SeamsWeb/operations/session/thresholdEcdsaProvisioning.js +0 -40
- package/dist/esm/react/SeamsWeb/operations/session/thresholdWarmSessionBootstrap.js +0 -20
- package/dist/esm/react/SeamsWeb/operations/tempo/executeEvmFamilyTransaction.js +0 -568
- package/dist/esm/react/SeamsWeb/operations/tempo/feeTokenPreference.js +0 -67
- package/dist/esm/react/SeamsWeb/operations/tempo/index.js +0 -39
- package/dist/esm/react/SeamsWeb/publicApi/auth.js +0 -24
- package/dist/esm/react/SeamsWeb/publicApi/awaitNearReady.js +0 -72
- package/dist/esm/react/SeamsWeb/publicApi/capabilitySelection.js +0 -63
- package/dist/esm/react/SeamsWeb/publicApi/chainTargets.js +0 -48
- package/dist/esm/react/SeamsWeb/publicApi/createPublicApi.js +0 -133
- package/dist/esm/react/SeamsWeb/publicApi/currentWallet.js +0 -46
- package/dist/esm/react/SeamsWeb/publicApi/devices.js +0 -83
- package/dist/esm/react/SeamsWeb/publicApi/evm.js +0 -103
- package/dist/esm/react/SeamsWeb/publicApi/keyExport.js +0 -90
- package/dist/esm/react/SeamsWeb/publicApi/near.js +0 -449
- package/dist/esm/react/SeamsWeb/publicApi/preferences.js +0 -61
- package/dist/esm/react/SeamsWeb/publicApi/recovery.js +0 -19
- package/dist/esm/react/SeamsWeb/publicApi/tempo.js +0 -244
- package/dist/esm/react/SeamsWeb/publicApi/transactionReview.js +0 -12
- package/dist/esm/react/SeamsWeb/publicApi/types.js +0 -10
- package/dist/esm/react/SeamsWeb/signingSurface/BrowserSigningSurface.js +0 -3917
- package/dist/esm/react/SeamsWeb/walletIframe/client/overlay/overlay-controller.js +0 -530
- package/dist/esm/react/SeamsWeb/walletIframe/client/overlay/overlay-styles.js +0 -417
- package/dist/esm/react/SeamsWeb/walletIframe/client/progress/on-events-progress-bus.js +0 -134
- package/dist/esm/react/SeamsWeb/walletIframe/client/router.js +0 -3368
- package/dist/esm/react/SeamsWeb/walletIframe/client/surface/domain.js +0 -288
- package/dist/esm/react/SeamsWeb/walletIframe/client/surface/geometry.js +0 -128
- package/dist/esm/react/SeamsWeb/walletIframe/client/surface/renderer.js +0 -119
- package/dist/esm/react/SeamsWeb/walletIframe/client/surface/transactionSurfaceQueue.js +0 -125
- package/dist/esm/react/SeamsWeb/walletIframe/client/transactionReviewReservation.js +0 -96
- package/dist/esm/react/SeamsWeb/walletIframe/client/transport/IframeTransport.js +0 -252
- package/dist/esm/react/SeamsWeb/walletIframe/client/transport/iframe-transport-dom.js +0 -71
- package/dist/esm/react/SeamsWeb/walletIframe/client/transport/iframe-transport-handshake.js +0 -211
- package/dist/esm/react/SeamsWeb/walletIframe/client/transport/webauthn-bridge.js +0 -99
- package/dist/esm/react/SeamsWeb/walletIframe/coordinator.js +0 -235
- package/dist/esm/react/SeamsWeb/walletIframe/host/restoredSessionPresignaturePrefill.js +0 -29
- package/dist/esm/react/SeamsWeb/walletIframe/host/surface-measurement-reporter.js +0 -158
- package/dist/esm/react/SeamsWeb/walletIframe/shared/exactSessionState.js +0 -605
- package/dist/esm/react/SeamsWeb/walletIframe/shared/is-dev-host.js +0 -11
- package/dist/esm/react/SeamsWeb/walletIframe/shared/messages.js +0 -588
- package/dist/esm/react/SeamsWeb/walletIframe/shared/transactionReview.js +0 -83
- package/dist/esm/react/SeamsWeb/walletIframe/shared/unlockOptions.js +0 -54
- package/dist/esm/react/base-styles.js +0 -13
- package/dist/esm/react/build-paths.js +0 -109
- package/dist/esm/react/config.js +0 -37
- package/dist/esm/react/core/accountData/near/accountProjection.js +0 -119
- package/dist/esm/react/core/accountData/near/accountRefs.js +0 -21
- package/dist/esm/react/core/accountData/near/keyMaterial.js +0 -171
- package/dist/esm/react/core/accountData/near/profileId.js +0 -24
- package/dist/esm/react/core/browser/walletIframe/csp-stylesheet.js +0 -189
- package/dist/esm/react/core/browser/walletIframe/events.js +0 -10
- package/dist/esm/react/core/browser/walletIframe/host-mode.js +0 -19
- package/dist/esm/react/core/browser/walletIframe/hostVariant.js +0 -16
- package/dist/esm/react/core/config/chains.js +0 -90
- package/dist/esm/react/core/config/configBuilder.js +0 -231
- package/dist/esm/react/core/config/configHelpers.js +0 -183
- package/dist/esm/react/core/config/defaultConfigs.js +0 -120
- package/dist/esm/react/core/config/defineConfig.js +0 -48
- package/dist/esm/react/core/config/managedRuntimeScope.js +0 -16
- package/dist/esm/react/core/indexedDB/accountKeyMaterial.js +0 -68
- package/dist/esm/react/core/indexedDB/accountSignerLifecycle.js +0 -143
- package/dist/esm/react/core/indexedDB/index.js +0 -60
- package/dist/esm/react/core/indexedDB/keyMaterialEnvelope.js +0 -69
- package/dist/esm/react/core/indexedDB/lastProfileState.js +0 -22
- package/dist/esm/react/core/indexedDB/linkedAuthoritySignerMaterial.js +0 -291
- package/dist/esm/react/core/indexedDB/nonceLaneCoordinationStore.js +0 -115
- package/dist/esm/react/core/indexedDB/normalization.js +0 -24
- package/dist/esm/react/core/indexedDB/pendingWalletRecoveryCommit.js +0 -477
- package/dist/esm/react/core/indexedDB/pendingWalletRegistrationCommit.js +0 -745
- package/dist/esm/react/core/indexedDB/profileAccountProjection.js +0 -70
- package/dist/esm/react/core/indexedDB/schemaNames.js +0 -845
- package/dist/esm/react/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestLookups.js +0 -209
- package/dist/esm/react/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestRecords.js +0 -848
- package/dist/esm/react/core/indexedDB/seamsWalletDB/ecdsaCapabilityManifestStore.js +0 -1215
- package/dist/esm/react/core/indexedDB/seamsWalletDB/ecdsaClientPresignatures.js +0 -235
- package/dist/esm/react/core/indexedDB/seamsWalletDB/manager.js +0 -140
- package/dist/esm/react/core/indexedDB/seamsWalletDB/pendingWalletRecoveryCodeBackup.js +0 -145
- package/dist/esm/react/core/indexedDB/seamsWalletDB/repositories.js +0 -4747
- package/dist/esm/react/core/indexedDB/seamsWalletDB/schema.js +0 -23
- package/dist/esm/react/core/indexedDB/seamsWalletDB/signingSessionSeals.js +0 -205
- package/dist/esm/react/core/indexedDB/seamsWalletDB/walletCustodyEcdsaContinuity.js +0 -198
- package/dist/esm/react/core/indexedDB/seamsWalletDB/walletSessionAuthorizationStore.js +0 -569
- package/dist/esm/react/core/indexedDB/singletons.js +0 -7
- package/dist/esm/react/core/indexedDB/unifiedIndexedDBManager.js +0 -578
- package/dist/esm/react/core/indexedDB/walletCustodyEd25519MaterialRecord.js +0 -60
- package/dist/esm/react/core/platform/browser/createBrowserPlatformRuntime.js +0 -552
- package/dist/esm/react/core/platform/secretSources.js +0 -111
- package/dist/esm/react/core/platform/signerCoreCommandAdapters.js +0 -122
- package/dist/esm/react/core/rpcClients/evm/EvmClient.js +0 -549
- package/dist/esm/react/core/rpcClients/evm/nonceBackend.js +0 -279
- package/dist/esm/react/core/rpcClients/near/NearClient.js +0 -56
- package/dist/esm/react/core/rpcClients/near/NearRpcError.js +0 -105
- package/dist/esm/react/core/rpcClients/near/rpcCalls.js +0 -376
- package/dist/esm/react/core/rpcClients/relayer/ownerWalletExecutionLanePreflight.js +0 -67
- package/dist/esm/react/core/rpcClients/relayer/passkeyCustodyEnvelope.js +0 -228
- package/dist/esm/react/core/rpcClients/relayer/registrationSignerSetRequest.js +0 -8
- package/dist/esm/react/core/rpcClients/relayer/relayerHttp.js +0 -26
- package/dist/esm/react/core/rpcClients/relayer/routerAbNormalSigning.js +0 -812
- package/dist/esm/react/core/rpcClients/relayer/routerAbNormalSigningValidation.js +0 -23
- package/dist/esm/react/core/rpcClients/relayer/sealedRefreshCapabilities.js +0 -148
- package/dist/esm/react/core/rpcClients/relayer/thresholdEcdsa.js +0 -237
- package/dist/esm/react/core/rpcClients/relayer/walletRecoveryFinalize.js +0 -174
- package/dist/esm/react/core/rpcClients/relayer/walletRecoveryGoogleEmailOtp.js +0 -161
- package/dist/esm/react/core/rpcClients/relayer/walletRecoveryPrepare.js +0 -295
- package/dist/esm/react/core/rpcClients/relayer/walletRecoveryRotate.js +0 -311
- package/dist/esm/react/core/rpcClients/relayer/walletRegistration.js +0 -2349
- package/dist/esm/react/core/rpcClients/relayer/walletRegistrationTerminalResponse.js +0 -719
- package/dist/esm/react/core/rpcClients/relayer/walletSessionAuthorizationStatus.js +0 -214
- package/dist/esm/react/core/runtime/createSigningRuntime.js +0 -100
- package/dist/esm/react/core/signingEngine/assembly/createManagers.js +0 -80
- package/dist/esm/react/core/signingEngine/assembly/createPorts.js +0 -54
- package/dist/esm/react/core/signingEngine/assembly/ports/emailOtp.js +0 -30
- package/dist/esm/react/core/signingEngine/assembly/ports/evmFamily.js +0 -73
- package/dist/esm/react/core/signingEngine/assembly/ports/near.js +0 -21
- package/dist/esm/react/core/signingEngine/assembly/ports/recovery.js +0 -75
- package/dist/esm/react/core/signingEngine/assembly/ports/registration.js +0 -22
- package/dist/esm/react/core/signingEngine/assembly/ports/session.js +0 -25
- package/dist/esm/react/core/signingEngine/assembly/ports/shared.js +0 -40
- package/dist/esm/react/core/signingEngine/assembly/ports/stepUpRuntime.js +0 -67
- package/dist/esm/react/core/signingEngine/assembly/ports/warmSigning.js +0 -92
- package/dist/esm/react/core/signingEngine/assembly/warmup.js +0 -68
- package/dist/esm/react/core/signingEngine/chains/evm/bytes.js +0 -22
- package/dist/esm/react/core/signingEngine/chains/evm/display/calldata.js +0 -25
- package/dist/esm/react/core/signingEngine/chains/evm/display/evmTx.js +0 -119
- package/dist/esm/react/core/signingEngine/chains/evm/display/functionSelectors.js +0 -72
- package/dist/esm/react/core/signingEngine/chains/evm/display/gas.js +0 -19
- package/dist/esm/react/core/signingEngine/chains/evm/display/normalization.js +0 -23
- package/dist/esm/react/core/signingEngine/chains/evm/evmAdapter.js +0 -44
- package/dist/esm/react/core/signingEngine/chains/evm/evmCryptoWasm.js +0 -198
- package/dist/esm/react/core/signingEngine/chains/near/display.js +0 -248
- package/dist/esm/react/core/signingEngine/chains/near/nearSignerWasm.js +0 -170
- package/dist/esm/react/core/signingEngine/chains/near/payloads.js +0 -58
- package/dist/esm/react/core/signingEngine/chains/tempo/display.js +0 -130
- package/dist/esm/react/core/signingEngine/chains/tempo/feeToken.js +0 -187
- package/dist/esm/react/core/signingEngine/chains/tempo/tempoAdapter.js +0 -49
- package/dist/esm/react/core/signingEngine/chains/tempo/tempoSignerWasm.js +0 -90
- package/dist/esm/react/core/signingEngine/flows/recovery/ecdsaDerivationExport.js +0 -428
- package/dist/esm/react/core/signingEngine/flows/recovery/ecdsaExportFlow.js +0 -660
- package/dist/esm/react/core/signingEngine/flows/recovery/ecdsaExportMaterial.js +0 -250
- package/dist/esm/react/core/signingEngine/flows/recovery/ed25519YaoExportFlow.js +0 -353
- package/dist/esm/react/core/signingEngine/flows/recovery/exportKeypairOperation.js +0 -213
- package/dist/esm/react/core/signingEngine/flows/recovery/exportLaneSelection.js +0 -283
- package/dist/esm/react/core/signingEngine/flows/recovery/keyExportConfirmation.js +0 -325
- package/dist/esm/react/core/signingEngine/flows/recovery/keyExportFlow.js +0 -81
- package/dist/esm/react/core/signingEngine/flows/recovery/passkeyEd25519YaoRecovery.js +0 -192
- package/dist/esm/react/core/signingEngine/flows/recovery/public.js +0 -26
- package/dist/esm/react/core/signingEngine/flows/recovery/stepUpAuthorization.js +0 -139
- package/dist/esm/react/core/signingEngine/flows/registration/accountLifecycle.js +0 -1098
- package/dist/esm/react/core/signingEngine/flows/registration/nearProvisioningRegistry.js +0 -79
- package/dist/esm/react/core/signingEngine/flows/registration/public.js +0 -85
- package/dist/esm/react/core/signingEngine/flows/registration/services/ecdsaRegistrationSessions.js +0 -77
- package/dist/esm/react/core/signingEngine/flows/registration/services/ecdsaWalletRecords.js +0 -15
- package/dist/esm/react/core/signingEngine/flows/registration/services/passkeyEd25519YaoAddSigner.js +0 -83
- package/dist/esm/react/core/signingEngine/flows/registration/services/registrationAccounts.js +0 -30
- package/dist/esm/react/core/signingEngine/flows/registration/session.js +0 -24
- package/dist/esm/react/core/signingEngine/flows/shared/signingConfirmation.js +0 -194
- package/dist/esm/react/core/signingEngine/flows/shared/signingStateMachine.js +0 -485
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/accountAuth.js +0 -12
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/addresses.js +0 -10
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/authPlanning.js +0 -139
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/ecdsaLanes.js +0 -102
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/ecdsaSelection.js +0 -233
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/emailOtpPublic.js +0 -123
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/emailOtpSigningSession.js +0 -227
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/errors.js +0 -127
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/events.js +0 -39
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/evmNonceLifecycle.js +0 -49
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/executorThresholdState.js +0 -22
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/freshAuthRetryPolicy.js +0 -98
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/freshWalletSessionRetry.js +0 -76
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/nonceLifecycleAdapter.js +0 -245
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/nonceResolution.js +0 -91
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/operationIds.js +0 -33
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/preparedSigning.js +0 -376
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/readySecp256k1Material.js +0 -191
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/requireEvmFamilyStepUpAuth.js +0 -128
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signEvmFamily.js +0 -510
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signEvmFamilyWithUiConfirmForTempo.js +0 -65
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signEvmWithUiConfirm.js +0 -26
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signatureUses.js +0 -12
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signerLoader.js +0 -25
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signers/ecdsaDerivationClientSigningMaterialSource.js +0 -82
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signers/secp256k1.js +0 -182
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signers/webauthnP256.js +0 -84
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signingFlow.js +0 -633
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/signingFlowRuntime.js +0 -392
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/stepUpAuthorization.js +0 -56
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/tempoNonceLifecycle.js +0 -47
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/thresholdAdmission.js +0 -87
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/transactionExecutor.js +0 -140
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/types.js +0 -20
- package/dist/esm/react/core/signingEngine/flows/signEvmFamily/webauthnP256KeyRef.js +0 -33
- package/dist/esm/react/core/signingEngine/flows/signNear/implicitAccountFunding.js +0 -202
- package/dist/esm/react/core/signingEngine/flows/signNear/nearSigningFlow.js +0 -56
- package/dist/esm/react/core/signingEngine/flows/signNear/requireNearStepUpAuth.js +0 -102
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/confirmationProgress.js +0 -28
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/ed25519YaoCapabilityResolution.js +0 -101
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/ed25519YaoNormalSigning.js +0 -822
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/implicitAccountFundingPort.js +0 -24
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/operationStepUpPreparation.js +0 -68
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/signatureOnlySigning.js +0 -343
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/signingMaterials.js +0 -25
- package/dist/esm/react/core/signingEngine/flows/signNear/shared/signingSessionAuthMode.js +0 -138
- package/dist/esm/react/core/signingEngine/flows/signNear/signDelegate.js +0 -290
- package/dist/esm/react/core/signingEngine/flows/signNear/signNear.js +0 -1238
- package/dist/esm/react/core/signingEngine/flows/signNear/signNep413.js +0 -144
- package/dist/esm/react/core/signingEngine/flows/signNear/signTransactions.js +0 -897
- package/dist/esm/react/core/signingEngine/flows/signNear/signatureUses.js +0 -12
- package/dist/esm/react/core/signingEngine/flows/signNear/stepUpAuthorization.js +0 -42
- package/dist/esm/react/core/signingEngine/interfaces/accountAuthMetadata.js +0 -14
- package/dist/esm/react/core/signingEngine/interfaces/ecdsaChainTarget.js +0 -142
- package/dist/esm/react/core/signingEngine/interfaces/operationStepUpPreparation.js +0 -18
- package/dist/esm/react/core/signingEngine/nonce/NonceCoordinator.js +0 -1026
- package/dist/esm/react/core/signingEngine/nonce/evmNonceLane.js +0 -182
- package/dist/esm/react/core/signingEngine/nonce/nearNonceLane.js +0 -669
- package/dist/esm/react/core/signingEngine/nonce/nearNonceLaneIdentity.js +0 -24
- package/dist/esm/react/core/signingEngine/nonce/nonceCoordinationRecordBoundary.js +0 -216
- package/dist/esm/react/core/signingEngine/nonce/nonceDiagnostics.js +0 -232
- package/dist/esm/react/core/signingEngine/nonce/nonceLaneKeys.js +0 -110
- package/dist/esm/react/core/signingEngine/nonce/nonceLeaseState.js +0 -128
- package/dist/esm/react/core/signingEngine/nonce/nonceTypes.js +0 -59
- package/dist/esm/react/core/signingEngine/nonce/nonceUtils.js +0 -33
- package/dist/esm/react/core/signingEngine/routerAb/ecdsaDerivation/httpRequest.js +0 -74
- package/dist/esm/react/core/signingEngine/routerAb/ecdsaDerivation/poolFillRoutes.js +0 -217
- package/dist/esm/react/core/signingEngine/routerAb/ecdsaDerivation/presignaturePool.js +0 -1218
- package/dist/esm/react/core/signingEngine/routerAb/ecdsaDerivation/presignatureRefillProgress.js +0 -53
- package/dist/esm/react/core/signingEngine/routerAb/ecdsaDerivation/signingMaterialRef.js +0 -22
- package/dist/esm/react/core/signingEngine/session/SigningSessionCoordinator.js +0 -347
- package/dist/esm/react/core/signingEngine/session/authority/authorityOperationResolver.js +0 -165
- package/dist/esm/react/core/signingEngine/session/availability/availableSigningLanes.js +0 -1064
- package/dist/esm/react/core/signingEngine/session/availability/canonicalLaneInventory.js +0 -127
- package/dist/esm/react/core/signingEngine/session/availability/clientSessionExpiryInvalidator.js +0 -72
- package/dist/esm/react/core/signingEngine/session/availability/persistedAvailableSigningLanes.js +0 -214
- package/dist/esm/react/core/signingEngine/session/availability/readiness.js +0 -464
- package/dist/esm/react/core/signingEngine/session/emailOtp/EmailOtpWalletSessionCoordinator.js +0 -131
- package/dist/esm/react/core/signingEngine/session/emailOtp/challengeDelivery.js +0 -56
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaBootstrapCommit.js +0 -106
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaLifecycleRuntime.js +0 -50
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaLogin.js +0 -936
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaPublication.js +0 -414
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaRecovery.js +0 -268
- package/dist/esm/react/core/signingEngine/session/emailOtp/ecdsaSigningSessionAuthority.js +0 -95
- package/dist/esm/react/core/signingEngine/session/emailOtp/ed25519ExportContext.js +0 -376
- package/dist/esm/react/core/signingEngine/session/emailOtp/exportRecovery.js +0 -286
- package/dist/esm/react/core/signingEngine/session/emailOtp/exportRecoveryRuntime.js +0 -50
- package/dist/esm/react/core/signingEngine/session/emailOtp/persistedSnapshot.js +0 -22
- package/dist/esm/react/core/signingEngine/session/emailOtp/publicTypes.js +0 -38
- package/dist/esm/react/core/signingEngine/session/emailOtp/routePlan.js +0 -60
- package/dist/esm/react/core/signingEngine/session/emailOtp/runtimeConfig.js +0 -24
- package/dist/esm/react/core/signingEngine/session/emailOtp/sealedRefreshPolicy.js +0 -49
- package/dist/esm/react/core/signingEngine/session/emailOtp/sealedRestoreOrchestrator.js +0 -234
- package/dist/esm/react/core/signingEngine/session/emailOtp/sealedRuntimePurpose.js +0 -16
- package/dist/esm/react/core/signingEngine/session/emailOtp/sealedSessionRegistry.js +0 -40
- package/dist/esm/react/core/signingEngine/session/emailOtp/status.js +0 -72
- package/dist/esm/react/core/signingEngine/session/emailOtp/walletUnlock.js +0 -168
- package/dist/esm/react/core/signingEngine/session/emailOtp/warmSessionRuntime.js +0 -70
- package/dist/esm/react/core/signingEngine/session/emailOtp/workerEnrollment.js +0 -159
- package/dist/esm/react/core/signingEngine/session/emailOtp/workerRequests.js +0 -84
- package/dist/esm/react/core/signingEngine/session/emailOtp/zeroize.js +0 -9
- package/dist/esm/react/core/signingEngine/session/identity/clientSessionPersistenceState.js +0 -95
- package/dist/esm/react/core/signingEngine/session/identity/emailOtpEcdsaDerivationIdentity.js +0 -23
- package/dist/esm/react/core/signingEngine/session/identity/evmFamilyEcdsaIdentity.js +0 -265
- package/dist/esm/react/core/signingEngine/session/identity/exactSigningLaneIdentity.js +0 -338
- package/dist/esm/react/core/signingEngine/session/identity/exactWalletSessionCredential.js +0 -106
- package/dist/esm/react/core/signingEngine/session/identity/exactWalletSessionReader.js +0 -54
- package/dist/esm/react/core/signingEngine/session/identity/laneIdentity.js +0 -168
- package/dist/esm/react/core/signingEngine/session/identity/ownerLaneScope.js +0 -185
- package/dist/esm/react/core/signingEngine/session/identity/selectLane.js +0 -335
- package/dist/esm/react/core/signingEngine/session/identity/signingLaneAuthBinding.js +0 -29
- package/dist/esm/react/core/signingEngine/session/keyMaterialBrands.js +0 -75
- package/dist/esm/react/core/signingEngine/session/lanes/walletExecutionLaneHydration.js +0 -194
- package/dist/esm/react/core/signingEngine/session/lifecycle/canonicalWalletSessionStatus.js +0 -32
- package/dist/esm/react/core/signingEngine/session/lifecycle/walletSessionFailure.js +0 -69
- package/dist/esm/react/core/signingEngine/session/lifecycle/walletSessionStatus.js +0 -123
- package/dist/esm/react/core/signingEngine/session/material/activeEcdsaCapabilityRuntime.js +0 -171
- package/dist/esm/react/core/signingEngine/session/material/activeWalletAuthorityEcdsaRuntime.js +0 -318
- package/dist/esm/react/core/signingEngine/session/material/ecdsaCapabilityHydration.js +0 -75
- package/dist/esm/react/core/signingEngine/session/material/ecdsaCapabilityManifest.js +0 -498
- package/dist/esm/react/core/signingEngine/session/material/ecdsaRoleLocalMaterialResolver.js +0 -122
- package/dist/esm/react/core/signingEngine/session/material/ecdsaSealedRuntime.js +0 -197
- package/dist/esm/react/core/signingEngine/session/material/ecdsaSigningCapability.js +0 -231
- package/dist/esm/react/core/signingEngine/session/material/linkedEcdsaHolderRuntime.js +0 -36
- package/dist/esm/react/core/signingEngine/session/material/mpcCapabilityHydration.js +0 -79
- package/dist/esm/react/core/signingEngine/session/material/nearEd25519YaoMaterialActivation.js +0 -80
- package/dist/esm/react/core/signingEngine/session/material/nearEd25519YaoSigningPreparation.js +0 -122
- package/dist/esm/react/core/signingEngine/session/material/restorableMpcMaterialRef.internal.js +0 -21
- package/dist/esm/react/core/signingEngine/session/material/walletSigningStateFailure.js +0 -84
- package/dist/esm/react/core/signingEngine/session/operationState/authorizationAdmission.js +0 -98
- package/dist/esm/react/core/signingEngine/session/operationState/lanes.js +0 -127
- package/dist/esm/react/core/signingEngine/session/operationState/preparedOperation.js +0 -38
- package/dist/esm/react/core/signingEngine/session/operationState/trace.js +0 -94
- package/dist/esm/react/core/signingEngine/session/operationState/transactionState.js +0 -106
- package/dist/esm/react/core/signingEngine/session/operationState/types.js +0 -88
- package/dist/esm/react/core/signingEngine/session/passkey/ecdsaBootstrap.js +0 -187
- package/dist/esm/react/core/signingEngine/session/passkey/ecdsaKeyFactsInventory.js +0 -206
- package/dist/esm/react/core/signingEngine/session/passkey/ecdsaRecovery.js +0 -87
- package/dist/esm/react/core/signingEngine/session/passkey/ecdsaSessionProvision.js +0 -224
- package/dist/esm/react/core/signingEngine/session/passkey/ecdsaWarmCapabilityBootstrap.js +0 -147
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519Provisioner.js +0 -55
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519SessionProvision.js +0 -229
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519YaoLocalMaterial.js +0 -537
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519YaoRecoveryCapability.js +0 -94
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519YaoSealedSession.js +0 -57
- package/dist/esm/react/core/signingEngine/session/passkey/ed25519YaoWarmRecovery.js +0 -314
- package/dist/esm/react/core/signingEngine/session/passkey/passkeyCustodySessionCache.js +0 -90
- package/dist/esm/react/core/signingEngine/session/passkey/prfCache.js +0 -60
- package/dist/esm/react/core/signingEngine/session/passkey/public.js +0 -15
- package/dist/esm/react/core/signingEngine/session/passkey/unlockEcdsaWarmupPlanner.js +0 -247
- package/dist/esm/react/core/signingEngine/session/passkey/warmSessionHydration.js +0 -9
- package/dist/esm/react/core/signingEngine/session/persistence/clientSessionPersistence.js +0 -143
- package/dist/esm/react/core/signingEngine/session/persistence/durableSealedSessionCommands.js +0 -30
- package/dist/esm/react/core/signingEngine/session/persistence/ecdsaRoleLocalRecords.js +0 -316
- package/dist/esm/react/core/signingEngine/session/persistence/ecdsaSealedRecordKey.js +0 -20
- package/dist/esm/react/core/signingEngine/session/persistence/sealedSessionRecords.js +0 -761
- package/dist/esm/react/core/signingEngine/session/persistence/sealedSessionStore.js +0 -518
- package/dist/esm/react/core/signingEngine/session/persistence/walletSessionAuthorizationProjection.js +0 -51
- package/dist/esm/react/core/signingEngine/session/planning/operationFingerprint.js +0 -30
- package/dist/esm/react/core/signingEngine/session/planning/operationIdBinding.js +0 -36
- package/dist/esm/react/core/signingEngine/session/planning/planner.js +0 -98
- package/dist/esm/react/core/signingEngine/session/postconditions/runtimePostconditions.js +0 -165
- package/dist/esm/react/core/signingEngine/session/public.js +0 -44
- package/dist/esm/react/core/signingEngine/session/routerAbSigningWalletSession.js +0 -125
- package/dist/esm/react/core/signingEngine/session/sealedRecovery/exactRecordLookup.js +0 -148
- package/dist/esm/react/core/signingEngine/session/sealedRecovery/materialActivationKey.js +0 -22
- package/dist/esm/react/core/signingEngine/session/sealedRecovery/recoveryRecord.js +0 -248
- package/dist/esm/react/core/signingEngine/session/sealedRecovery/restoreCoordinator.js +0 -229
- package/dist/esm/react/core/signingEngine/session/userPreferences.js +0 -212
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/capabilityReader.js +0 -62
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/capabilityReaderCore.js +0 -293
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/clearVolatileWarmSigningMaterial.js +0 -44
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ecdsaBootstrapPersistence.js +0 -107
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ecdsaBootstrapQueue.js +0 -22
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ecdsaLoginPrefill.js +0 -93
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ecdsaLoginPrefillSigningMaterialSource.js +0 -50
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ecdsaProvisionPlan.js +0 -9
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/ed25519SealedSessionRuntime.js +0 -251
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/nearEd25519CapabilityRehydration.js +0 -98
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/public.js +0 -31
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/readModel.js +0 -161
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/routerAbEd25519WalletSessionState.js +0 -256
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/routerAbWalletSessionCredential.js +0 -73
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/sealedRefreshParity.js +0 -67
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/statusReader.js +0 -100
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/transitions.js +0 -51
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/types.js +0 -122
- package/dist/esm/react/core/signingEngine/session/warmCapabilities/volatileWarmMaterialCommands.js +0 -45
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/channel/confirmCommon.js +0 -89
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/channel/confirmTypes.js +0 -12
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/confirmOperation.js +0 -51
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/intentDigestPreparation.js +0 -29
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/methodSelection.js +0 -41
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/otpPrompt/authLane.js +0 -32
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/otpPrompt/exportAuthorization.js +0 -108
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/otpPrompt/promptText.js +0 -8
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/otpPrompt/signingPrompt.js +0 -15
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/passkeyPrompt/touchIdPrompt.js +0 -295
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/passkeyPrompt/webauthnPromptCoordinator.js +0 -170
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/requireStepUpAuth.js +0 -63
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/types.js +0 -29
- package/dist/esm/react/core/signingEngine/stepUpConfirmation/userConfirmationType.js +0 -15
- package/dist/esm/react/core/signingEngine/threshold/commitQueueShared.js +0 -139
- package/dist/esm/react/core/signingEngine/threshold/crypto/ecdsaDerivationClientWasm.js +0 -619
- package/dist/esm/react/core/signingEngine/threshold/crypto/ed25519YaoLaneWasm.js +0 -70
- package/dist/esm/react/core/signingEngine/threshold/ecdsa/activation.js +0 -267
- package/dist/esm/react/core/signingEngine/threshold/ecdsa/bootstrapSession.js +0 -119
- package/dist/esm/react/core/signingEngine/threshold/ecdsa/operationStepUp.js +0 -110
- package/dist/esm/react/core/signingEngine/threshold/ecdsa/postRegistrationSessionActivation.js +0 -132
- package/dist/esm/react/core/signingEngine/threshold/ecdsa/signingQueue.js +0 -16
- package/dist/esm/react/core/signingEngine/threshold/ed25519/commitQueue.js +0 -16
- package/dist/esm/react/core/signingEngine/threshold/ed25519/connectSession.js +0 -137
- package/dist/esm/react/core/signingEngine/threshold/ed25519/walletSession.js +0 -363
- package/dist/esm/react/core/signingEngine/threshold/ed25519/yaoActiveClientRegistry.js +0 -146
- package/dist/esm/react/core/signingEngine/threshold/ed25519/yaoClient.js +0 -597
- package/dist/esm/react/core/signingEngine/threshold/ed25519/yaoPageLifecycleOwner.js +0 -23
- package/dist/esm/react/core/signingEngine/threshold/ed25519/yaoPublicCapabilityReferences.js +0 -295
- package/dist/esm/react/core/signingEngine/threshold/sessionPolicy.js +0 -94
- package/dist/esm/react/core/signingEngine/uiConfirm/PasskeyMpcExportManager.js +0 -233
- package/dist/esm/react/core/signingEngine/uiConfirm/PasskeyMpcSessionDurableState.js +0 -496
- package/dist/esm/react/core/signingEngine/uiConfirm/PasskeyMpcSessionManager.js +0 -746
- package/dist/esm/react/core/signingEngine/uiConfirm/UiConfirmManager.js +0 -600
- package/dist/esm/react/core/signingEngine/uiConfirm/confirmationReadinessRegistry.js +0 -41
- package/dist/esm/react/core/signingEngine/uiConfirm/exportConfirmRequest.js +0 -149
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/determineConfirmationConfig.js +0 -82
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flowOrchestrator.js +0 -363
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/adapters/adapters.js +0 -337
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/adapters/request.js +0 -120
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/localOnly.js +0 -150
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/registration.js +0 -235
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/requestRegistrationCredentialConfirmation.js +0 -178
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/flows/signing.js +0 -684
- package/dist/esm/react/core/signingEngine/uiConfirm/handlers/handlePromptFromWorker.js +0 -90
- package/dist/esm/react/core/signingEngine/uiConfirm/nearFundingNotice.js +0 -50
- package/dist/esm/react/core/signingEngine/uiConfirm/transactionReviewAdmission.js +0 -8
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/appearance-token-vars.js +0 -31
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/appearance.js +0 -27
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/confirm-surface-resize.js +0 -346
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/confirm-ui.js +0 -516
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/confirmation-body-model.js +0 -24
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/confirmation-model.js +0 -161
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/drawer-gesture.js +0 -16
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/export-private-key-reveal.js +0 -155
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/export-viewer-host.js +0 -207
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmContent.js +0 -131
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmHeader.js +0 -29
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmationBody.js +0 -49
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmationContent.js +0 -137
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmationDrawer.js +0 -294
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ConfirmationModal.js +0 -67
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/CopyStatusIcon.js +0 -41
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/EmailOtpContent.js +0 -141
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/EmailOtpInput.js +0 -92
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ExportPrivateKeySurface.js +0 -318
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/HaloBorder.js +0 -91
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/PadlockIcon.js +0 -32
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/PasskeyHaloLoading.js +0 -63
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/PasskeyRegistrationContent.js +0 -75
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/PasskeyRegistrationDetails.js +0 -33
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/RecoveryCodeBackupSurface.js +0 -518
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/ReviewDisclosure.js +0 -128
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/SeamsWordmark.js +0 -22
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/TransactionLabel.js +0 -158
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/TransactionReceipt.js +0 -289
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/TransactionReview.js +0 -311
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/TransactionTree.js +0 -284
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/clipboard.js +0 -26
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/confirmation-controller.js +0 -80
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/confirmation-styles.js +0 -20
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/email-otp-session.js +0 -178
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/mountConfirmationSurface.js +0 -297
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/mountExportPrivateKeySurface.js +0 -86
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/preact/mountRecoveryCodeBackupSurface.js +0 -82
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/seamsWordmarkPaths.js +0 -6
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/surface-measurement-binding.js +0 -12
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/surface-resize-events.js +0 -18
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-activity.js +0 -46
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/abi/abiDecode.js +0 -325
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/abi/enrichDisplayModelWithAbi.js +0 -77
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/confirmation-tree.js +0 -27
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/formatters.js +0 -57
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/renderers/fallback.js +0 -52
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/renderers/types.js +0 -62
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-display/tree.js +0 -249
- package/dist/esm/react/core/signingEngine/uiConfirm/ui/transaction-receipt.js +0 -50
- package/dist/esm/react/core/signingEngine/uiConfirm/warmSessionUiConfirm.js +0 -65
- package/dist/esm/react/core/signingEngine/walletCustody/activateEd25519Capability.js +0 -123
- package/dist/esm/react/core/signingEngine/walletCustody/ceremonyActiveClientMetadata.js +0 -94
- package/dist/esm/react/core/signingEngine/walletCustody/ceremonyDriver.js +0 -171
- package/dist/esm/react/core/signingEngine/walletCustody/ceremonyStepRunner.js +0 -20
- package/dist/esm/react/core/signingEngine/walletCustody/ed25519ActiveClient.js +0 -100
- package/dist/esm/react/core/signingEngine/walletCustody/ed25519Projection.js +0 -32
- package/dist/esm/react/core/signingEngine/walletCustody/ed25519SeedMaterial.js +0 -92
- package/dist/esm/react/core/signingEngine/walletCustody/emailOtpLink.js +0 -135
- package/dist/esm/react/core/signingEngine/walletCustody/joinCustodyWire.js +0 -64
- package/dist/esm/react/core/signingEngine/walletCustody/openCustodyCache.js +0 -130
- package/dist/esm/react/core/signingEngine/walletCustody/passkeyLink.js +0 -183
- package/dist/esm/react/core/signingEngine/walletCustody/recoveryReplacementEnvelope.js +0 -60
- package/dist/esm/react/core/signingEngine/walletCustody/registrationCeremony.js +0 -461
- package/dist/esm/react/core/signingEngine/walletCustody/unlockedEd25519ExportRootCapability.js +0 -258
- package/dist/esm/react/core/signingEngine/walletCustody/walletRecoveryCredential.js +0 -24
- package/dist/esm/react/core/signingEngine/walletCustody/walletRecoveryEcdsa.js +0 -76
- package/dist/esm/react/core/signingEngine/walletCustody/walletRecoveryEd25519.js +0 -129
- package/dist/esm/react/core/signingEngine/walletCustody/walletRecoveryManifest.js +0 -180
- package/dist/esm/react/core/signingEngine/walletCustody/walletRecoveryRotation.js +0 -103
- package/dist/esm/react/core/signingEngine/webauthnAuth/credentials/collectAuthenticationCredentialForChallengeB64u.js +0 -154
- package/dist/esm/react/core/signingEngine/webauthnAuth/credentials/credentialExtensions.js +0 -36
- package/dist/esm/react/core/signingEngine/webauthnAuth/credentials/helpers.js +0 -273
- package/dist/esm/react/core/signingEngine/webauthnAuth/device/signerSlot.js +0 -25
- package/dist/esm/react/core/signingEngine/webauthnAuth/fallbacks/safari-fallbacks.js +0 -171
- package/dist/esm/react/core/signingEngine/workerManager/SignerWorkerManager.js +0 -70
- package/dist/esm/react/core/signingEngine/workerManager/deviceLinkingPorts.js +0 -342
- package/dist/esm/react/core/signingEngine/workerManager/deviceLinkingSourceContribution.js +0 -158
- package/dist/esm/react/core/signingEngine/workerManager/ecdsaClientWorkerChannels.js +0 -17
- package/dist/esm/react/core/signingEngine/workerManager/ecdsaPresignLifecycle.js +0 -6
- package/dist/esm/react/core/signingEngine/workerManager/ecdsaPresignPoolIdentity.js +0 -49
- package/dist/esm/react/core/signingEngine/workerManager/executeWorkerOperation.js +0 -12
- package/dist/esm/react/core/signingEngine/workerManager/nearKeyOps/createNearKeyOps.js +0 -32
- package/dist/esm/react/core/signingEngine/workerManager/validation.js +0 -114
- package/dist/esm/react/core/signingEngine/workerManager/workerTransport.js +0 -773
- package/dist/esm/react/core/signingEngine/workerManager/workerTypes.js +0 -109
- package/dist/esm/react/core/types/accountIds.js +0 -26
- package/dist/esm/react/core/types/actionBuilders.js +0 -73
- package/dist/esm/react/core/types/confirmationConfig.js +0 -39
- package/dist/esm/react/core/types/eventLogging.js +0 -28
- package/dist/esm/react/core/types/linkDevice.js +0 -49
- package/dist/esm/react/core/types/sdkSentEvents.js +0 -602
- package/dist/esm/react/core/types/secure-confirm-worker.js +0 -22
- package/dist/esm/react/core/types/signer-worker.js +0 -50
- package/dist/esm/react/core/types/walletIframeIdentity.js +0 -15
- package/dist/esm/react/core/walletRuntimePaths/base.js +0 -60
- package/dist/esm/react/core/walletRuntimePaths/emailOtpWorker.js +0 -12
- package/dist/esm/react/core/walletRuntimePaths/multichainWorkers.js +0 -25
- package/dist/esm/react/core/walletRuntimePaths/walletCustodyCeremonyWorker.js +0 -18
- package/dist/esm/react/core/walletRuntimePaths/workers.js +0 -93
- package/dist/esm/react/externalEvm/boundary.js +0 -309
- package/dist/esm/react/externalEvm/controller.js +0 -440
- package/dist/esm/react/externalEvm/types.js +0 -31
- package/dist/esm/react/node_modules/@noble/hashes/esm/_u64.js +0 -36
- package/dist/esm/react/node_modules/@noble/hashes/esm/sha3.js +0 -197
- package/dist/esm/react/node_modules/@noble/hashes/esm/utils.js +0 -87
- package/dist/esm/react/node_modules/viem/_esm/errors/abi.js +0 -48
- package/dist/esm/react/node_modules/viem/_esm/errors/address.js +0 -14
- package/dist/esm/react/node_modules/viem/_esm/errors/base.js +0 -86
- package/dist/esm/react/node_modules/viem/_esm/errors/data.js +0 -16
- package/dist/esm/react/node_modules/viem/_esm/errors/encoding.js +0 -16
- package/dist/esm/react/node_modules/viem/_esm/errors/typedData.js +0 -28
- package/dist/esm/react/node_modules/viem/_esm/errors/version.js +0 -6
- package/dist/esm/react/node_modules/viem/_esm/utils/abi/encodeAbiParameters.js +0 -243
- package/dist/esm/react/node_modules/viem/_esm/utils/address/getAddress.js +0 -28
- package/dist/esm/react/node_modules/viem/_esm/utils/address/isAddress.js +0 -23
- package/dist/esm/react/node_modules/viem/_esm/utils/data/concat.js +0 -23
- package/dist/esm/react/node_modules/viem/_esm/utils/data/isHex.js +0 -10
- package/dist/esm/react/node_modules/viem/_esm/utils/data/pad.js +0 -40
- package/dist/esm/react/node_modules/viem/_esm/utils/data/size.js +0 -16
- package/dist/esm/react/node_modules/viem/_esm/utils/data/slice.js +0 -59
- package/dist/esm/react/node_modules/viem/_esm/utils/encoding/fromHex.js +0 -13
- package/dist/esm/react/node_modules/viem/_esm/utils/encoding/toBytes.js +0 -175
- package/dist/esm/react/node_modules/viem/_esm/utils/encoding/toHex.js +0 -168
- package/dist/esm/react/node_modules/viem/_esm/utils/hash/keccak256.js +0 -15
- package/dist/esm/react/node_modules/viem/_esm/utils/lru.js +0 -38
- package/dist/esm/react/node_modules/viem/_esm/utils/regex.js +0 -7
- package/dist/esm/react/node_modules/viem/_esm/utils/signature/hashTypedData.js +0 -113
- package/dist/esm/react/node_modules/viem/_esm/utils/stringify.js +0 -9
- package/dist/esm/react/node_modules/viem/_esm/utils/typedData.js +0 -80
- package/dist/esm/react/shared-ts/src/authorization/capabilityKinds.js +0 -111
- package/dist/esm/react/shared-ts/src/authorization/delegatedAuthority.js +0 -121
- package/dist/esm/react/shared-ts/src/authorization/index.js +0 -6
- package/dist/esm/react/shared-ts/src/authorization/operationFingerprint.js +0 -57
- package/dist/esm/react/shared-ts/src/authorization/walletAuthority.js +0 -719
- package/dist/esm/react/shared-ts/src/authorization/walletCustodyOperation.js +0 -16
- package/dist/esm/react/shared-ts/src/authorization/walletSessionIssuance.js +0 -115
- package/dist/esm/react/shared-ts/src/authorization/walletSignerActivationEquality.js +0 -12
- package/dist/esm/react/shared-ts/src/device-linking/activeWalletSession.js +0 -104
- package/dist/esm/react/shared-ts/src/device-linking/authorityActivation.js +0 -142
- package/dist/esm/react/shared-ts/src/device-linking/committedSignerPackages.js +0 -270
- package/dist/esm/react/shared-ts/src/device-linking/contracts.js +0 -8
- package/dist/esm/react/shared-ts/src/device-linking/delegatedActivationPlan.js +0 -130
- package/dist/esm/react/shared-ts/src/device-linking/deviceManagement.js +0 -120
- package/dist/esm/react/shared-ts/src/device-linking/digests.js +0 -115
- package/dist/esm/react/shared-ts/src/device-linking/ed25519ExportRoot.js +0 -167
- package/dist/esm/react/shared-ts/src/device-linking/index.js +0 -12
- package/dist/esm/react/shared-ts/src/device-linking/parsers.js +0 -1029
- package/dist/esm/react/shared-ts/src/device-linking/requestProof.js +0 -25
- package/dist/esm/react/shared-ts/src/device-linking/sourceContribution.js +0 -542
- package/dist/esm/react/shared-ts/src/device-linking/walletSessionCredentialDelivery.js +0 -173
- package/dist/esm/react/shared-ts/src/device-linking/wireFields.js +0 -59
- package/dist/esm/react/shared-ts/src/near/actions.js +0 -236
- package/dist/esm/react/shared-ts/src/near/nearClient.js +0 -252
- package/dist/esm/react/shared-ts/src/passkey-custody/ceremonyCommitPayload.js +0 -43
- package/dist/esm/react/shared-ts/src/passkey-custody/custodyEnvelope.js +0 -278
- package/dist/esm/react/shared-ts/src/passkey-custody/custodySecretBinding.js +0 -181
- package/dist/esm/react/shared-ts/src/passkey-custody/index.js +0 -4
- package/dist/esm/react/shared-ts/src/passkey-custody/primitives.js +0 -62
- package/dist/esm/react/shared-ts/src/signing-lanes/evmFamilySigningKeySlotId.js +0 -49
- package/dist/esm/react/shared-ts/src/signing-lanes/index.js +0 -8
- package/dist/esm/react/shared-ts/src/signing-lanes/ownerContinuity.js +0 -62
- package/dist/esm/react/shared-ts/src/signing-lanes/participantDigest.js +0 -2
- package/dist/esm/react/shared-ts/src/signing-lanes/participants.js +0 -256
- package/dist/esm/react/shared-ts/src/signing-lanes/recordParsers.js +0 -479
- package/dist/esm/react/shared-ts/src/signing-lanes/rotationDigests.js +0 -6
- package/dist/esm/react/shared-ts/src/signing-lanes/rotationParsers.js +0 -3
- package/dist/esm/react/shared-ts/src/signing-lanes/rotationProtocolParsers.js +0 -8
- package/dist/esm/react/shared-ts/src/signing-lanes/rotationWireFields.js +0 -3
- package/dist/esm/react/shared-ts/src/threshold/ecdsaDerivationRoleLocalBootstrap.js +0 -39
- package/dist/esm/react/shared-ts/src/threshold/ed25519OperationFingerprint.js +0 -222
- package/dist/esm/react/shared-ts/src/threshold/keyMaterialBrands.js +0 -25
- package/dist/esm/react/shared-ts/src/threshold/participants.js +0 -67
- package/dist/esm/react/shared-ts/src/threshold/secp256k1.js +0 -6
- package/dist/esm/react/shared-ts/src/threshold/sessionPolicy.js +0 -8
- package/dist/esm/react/shared-ts/src/threshold/signingRootScope.js +0 -43
- package/dist/esm/react/shared-ts/src/utils/addAuthMethodRegistration.js +0 -103
- package/dist/esm/react/shared-ts/src/utils/addWalletAuthMethod.js +0 -1
- package/dist/esm/react/shared-ts/src/utils/authenticatorOptions.js +0 -22
- package/dist/esm/react/shared-ts/src/utils/base58.js +0 -28
- package/dist/esm/react/shared-ts/src/utils/base64.js +0 -70
- package/dist/esm/react/shared-ts/src/utils/canonicalPrimitives.js +0 -38
- package/dist/esm/react/shared-ts/src/utils/digestEncoding.js +0 -63
- package/dist/esm/react/shared-ts/src/utils/digests.js +0 -33
- package/dist/esm/react/shared-ts/src/utils/domainIds.js +0 -257
- package/dist/esm/react/shared-ts/src/utils/ecdsaCapabilityActivation.js +0 -67
- package/dist/esm/react/shared-ts/src/utils/ecdsaKeyFactsInventory.js +0 -44
- package/dist/esm/react/shared-ts/src/utils/ecdsaServerTiming.js +0 -38
- package/dist/esm/react/shared-ts/src/utils/emailOtpDomain.js +0 -28
- package/dist/esm/react/shared-ts/src/utils/emailOtpRecoveryKey.js +0 -65
- package/dist/esm/react/shared-ts/src/utils/encoders.js +0 -2
- package/dist/esm/react/shared-ts/src/utils/errors.js +0 -95
- package/dist/esm/react/shared-ts/src/utils/evmRpcResults.js +0 -101
- package/dist/esm/react/shared-ts/src/utils/exactKeys.js +0 -17
- package/dist/esm/react/shared-ts/src/utils/exactRecord.js +0 -44
- package/dist/esm/react/shared-ts/src/utils/index.js +0 -38
- package/dist/esm/react/shared-ts/src/utils/jsonRpc.js +0 -64
- package/dist/esm/react/shared-ts/src/utils/keccak.js +0 -150
- package/dist/esm/react/shared-ts/src/utils/near.js +0 -205
- package/dist/esm/react/shared-ts/src/utils/nearRpcResults.js +0 -205
- package/dist/esm/react/shared-ts/src/utils/normalize.js +0 -86
- package/dist/esm/react/shared-ts/src/utils/registrationAuthMethodInput.js +0 -84
- package/dist/esm/react/shared-ts/src/utils/registrationEstablishedSession.js +0 -275
- package/dist/esm/react/shared-ts/src/utils/registrationIds.js +0 -226
- package/dist/esm/react/shared-ts/src/utils/registrationIntent.js +0 -390
- package/dist/esm/react/shared-ts/src/utils/registrationSignerPlan.js +0 -439
- package/dist/esm/react/shared-ts/src/utils/routerAbEcdsaDerivation.js +0 -1334
- package/dist/esm/react/shared-ts/src/utils/routerAbEd25519Yao.js +0 -747
- package/dist/esm/react/shared-ts/src/utils/routerAbEd25519YaoDigests.js +0 -76
- package/dist/esm/react/shared-ts/src/utils/routerAbNormalSigningIdentity.js +0 -115
- package/dist/esm/react/shared-ts/src/utils/routerAbPublicKeyset.js +0 -11
- package/dist/esm/react/shared-ts/src/utils/routerAbTraceContext.js +0 -36
- package/dist/esm/react/shared-ts/src/utils/secureRandomId.js +0 -35
- package/dist/esm/react/shared-ts/src/utils/signerDomain.js +0 -37
- package/dist/esm/react/shared-ts/src/utils/signerSlot.js +0 -12
- package/dist/esm/react/shared-ts/src/utils/signingSessionSeal.js +0 -98
- package/dist/esm/react/shared-ts/src/utils/theme.js +0 -8
- package/dist/esm/react/shared-ts/src/utils/thresholdEcdsaChainTarget.js +0 -9
- package/dist/esm/react/shared-ts/src/utils/thresholdEcdsaKeyHandle.js +0 -28
- package/dist/esm/react/shared-ts/src/utils/validation.js +0 -92
- package/dist/esm/react/shared-ts/src/utils/walletAddSignerActivation.js +0 -32
- package/dist/esm/react/shared-ts/src/utils/walletAuthAuthority.js +0 -224
- package/dist/esm/react/shared-ts/src/utils/walletAuthMethodRecord.js +0 -357
- package/dist/esm/react/shared-ts/src/utils/walletCapabilityBindings.js +0 -277
- package/dist/esm/react/shared-ts/src/utils/walletSessionFailure.js +0 -28
- package/dist/esm/react/shared-ts/src/utils/webauthnDeviceInfo.js +0 -50
- package/dist/esm/react/shared-ts/src/utils/wireSchema.js +0 -66
- package/dist/esm/react/shared-ts/src/wallet-recovery/index.js +0 -10
- package/dist/esm/react/shared-ts/src/wallet-recovery/recoveryCodeIssuance.js +0 -35
- package/dist/esm/react/shared-ts/src/wallet-recovery/recoveryCodeLocator.js +0 -34
- package/dist/esm/react/shared-ts/src/wallet-recovery/recoveryCodeReservation.js +0 -24
- package/dist/esm/react/shared-ts/src/wallet-recovery/recoveryCodes.js +0 -3
- package/dist/esm/react/shared-ts/src/wallet-recovery/recoveryKeyId.js +0 -14
- package/dist/esm/react/shared-ts/src/wallet-recovery/walletRecoveryCommittedProjection.js +0 -251
- package/dist/esm/react/shared-ts/src/wallet-recovery/walletRecoveryEcdsaPossession.js +0 -153
- package/dist/esm/react/shared-ts/src/wallet-recovery/walletRecoveryEnvelopeSet.js +0 -84
- package/dist/esm/react/shared-ts/src/wallet-recovery/walletRecoveryRotation.js +0 -64
- package/dist/esm/react/theme/base-styles.js +0 -117
- package/dist/esm/react/theme/palette.js +0 -170
- package/dist/esm/react/utils/deviceDetection.js +0 -95
- package/dist/esm/react/utils/intentDigest.js +0 -77
- package/dist/esm/react/utils/menuItemBlink.js +0 -24
- package/dist/esm/react/utils/qrScanner.js +0 -297
- package/dist/esm/sdk/ConfirmationDrawer-MgFTBwwK.js +0 -425
- package/dist/esm/sdk/EvmClient-f3gUhS2L.js +0 -644
- package/dist/esm/sdk/NearClient-DY4NfHeD.js +0 -402
- package/dist/esm/sdk/NonceCoordinator-4XWPhYww.js +0 -2253
- package/dist/esm/sdk/accountIds-DhIPGOSN.js +0 -23
- package/dist/esm/sdk/accountLifecycle-zthG08aC.js +0 -1341
- package/dist/esm/sdk/actions-CCvThiKe.js +0 -225
- package/dist/esm/sdk/adapters-Dli9XAZp.js +0 -4836
- package/dist/esm/sdk/base-D1B5mGin.js +0 -64
- package/dist/esm/sdk/base64-Clm8C-e9.js +0 -68
- package/dist/esm/sdk/browser-D6eZGhzE.js +0 -2393
- package/dist/esm/sdk/bytes-qKxKn4gg.js +0 -40
- package/dist/esm/sdk/canonicalPrimitives-BTHWz80v.js +0 -36
- package/dist/esm/sdk/canonicalSignerErrorCode-BBIk365e.js +0 -139
- package/dist/esm/sdk/capabilityKinds-hvYqa6S_.js +0 -109
- package/dist/esm/sdk/chains-BMh3btVo.js +0 -124
- package/dist/esm/sdk/challengeDelivery-DZtopOAG.js +0 -74
- package/dist/esm/sdk/chunk-BtrIJ4_z.js +0 -33
- package/dist/esm/sdk/configHelpers-D1EqxVxg.js +0 -179
- package/dist/esm/sdk/csp-stylesheet-btENhsNp.js +0 -215
- package/dist/esm/sdk/defaultConfigs-D_33pPT9.js +0 -355
- package/dist/esm/sdk/display-P4nQF-yc.js +0 -126
- package/dist/esm/sdk/domainIds-lcrFg6Sa.js +0 -338
- package/dist/esm/sdk/ecdsaCapabilityManifest-DuMs0VtU.js +0 -805
- package/dist/esm/sdk/ecdsaChainTarget-Bl-JWyuw.js +0 -121
- package/dist/esm/sdk/ecdsaPresignLifecycle-Bfx2AQKb.js +0 -1983
- package/dist/esm/sdk/ecdsaPresignPoolIdentity-BjxZVIqn.js +0 -47
- package/dist/esm/sdk/ecdsaWalletRecords-D42rtA9z.js +0 -18
- package/dist/esm/sdk/encoders-D8d07vpx.js +0 -0
- package/dist/esm/sdk/enrichDisplayModelWithAbi-CWggsykc.js +0 -395
- package/dist/esm/sdk/enrichDisplayModelWithAbi-SDRwTd_M.js +0 -579
- package/dist/esm/sdk/errors-93h9uAW9.js +0 -92
- package/dist/esm/sdk/events-DYoBL2HO.js +0 -8
- package/dist/esm/sdk/evmCryptoWasm-DWklhEEb.js +0 -196
- package/dist/esm/sdk/evmFamilyEcdsaIdentity-CqGafQsI.js +0 -4274
- package/dist/esm/sdk/exactSessionState-LWDUXydN.js +0 -2592
- package/dist/esm/sdk/exactSigningLaneIdentity-m6uTXV_A.js +0 -335
- package/dist/esm/sdk/executeWorkerOperation-Cl9whMK7.js +0 -10
- package/dist/esm/sdk/export-viewer-host-rWMSQQMP.js +0 -204
- package/dist/esm/sdk/helpers-ZrowMnev.js +0 -302
- package/dist/esm/sdk/host-CnV8nAUe.js +0 -533
- package/dist/esm/sdk/intentDigest-CvOSNlCH.js +0 -75
- package/dist/esm/sdk/jsonRpc-VVkaQkFD.js +0 -62
- package/dist/esm/sdk/jsxRuntime.module-CuH5ZEIA.js +0 -298
- package/dist/esm/sdk/keccak-DUL3d8SF.js +0 -148
- package/dist/esm/sdk/keyMaterialBrands-CogGAAZn.js +0 -94
- package/dist/esm/sdk/localOnly-DTpa2jD5.js +0 -146
- package/dist/esm/sdk/messages-C7Dbx9iN.js +0 -594
- package/dist/esm/sdk/mountExportPrivateKeySurface-DgX-IBG_.js +0 -542
- package/dist/esm/sdk/mountRecoveryCodeBackupSurface-DXrExiJ7.js +0 -590
- package/dist/esm/sdk/nearEd25519YaoMaterialActivation-B5GecIvq.js +0 -4018
- package/dist/esm/sdk/nearEd25519YaoSigningPreparation-CdOT5RuC.js +0 -405
- package/dist/esm/sdk/nearRpcResults-DoUgDATm.js +0 -216
- package/dist/esm/sdk/nonceLaneKeys-C3c9lG6u.js +0 -164
- package/dist/esm/sdk/normalization-CBt413-z.js +0 -22
- package/dist/esm/sdk/operationFingerprint-C8Trar4R.js +0 -929
- package/dist/esm/sdk/operationFingerprint-CGZui5dR.js +0 -55
- package/dist/esm/sdk/passkey-custody-UUHbC0pk.js +0 -487
- package/dist/esm/sdk/pendingWalletRecoveryCodeBackup-BWluQMbt.js +0 -237
- package/dist/esm/sdk/prfCache-wqQSjYLn.js +0 -58
- package/dist/esm/sdk/profileAccountProjection-uZVJuBvS.js +0 -86
- package/dist/esm/sdk/promptText-CuRa_ivd.js +0 -32
- package/dist/esm/sdk/recovery-entrypoint-C3fydnRC.js +0 -779
- package/dist/esm/sdk/registration-Ct_7LdGf.js +0 -14402
- package/dist/esm/sdk/registration-DHERU8R_.js +0 -233
- package/dist/esm/sdk/registrationAccounts-DmWPzf3T.js +0 -33
- package/dist/esm/sdk/registrationIds-DLSdEKSv.js +0 -310
- package/dist/esm/sdk/registrationIntent-4zwk16zQ.js +0 -387
- package/dist/esm/sdk/registrationPreparationPreload-D6zpWp4O.js +0 -13
- package/dist/esm/sdk/registrationSignerPlan-DhV8VAob.js +0 -437
- package/dist/esm/sdk/relayerHttp-VC8Holz1.js +0 -24
- package/dist/esm/sdk/routePlan-D59x5xzQ.js +0 -83
- package/dist/esm/sdk/router-B4ZWFy9E.js +0 -4721
- package/dist/esm/sdk/routerAbNormalSigning-CVFEOZ2m.js +0 -992
- package/dist/esm/sdk/runtime-auth-DdfynDKt.js +0 -5393
- package/dist/esm/sdk/runtime-device-link-HJ2ptFux.js +0 -259
- package/dist/esm/sdk/runtime-ecdsa-tempo-BGLsTAWR.js +0 -177
- package/dist/esm/sdk/runtime-email-otp-CpX88VZJ.js +0 -320
- package/dist/esm/sdk/runtime-export-DIVY473L.js +0 -112
- package/dist/esm/sdk/runtime-near-CxtQi4b2.js +0 -278
- package/dist/esm/sdk/runtime-preferences-vnJc5Svg.js +0 -67
- package/dist/esm/sdk/runtime-recovery-codes-BSCLVHQj.js +0 -95
- package/dist/esm/sdk/runtime-recovery-i08vCJST.js +0 -45
- package/dist/esm/sdk/runtimeContext-D3TBExQ6.js +0 -44484
- package/dist/esm/sdk/runtimeLoader-DQVEFVaW.js +0 -44
- package/dist/esm/sdk/sdkSentEvents-MqDkbQg1.js +0 -599
- package/dist/esm/sdk/secp256k1-D-I6Gh4D.js +0 -2515
- package/dist/esm/sdk/secureRandomId-BORsmdS4.js +0 -33
- package/dist/esm/sdk/sessionPolicy-DO-MkL65.js +0 -460
- package/dist/esm/sdk/shared-DkbeLCI3.js +0 -33
- package/dist/esm/sdk/signEvmFamily-C3C97Th-.js +0 -4607
- package/dist/esm/sdk/signEvmFamilyWithUiConfirmForTempo-BI9DSTIS.js +0 -226
- package/dist/esm/sdk/signEvmWithUiConfirm-Bmcim5-g.js +0 -27
- package/dist/esm/sdk/signNear-Bmb2fj_a.js +0 -5893
- package/dist/esm/sdk/signatureUses-BkGyYt8F.js +0 -51
- package/dist/esm/sdk/signerDomain-IEAVrOrc.js +0 -59
- package/dist/esm/sdk/signerLoader-B7orgq5Z.js +0 -23
- package/dist/esm/sdk/signerSlot-_ovonwVX.js +0 -10
- package/dist/esm/sdk/signingFlow-SZ8t_lxv.js +0 -1319
- package/dist/esm/sdk/signingSessionSeal-Cu-GHm6y.js +0 -96
- package/dist/esm/sdk/surface-measurement-reporter-CSTyRsMa.js +0 -156
- package/dist/esm/sdk/trace-DKLQZvec.js +0 -126
- package/dist/esm/sdk/transaction-activity-CSMCveBn.js +0 -218
- package/dist/esm/sdk/transactionReview-DpHLTznU.js +0 -100
- package/dist/esm/sdk/transactionReviewAdmission-BCPvl8OZ.js +0 -172
- package/dist/esm/sdk/transactionState-CJ4U8pcl.js +0 -1894
- package/dist/esm/sdk/types-Dx9fczU7.js +0 -111
- package/dist/esm/sdk/validation-gat4LEKm.js +0 -409
- package/dist/esm/sdk/wallet-recovery-BX61-79p.js +0 -1902
- package/dist/esm/sdk/walletAuthority-DD9T25F6.js +0 -1247
- package/dist/esm/sdk/walletCustodyEcdsaContinuity-CF4bv9OI.js +0 -11000
- package/dist/esm/sdk/walletIframeIdentity-DB6Z2EC9.js +0 -13
- package/dist/esm/sdk/walletRecoveryCommit-AI1AtIRP.js +0 -2101
- package/dist/esm/sdk/walletRecoveryRotate-BgLlW5ih.js +0 -309
- package/dist/esm/sdk/warmSessionHydration-Os8niEm7.js +0 -7
- package/dist/esm/sdk/webauthnP256-DC5EIbKN.js +0 -82
- package/dist/esm/sdk/webauthnPromptCoordinator-L96oVvLz.js +0 -168
- package/dist/esm/shared-ts/src/signing-lanes/rotationDigests.js +0 -6
- package/dist/esm/shared-ts/src/signing-lanes/rotationParsers.js +0 -3
- package/dist/esm/shared-ts/src/signing-lanes/rotationProtocolParsers.js +0 -8
- package/dist/esm/shared-ts/src/signing-lanes/rotationWireFields.js +0 -3
- package/dist/esm/shared-ts/src/utils/addWalletAuthMethod.js +0 -1
- package/dist/esm/styles.css +0 -43
- package/dist/public/sdk/ConfirmationDrawer-MgFTBwwK.js +0 -425
- package/dist/public/sdk/EvmClient-f3gUhS2L.js +0 -644
- package/dist/public/sdk/NearClient-DY4NfHeD.js +0 -402
- package/dist/public/sdk/NonceCoordinator-4XWPhYww.js +0 -2253
- package/dist/public/sdk/accountIds-DhIPGOSN.js +0 -23
- package/dist/public/sdk/accountLifecycle-zthG08aC.js +0 -1341
- package/dist/public/sdk/actions-CCvThiKe.js +0 -225
- package/dist/public/sdk/adapters-Dli9XAZp.js +0 -4836
- package/dist/public/sdk/base-D1B5mGin.js +0 -64
- package/dist/public/sdk/base64-Clm8C-e9.js +0 -68
- package/dist/public/sdk/browser-D6eZGhzE.js +0 -2393
- package/dist/public/sdk/bytes-qKxKn4gg.js +0 -40
- package/dist/public/sdk/canonicalPrimitives-BTHWz80v.js +0 -36
- package/dist/public/sdk/canonicalSignerErrorCode-BBIk365e.js +0 -139
- package/dist/public/sdk/capabilityKinds-hvYqa6S_.js +0 -109
- package/dist/public/sdk/chains-BMh3btVo.js +0 -124
- package/dist/public/sdk/challengeDelivery-DZtopOAG.js +0 -74
- package/dist/public/sdk/chunk-BtrIJ4_z.js +0 -33
- package/dist/public/sdk/configHelpers-D1EqxVxg.js +0 -179
- package/dist/public/sdk/csp-stylesheet-btENhsNp.js +0 -215
- package/dist/public/sdk/defaultConfigs-D_33pPT9.js +0 -355
- package/dist/public/sdk/display-P4nQF-yc.js +0 -126
- package/dist/public/sdk/domainIds-lcrFg6Sa.js +0 -338
- package/dist/public/sdk/ecdsaCapabilityManifest-DuMs0VtU.js +0 -805
- package/dist/public/sdk/ecdsaChainTarget-Bl-JWyuw.js +0 -121
- package/dist/public/sdk/ecdsaPresignLifecycle-Bfx2AQKb.js +0 -1983
- package/dist/public/sdk/ecdsaPresignPoolIdentity-BjxZVIqn.js +0 -47
- package/dist/public/sdk/ecdsaWalletRecords-D42rtA9z.js +0 -18
- package/dist/public/sdk/encoders-D8d07vpx.js +0 -0
- package/dist/public/sdk/enrichDisplayModelWithAbi-CWggsykc.js +0 -395
- package/dist/public/sdk/enrichDisplayModelWithAbi-SDRwTd_M.js +0 -579
- package/dist/public/sdk/errors-93h9uAW9.js +0 -92
- package/dist/public/sdk/events-DYoBL2HO.js +0 -8
- package/dist/public/sdk/evmCryptoWasm-DWklhEEb.js +0 -196
- package/dist/public/sdk/evmFamilyEcdsaIdentity-CqGafQsI.js +0 -4274
- package/dist/public/sdk/exactSessionState-LWDUXydN.js +0 -2592
- package/dist/public/sdk/exactSigningLaneIdentity-m6uTXV_A.js +0 -335
- package/dist/public/sdk/executeWorkerOperation-Cl9whMK7.js +0 -10
- package/dist/public/sdk/export-viewer-host-rWMSQQMP.js +0 -204
- package/dist/public/sdk/helpers-ZrowMnev.js +0 -302
- package/dist/public/sdk/host-CnV8nAUe.js +0 -533
- package/dist/public/sdk/intentDigest-CvOSNlCH.js +0 -75
- package/dist/public/sdk/jsonRpc-VVkaQkFD.js +0 -62
- package/dist/public/sdk/jsxRuntime.module-CuH5ZEIA.js +0 -298
- package/dist/public/sdk/keccak-DUL3d8SF.js +0 -148
- package/dist/public/sdk/keyMaterialBrands-CogGAAZn.js +0 -94
- package/dist/public/sdk/localOnly-DTpa2jD5.js +0 -146
- package/dist/public/sdk/messages-C7Dbx9iN.js +0 -594
- package/dist/public/sdk/mountExportPrivateKeySurface-DgX-IBG_.js +0 -542
- package/dist/public/sdk/mountRecoveryCodeBackupSurface-DXrExiJ7.js +0 -590
- package/dist/public/sdk/nearEd25519YaoMaterialActivation-B5GecIvq.js +0 -4018
- package/dist/public/sdk/nearEd25519YaoSigningPreparation-CdOT5RuC.js +0 -405
- package/dist/public/sdk/nearRpcResults-DoUgDATm.js +0 -216
- package/dist/public/sdk/nonceLaneKeys-C3c9lG6u.js +0 -164
- package/dist/public/sdk/normalization-CBt413-z.js +0 -22
- package/dist/public/sdk/operationFingerprint-C8Trar4R.js +0 -929
- package/dist/public/sdk/operationFingerprint-CGZui5dR.js +0 -55
- package/dist/public/sdk/passkey-custody-UUHbC0pk.js +0 -487
- package/dist/public/sdk/pendingWalletRecoveryCodeBackup-BWluQMbt.js +0 -237
- package/dist/public/sdk/prfCache-wqQSjYLn.js +0 -58
- package/dist/public/sdk/profileAccountProjection-uZVJuBvS.js +0 -86
- package/dist/public/sdk/promptText-CuRa_ivd.js +0 -32
- package/dist/public/sdk/recovery-entrypoint-C3fydnRC.js +0 -779
- package/dist/public/sdk/registration-Ct_7LdGf.js +0 -14402
- package/dist/public/sdk/registration-DHERU8R_.js +0 -233
- package/dist/public/sdk/registrationAccounts-DmWPzf3T.js +0 -33
- package/dist/public/sdk/registrationIds-DLSdEKSv.js +0 -310
- package/dist/public/sdk/registrationIntent-4zwk16zQ.js +0 -387
- package/dist/public/sdk/registrationPreparationPreload-D6zpWp4O.js +0 -13
- package/dist/public/sdk/registrationSignerPlan-DhV8VAob.js +0 -437
- package/dist/public/sdk/relayerHttp-VC8Holz1.js +0 -24
- package/dist/public/sdk/routePlan-D59x5xzQ.js +0 -83
- package/dist/public/sdk/router-B4ZWFy9E.js +0 -4721
- package/dist/public/sdk/routerAbNormalSigning-CVFEOZ2m.js +0 -992
- package/dist/public/sdk/runtime-auth-DdfynDKt.js +0 -5393
- package/dist/public/sdk/runtime-device-link-HJ2ptFux.js +0 -259
- package/dist/public/sdk/runtime-ecdsa-tempo-BGLsTAWR.js +0 -177
- package/dist/public/sdk/runtime-email-otp-CpX88VZJ.js +0 -320
- package/dist/public/sdk/runtime-export-DIVY473L.js +0 -112
- package/dist/public/sdk/runtime-near-CxtQi4b2.js +0 -278
- package/dist/public/sdk/runtime-preferences-vnJc5Svg.js +0 -67
- package/dist/public/sdk/runtime-recovery-codes-BSCLVHQj.js +0 -95
- package/dist/public/sdk/runtime-recovery-i08vCJST.js +0 -45
- package/dist/public/sdk/runtimeContext-D3TBExQ6.js +0 -44484
- package/dist/public/sdk/runtimeLoader-DQVEFVaW.js +0 -44
- package/dist/public/sdk/sdkSentEvents-MqDkbQg1.js +0 -599
- package/dist/public/sdk/secp256k1-D-I6Gh4D.js +0 -2515
- package/dist/public/sdk/secureRandomId-BORsmdS4.js +0 -33
- package/dist/public/sdk/sessionPolicy-DO-MkL65.js +0 -460
- package/dist/public/sdk/shared-DkbeLCI3.js +0 -33
- package/dist/public/sdk/signEvmFamily-C3C97Th-.js +0 -4607
- package/dist/public/sdk/signEvmFamilyWithUiConfirmForTempo-BI9DSTIS.js +0 -226
- package/dist/public/sdk/signEvmWithUiConfirm-Bmcim5-g.js +0 -27
- package/dist/public/sdk/signNear-Bmb2fj_a.js +0 -5893
- package/dist/public/sdk/signatureUses-BkGyYt8F.js +0 -51
- package/dist/public/sdk/signerDomain-IEAVrOrc.js +0 -59
- package/dist/public/sdk/signerLoader-B7orgq5Z.js +0 -23
- package/dist/public/sdk/signerSlot-_ovonwVX.js +0 -10
- package/dist/public/sdk/signingFlow-SZ8t_lxv.js +0 -1319
- package/dist/public/sdk/signingSessionSeal-Cu-GHm6y.js +0 -96
- package/dist/public/sdk/surface-measurement-reporter-CSTyRsMa.js +0 -156
- package/dist/public/sdk/trace-DKLQZvec.js +0 -126
- package/dist/public/sdk/transaction-activity-CSMCveBn.js +0 -218
- package/dist/public/sdk/transactionReview-DpHLTznU.js +0 -100
- package/dist/public/sdk/transactionReviewAdmission-BCPvl8OZ.js +0 -172
- package/dist/public/sdk/transactionState-CJ4U8pcl.js +0 -1894
- package/dist/public/sdk/types-Dx9fczU7.js +0 -111
- package/dist/public/sdk/validation-gat4LEKm.js +0 -409
- package/dist/public/sdk/wallet-recovery-BX61-79p.js +0 -1902
- package/dist/public/sdk/walletAuthority-DD9T25F6.js +0 -1247
- package/dist/public/sdk/walletCustodyEcdsaContinuity-CF4bv9OI.js +0 -11000
- package/dist/public/sdk/walletIframeIdentity-DB6Z2EC9.js +0 -13
- package/dist/public/sdk/walletRecoveryCommit-AI1AtIRP.js +0 -2101
- package/dist/public/sdk/walletRecoveryRotate-BgLlW5ih.js +0 -309
- package/dist/public/sdk/warmSessionHydration-Os8niEm7.js +0 -7
- package/dist/public/sdk/webauthnP256-DC5EIbKN.js +0 -82
- package/dist/public/sdk/webauthnPromptCoordinator-L96oVvLz.js +0 -168
- package/dist/types/shared-ts/src/signing-lanes/participantDigest.typecheck.d.ts +0 -2
- package/dist/types/shared-ts/src/signing-lanes/rotation.typecheck.d.ts +0 -2
- package/dist/types/shared-ts/src/signing-lanes/rotationDigests.d.ts +0 -13
- package/dist/types/shared-ts/src/signing-lanes/rotationLifecycle.d.ts +0 -78
- package/dist/types/shared-ts/src/signing-lanes/rotationParsers.d.ts +0 -27
- package/dist/types/shared-ts/src/signing-lanes/rotationProtocolParsers.d.ts +0 -6
- package/dist/types/shared-ts/src/signing-lanes/rotationWireFields.d.ts +0 -20
- package/dist/types/shared-ts/src/wallet-recovery/recoveryCodeAttempt.d.ts +0 -59
- package/dist/types/wallet/src/SeamsWeb/walletIframe/client/transport/webauthn-bridge.d.ts +0 -3
- package/dist/types/wallet/src/core/indexedDB/seamsWalletDB/laneHolderMaterialStore.d.ts +0 -52
- package/dist/types/wallet/src/core/signingEngine/interfaces/nearKeyOps.d.ts +0 -15
- package/dist/types/wallet/src/core/signingEngine/session/holderShares/forbiddenHolderSharePayloads.typecheck.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/holderShares/holderShareHandle.d.ts +0 -6
- package/dist/types/wallet/src/core/signingEngine/session/identity/emailOtpEcdsaDerivationIdentity.typecheck.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/lanes/operations/activationCoordinator.d.ts +0 -37
- package/dist/types/wallet/src/core/signingEngine/session/lanes/operations/laneMaterialInvalidation.d.ts +0 -23
- package/dist/types/wallet/src/core/signingEngine/session/lanes/operations/operations.typecheck.d.ts +0 -2
- package/dist/types/wallet/src/core/signingEngine/session/lanes/operations/recipientPreparation.d.ts +0 -55
- package/dist/types/wallet/src/core/signingEngine/session/warmCapabilities/ecdsaProvisionPlan.typecheck.d.ts +0 -6
- package/dist/types/wallet/src/core/signingEngine/threshold/crypto/ecdsaLaneWasm.d.ts +0 -4
- package/dist/types/wallet/src/core/signingEngine/webauthnAuth/fallbacks/safari-fallbacks.d.ts +0 -44
- package/dist/types/wallet/src/core/signingEngine/workerManager/nearKeyOps/createNearKeyOps.d.ts +0 -4
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/ecdsaLaneHolderWorkerRuntime.d.ts +0 -20
- package/dist/types/wallet/src/core/signingEngine/workerManager/workers/email-otp/passkeyCustodyLink.d.ts +0 -18
- /package/dist/esm/{react/SeamsWeb → SeamsWeb}/assembly/preconnectWalletAssets.js +0 -0
|
@@ -157,51 +157,6 @@ function passArray8ToWasm0(arg, malloc) {
|
|
|
157
157
|
return ptr;
|
|
158
158
|
}
|
|
159
159
|
var EcdsaLaneHolderSessionV1Finalization = typeof FinalizationRegistry === "undefined" ? { register: () => {}, unregister: () => {} } : new FinalizationRegistry((ptr) => wasm.__wbg_ecdsalaneholdersessionv1_free(ptr >>> 0, 1));
|
|
160
|
-
|
|
161
|
-
class EcdsaLaneHolderSessionV1 {
|
|
162
|
-
__destroy_into_raw() {
|
|
163
|
-
const ptr = this.__wbg_ptr;
|
|
164
|
-
this.__wbg_ptr = 0;
|
|
165
|
-
EcdsaLaneHolderSessionV1Finalization.unregister(this);
|
|
166
|
-
return ptr;
|
|
167
|
-
}
|
|
168
|
-
free() {
|
|
169
|
-
const ptr = this.__destroy_into_raw();
|
|
170
|
-
wasm.__wbg_ecdsalaneholdersessionv1_free(ptr, 0);
|
|
171
|
-
}
|
|
172
|
-
constructor(state_blob_b64u) {
|
|
173
|
-
const ptr0 = passStringToWasm0(state_blob_b64u, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
174
|
-
const len0 = WASM_VECTOR_LEN;
|
|
175
|
-
const ret = wasm.ecdsalaneholdersessionv1_new(ptr0, len0);
|
|
176
|
-
if (ret[2]) {
|
|
177
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
178
|
-
}
|
|
179
|
-
this.__wbg_ptr = ret[0] >>> 0;
|
|
180
|
-
EcdsaLaneHolderSessionV1Finalization.register(this, this.__wbg_ptr, this);
|
|
181
|
-
return this;
|
|
182
|
-
}
|
|
183
|
-
prepare(input_json) {
|
|
184
|
-
let deferred3_0;
|
|
185
|
-
let deferred3_1;
|
|
186
|
-
try {
|
|
187
|
-
const ptr0 = passStringToWasm0(input_json, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
188
|
-
const len0 = WASM_VECTOR_LEN;
|
|
189
|
-
const ret = wasm.ecdsalaneholdersessionv1_prepare(this.__wbg_ptr, ptr0, len0);
|
|
190
|
-
var ptr2 = ret[0];
|
|
191
|
-
var len2 = ret[1];
|
|
192
|
-
if (ret[3]) {
|
|
193
|
-
ptr2 = 0;
|
|
194
|
-
len2 = 0;
|
|
195
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
196
|
-
}
|
|
197
|
-
deferred3_0 = ptr2;
|
|
198
|
-
deferred3_1 = len2;
|
|
199
|
-
return getStringFromWasm0(ptr2, len2);
|
|
200
|
-
} finally {
|
|
201
|
-
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
160
|
var EcdsaLinkedHolderMaterialV1Finalization = typeof FinalizationRegistry === "undefined" ? { register: () => {}, unregister: () => {} } : new FinalizationRegistry((ptr) => wasm.__wbg_ecdsalinkedholdermaterialv1_free(ptr >>> 0, 1));
|
|
206
161
|
|
|
207
162
|
class EcdsaLinkedHolderMaterialV1 {
|
|
@@ -494,13 +449,6 @@ class LinkedDeviceEcdsaSourceContributionSessionV1 {
|
|
|
494
449
|
var RouterAbEcdsaClientCeremonyV1Finalization = typeof FinalizationRegistry === "undefined" ? { register: () => {}, unregister: () => {} } : new FinalizationRegistry((ptr) => wasm.__wbg_routerabecdsaclientceremonyv1_free(ptr >>> 0, 1));
|
|
495
450
|
|
|
496
451
|
class RouterAbEcdsaClientCeremonyV1 {
|
|
497
|
-
static __wrap(ptr) {
|
|
498
|
-
ptr = ptr >>> 0;
|
|
499
|
-
const obj = Object.create(RouterAbEcdsaClientCeremonyV1.prototype);
|
|
500
|
-
obj.__wbg_ptr = ptr;
|
|
501
|
-
RouterAbEcdsaClientCeremonyV1Finalization.register(obj, obj.__wbg_ptr, obj);
|
|
502
|
-
return obj;
|
|
503
|
-
}
|
|
504
452
|
__destroy_into_raw() {
|
|
505
453
|
const ptr = this.__wbg_ptr;
|
|
506
454
|
this.__wbg_ptr = 0;
|
|
@@ -591,15 +539,6 @@ class RouterAbEcdsaClientCeremonyV1 {
|
|
|
591
539
|
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
592
540
|
}
|
|
593
541
|
}
|
|
594
|
-
static fromRecipientPrivateKey(recipient_private_key) {
|
|
595
|
-
const ptr0 = passArray8ToWasm0(recipient_private_key, wasm.__wbindgen_malloc);
|
|
596
|
-
const len0 = WASM_VECTOR_LEN;
|
|
597
|
-
const ret = wasm.routerabecdsaclientceremonyv1_fromRecipientPrivateKey(ptr0, len0);
|
|
598
|
-
if (ret[2]) {
|
|
599
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
600
|
-
}
|
|
601
|
-
return RouterAbEcdsaClientCeremonyV1.__wrap(ret[0]);
|
|
602
|
-
}
|
|
603
542
|
build_explicit_export_request(input_json) {
|
|
604
543
|
let deferred3_0;
|
|
605
544
|
let deferred3_1;
|
|
@@ -621,15 +560,6 @@ class RouterAbEcdsaClientCeremonyV1 {
|
|
|
621
560
|
wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);
|
|
622
561
|
}
|
|
623
562
|
}
|
|
624
|
-
open_committed_role_envelopes(input_json) {
|
|
625
|
-
const ptr0 = passStringToWasm0(input_json, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
626
|
-
const len0 = WASM_VECTOR_LEN;
|
|
627
|
-
const ret = wasm.routerabecdsaclientceremonyv1_open_committed_role_envelopes(this.__wbg_ptr, ptr0, len0);
|
|
628
|
-
if (ret[2]) {
|
|
629
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
630
|
-
}
|
|
631
|
-
return WasmOrdinaryEcdsaClientMaterialV1.__wrap(ret[0]);
|
|
632
|
-
}
|
|
633
563
|
verify_encrypted_proof_bundles(input_json) {
|
|
634
564
|
const ptr0 = passStringToWasm0(input_json, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
635
565
|
const len0 = WASM_VECTOR_LEN;
|
|
@@ -718,57 +648,6 @@ class RouterAbEcdsaClientCeremonyV1 {
|
|
|
718
648
|
wasm.routerabecdsaclientceremonyv1_close(this.__wbg_ptr);
|
|
719
649
|
}
|
|
720
650
|
}
|
|
721
|
-
var WasmOrdinaryEcdsaClientMaterialV1Finalization = typeof FinalizationRegistry === "undefined" ? { register: () => {}, unregister: () => {} } : new FinalizationRegistry((ptr) => wasm.__wbg_wasmordinaryecdsaclientmaterialv1_free(ptr >>> 0, 1));
|
|
722
|
-
|
|
723
|
-
class WasmOrdinaryEcdsaClientMaterialV1 {
|
|
724
|
-
static __wrap(ptr) {
|
|
725
|
-
ptr = ptr >>> 0;
|
|
726
|
-
const obj = Object.create(WasmOrdinaryEcdsaClientMaterialV1.prototype);
|
|
727
|
-
obj.__wbg_ptr = ptr;
|
|
728
|
-
WasmOrdinaryEcdsaClientMaterialV1Finalization.register(obj, obj.__wbg_ptr, obj);
|
|
729
|
-
return obj;
|
|
730
|
-
}
|
|
731
|
-
__destroy_into_raw() {
|
|
732
|
-
const ptr = this.__wbg_ptr;
|
|
733
|
-
this.__wbg_ptr = 0;
|
|
734
|
-
WasmOrdinaryEcdsaClientMaterialV1Finalization.unregister(this);
|
|
735
|
-
return ptr;
|
|
736
|
-
}
|
|
737
|
-
free() {
|
|
738
|
-
const ptr = this.__destroy_into_raw();
|
|
739
|
-
wasm.__wbg_wasmordinaryecdsaclientmaterialv1_free(ptr, 0);
|
|
740
|
-
}
|
|
741
|
-
transcript() {
|
|
742
|
-
const ret = wasm.wasmordinaryecdsaclientmaterialv1_transcript(this.__wbg_ptr);
|
|
743
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
744
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
745
|
-
return v1;
|
|
746
|
-
}
|
|
747
|
-
activation_id() {
|
|
748
|
-
let deferred1_0;
|
|
749
|
-
let deferred1_1;
|
|
750
|
-
try {
|
|
751
|
-
const ret = wasm.wasmordinaryecdsaclientmaterialv1_activation_id(this.__wbg_ptr);
|
|
752
|
-
deferred1_0 = ret[0];
|
|
753
|
-
deferred1_1 = ret[1];
|
|
754
|
-
return getStringFromWasm0(ret[0], ret[1]);
|
|
755
|
-
} finally {
|
|
756
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
757
|
-
}
|
|
758
|
-
}
|
|
759
|
-
take_client_material() {
|
|
760
|
-
const ret = wasm.wasmordinaryecdsaclientmaterialv1_take_client_material(this.__wbg_ptr);
|
|
761
|
-
if (ret[3]) {
|
|
762
|
-
throw takeFromExternrefTable0(ret[2]);
|
|
763
|
-
}
|
|
764
|
-
var v1 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
765
|
-
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
766
|
-
return v1;
|
|
767
|
-
}
|
|
768
|
-
destroy() {
|
|
769
|
-
wasm.wasmordinaryecdsaclientmaterialv1_destroy(this.__wbg_ptr);
|
|
770
|
-
}
|
|
771
|
-
}
|
|
772
651
|
async function __wbg_load(module, imports) {
|
|
773
652
|
if (typeof Response === "function" && module instanceof Response) {
|
|
774
653
|
if (typeof WebAssembly.instantiateStreaming === "function") {
|
|
@@ -1380,166 +1259,13 @@ function parseRootShareEpoch(raw) {
|
|
|
1380
1259
|
function parseWalletKeyId(raw) {
|
|
1381
1260
|
return parseDomainId(raw, "walletKeyId");
|
|
1382
1261
|
}
|
|
1383
|
-
function parseSigningLaneId(raw) {
|
|
1384
|
-
return parseDomainId(raw, "signingLaneId");
|
|
1385
|
-
}
|
|
1386
|
-
function parseLaneShareEpoch(raw) {
|
|
1387
|
-
return parseDomainId(raw, "laneShareEpoch");
|
|
1388
|
-
}
|
|
1389
|
-
function parseLaneOperationId(raw) {
|
|
1390
|
-
return parseDomainId(raw, "laneOperationId");
|
|
1391
|
-
}
|
|
1392
|
-
function parseLaneEnrollmentId(raw) {
|
|
1393
|
-
return parseDomainId(raw, "laneEnrollmentId");
|
|
1394
|
-
}
|
|
1395
|
-
function parseLaneOperationIdempotencyKey(raw) {
|
|
1396
|
-
return parseDomainId(raw, "laneOperationIdempotencyKey");
|
|
1397
|
-
}
|
|
1398
1262
|
function parseLinkedDeviceEnrollmentId(raw) {
|
|
1399
1263
|
return parseDomainId(raw, "linkedDeviceEnrollmentId");
|
|
1400
1264
|
}
|
|
1401
|
-
function parseEd25519YaoSuiteId(raw) {
|
|
1402
|
-
return parseDomainId(raw, "ed25519YaoSuiteId");
|
|
1403
|
-
}
|
|
1404
|
-
function parseEcdsaRelayerKeyId(raw) {
|
|
1405
|
-
return parseDomainId(raw, "ecdsaRelayerKeyId");
|
|
1406
|
-
}
|
|
1407
1265
|
function parseLinkDeviceSessionId(raw) {
|
|
1408
1266
|
return parseDomainId(raw, "linkDeviceSessionId");
|
|
1409
1267
|
}
|
|
1410
|
-
// ../../node_modules/base-x/src/esm/index.js
|
|
1411
|
-
function base(ALPHABET) {
|
|
1412
|
-
if (ALPHABET.length >= 255) {
|
|
1413
|
-
throw new TypeError("Alphabet too long");
|
|
1414
|
-
}
|
|
1415
|
-
const BASE_MAP = new Uint8Array(256);
|
|
1416
|
-
for (let j = 0;j < BASE_MAP.length; j++) {
|
|
1417
|
-
BASE_MAP[j] = 255;
|
|
1418
|
-
}
|
|
1419
|
-
for (let i = 0;i < ALPHABET.length; i++) {
|
|
1420
|
-
const x = ALPHABET.charAt(i);
|
|
1421
|
-
const xc = x.charCodeAt(0);
|
|
1422
|
-
if (BASE_MAP[xc] !== 255) {
|
|
1423
|
-
throw new TypeError(x + " is ambiguous");
|
|
1424
|
-
}
|
|
1425
|
-
BASE_MAP[xc] = i;
|
|
1426
|
-
}
|
|
1427
|
-
const BASE = ALPHABET.length;
|
|
1428
|
-
const LEADER = ALPHABET.charAt(0);
|
|
1429
|
-
const FACTOR = Math.log(BASE) / Math.log(256);
|
|
1430
|
-
const iFACTOR = Math.log(256) / Math.log(BASE);
|
|
1431
|
-
function encode(source) {
|
|
1432
|
-
if (source instanceof Uint8Array) {} else if (ArrayBuffer.isView(source)) {
|
|
1433
|
-
source = new Uint8Array(source.buffer, source.byteOffset, source.byteLength);
|
|
1434
|
-
} else if (Array.isArray(source)) {
|
|
1435
|
-
source = Uint8Array.from(source);
|
|
1436
|
-
}
|
|
1437
|
-
if (!(source instanceof Uint8Array)) {
|
|
1438
|
-
throw new TypeError("Expected Uint8Array");
|
|
1439
|
-
}
|
|
1440
|
-
if (source.length === 0) {
|
|
1441
|
-
return "";
|
|
1442
|
-
}
|
|
1443
|
-
let zeroes = 0;
|
|
1444
|
-
let length = 0;
|
|
1445
|
-
let pbegin = 0;
|
|
1446
|
-
const pend = source.length;
|
|
1447
|
-
while (pbegin !== pend && source[pbegin] === 0) {
|
|
1448
|
-
pbegin++;
|
|
1449
|
-
zeroes++;
|
|
1450
|
-
}
|
|
1451
|
-
const size = (pend - pbegin) * iFACTOR + 1 >>> 0;
|
|
1452
|
-
const b58 = new Uint8Array(size);
|
|
1453
|
-
while (pbegin !== pend) {
|
|
1454
|
-
let carry = source[pbegin];
|
|
1455
|
-
let i = 0;
|
|
1456
|
-
for (let it1 = size - 1;(carry !== 0 || i < length) && it1 !== -1; it1--, i++) {
|
|
1457
|
-
carry += 256 * b58[it1] >>> 0;
|
|
1458
|
-
b58[it1] = carry % BASE >>> 0;
|
|
1459
|
-
carry = carry / BASE >>> 0;
|
|
1460
|
-
}
|
|
1461
|
-
if (carry !== 0) {
|
|
1462
|
-
throw new Error("Non-zero carry");
|
|
1463
|
-
}
|
|
1464
|
-
length = i;
|
|
1465
|
-
pbegin++;
|
|
1466
|
-
}
|
|
1467
|
-
let it2 = size - length;
|
|
1468
|
-
while (it2 !== size && b58[it2] === 0) {
|
|
1469
|
-
it2++;
|
|
1470
|
-
}
|
|
1471
|
-
let str = LEADER.repeat(zeroes);
|
|
1472
|
-
for (;it2 < size; ++it2) {
|
|
1473
|
-
str += ALPHABET.charAt(b58[it2]);
|
|
1474
|
-
}
|
|
1475
|
-
return str;
|
|
1476
|
-
}
|
|
1477
|
-
function decodeUnsafe(source) {
|
|
1478
|
-
if (typeof source !== "string") {
|
|
1479
|
-
throw new TypeError("Expected String");
|
|
1480
|
-
}
|
|
1481
|
-
if (source.length === 0) {
|
|
1482
|
-
return new Uint8Array;
|
|
1483
|
-
}
|
|
1484
|
-
let psz = 0;
|
|
1485
|
-
let zeroes = 0;
|
|
1486
|
-
let length = 0;
|
|
1487
|
-
while (source[psz] === LEADER) {
|
|
1488
|
-
zeroes++;
|
|
1489
|
-
psz++;
|
|
1490
|
-
}
|
|
1491
|
-
const size = (source.length - psz) * FACTOR + 1 >>> 0;
|
|
1492
|
-
const b256 = new Uint8Array(size);
|
|
1493
|
-
while (psz < source.length) {
|
|
1494
|
-
const charCode = source.charCodeAt(psz);
|
|
1495
|
-
if (charCode > 255) {
|
|
1496
|
-
return;
|
|
1497
|
-
}
|
|
1498
|
-
let carry = BASE_MAP[charCode];
|
|
1499
|
-
if (carry === 255) {
|
|
1500
|
-
return;
|
|
1501
|
-
}
|
|
1502
|
-
let i = 0;
|
|
1503
|
-
for (let it3 = size - 1;(carry !== 0 || i < length) && it3 !== -1; it3--, i++) {
|
|
1504
|
-
carry += BASE * b256[it3] >>> 0;
|
|
1505
|
-
b256[it3] = carry % 256 >>> 0;
|
|
1506
|
-
carry = carry / 256 >>> 0;
|
|
1507
|
-
}
|
|
1508
|
-
if (carry !== 0) {
|
|
1509
|
-
throw new Error("Non-zero carry");
|
|
1510
|
-
}
|
|
1511
|
-
length = i;
|
|
1512
|
-
psz++;
|
|
1513
|
-
}
|
|
1514
|
-
let it4 = size - length;
|
|
1515
|
-
while (it4 !== size && b256[it4] === 0) {
|
|
1516
|
-
it4++;
|
|
1517
|
-
}
|
|
1518
|
-
const vch = new Uint8Array(zeroes + (size - it4));
|
|
1519
|
-
let j = zeroes;
|
|
1520
|
-
while (it4 !== size) {
|
|
1521
|
-
vch[j++] = b256[it4++];
|
|
1522
|
-
}
|
|
1523
|
-
return vch;
|
|
1524
|
-
}
|
|
1525
|
-
function decode(string) {
|
|
1526
|
-
const buffer = decodeUnsafe(string);
|
|
1527
|
-
if (buffer) {
|
|
1528
|
-
return buffer;
|
|
1529
|
-
}
|
|
1530
|
-
throw new Error("Non-base" + BASE + " character");
|
|
1531
|
-
}
|
|
1532
|
-
return {
|
|
1533
|
-
encode,
|
|
1534
|
-
decodeUnsafe,
|
|
1535
|
-
decode
|
|
1536
|
-
};
|
|
1537
|
-
}
|
|
1538
|
-
var esm_default = base;
|
|
1539
1268
|
|
|
1540
|
-
// ../../node_modules/bs58/src/esm/index.js
|
|
1541
|
-
var ALPHABET = "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";
|
|
1542
|
-
var esm_default2 = esm_default(ALPHABET);
|
|
1543
1269
|
// ../shared-ts/src/utils/walletAuthAuthority.ts
|
|
1544
1270
|
function parseWalletAuthAuthorityRef(raw) {
|
|
1545
1271
|
if (!raw || typeof raw !== "object" || Array.isArray(raw))
|
|
@@ -1934,18 +1660,6 @@ function requireCanonicalBase64Url(value, label) {
|
|
|
1934
1660
|
}
|
|
1935
1661
|
return decoded;
|
|
1936
1662
|
}
|
|
1937
|
-
function requireParsed(result, label) {
|
|
1938
|
-
if (result.ok)
|
|
1939
|
-
return result.value;
|
|
1940
|
-
throw new Error(`${label} ${result.error.message}`);
|
|
1941
|
-
}
|
|
1942
|
-
function parseDigestField(value, label) {
|
|
1943
|
-
try {
|
|
1944
|
-
return parseDigestB64u(value);
|
|
1945
|
-
} catch (error) {
|
|
1946
|
-
throw new Error(`${label} ${error instanceof Error ? error.message : "is not a digest"}`);
|
|
1947
|
-
}
|
|
1948
|
-
}
|
|
1949
1663
|
var PASSKEY_CUSTODY_WRAP_TAG_LENGTH = 16;
|
|
1950
1664
|
function parseEnvelopeCiphertextB64u(value, label = "ciphertextB64u") {
|
|
1951
1665
|
const decoded = requireCanonicalBase64Url(value, label);
|
|
@@ -1954,13 +1668,6 @@ function parseEnvelopeCiphertextB64u(value, label = "ciphertextB64u") {
|
|
|
1954
1668
|
}
|
|
1955
1669
|
return value;
|
|
1956
1670
|
}
|
|
1957
|
-
function parseEd25519PublicKeyB64u(value, label = "registeredPublicKeyB64u") {
|
|
1958
|
-
const decoded = requireCanonicalBase64Url(value, label);
|
|
1959
|
-
if (decoded.length !== 32) {
|
|
1960
|
-
throw new Error(`${label} must decode to a 32-byte Ed25519 public key`);
|
|
1961
|
-
}
|
|
1962
|
-
return value;
|
|
1963
|
-
}
|
|
1964
1671
|
function parseSecp256k1CompressedPublicKeyB64u(value, label = "publicKey33B64u") {
|
|
1965
1672
|
const decoded = requireCanonicalBase64Url(value, label);
|
|
1966
1673
|
if (decoded.length !== 33) {
|
|
@@ -1971,12 +1678,6 @@ function parseSecp256k1CompressedPublicKeyB64u(value, label = "publicKey33B64u")
|
|
|
1971
1678
|
}
|
|
1972
1679
|
return value;
|
|
1973
1680
|
}
|
|
1974
|
-
function parseKeyCreationSignerSlot(value, label = "keyCreationSignerSlot") {
|
|
1975
|
-
if (typeof value !== "number" || !Number.isSafeInteger(value) || value <= 0 || value > 4294967295) {
|
|
1976
|
-
throw new Error(`${label} must be a positive u32`);
|
|
1977
|
-
}
|
|
1978
|
-
return value;
|
|
1979
|
-
}
|
|
1980
1681
|
// ../shared-ts/src/signing-lanes/evmFamilySigningKeySlotId.ts
|
|
1981
1682
|
function isEvmFamilySigningKeySlotIdShape(value) {
|
|
1982
1683
|
const parts = value.split(":");
|
|
@@ -2141,60 +1842,6 @@ var SERVER_ALLOCATED_WALLET_NOUNS = [
|
|
|
2141
1842
|
];
|
|
2142
1843
|
var SERVER_ALLOCATED_WALLET_ADJECTIVE_SET = new Set(SERVER_ALLOCATED_WALLET_ADJECTIVES);
|
|
2143
1844
|
var SERVER_ALLOCATED_WALLET_NOUN_SET = new Set(SERVER_ALLOCATED_WALLET_NOUNS);
|
|
2144
|
-
function nearEd25519SigningKeyIdFromString(value) {
|
|
2145
|
-
const normalized = String(value || "").trim();
|
|
2146
|
-
if (!normalized) {
|
|
2147
|
-
throw new Error("nearEd25519SigningKeyId is required");
|
|
2148
|
-
}
|
|
2149
|
-
return normalized;
|
|
2150
|
-
}
|
|
2151
|
-
function parseNearEd25519SigningKeyId(value) {
|
|
2152
|
-
if (typeof value !== "string") {
|
|
2153
|
-
throw new Error("nearEd25519SigningKeyId must be a string");
|
|
2154
|
-
}
|
|
2155
|
-
return nearEd25519SigningKeyIdFromString(value);
|
|
2156
|
-
}
|
|
2157
|
-
|
|
2158
|
-
// ../shared-ts/src/utils/exactRecord.ts
|
|
2159
|
-
var SECRET_BEARING_FIELD_SUBSTRINGS = [
|
|
2160
|
-
"prf",
|
|
2161
|
-
"kek",
|
|
2162
|
-
"seed",
|
|
2163
|
-
"scalar",
|
|
2164
|
-
"secretkey",
|
|
2165
|
-
"privatekey",
|
|
2166
|
-
"plaintext",
|
|
2167
|
-
"recoverycode",
|
|
2168
|
-
"clientroot",
|
|
2169
|
-
"holdershare"
|
|
2170
|
-
];
|
|
2171
|
-
function rejectUnknownFields(record, allowed, label, knownOnOtherBranches = []) {
|
|
2172
|
-
const allowedSet = new Set(allowed);
|
|
2173
|
-
const knownSet = new Set(knownOnOtherBranches);
|
|
2174
|
-
for (const field of Object.keys(record)) {
|
|
2175
|
-
if (allowedSet.has(field))
|
|
2176
|
-
continue;
|
|
2177
|
-
if (knownSet.has(field)) {
|
|
2178
|
-
throw new Error(`${label}.${field} is not part of ${label}`);
|
|
2179
|
-
}
|
|
2180
|
-
const normalized = field.toLowerCase().replace(/_/g, "");
|
|
2181
|
-
const namesAPublicKey = normalized.includes("publickey");
|
|
2182
|
-
if (!namesAPublicKey && SECRET_BEARING_FIELD_SUBSTRINGS.some((substring) => normalized.includes(substring))) {
|
|
2183
|
-
throw new Error(`${label}.${field} must never carry plaintext custody material`);
|
|
2184
|
-
}
|
|
2185
|
-
throw new Error(`${label}.${field} is not part of ${label}`);
|
|
2186
|
-
}
|
|
2187
|
-
}
|
|
2188
|
-
function exactRecord(raw, fields, label) {
|
|
2189
|
-
const record = requireRecord(raw, label);
|
|
2190
|
-
rejectUnknownFields(record, fields, label);
|
|
2191
|
-
for (const field of fields) {
|
|
2192
|
-
if (!Object.prototype.hasOwnProperty.call(record, field) || record[field] === undefined) {
|
|
2193
|
-
throw new Error(`${label}.${field} is required`);
|
|
2194
|
-
}
|
|
2195
|
-
}
|
|
2196
|
-
return record;
|
|
2197
|
-
}
|
|
2198
1845
|
|
|
2199
1846
|
// ../shared-ts/src/passkey-custody/custodySecretBinding.ts
|
|
2200
1847
|
var LANE_SCOPE_FIELDS = ["kind", "walletKeyId", "laneId", "laneShareEpoch"];
|
|
@@ -2299,7 +1946,6 @@ var EcdsaDerivationClientCustomRequestType = {
|
|
|
2299
1946
|
PrewarmEcdsaRegistrationCrypto: 70018,
|
|
2300
1947
|
VerifyRouterAbEcdsaPostRegistrationProofs: 70019,
|
|
2301
1948
|
SignWalletRecoveryEcdsaMaterialPossessionProof: 70020,
|
|
2302
|
-
PrepareEcdsaAdditiveLaneHolder: 70021,
|
|
2303
1949
|
PrepareLinkedDeviceEcdsaSourceContribution: 70022,
|
|
2304
1950
|
StoreLinkedDeviceEcdsaHolderMaterial: 70023,
|
|
2305
1951
|
DisposeLinkedDeviceEcdsaHolderMaterials: 70024,
|
|
@@ -2323,7 +1969,6 @@ var EcdsaDerivationClientCustomResponseType = {
|
|
|
2323
1969
|
PrewarmEcdsaRegistrationCryptoSuccess: 70118,
|
|
2324
1970
|
VerifyRouterAbEcdsaPostRegistrationProofsSuccess: 70119,
|
|
2325
1971
|
SignWalletRecoveryEcdsaMaterialPossessionProofSuccess: 70120,
|
|
2326
|
-
PrepareEcdsaAdditiveLaneHolderSuccess: 70121,
|
|
2327
1972
|
PrepareLinkedDeviceEcdsaSourceContributionSuccess: 70122,
|
|
2328
1973
|
StoreLinkedDeviceEcdsaHolderMaterialSuccess: 70123,
|
|
2329
1974
|
DisposeLinkedDeviceEcdsaHolderMaterialsSuccess: 70124,
|
|
@@ -2485,9 +2130,6 @@ var AUTHORIZATION_EVIDENCE_KIND_VALUES = Object.values(AUTHORIZATION_EVIDENCE_KI
|
|
|
2485
2130
|
function parseDeviceId(value) {
|
|
2486
2131
|
return parseAuthorizationId(value, "deviceId");
|
|
2487
2132
|
}
|
|
2488
|
-
function parseAuthorizedOperationId(value) {
|
|
2489
|
-
return parseAuthorizationId(value, "authorizedOperationId");
|
|
2490
|
-
}
|
|
2491
2133
|
function parseAuthorizationId(value, fieldName) {
|
|
2492
2134
|
if (typeof value !== "string") {
|
|
2493
2135
|
return {
|
|
@@ -2520,75 +2162,6 @@ function parseAuthorizationId(value, fieldName) {
|
|
|
2520
2162
|
return { ok: true, value: normalized };
|
|
2521
2163
|
}
|
|
2522
2164
|
|
|
2523
|
-
// ../shared-ts/src/utils/wireSchema.ts
|
|
2524
|
-
function wireLiteral(...literals) {
|
|
2525
|
-
const parse = (raw, label) => {
|
|
2526
|
-
if (!literals.includes(raw))
|
|
2527
|
-
throw new Error(`${label} is invalid`);
|
|
2528
|
-
return raw;
|
|
2529
|
-
};
|
|
2530
|
-
return Object.assign(parse, { literals });
|
|
2531
|
-
}
|
|
2532
|
-
function wireObject(shape, refine) {
|
|
2533
|
-
const keys = Object.keys(shape);
|
|
2534
|
-
const order = [
|
|
2535
|
-
...keys.filter((key) => ("literals" in shape[key])),
|
|
2536
|
-
...keys.filter((key) => !("literals" in shape[key]))
|
|
2537
|
-
];
|
|
2538
|
-
const parse = (raw, label) => {
|
|
2539
|
-
const record = exactRecord(raw, keys, label);
|
|
2540
|
-
const parsed = new Map;
|
|
2541
|
-
for (const key of order)
|
|
2542
|
-
parsed.set(key, shape[key](record[key], `${label}.${key}`));
|
|
2543
|
-
const value = Object.fromEntries(keys.map((key) => [key, parsed.get(key)]));
|
|
2544
|
-
refine?.(value, label);
|
|
2545
|
-
return value;
|
|
2546
|
-
};
|
|
2547
|
-
return Object.assign(parse, { shape });
|
|
2548
|
-
}
|
|
2549
|
-
function wireUnion(tag, variants) {
|
|
2550
|
-
const byTag = new Map;
|
|
2551
|
-
for (const variant of variants) {
|
|
2552
|
-
for (const literal of variant.shape[tag].literals)
|
|
2553
|
-
byTag.set(literal, variant);
|
|
2554
|
-
}
|
|
2555
|
-
return (raw, label) => {
|
|
2556
|
-
const record = requireRecord(raw, label);
|
|
2557
|
-
const variant = byTag.get(record[tag]);
|
|
2558
|
-
if (!variant)
|
|
2559
|
-
throw new Error(`${label}.${tag} is invalid`);
|
|
2560
|
-
return variant(record, label);
|
|
2561
|
-
};
|
|
2562
|
-
}
|
|
2563
|
-
function wireNonEmptyArray(item, refine) {
|
|
2564
|
-
return (raw, label) => {
|
|
2565
|
-
const entries = requireArray(raw, label);
|
|
2566
|
-
if (entries.length === 0)
|
|
2567
|
-
throw new Error(`${label} must be non-empty`);
|
|
2568
|
-
const [first, ...rest] = entries.map((entry, index) => item(entry, `${label}[${index}]`));
|
|
2569
|
-
const items = [first, ...rest];
|
|
2570
|
-
refine?.(items, label);
|
|
2571
|
-
return items;
|
|
2572
|
-
};
|
|
2573
|
-
}
|
|
2574
|
-
function wireResult(parse) {
|
|
2575
|
-
return (raw, label) => {
|
|
2576
|
-
const result = parse(raw);
|
|
2577
|
-
if (result.ok)
|
|
2578
|
-
return result.value;
|
|
2579
|
-
throw new Error(`${label} ${result.error.message}`);
|
|
2580
|
-
};
|
|
2581
|
-
}
|
|
2582
|
-
function wireLabeled(parse) {
|
|
2583
|
-
return (raw, label) => {
|
|
2584
|
-
try {
|
|
2585
|
-
return parse(raw);
|
|
2586
|
-
} catch (error) {
|
|
2587
|
-
throw new Error(`${label} ${error instanceof Error ? error.message : "is invalid"}`);
|
|
2588
|
-
}
|
|
2589
|
-
};
|
|
2590
|
-
}
|
|
2591
|
-
|
|
2592
2165
|
// ../shared-ts/src/authorization/delegatedAuthority.ts
|
|
2593
2166
|
var FULL_OWNER_PERMISSIONS = Object.freeze([
|
|
2594
2167
|
"export_keys",
|
|
@@ -3591,6 +3164,12 @@ function requireEcdsaOperationStepUpKind(value) {
|
|
|
3591
3164
|
}
|
|
3592
3165
|
}
|
|
3593
3166
|
|
|
3167
|
+
// ../shared-ts/src/utils/routerAbEd25519YaoDigests.ts
|
|
3168
|
+
var UTF8 = new TextEncoder;
|
|
3169
|
+
|
|
3170
|
+
// ../shared-ts/src/utils/routerAbEd25519Yao.ts
|
|
3171
|
+
var ED25519_YAO_CONTROL_CIPHERTEXT_MAX_BYTES_V1 = 64 * 1024;
|
|
3172
|
+
|
|
3594
3173
|
// ../shared-ts/src/threshold/ecdsaDerivationRoleLocalBootstrap.ts
|
|
3595
3174
|
function requireSdkBindingFactString(value, field) {
|
|
3596
3175
|
const normalized = String(value ?? "").trim();
|
|
@@ -3608,647 +3187,70 @@ function parseSdkEcdsaDerivationSigningRootVersion(value) {
|
|
|
3608
3187
|
return requireSdkBindingFactString(value, "signingRootVersion");
|
|
3609
3188
|
}
|
|
3610
3189
|
|
|
3611
|
-
// ../shared-ts/src/
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
|
|
3190
|
+
// ../shared-ts/src/device-linking/sourceContribution.ts
|
|
3191
|
+
var LINKED_DEVICE_ECDSA_SOURCE_CONTRIBUTION_ENVELOPE_KIND_V1 = "seams/linked-device/ecdsa-source-contribution-envelope/v1";
|
|
3192
|
+
function parseLinkedDeviceEcdsaSourceContributionPreparationV1(raw) {
|
|
3193
|
+
const record = exactRecord2(raw, [
|
|
3194
|
+
"linkSessionId",
|
|
3195
|
+
"enrollmentId",
|
|
3196
|
+
"sourceAuthorityId",
|
|
3197
|
+
"source",
|
|
3198
|
+
"target"
|
|
3199
|
+
], "linked-device ECDSA source contribution preparation");
|
|
3200
|
+
const source = parseEcdsaSourceSigner(record.source);
|
|
3201
|
+
const target = parseEcdsaTarget(record.target);
|
|
3202
|
+
assertEcdsaSourceTargetActivations(source.activation, target.activation);
|
|
3203
|
+
return {
|
|
3204
|
+
linkSessionId: parseSessionId(record.linkSessionId),
|
|
3205
|
+
enrollmentId: parseEnrollmentId(record.enrollmentId),
|
|
3206
|
+
sourceAuthorityId: parseAuthorityId(record.sourceAuthorityId),
|
|
3207
|
+
source,
|
|
3208
|
+
target
|
|
3209
|
+
};
|
|
3630
3210
|
}
|
|
3631
|
-
function
|
|
3632
|
-
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3637
|
-
|
|
3638
|
-
|
|
3639
|
-
if (bytes.length === 0 || base64UrlEncode(bytes) !== raw) {
|
|
3640
|
-
return { ok: false, error: invalid(field, "must be canonical unpadded base64url") };
|
|
3641
|
-
}
|
|
3642
|
-
} catch {
|
|
3643
|
-
return { ok: false, error: invalid(field, "must be canonical unpadded base64url") };
|
|
3211
|
+
function parseLinkedDeviceEcdsaSourceContributionPackageV1(raw) {
|
|
3212
|
+
const record = exactRecord2(raw, ["binding", "encryptedDelta", "encryptedTargetClientShare"], "linked-device ECDSA source contribution package");
|
|
3213
|
+
const binding = parseLinkedDeviceEcdsaSourceContributionBindingV1(record.binding);
|
|
3214
|
+
const encryptedDelta = parseLinkedDeviceEcdsaEncryptedSourceContributionV1(record.encryptedDelta, "encryptedDelta");
|
|
3215
|
+
const encryptedTargetClientShare = parseLinkedDeviceEcdsaEncryptedSourceContributionV1(record.encryptedTargetClientShare, "encryptedTargetClientShare");
|
|
3216
|
+
const bindingDigest = encryptedDelta.bindingDigestB64u;
|
|
3217
|
+
if (encryptedTargetClientShare.bindingDigestB64u !== bindingDigest) {
|
|
3218
|
+
throw new Error("linked-device ECDSA source contribution envelope bindings differ");
|
|
3644
3219
|
}
|
|
3645
|
-
|
|
3646
|
-
|
|
3647
|
-
function parseDigest(raw, field, brand) {
|
|
3648
|
-
if (raw === undefined || raw === null)
|
|
3649
|
-
return { ok: false, error: missing(field) };
|
|
3650
|
-
try {
|
|
3651
|
-
return { ok: true, value: brand(parseDigestB64u(raw)) };
|
|
3652
|
-
} catch {
|
|
3653
|
-
return { ok: false, error: invalid(field, "must be canonical base64url for 32 bytes") };
|
|
3220
|
+
if (encryptedDelta.recipientPublicKeyB64u !== binding.target.signingWorkerRecipientPublicKeyB64u || encryptedTargetClientShare.recipientPublicKeyB64u !== binding.target.clientRecipientPublicKeyB64u) {
|
|
3221
|
+
throw new Error("linked-device ECDSA source contribution envelope recipients differ");
|
|
3654
3222
|
}
|
|
3223
|
+
return { binding, encryptedDelta, encryptedTargetClientShare };
|
|
3655
3224
|
}
|
|
3656
|
-
function
|
|
3657
|
-
|
|
3658
|
-
|
|
3659
|
-
|
|
3660
|
-
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3669
|
-
return parseIdentityId(raw, "signingWorkerParticipantId");
|
|
3670
|
-
}
|
|
3671
|
-
function parseSigningWorkerRecipientKeyId(raw) {
|
|
3672
|
-
return parseIdentityId(raw, "signingWorkerRecipientKeyId");
|
|
3673
|
-
}
|
|
3674
|
-
function parseLaneHolderCustodyBindingId(raw) {
|
|
3675
|
-
return parseIdentityId(raw, "laneHolderCustodyBindingId");
|
|
3676
|
-
}
|
|
3677
|
-
function parseHpkePublicKeyB64u(raw) {
|
|
3678
|
-
return parseHpkePublicKey(raw, "hpkePublicKeyB64u");
|
|
3679
|
-
}
|
|
3680
|
-
function parseLaneParticipantBindingDigestB64u(raw) {
|
|
3681
|
-
return parseDigest(raw, "participantBindingDigestB64u", brandParticipantDigest);
|
|
3682
|
-
}
|
|
3683
|
-
function parseLaneCustodyBindingDigestB64u(raw) {
|
|
3684
|
-
return parseDigest(raw, "custodyBindingDigestB64u", brandLaneCustodyDigest);
|
|
3225
|
+
function parseLinkedDeviceEcdsaSourceContributionBindingV1(raw) {
|
|
3226
|
+
const record = exactRecord2(raw, ["linkSessionId", "enrollmentId", "sourceAuthorityId", "source", "target", "targetClientPublicKey33B64u"], "linked-device ECDSA source contribution binding");
|
|
3227
|
+
const source = parseEcdsaSourceSigner(record.source);
|
|
3228
|
+
const target = parseEcdsaTarget(record.target);
|
|
3229
|
+
assertEcdsaSourceTargetActivations(source.activation, target.activation);
|
|
3230
|
+
return {
|
|
3231
|
+
linkSessionId: requireText(record.linkSessionId, "binding.linkSessionId"),
|
|
3232
|
+
enrollmentId: requireText(record.enrollmentId, "binding.enrollmentId"),
|
|
3233
|
+
sourceAuthorityId: requireText(record.sourceAuthorityId, "binding.sourceAuthorityId"),
|
|
3234
|
+
source,
|
|
3235
|
+
target,
|
|
3236
|
+
targetClientPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.targetClientPublicKey33B64u, "binding.targetClientPublicKey33B64u")
|
|
3237
|
+
};
|
|
3685
3238
|
}
|
|
3686
|
-
function
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
|
|
3693
|
-
|
|
3694
|
-
|
|
3695
|
-
|
|
3696
|
-
|
|
3697
|
-
|
|
3698
|
-
|
|
3699
|
-
|
|
3700
|
-
|
|
3701
|
-
];
|
|
3702
|
-
function parseWalletSignerId(raw, label = "walletSignerId") {
|
|
3703
|
-
if (typeof raw !== "string")
|
|
3704
|
-
throw new Error(`${label} must be a string`);
|
|
3705
|
-
const value = raw.trim();
|
|
3706
|
-
if (!value)
|
|
3707
|
-
throw new Error(`${label} is required`);
|
|
3708
|
-
if (hasWhitespaceOrControlCharacters(value)) {
|
|
3709
|
-
throw new Error(`${label} must not contain whitespace or control characters`);
|
|
3710
|
-
}
|
|
3711
|
-
return value;
|
|
3712
|
-
}
|
|
3713
|
-
function parseParticipantId(raw, label) {
|
|
3714
|
-
if (typeof raw !== "number" || !Number.isSafeInteger(raw) || raw <= 0) {
|
|
3715
|
-
throw new Error(`${label} must be a positive safe integer`);
|
|
3716
|
-
}
|
|
3717
|
-
return raw;
|
|
3718
|
-
}
|
|
3719
|
-
function parseParticipantIds(raw, label) {
|
|
3720
|
-
if (!Array.isArray(raw) || raw.length !== 2) {
|
|
3721
|
-
throw new Error(`${label} must contain exactly two participant ids`);
|
|
3722
|
-
}
|
|
3723
|
-
const first = parseParticipantId(raw[0], `${label}[0]`);
|
|
3724
|
-
const second = parseParticipantId(raw[1], `${label}[1]`);
|
|
3725
|
-
if (first === second)
|
|
3726
|
-
throw new Error(`${label} must contain distinct participant ids`);
|
|
3727
|
-
return [first, second];
|
|
3728
|
-
}
|
|
3729
|
-
function buildOwnerLaneParticipantContinuityV1(args) {
|
|
3730
|
-
const participantIds = parseParticipantIds(args.participantIds, "participantIds");
|
|
3731
|
-
return {
|
|
3732
|
-
kind: "owner_lane_participant_continuity_v1",
|
|
3733
|
-
signerId: parseWalletSignerId(args.signerId),
|
|
3734
|
-
participantIds,
|
|
3735
|
-
signingWorkerId: requireParsed(parseMpcSigningWorkerRef(args.signingWorkerId), "signingWorkerId"),
|
|
3736
|
-
custodyKeyManifestDigestB64u: parseDigestField(args.custodyKeyManifestDigestB64u, "custodyKeyManifestDigestB64u"),
|
|
3737
|
-
sourceIdentityDigestB64u: parseDigestField(args.sourceIdentityDigestB64u, "sourceIdentityDigestB64u")
|
|
3738
|
-
};
|
|
3739
|
-
}
|
|
3740
|
-
function parseOwnerLaneParticipantContinuityV1(raw, label = "ownerParticipantContinuity") {
|
|
3741
|
-
const record = requireRecord(raw, label);
|
|
3742
|
-
rejectUnknownFields(record, OWNER_LANE_PARTICIPANT_CONTINUITY_FIELDS, label);
|
|
3743
|
-
if (record.kind !== "owner_lane_participant_continuity_v1") {
|
|
3744
|
-
throw new Error(`${label}.kind must be owner_lane_participant_continuity_v1`);
|
|
3745
|
-
}
|
|
3746
|
-
return buildOwnerLaneParticipantContinuityV1({
|
|
3747
|
-
signerId: parseWalletSignerId(record.signerId, `${label}.signerId`),
|
|
3748
|
-
participantIds: parseParticipantIds(record.participantIds, `${label}.participantIds`),
|
|
3749
|
-
signingWorkerId: requireParsed(parseMpcSigningWorkerRef(record.signingWorkerId), `${label}.signingWorkerId`),
|
|
3750
|
-
custodyKeyManifestDigestB64u: parseDigestField(record.custodyKeyManifestDigestB64u, `${label}.custodyKeyManifestDigestB64u`),
|
|
3751
|
-
sourceIdentityDigestB64u: parseDigestField(record.sourceIdentityDigestB64u, `${label}.sourceIdentityDigestB64u`)
|
|
3752
|
-
});
|
|
3753
|
-
}
|
|
3754
|
-
|
|
3755
|
-
// ../shared-ts/src/signing-lanes/rotationWireFields.ts
|
|
3756
|
-
function requiredString(raw, label) {
|
|
3757
|
-
if (typeof raw !== "string")
|
|
3758
|
-
throw new Error(`${label} must be a string`);
|
|
3759
|
-
const value = raw.trim();
|
|
3760
|
-
if (!value)
|
|
3761
|
-
throw new Error(`${label} is required`);
|
|
3762
|
-
if (hasWhitespaceOrControlCharacters(value)) {
|
|
3763
|
-
throw new Error(`${label} must not contain whitespace or control characters`);
|
|
3764
|
-
}
|
|
3765
|
-
return value;
|
|
3766
|
-
}
|
|
3767
|
-
function requiredInteger(raw, label) {
|
|
3768
|
-
if (!Number.isSafeInteger(raw) || Number(raw) < 0) {
|
|
3769
|
-
throw new Error(`${label} must be a non-negative safe integer`);
|
|
3770
|
-
}
|
|
3771
|
-
return Number(raw);
|
|
3772
|
-
}
|
|
3773
|
-
function parseLaneKind(raw, label) {
|
|
3774
|
-
switch (raw) {
|
|
3775
|
-
case "owner_passkey":
|
|
3776
|
-
case "owner_email_otp":
|
|
3777
|
-
case "linked_device":
|
|
3778
|
-
case "delegated_execution":
|
|
3779
|
-
case "recovery":
|
|
3780
|
-
case "break_glass":
|
|
3781
|
-
return raw;
|
|
3782
|
-
default:
|
|
3783
|
-
throw new Error(`${label} must be a known signing lane kind`);
|
|
3784
|
-
}
|
|
3785
|
-
}
|
|
3786
|
-
var laneOperationId = /* @__PURE__ */ wireResult(parseLaneOperationId);
|
|
3787
|
-
var laneEnrollmentId = /* @__PURE__ */ wireResult(parseLaneEnrollmentId);
|
|
3788
|
-
var walletId2 = /* @__PURE__ */ wireResult(parseWalletId);
|
|
3789
|
-
var walletKeyId = /* @__PURE__ */ wireResult(parseWalletKeyId);
|
|
3790
|
-
var signingLaneId = /* @__PURE__ */ wireResult(parseSigningLaneId);
|
|
3791
|
-
var laneShareEpoch = /* @__PURE__ */ wireResult(parseLaneShareEpoch);
|
|
3792
|
-
var materialActivationId = /* @__PURE__ */ wireResult(parseMpcMaterialActivationId);
|
|
3793
|
-
var materialActivation2 = /* @__PURE__ */ wireResult(parseMpcMaterialActivationRef);
|
|
3794
|
-
var laneParticipantBindingDigest = /* @__PURE__ */ wireResult(parseLaneParticipantBindingDigestB64u);
|
|
3795
|
-
var digest2 = /* @__PURE__ */ wireLabeled(parseDigestB64u);
|
|
3796
|
-
var digestString = digest2;
|
|
3797
|
-
var authorizedOperationId = /* @__PURE__ */ wireResult(parseAuthorizedOperationId);
|
|
3798
|
-
function laneOperationAuthorizationBindingV1() {
|
|
3799
|
-
return wireUnion("kind", [
|
|
3800
|
-
wireObject({
|
|
3801
|
-
kind: wireLiteral("linked_device_enrollment"),
|
|
3802
|
-
authorizedOperationId,
|
|
3803
|
-
linkedDeviceEnrollmentId: wireResult(parseLinkedDeviceEnrollmentId),
|
|
3804
|
-
linkedDevicePermissionDigestB64u: digestString
|
|
3805
|
-
}),
|
|
3806
|
-
wireObject({
|
|
3807
|
-
kind: wireLiteral("owner_lane_refresh"),
|
|
3808
|
-
authorizedOperationId,
|
|
3809
|
-
ownerLaneRefreshDigestB64u: digestString
|
|
3810
|
-
})
|
|
3811
|
-
]);
|
|
3812
|
-
}
|
|
3813
|
-
function parseAuthorization(raw, label) {
|
|
3814
|
-
return laneOperationAuthorizationBindingV1()(raw, label);
|
|
3815
|
-
}
|
|
3816
|
-
|
|
3817
|
-
// ../shared-ts/src/signing-lanes/rotationProtocolParsers.ts
|
|
3818
|
-
function opaqueJson(raw, label) {
|
|
3819
|
-
if (typeof raw !== "string" || raw.length === 0) {
|
|
3820
|
-
throw new Error(`${label} must be a non-empty JSON string`);
|
|
3821
|
-
}
|
|
3822
|
-
try {
|
|
3823
|
-
const parsed = JSON.parse(raw);
|
|
3824
|
-
if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
|
|
3825
|
-
throw new Error("top-level value must be an object");
|
|
3826
|
-
}
|
|
3827
|
-
} catch (error) {
|
|
3828
|
-
throw new Error(`${label} must contain valid object JSON: ${error instanceof Error ? error.message : "invalid JSON"}`);
|
|
3829
|
-
}
|
|
3830
|
-
return raw;
|
|
3831
|
-
}
|
|
3832
|
-
var hpkePublicKey = /* @__PURE__ */ wireResult(parseHpkePublicKeyB64u);
|
|
3833
|
-
var hpkePublicKeyDigest = /* @__PURE__ */ wireResult(parseSigningWorkerRecipientKeyDigestB64u);
|
|
3834
|
-
var signingWorkerRecipientKeyId = /* @__PURE__ */ wireResult(parseSigningWorkerRecipientKeyId);
|
|
3835
|
-
var laneHolderParticipantId = /* @__PURE__ */ wireResult(parseLaneHolderParticipantId);
|
|
3836
|
-
var signingWorkerParticipantId = /* @__PURE__ */ wireResult(parseSigningWorkerParticipantId);
|
|
3837
|
-
var laneOperationIdempotencyKey = /* @__PURE__ */ wireResult(parseLaneOperationIdempotencyKey);
|
|
3838
|
-
var ed25519YaoSuiteId = /* @__PURE__ */ wireResult(parseEd25519YaoSuiteId);
|
|
3839
|
-
var compressedPointString = (raw) => parseSecp256k1CompressedPublicKeyB64u(raw);
|
|
3840
|
-
function sourceKind(expected) {
|
|
3841
|
-
return (raw, label) => {
|
|
3842
|
-
if (raw !== expected)
|
|
3843
|
-
throw new Error(`${label} must be ${expected}`);
|
|
3844
|
-
return expected;
|
|
3845
|
-
};
|
|
3846
|
-
}
|
|
3847
|
-
var participantBindingDigestString = laneParticipantBindingDigest;
|
|
3848
|
-
function ownerLaneProtocolSourceV1() {
|
|
3849
|
-
return wireObject({
|
|
3850
|
-
sourceKind: sourceKind("owner_registration"),
|
|
3851
|
-
laneId: signingLaneId,
|
|
3852
|
-
laneKind: wireLiteral("owner_passkey", "owner_email_otp"),
|
|
3853
|
-
laneShareEpoch,
|
|
3854
|
-
revocationEpoch: requiredInteger,
|
|
3855
|
-
ownerParticipantContinuity: parseOwnerLaneParticipantContinuityV1,
|
|
3856
|
-
participantBindingDigestB64u: participantBindingDigestString,
|
|
3857
|
-
materialActivation: materialActivation2
|
|
3858
|
-
});
|
|
3859
|
-
}
|
|
3860
|
-
function provisionedLaneProtocolSourceV1() {
|
|
3861
|
-
return wireObject({
|
|
3862
|
-
sourceKind: sourceKind("provisioned_lane"),
|
|
3863
|
-
laneId: signingLaneId,
|
|
3864
|
-
laneKind: wireLiteral("linked_device", "delegated_execution", "recovery", "break_glass"),
|
|
3865
|
-
laneShareEpoch,
|
|
3866
|
-
revocationEpoch: requiredInteger,
|
|
3867
|
-
holderParticipantId: laneHolderParticipantId,
|
|
3868
|
-
signingWorkerParticipantId,
|
|
3869
|
-
signingWorkerRecipientKeyId,
|
|
3870
|
-
participantBindingDigestB64u: participantBindingDigestString,
|
|
3871
|
-
materialActivation: materialActivation2
|
|
3872
|
-
});
|
|
3873
|
-
}
|
|
3874
|
-
function parseSource(raw, label) {
|
|
3875
|
-
const record = requireRecord(raw, label);
|
|
3876
|
-
const laneKind = parseLaneKind(record.laneKind, `${label}.laneKind`);
|
|
3877
|
-
return laneKind === "owner_passkey" || laneKind === "owner_email_otp" ? ownerLaneProtocolSourceV1()(record, label) : provisionedLaneProtocolSourceV1()(record, label);
|
|
3878
|
-
}
|
|
3879
|
-
function laneTargetHolderV1() {
|
|
3880
|
-
return wireObject({
|
|
3881
|
-
participantId: laneHolderParticipantId,
|
|
3882
|
-
participantBindingDigestB64u: laneParticipantBindingDigest,
|
|
3883
|
-
custodyBindingId: wireResult(parseLaneHolderCustodyBindingId),
|
|
3884
|
-
custodyBindingDigestB64u: wireResult(parseLaneCustodyBindingDigestB64u),
|
|
3885
|
-
hpkePublicKeyB64u: hpkePublicKey,
|
|
3886
|
-
hpkePublicKeyDigestB64u: hpkePublicKeyDigest
|
|
3887
|
-
});
|
|
3888
|
-
}
|
|
3889
|
-
function laneTargetSigningWorkerV1() {
|
|
3890
|
-
return wireObject({
|
|
3891
|
-
participantId: signingWorkerParticipantId,
|
|
3892
|
-
participantBindingDigestB64u: laneParticipantBindingDigest,
|
|
3893
|
-
recipientKeyId: signingWorkerRecipientKeyId,
|
|
3894
|
-
hpkePublicKeyB64u: hpkePublicKey,
|
|
3895
|
-
hpkePublicKeyDigestB64u: hpkePublicKeyDigest
|
|
3896
|
-
});
|
|
3897
|
-
}
|
|
3898
|
-
function buildLaneCreationTargetV1(args) {
|
|
3899
|
-
return {
|
|
3900
|
-
operation: "create_lane",
|
|
3901
|
-
laneId: args.laneId,
|
|
3902
|
-
laneKind: "linked_device",
|
|
3903
|
-
laneShareEpoch: args.laneShareEpoch,
|
|
3904
|
-
expectedTargetState: "absent"
|
|
3905
|
-
};
|
|
3906
|
-
}
|
|
3907
|
-
function buildLaneRefreshTargetV1(args) {
|
|
3908
|
-
return {
|
|
3909
|
-
operation: "refresh_lane",
|
|
3910
|
-
laneId: args.laneId,
|
|
3911
|
-
laneKind: args.laneKind,
|
|
3912
|
-
laneShareEpoch: args.laneShareEpoch,
|
|
3913
|
-
expectedTargetState: "active_previous_epoch",
|
|
3914
|
-
priorMaterialActivation: args.priorMaterialActivation
|
|
3915
|
-
};
|
|
3916
|
-
}
|
|
3917
|
-
function parseTarget(raw, source, label) {
|
|
3918
|
-
const record = requireRecord(raw, label);
|
|
3919
|
-
if (record.operation === "create_lane") {
|
|
3920
|
-
const value = exactRecord(record, ["operation", "laneId", "laneKind", "laneShareEpoch", "expectedTargetState"], label);
|
|
3921
|
-
if (value.laneKind !== "linked_device" || value.expectedTargetState !== "absent") {
|
|
3922
|
-
throw new Error(`${label} create branch has invalid target state`);
|
|
3923
|
-
}
|
|
3924
|
-
const target = buildLaneCreationTargetV1({
|
|
3925
|
-
laneId: signingLaneId(value.laneId, `${label}.laneId`),
|
|
3926
|
-
laneShareEpoch: laneShareEpoch(value.laneShareEpoch, `${label}.laneShareEpoch`)
|
|
3927
|
-
});
|
|
3928
|
-
if (source.laneKind === "linked_device" || source.laneKind === "delegated_execution") {
|
|
3929
|
-
throw new Error(`${label} creation requires an owner-controlled source lane`);
|
|
3930
|
-
}
|
|
3931
|
-
if (String(target.laneId) === String(source.laneId)) {
|
|
3932
|
-
throw new Error(`${label}.laneId must differ from source.laneId for creation`);
|
|
3933
|
-
}
|
|
3934
|
-
return target;
|
|
3935
|
-
}
|
|
3936
|
-
if (record.operation === "refresh_lane") {
|
|
3937
|
-
const value = exactRecord(record, [
|
|
3938
|
-
"operation",
|
|
3939
|
-
"laneId",
|
|
3940
|
-
"laneKind",
|
|
3941
|
-
"laneShareEpoch",
|
|
3942
|
-
"expectedTargetState",
|
|
3943
|
-
"priorMaterialActivation"
|
|
3944
|
-
], label);
|
|
3945
|
-
if (value.expectedTargetState !== "active_previous_epoch") {
|
|
3946
|
-
throw new Error(`${label} refresh branch has invalid target state`);
|
|
3947
|
-
}
|
|
3948
|
-
const laneId = signingLaneId(value.laneId, `${label}.laneId`);
|
|
3949
|
-
if (String(laneId) !== String(source.laneId)) {
|
|
3950
|
-
throw new Error(`${label}.laneId must match source.laneId for refresh`);
|
|
3951
|
-
}
|
|
3952
|
-
const shareEpoch = laneShareEpoch(value.laneShareEpoch, `${label}.laneShareEpoch`);
|
|
3953
|
-
if (String(shareEpoch) === String(source.laneShareEpoch)) {
|
|
3954
|
-
throw new Error(`${label}.laneShareEpoch must advance source.laneShareEpoch`);
|
|
3955
|
-
}
|
|
3956
|
-
const laneKind = parseLaneKind(value.laneKind, `${label}.laneKind`);
|
|
3957
|
-
if (laneKind !== source.laneKind) {
|
|
3958
|
-
throw new Error(`${label}.laneKind must match source.laneKind for refresh`);
|
|
3959
|
-
}
|
|
3960
|
-
if (laneKind !== "delegated_execution") {
|
|
3961
|
-
return buildLaneRefreshTargetV1({
|
|
3962
|
-
laneId,
|
|
3963
|
-
laneKind,
|
|
3964
|
-
laneShareEpoch: shareEpoch,
|
|
3965
|
-
priorMaterialActivation: materialActivation2(value.priorMaterialActivation, `${label}.priorMaterialActivation`)
|
|
3966
|
-
});
|
|
3967
|
-
}
|
|
3968
|
-
}
|
|
3969
|
-
throw new Error(`${label}.operation is invalid`);
|
|
3970
|
-
}
|
|
3971
|
-
function parseOperation(rawTarget, rawAuthorization, source, label) {
|
|
3972
|
-
const target = parseTarget(rawTarget, source, `${label}.target`);
|
|
3973
|
-
const authorization = parseAuthorization(rawAuthorization, `${label}.authorization`);
|
|
3974
|
-
if (target.operation === "create_lane") {
|
|
3975
|
-
if (authorization.kind !== "linked_device_enrollment") {
|
|
3976
|
-
throw new Error(`${label}.authorization must be linked-device enrollment for creation`);
|
|
3977
|
-
}
|
|
3978
|
-
return { target, authorization };
|
|
3979
|
-
}
|
|
3980
|
-
if (authorization.kind !== "owner_lane_refresh") {
|
|
3981
|
-
throw new Error(`${label}.authorization must be owner refresh for refresh`);
|
|
3982
|
-
}
|
|
3983
|
-
return { target, authorization };
|
|
3984
|
-
}
|
|
3985
|
-
function isParsedCreationOperation(value) {
|
|
3986
|
-
return value.target.operation === "create_lane";
|
|
3987
|
-
}
|
|
3988
|
-
function parseCommonJob(record, label) {
|
|
3989
|
-
const source = parseSource(record.source, `${label}.source`);
|
|
3990
|
-
const targetHolder = laneTargetHolderV1()(record.targetHolder, `${label}.targetHolder`);
|
|
3991
|
-
const targetSigningWorker = laneTargetSigningWorkerV1()(record.targetSigningWorker, `${label}.targetSigningWorker`);
|
|
3992
|
-
const targetMaterialActivationId = materialActivationId(record.targetMaterialActivationId, `${label}.targetMaterialActivationId`);
|
|
3993
|
-
if (String(targetMaterialActivationId) === String(source.materialActivation.activationId)) {
|
|
3994
|
-
throw new Error(`${label}.targetMaterialActivationId must be fresh`);
|
|
3995
|
-
}
|
|
3996
|
-
if (record.protocolVersion !== "rotatable_signing_lane_protocol_v1") {
|
|
3997
|
-
throw new Error(`${label}.protocolVersion is invalid`);
|
|
3998
|
-
}
|
|
3999
|
-
return {
|
|
4000
|
-
operationId: laneOperationId(record.operationId, `${label}.operationId`),
|
|
4001
|
-
enrollmentId: laneEnrollmentId(record.enrollmentId, `${label}.enrollmentId`),
|
|
4002
|
-
idempotencyKey: laneOperationIdempotencyKey(record.idempotencyKey, `${label}.idempotencyKey`),
|
|
4003
|
-
walletId: walletId2(record.walletId, `${label}.walletId`),
|
|
4004
|
-
walletKeyId: walletKeyId(record.walletKeyId, `${label}.walletKeyId`),
|
|
4005
|
-
source,
|
|
4006
|
-
targetHolder,
|
|
4007
|
-
targetSigningWorker,
|
|
4008
|
-
targetMaterialActivationId,
|
|
4009
|
-
protocolVersion: "rotatable_signing_lane_protocol_v1",
|
|
4010
|
-
expiresAtMs: requiredInteger(record.expiresAtMs, `${label}.expiresAtMs`)
|
|
4011
|
-
};
|
|
4012
|
-
}
|
|
4013
|
-
function ecdsaSourceCapabilityBindingV1() {
|
|
4014
|
-
return wireObject({
|
|
4015
|
-
manifestId: parseEcdsaCapabilityManifestId,
|
|
4016
|
-
manifestRevision: parseEcdsaCapabilityManifestRevision,
|
|
4017
|
-
serverGeneration: parseEcdsaServerGeneration,
|
|
4018
|
-
ecdsaThresholdKeyId: parseSdkEcdsaDerivationThresholdKeyId,
|
|
4019
|
-
relayerKeyId: wireResult(parseEcdsaRelayerKeyId)
|
|
4020
|
-
});
|
|
4021
|
-
}
|
|
4022
|
-
function thresholdEcdsaChainTarget() {
|
|
4023
|
-
return wireUnion("kind", [
|
|
4024
|
-
wireObject({
|
|
4025
|
-
kind: wireLiteral("evm"),
|
|
4026
|
-
namespace: wireLiteral("eip155"),
|
|
4027
|
-
chainId: requiredInteger,
|
|
4028
|
-
networkSlug: requiredString
|
|
4029
|
-
}),
|
|
4030
|
-
wireObject({
|
|
4031
|
-
kind: wireLiteral("tempo"),
|
|
4032
|
-
chainId: requiredInteger,
|
|
4033
|
-
networkSlug: requiredString
|
|
4034
|
-
})
|
|
4035
|
-
]);
|
|
4036
|
-
}
|
|
4037
|
-
function ecdsaTargetCapabilityBindingV1() {
|
|
4038
|
-
return wireObject({
|
|
4039
|
-
manifestId: parseEcdsaCapabilityManifestId,
|
|
4040
|
-
manifestRevision: parseEcdsaCapabilityManifestRevision,
|
|
4041
|
-
ecdsaThresholdKeyId: parseSdkEcdsaDerivationThresholdKeyId,
|
|
4042
|
-
orderedThresholdSessions: wireNonEmptyArray(wireObject({
|
|
4043
|
-
chainTarget: thresholdEcdsaChainTarget(),
|
|
4044
|
-
thresholdSessionId: wireResult(parseThresholdEcdsaSessionId),
|
|
4045
|
-
participantBindingDigestB64u: digestString
|
|
4046
|
-
}))
|
|
4047
|
-
});
|
|
4048
|
-
}
|
|
4049
|
-
var LANE_JOB_FIELDS = [
|
|
4050
|
-
"kind",
|
|
4051
|
-
"keyFamily",
|
|
4052
|
-
"operationId",
|
|
4053
|
-
"enrollmentId",
|
|
4054
|
-
"idempotencyKey",
|
|
4055
|
-
"walletId",
|
|
4056
|
-
"walletKeyId",
|
|
4057
|
-
"source",
|
|
4058
|
-
"targetHolder",
|
|
4059
|
-
"targetSigningWorker",
|
|
4060
|
-
"targetMaterialActivationId",
|
|
4061
|
-
"protocolVersion",
|
|
4062
|
-
"expiresAtMs",
|
|
4063
|
-
"target",
|
|
4064
|
-
"authorization"
|
|
4065
|
-
];
|
|
4066
|
-
function parseEcdsaJob(record, label) {
|
|
4067
|
-
const value = exactRecord(record, [
|
|
4068
|
-
...LANE_JOB_FIELDS,
|
|
4069
|
-
"evmFamilySigningKeySlotId",
|
|
4070
|
-
"thresholdPublicKey33B64u",
|
|
4071
|
-
"evmAddress",
|
|
4072
|
-
"sourceCapability",
|
|
4073
|
-
"targetCapability",
|
|
4074
|
-
"sourceHolderVerifyingShare33B64u",
|
|
4075
|
-
"sourceServerVerifyingShare33B64u",
|
|
4076
|
-
"reshareChannelBindingDigestB64u",
|
|
4077
|
-
"transcriptEncoding"
|
|
4078
|
-
], label);
|
|
4079
|
-
if (value.kind !== "ecdsa_additive_lane_job_v1" || value.keyFamily !== "ecdsa_secp256k1") {
|
|
4080
|
-
throw new Error(`${label} kind/keyFamily is invalid`);
|
|
4081
|
-
}
|
|
4082
|
-
if (value.transcriptEncoding !== "ecdsa_additive_lane_transcript_v1") {
|
|
4083
|
-
throw new Error(`${label}.transcriptEncoding is invalid`);
|
|
4084
|
-
}
|
|
4085
|
-
const common = parseCommonJob(value, label);
|
|
4086
|
-
const operation = parseOperation(value.target, value.authorization, common.source, `${label}.operation`);
|
|
4087
|
-
const curve = {
|
|
4088
|
-
kind: "ecdsa_additive_lane_job_v1",
|
|
4089
|
-
keyFamily: "ecdsa_secp256k1",
|
|
4090
|
-
evmFamilySigningKeySlotId: (() => {
|
|
4091
|
-
const parsed = parseEvmFamilySigningKeySlotId(value.evmFamilySigningKeySlotId);
|
|
4092
|
-
if (parsed.ok)
|
|
4093
|
-
return parsed.value;
|
|
4094
|
-
throw new Error(`${label}.evmFamilySigningKeySlotId is invalid`);
|
|
4095
|
-
})(),
|
|
4096
|
-
thresholdPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(value.thresholdPublicKey33B64u),
|
|
4097
|
-
evmAddress: requiredString(value.evmAddress, `${label}.evmAddress`),
|
|
4098
|
-
sourceCapability: ecdsaSourceCapabilityBindingV1()(value.sourceCapability, `${label}.sourceCapability`),
|
|
4099
|
-
targetCapability: ecdsaTargetCapabilityBindingV1()(value.targetCapability, `${label}.targetCapability`),
|
|
4100
|
-
sourceHolderVerifyingShare33B64u: parseSecp256k1CompressedPublicKeyB64u(value.sourceHolderVerifyingShare33B64u, `${label}.sourceHolderVerifyingShare33B64u`),
|
|
4101
|
-
sourceServerVerifyingShare33B64u: parseSecp256k1CompressedPublicKeyB64u(value.sourceServerVerifyingShare33B64u, `${label}.sourceServerVerifyingShare33B64u`),
|
|
4102
|
-
reshareChannelBindingDigestB64u: digest2(value.reshareChannelBindingDigestB64u, `${label}.reshareChannelBindingDigestB64u`),
|
|
4103
|
-
transcriptEncoding: "ecdsa_additive_lane_transcript_v1"
|
|
4104
|
-
};
|
|
4105
|
-
return { ...common, ...operation, ...curve };
|
|
4106
|
-
}
|
|
4107
|
-
function parseEdJob(record, label) {
|
|
4108
|
-
const value = exactRecord(record, [
|
|
4109
|
-
...LANE_JOB_FIELDS,
|
|
4110
|
-
"yaoRequestKind",
|
|
4111
|
-
"registeredPublicKeyB64u",
|
|
4112
|
-
"nearEd25519SigningKeyId",
|
|
4113
|
-
"keyCreationSignerSlot",
|
|
4114
|
-
"stableContextBindingB64u",
|
|
4115
|
-
"yaoSuiteId",
|
|
4116
|
-
"circuitDigestB64u"
|
|
4117
|
-
], label);
|
|
4118
|
-
if (value.kind !== "ed25519_yao_lane_job_v1" || value.keyFamily !== "ed25519") {
|
|
4119
|
-
throw new Error(`${label} kind/keyFamily is invalid`);
|
|
4120
|
-
}
|
|
4121
|
-
const common = parseCommonJob(value, label);
|
|
4122
|
-
const operation = parseOperation(value.target, value.authorization, common.source, `${label}.operation`);
|
|
4123
|
-
const yaoRequestKind = requiredString(value.yaoRequestKind, `${label}.yaoRequestKind`);
|
|
4124
|
-
const curve = {
|
|
4125
|
-
kind: "ed25519_yao_lane_job_v1",
|
|
4126
|
-
keyFamily: "ed25519",
|
|
4127
|
-
registeredPublicKeyB64u: parseEd25519PublicKeyB64u(value.registeredPublicKeyB64u),
|
|
4128
|
-
nearEd25519SigningKeyId: parseNearEd25519SigningKeyId(value.nearEd25519SigningKeyId),
|
|
4129
|
-
keyCreationSignerSlot: parseKeyCreationSignerSlot(value.keyCreationSignerSlot),
|
|
4130
|
-
stableContextBindingB64u: digest2(value.stableContextBindingB64u, `${label}.stableContextBindingB64u`),
|
|
4131
|
-
yaoSuiteId: ed25519YaoSuiteId(value.yaoSuiteId, `${label}.yaoSuiteId`),
|
|
4132
|
-
circuitDigestB64u: digest2(value.circuitDigestB64u, `${label}.circuitDigestB64u`)
|
|
4133
|
-
};
|
|
4134
|
-
if (isParsedCreationOperation(operation)) {
|
|
4135
|
-
if (yaoRequestKind !== "lane_provisioning")
|
|
4136
|
-
throw new Error(`${label}.yaoRequestKind must be lane_provisioning for creation`);
|
|
4137
|
-
return { ...common, ...operation, yaoRequestKind, ...curve };
|
|
4138
|
-
}
|
|
4139
|
-
if (yaoRequestKind !== "lane_refresh")
|
|
4140
|
-
throw new Error(`${label}.yaoRequestKind must be lane_refresh for refresh`);
|
|
4141
|
-
return { ...common, ...operation, yaoRequestKind, ...curve };
|
|
4142
|
-
}
|
|
4143
|
-
function parseRotatableSigningLaneJobV1(raw, label = "laneProtocolJob") {
|
|
4144
|
-
const record = requireRecord(raw, label);
|
|
4145
|
-
if (record.kind === "ed25519_yao_lane_job_v1")
|
|
4146
|
-
return parseEdJob(record, label);
|
|
4147
|
-
if (record.kind === "ecdsa_additive_lane_job_v1")
|
|
4148
|
-
return parseEcdsaJob(record, label);
|
|
4149
|
-
throw new Error(`${label}.kind is invalid`);
|
|
4150
|
-
}
|
|
4151
|
-
function laneHolderPackageWireV1() {
|
|
4152
|
-
return wireUnion("kind", [
|
|
4153
|
-
wireObject({
|
|
4154
|
-
kind: wireLiteral("ed25519_yao_lane_holder_package_set_v1"),
|
|
4155
|
-
deriverAEncryptedPackageJson: opaqueJson,
|
|
4156
|
-
deriverBEncryptedPackageJson: opaqueJson
|
|
4157
|
-
}),
|
|
4158
|
-
wireObject({
|
|
4159
|
-
kind: wireLiteral("ecdsa_additive_lane_holder_package_v1"),
|
|
4160
|
-
ecdsaEncryptedMaterialEnvelopeJson: opaqueJson
|
|
4161
|
-
})
|
|
4162
|
-
]);
|
|
4163
|
-
}
|
|
4164
|
-
function parseLaneHolderPackageWireV1(raw, label = "laneHolderPackage") {
|
|
4165
|
-
return laneHolderPackageWireV1()(raw, label);
|
|
4166
|
-
}
|
|
4167
|
-
function ecdsaAdditiveLaneHolderRoundV1() {
|
|
4168
|
-
return wireObject({
|
|
4169
|
-
kind: wireLiteral("ecdsa_additive_lane_holder_round_v1"),
|
|
4170
|
-
preambleHashB64u: digestString,
|
|
4171
|
-
targetHolderPublicCommitment33B64u: compressedPointString,
|
|
4172
|
-
encryptedDeltaCiphertextDigestB64u: digestString,
|
|
4173
|
-
sealedTargetHolderMaterialDigestB64u: digestString,
|
|
4174
|
-
holderAttestationB64u: requiredString,
|
|
4175
|
-
holderCommittedAtMs: requiredInteger
|
|
4176
|
-
});
|
|
4177
|
-
}
|
|
4178
|
-
function parseEcdsaAdditiveLaneHolderRoundV1(raw, label = "ecdsaHolderRound") {
|
|
4179
|
-
return ecdsaAdditiveLaneHolderRoundV1()(raw, label);
|
|
4180
|
-
}
|
|
4181
|
-
|
|
4182
|
-
// ../shared-ts/src/utils/routerAbEd25519YaoDigests.ts
|
|
4183
|
-
var UTF8 = new TextEncoder;
|
|
4184
|
-
|
|
4185
|
-
// ../shared-ts/src/utils/routerAbEd25519Yao.ts
|
|
4186
|
-
var ED25519_YAO_CONTROL_CIPHERTEXT_MAX_BYTES_V1 = 64 * 1024;
|
|
4187
|
-
|
|
4188
|
-
// ../shared-ts/src/device-linking/sourceContribution.ts
|
|
4189
|
-
var LINKED_DEVICE_ECDSA_SOURCE_CONTRIBUTION_ENVELOPE_KIND_V1 = "seams/linked-device/ecdsa-source-contribution-envelope/v1";
|
|
4190
|
-
function parseLinkedDeviceEcdsaSourceContributionPreparationV1(raw) {
|
|
4191
|
-
const record = exactRecord2(raw, [
|
|
4192
|
-
"linkSessionId",
|
|
4193
|
-
"enrollmentId",
|
|
4194
|
-
"sourceAuthorityId",
|
|
4195
|
-
"source",
|
|
4196
|
-
"target"
|
|
4197
|
-
], "linked-device ECDSA source contribution preparation");
|
|
4198
|
-
const source = parseEcdsaSourceSigner(record.source);
|
|
4199
|
-
const target = parseEcdsaTarget(record.target);
|
|
4200
|
-
assertEcdsaSourceTargetActivations(source.activation, target.activation);
|
|
4201
|
-
return {
|
|
4202
|
-
linkSessionId: parseSessionId(record.linkSessionId),
|
|
4203
|
-
enrollmentId: parseEnrollmentId(record.enrollmentId),
|
|
4204
|
-
sourceAuthorityId: parseAuthorityId(record.sourceAuthorityId),
|
|
4205
|
-
source,
|
|
4206
|
-
target
|
|
4207
|
-
};
|
|
4208
|
-
}
|
|
4209
|
-
function parseLinkedDeviceEcdsaSourceContributionPackageV1(raw) {
|
|
4210
|
-
const record = exactRecord2(raw, ["binding", "encryptedDelta", "encryptedTargetClientShare"], "linked-device ECDSA source contribution package");
|
|
4211
|
-
const binding = parseLinkedDeviceEcdsaSourceContributionBindingV1(record.binding);
|
|
4212
|
-
const encryptedDelta = parseLinkedDeviceEcdsaEncryptedSourceContributionV1(record.encryptedDelta, "encryptedDelta");
|
|
4213
|
-
const encryptedTargetClientShare = parseLinkedDeviceEcdsaEncryptedSourceContributionV1(record.encryptedTargetClientShare, "encryptedTargetClientShare");
|
|
4214
|
-
const bindingDigest = encryptedDelta.bindingDigestB64u;
|
|
4215
|
-
if (encryptedTargetClientShare.bindingDigestB64u !== bindingDigest) {
|
|
4216
|
-
throw new Error("linked-device ECDSA source contribution envelope bindings differ");
|
|
4217
|
-
}
|
|
4218
|
-
if (encryptedDelta.recipientPublicKeyB64u !== binding.target.signingWorkerRecipientPublicKeyB64u || encryptedTargetClientShare.recipientPublicKeyB64u !== binding.target.clientRecipientPublicKeyB64u) {
|
|
4219
|
-
throw new Error("linked-device ECDSA source contribution envelope recipients differ");
|
|
4220
|
-
}
|
|
4221
|
-
return { binding, encryptedDelta, encryptedTargetClientShare };
|
|
4222
|
-
}
|
|
4223
|
-
function parseLinkedDeviceEcdsaSourceContributionBindingV1(raw) {
|
|
4224
|
-
const record = exactRecord2(raw, ["linkSessionId", "enrollmentId", "sourceAuthorityId", "source", "target", "targetClientPublicKey33B64u"], "linked-device ECDSA source contribution binding");
|
|
4225
|
-
const source = parseEcdsaSourceSigner(record.source);
|
|
4226
|
-
const target = parseEcdsaTarget(record.target);
|
|
4227
|
-
assertEcdsaSourceTargetActivations(source.activation, target.activation);
|
|
4228
|
-
return {
|
|
4229
|
-
linkSessionId: requireText(record.linkSessionId, "binding.linkSessionId"),
|
|
4230
|
-
enrollmentId: requireText(record.enrollmentId, "binding.enrollmentId"),
|
|
4231
|
-
sourceAuthorityId: requireText(record.sourceAuthorityId, "binding.sourceAuthorityId"),
|
|
4232
|
-
source,
|
|
4233
|
-
target,
|
|
4234
|
-
targetClientPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.targetClientPublicKey33B64u, "binding.targetClientPublicKey33B64u")
|
|
4235
|
-
};
|
|
4236
|
-
}
|
|
4237
|
-
function parseEcdsaSourceSigner(raw) {
|
|
4238
|
-
const record = exactRecord2(raw, [
|
|
4239
|
-
"activation",
|
|
4240
|
-
"clientPublicKey33B64u",
|
|
4241
|
-
"relayerPublicKey33B64u",
|
|
4242
|
-
"thresholdPublicKey33B64u",
|
|
4243
|
-
"thresholdEthereumAddress20B64u"
|
|
4244
|
-
], "linked-device ECDSA source signer");
|
|
4245
|
-
return {
|
|
4246
|
-
activation: parseActivation(record.activation, "source.activation"),
|
|
4247
|
-
clientPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.clientPublicKey33B64u, "source.clientPublicKey33B64u"),
|
|
4248
|
-
relayerPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.relayerPublicKey33B64u, "source.relayerPublicKey33B64u"),
|
|
4249
|
-
thresholdPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.thresholdPublicKey33B64u, "source.thresholdPublicKey33B64u"),
|
|
4250
|
-
thresholdEthereumAddress20B64u: parseFixedBase64(record.thresholdEthereumAddress20B64u, 20, "source.thresholdEthereumAddress20B64u")
|
|
4251
|
-
};
|
|
3239
|
+
function parseEcdsaSourceSigner(raw) {
|
|
3240
|
+
const record = exactRecord2(raw, [
|
|
3241
|
+
"activation",
|
|
3242
|
+
"clientPublicKey33B64u",
|
|
3243
|
+
"relayerPublicKey33B64u",
|
|
3244
|
+
"thresholdPublicKey33B64u",
|
|
3245
|
+
"thresholdEthereumAddress20B64u"
|
|
3246
|
+
], "linked-device ECDSA source signer");
|
|
3247
|
+
return {
|
|
3248
|
+
activation: parseActivation(record.activation, "source.activation"),
|
|
3249
|
+
clientPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.clientPublicKey33B64u, "source.clientPublicKey33B64u"),
|
|
3250
|
+
relayerPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.relayerPublicKey33B64u, "source.relayerPublicKey33B64u"),
|
|
3251
|
+
thresholdPublicKey33B64u: parseSecp256k1CompressedPublicKeyB64u(record.thresholdPublicKey33B64u, "source.thresholdPublicKey33B64u"),
|
|
3252
|
+
thresholdEthereumAddress20B64u: parseFixedBase64(record.thresholdEthereumAddress20B64u, 20, "source.thresholdEthereumAddress20B64u")
|
|
3253
|
+
};
|
|
4252
3254
|
}
|
|
4253
3255
|
function parseEcdsaTarget(raw) {
|
|
4254
3256
|
const record = exactRecord2(raw, [
|
|
@@ -4366,31 +3368,6 @@ var EcdsaClientWorkerControlKind = {
|
|
|
4366
3368
|
AttachLinkedHolderToPresign: "attach_linked_holder_to_ecdsa_presign_v1",
|
|
4367
3369
|
AttachPresignToOnline: "attach_ecdsa_presign_to_online_v1"
|
|
4368
3370
|
};
|
|
4369
|
-
function parsePrepareEcdsaAdditiveLaneHolderRequestV1(raw) {
|
|
4370
|
-
if (!isObject(raw) || Array.isArray(raw)) {
|
|
4371
|
-
throw new Error("ECDSA lane holder request must be an object");
|
|
4372
|
-
}
|
|
4373
|
-
const fields = Object.keys(raw);
|
|
4374
|
-
if (fields.length !== 3 || !fields.includes("kind") || !fields.includes("job") || !fields.includes("holderCommittedAtMs")) {
|
|
4375
|
-
throw new Error("ECDSA lane holder request has invalid fields");
|
|
4376
|
-
}
|
|
4377
|
-
if (raw.kind !== "prepare_ecdsa_additive_lane_holder_v1") {
|
|
4378
|
-
throw new Error("ECDSA lane holder request kind is invalid");
|
|
4379
|
-
}
|
|
4380
|
-
const job = parseRotatableSigningLaneJobV1(raw.job, "ecdsaLaneHolderRequest.job");
|
|
4381
|
-
if (job.keyFamily !== "ecdsa_secp256k1") {
|
|
4382
|
-
throw new Error("ECDSA lane holder request requires an ECDSA lane job");
|
|
4383
|
-
}
|
|
4384
|
-
const holderCommittedAtMs = raw.holderCommittedAtMs;
|
|
4385
|
-
if (typeof holderCommittedAtMs !== "number" || !Number.isSafeInteger(holderCommittedAtMs) || holderCommittedAtMs < 0) {
|
|
4386
|
-
throw new Error("ECDSA lane holder request holderCommittedAtMs is invalid");
|
|
4387
|
-
}
|
|
4388
|
-
return {
|
|
4389
|
-
kind: "prepare_ecdsa_additive_lane_holder_v1",
|
|
4390
|
-
job,
|
|
4391
|
-
holderCommittedAtMs
|
|
4392
|
-
};
|
|
4393
|
-
}
|
|
4394
3371
|
function parsePrepareLinkedDeviceEcdsaSourceContributionRequestV1(raw) {
|
|
4395
3372
|
if (!isObject(raw) || Array.isArray(raw)) {
|
|
4396
3373
|
throw new Error("linked-device ECDSA source contribution request must be an object");
|
|
@@ -4774,67 +3751,6 @@ function isAttachLinkedHolderToPresignPort(value) {
|
|
|
4774
3751
|
return parsed?.kind === EcdsaClientWorkerControlKind.AttachLinkedHolderToPresign && parsed.port instanceof MessagePort;
|
|
4775
3752
|
}
|
|
4776
3753
|
|
|
4777
|
-
// src/core/signingEngine/threshold/crypto/ecdsaLaneWasm.ts
|
|
4778
|
-
function nonEmpty(value, label) {
|
|
4779
|
-
if (typeof value !== "string" || !value.trim())
|
|
4780
|
-
throw new Error(`${label} is required`);
|
|
4781
|
-
return value;
|
|
4782
|
-
}
|
|
4783
|
-
function parseEcdsaAdditiveLaneHolderPreparationV1(value) {
|
|
4784
|
-
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
4785
|
-
throw new Error("ECDSA holder preparation must be an object");
|
|
4786
|
-
}
|
|
4787
|
-
const allowed = new Set(["kind", "holderRound", "holderPackage", "encryptedDeltaPackageJson"]);
|
|
4788
|
-
for (const key of Object.keys(value)) {
|
|
4789
|
-
if (!allowed.has(key))
|
|
4790
|
-
throw new Error(`ECDSA holder preparation.${key} is not allowed`);
|
|
4791
|
-
}
|
|
4792
|
-
const kind = Reflect.get(value, "kind");
|
|
4793
|
-
if (kind !== "ecdsa_additive_lane_holder_preparation_v1") {
|
|
4794
|
-
throw new Error("ECDSA holder preparation kind is invalid");
|
|
4795
|
-
}
|
|
4796
|
-
const holderPackage = parseLaneHolderPackageWireV1(Reflect.get(value, "holderPackage"));
|
|
4797
|
-
if (holderPackage.kind !== "ecdsa_additive_lane_holder_package_v1") {
|
|
4798
|
-
throw new Error("ECDSA holder preparation returned the wrong package family");
|
|
4799
|
-
}
|
|
4800
|
-
return {
|
|
4801
|
-
kind,
|
|
4802
|
-
holderRound: parseEcdsaAdditiveLaneHolderRoundV1(Reflect.get(value, "holderRound")),
|
|
4803
|
-
holderPackage,
|
|
4804
|
-
encryptedDeltaPackageJson: nonEmpty(Reflect.get(value, "encryptedDeltaPackageJson"), "encryptedDeltaPackageJson")
|
|
4805
|
-
};
|
|
4806
|
-
}
|
|
4807
|
-
|
|
4808
|
-
// src/core/signingEngine/workerManager/workers/ecdsaLaneHolderWorkerRuntime.ts
|
|
4809
|
-
function resolveExactEcdsaLaneSourceMaterialV1(request, candidates) {
|
|
4810
|
-
const matches = [];
|
|
4811
|
-
for (const candidate of candidates) {
|
|
4812
|
-
if (mpcMaterialActivationRefsEqual(candidate.materialActivation, request.job.source.materialActivation)) {
|
|
4813
|
-
matches.push(candidate);
|
|
4814
|
-
}
|
|
4815
|
-
}
|
|
4816
|
-
if (matches.length === 0) {
|
|
4817
|
-
throw new Error("ECDSA lane source material is not loaded for the exact activation");
|
|
4818
|
-
}
|
|
4819
|
-
if (matches.length !== 1) {
|
|
4820
|
-
throw new Error("ECDSA lane source activation resolves to multiple loaded materials");
|
|
4821
|
-
}
|
|
4822
|
-
return matches[0];
|
|
4823
|
-
}
|
|
4824
|
-
function prepareEcdsaLaneHolderInWorkerV1(args) {
|
|
4825
|
-
const source = resolveExactEcdsaLaneSourceMaterialV1(args.request, args.candidates);
|
|
4826
|
-
const session = args.sessionFactory.create(source.stateBlobB64u);
|
|
4827
|
-
try {
|
|
4828
|
-
const output = JSON.parse(session.prepare(JSON.stringify({
|
|
4829
|
-
job: args.request.job,
|
|
4830
|
-
holderCommittedAtMs: args.request.holderCommittedAtMs
|
|
4831
|
-
})));
|
|
4832
|
-
return parseEcdsaAdditiveLaneHolderPreparationV1(output);
|
|
4833
|
-
} finally {
|
|
4834
|
-
session.free();
|
|
4835
|
-
}
|
|
4836
|
-
}
|
|
4837
|
-
|
|
4838
3754
|
// src/core/platform/signerCoreCommandAdapters.ts
|
|
4839
3755
|
function requireBase64UrlBytes(value, field, byteLength) {
|
|
4840
3756
|
const normalized = String(value || "").trim();
|
|
@@ -5182,7 +4098,7 @@ var WALLET_AUTH_METHODS = {
|
|
|
5182
4098
|
var WALLET_AUTH_METHOD_VALUES = Object.values(WALLET_AUTH_METHODS);
|
|
5183
4099
|
|
|
5184
4100
|
// ../shared-ts/src/utils/thresholdEcdsaKeyHandle.ts
|
|
5185
|
-
function
|
|
4101
|
+
function requiredString(value, field) {
|
|
5186
4102
|
const normalized = String(value ?? "").trim();
|
|
5187
4103
|
if (!normalized)
|
|
5188
4104
|
throw new Error(`[threshold-ecdsa-key-handle] ${field} is required`);
|
|
@@ -5194,17 +4110,17 @@ function normalizedSigningRootVersion(value) {
|
|
|
5194
4110
|
async function deriveThresholdEcdsaKeyHandle(input) {
|
|
5195
4111
|
const canonical = alphabetizeStringify({
|
|
5196
4112
|
domain: "seams.threshold_ecdsa.key_handle.v1",
|
|
5197
|
-
ecdsaThresholdKeyId:
|
|
5198
|
-
signingRootId:
|
|
4113
|
+
ecdsaThresholdKeyId: requiredString(input.ecdsaThresholdKeyId, "ecdsaThresholdKeyId"),
|
|
4114
|
+
signingRootId: requiredString(input.signingRootId, "signingRootId"),
|
|
5199
4115
|
signingRootVersion: normalizedSigningRootVersion(input.signingRootVersion)
|
|
5200
4116
|
});
|
|
5201
4117
|
const digest = await sha256BytesUtf8(canonical);
|
|
5202
4118
|
return `ederivation-key-${base64UrlEncode(digest)}`;
|
|
5203
4119
|
}
|
|
5204
|
-
// ../shared-ts/src/
|
|
5205
|
-
var
|
|
4120
|
+
// ../shared-ts/src/utils/digestEncoding.ts
|
|
4121
|
+
var TEXT_ENCODER = new TextEncoder;
|
|
5206
4122
|
// src/core/signingEngine/session/identity/evmFamilyEcdsaIdentity.ts
|
|
5207
|
-
function
|
|
4123
|
+
function requiredString2(value, field) {
|
|
5208
4124
|
const normalized = String(value ?? "").trim();
|
|
5209
4125
|
if (!normalized)
|
|
5210
4126
|
throw new Error(`[evm-family-ecdsa] ${field} is required`);
|
|
@@ -5218,10 +4134,10 @@ function normalizeThresholdOwnerAddress(value) {
|
|
|
5218
4134
|
return normalized;
|
|
5219
4135
|
}
|
|
5220
4136
|
function toEvmFamilyEcdsaKeyHandle(value) {
|
|
5221
|
-
return
|
|
4137
|
+
return requiredString2(value, "keyHandle");
|
|
5222
4138
|
}
|
|
5223
4139
|
function toThresholdEcdsaPublicKeyB64u(value) {
|
|
5224
|
-
const normalized =
|
|
4140
|
+
const normalized = requiredString2(value, "thresholdEcdsaPublicKeyB64u");
|
|
5225
4141
|
let bytes;
|
|
5226
4142
|
try {
|
|
5227
4143
|
bytes = base64UrlDecode(normalized);
|
|
@@ -5268,1605 +4184,1584 @@ function toEcdsaDerivationSigningRootVersion(value) {
|
|
|
5268
4184
|
return parseSdkEcdsaDerivationSigningRootVersion(value);
|
|
5269
4185
|
}
|
|
5270
4186
|
|
|
5271
|
-
//
|
|
5272
|
-
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5276
|
-
return
|
|
5277
|
-
IDBDatabase,
|
|
5278
|
-
IDBObjectStore,
|
|
5279
|
-
IDBIndex,
|
|
5280
|
-
IDBCursor,
|
|
5281
|
-
IDBTransaction
|
|
5282
|
-
]);
|
|
4187
|
+
// src/core/signingEngine/session/persistence/ecdsaRoleLocalRecords.ts
|
|
4188
|
+
function requiredString3(value, field) {
|
|
4189
|
+
if (typeof value !== "string" || !value.trim()) {
|
|
4190
|
+
throw new Error(`[platform][ecdsa-role-local] ${field} is required`);
|
|
4191
|
+
}
|
|
4192
|
+
return value.trim();
|
|
5283
4193
|
}
|
|
5284
|
-
function
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5288
|
-
|
|
5289
|
-
|
|
4194
|
+
function parseBase64UrlBytes(value, field, byteLength) {
|
|
4195
|
+
const normalized = requiredString3(value, field);
|
|
4196
|
+
const decoded = base64UrlDecode(normalized);
|
|
4197
|
+
if (decoded.length !== byteLength) {
|
|
4198
|
+
throw new Error(`[platform][ecdsa-role-local] ${field} must decode to ${byteLength} bytes`);
|
|
4199
|
+
}
|
|
4200
|
+
return normalized;
|
|
5290
4201
|
}
|
|
5291
|
-
|
|
5292
|
-
|
|
5293
|
-
|
|
5294
|
-
|
|
5295
|
-
|
|
5296
|
-
|
|
5297
|
-
|
|
5298
|
-
|
|
5299
|
-
|
|
5300
|
-
|
|
5301
|
-
resolve(wrap(request.result));
|
|
5302
|
-
unlisten();
|
|
5303
|
-
};
|
|
5304
|
-
const error = () => {
|
|
5305
|
-
reject(request.error);
|
|
5306
|
-
unlisten();
|
|
5307
|
-
};
|
|
5308
|
-
request.addEventListener("success", success);
|
|
5309
|
-
request.addEventListener("error", error);
|
|
5310
|
-
});
|
|
5311
|
-
reverseTransformCache.set(promise, request);
|
|
5312
|
-
return promise;
|
|
4202
|
+
function parseCompressedSecp256k1PublicKey(value, field) {
|
|
4203
|
+
const normalized = requiredString3(value, field);
|
|
4204
|
+
const decoded = base64UrlDecode(normalized);
|
|
4205
|
+
if (decoded.length !== 33) {
|
|
4206
|
+
throw new Error(`[platform][ecdsa-role-local] ${field} must decode to 33 bytes`);
|
|
4207
|
+
}
|
|
4208
|
+
if (decoded[0] !== 2 && decoded[0] !== 3) {
|
|
4209
|
+
throw new Error(`[platform][ecdsa-role-local] ${field} must be a compressed SEC1 key`);
|
|
4210
|
+
}
|
|
4211
|
+
return normalized;
|
|
5313
4212
|
}
|
|
5314
|
-
function
|
|
5315
|
-
|
|
5316
|
-
return;
|
|
5317
|
-
const done = new Promise((resolve, reject) => {
|
|
5318
|
-
const unlisten = () => {
|
|
5319
|
-
tx.removeEventListener("complete", complete);
|
|
5320
|
-
tx.removeEventListener("error", error);
|
|
5321
|
-
tx.removeEventListener("abort", error);
|
|
5322
|
-
};
|
|
5323
|
-
const complete = () => {
|
|
5324
|
-
resolve();
|
|
5325
|
-
unlisten();
|
|
5326
|
-
};
|
|
5327
|
-
const error = () => {
|
|
5328
|
-
reject(tx.error || new DOMException("AbortError", "AbortError"));
|
|
5329
|
-
unlisten();
|
|
5330
|
-
};
|
|
5331
|
-
tx.addEventListener("complete", complete);
|
|
5332
|
-
tx.addEventListener("error", error);
|
|
5333
|
-
tx.addEventListener("abort", error);
|
|
5334
|
-
});
|
|
5335
|
-
transactionDoneMap.set(tx, done);
|
|
4213
|
+
function parseEcdsaDerivationClientSharePublicKey(value) {
|
|
4214
|
+
return parseCompressedSecp256k1PublicKey(value, "derivationClientSharePublicKey33B64u");
|
|
5336
4215
|
}
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
4216
|
+
function parseRelayerEcdsaDerivationPublicKey(value) {
|
|
4217
|
+
return parseCompressedSecp256k1PublicKey(value, "relayerPublicKey33B64u");
|
|
4218
|
+
}
|
|
4219
|
+
function parseGroupPublicKey(value) {
|
|
4220
|
+
return parseCompressedSecp256k1PublicKey(value, "groupPublicKey33B64u");
|
|
4221
|
+
}
|
|
4222
|
+
function parseEthereumAddress2(value) {
|
|
4223
|
+
const normalized = requiredString3(value, "ethereumAddress").toLowerCase();
|
|
4224
|
+
if (!/^0x[0-9a-f]{40}$/.test(normalized)) {
|
|
4225
|
+
throw new Error("[platform][ecdsa-role-local] ethereumAddress must be an EVM address");
|
|
4226
|
+
}
|
|
4227
|
+
return normalized;
|
|
4228
|
+
}
|
|
4229
|
+
function parseParticipantIds(value) {
|
|
4230
|
+
if (!Array.isArray(value) || value.length !== 2 || value[0] !== 1 || value[1] !== 2) {
|
|
4231
|
+
throw new Error("[platform][ecdsa-role-local] participantIds must be [1, 2]");
|
|
4232
|
+
}
|
|
4233
|
+
return [1, 2];
|
|
4234
|
+
}
|
|
4235
|
+
function parseChainTarget(input) {
|
|
4236
|
+
if (input === null || typeof input !== "object" || Array.isArray(input)) {
|
|
4237
|
+
throw new Error("[platform][ecdsa-role-local] chainTarget must be an object");
|
|
4238
|
+
}
|
|
4239
|
+
const kind = requiredString3(Reflect.get(input, "kind"), "chainTarget.kind").toLowerCase();
|
|
4240
|
+
switch (kind) {
|
|
4241
|
+
case "evm": {
|
|
4242
|
+
const fields = Object.keys(input).sort();
|
|
4243
|
+
if (fields.join(",") !== "chainId,kind,namespace,networkSlug") {
|
|
4244
|
+
throw new Error("[platform][ecdsa-role-local] EVM chainTarget fields are invalid");
|
|
5344
4245
|
}
|
|
4246
|
+
return thresholdEcdsaChainTargetFromRequest({
|
|
4247
|
+
kind: Reflect.get(input, "kind"),
|
|
4248
|
+
namespace: Reflect.get(input, "namespace"),
|
|
4249
|
+
chainId: Reflect.get(input, "chainId"),
|
|
4250
|
+
networkSlug: Reflect.get(input, "networkSlug")
|
|
4251
|
+
});
|
|
5345
4252
|
}
|
|
5346
|
-
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
|
|
5353
|
-
|
|
5354
|
-
|
|
4253
|
+
case "tempo": {
|
|
4254
|
+
const fields = Object.keys(input).sort();
|
|
4255
|
+
if (fields.join(",") !== "chainId,kind,networkSlug") {
|
|
4256
|
+
throw new Error("[platform][ecdsa-role-local] Tempo chainTarget fields are invalid");
|
|
4257
|
+
}
|
|
4258
|
+
return thresholdEcdsaChainTargetFromRequest({
|
|
4259
|
+
kind: Reflect.get(input, "kind"),
|
|
4260
|
+
chainId: Reflect.get(input, "chainId"),
|
|
4261
|
+
networkSlug: Reflect.get(input, "networkSlug")
|
|
4262
|
+
});
|
|
5355
4263
|
}
|
|
5356
|
-
|
|
4264
|
+
default:
|
|
4265
|
+
throw new Error("[platform][ecdsa-role-local] chainTarget kind is invalid");
|
|
5357
4266
|
}
|
|
5358
|
-
};
|
|
5359
|
-
function replaceTraps(callback) {
|
|
5360
|
-
idbProxyTraps = callback(idbProxyTraps);
|
|
5361
4267
|
}
|
|
5362
|
-
function
|
|
5363
|
-
if (
|
|
5364
|
-
|
|
5365
|
-
func.apply(unwrap(this), args);
|
|
5366
|
-
return wrap(this.request);
|
|
5367
|
-
};
|
|
4268
|
+
function parsePublicFacts(input) {
|
|
4269
|
+
if (input === null || typeof input !== "object" || Array.isArray(input)) {
|
|
4270
|
+
throw new Error("[platform][ecdsa-role-local] publicFacts must be an object");
|
|
5368
4271
|
}
|
|
5369
|
-
|
|
5370
|
-
|
|
4272
|
+
const fields = Object.keys(input).sort();
|
|
4273
|
+
if (fields.join(",") !== "applicationBindingDigestB64u,chainTarget,clientParticipantId,contextBinding32B64u,derivationClientSharePublicKey33B64u,ecdsaThresholdKeyId,ethereumAddress,groupPublicKey33B64u,keyHandle,participantIds,publicCapability,relayerParticipantId,relayerPublicKey33B64u,signingRootId,signingRootVersion,walletId") {
|
|
4274
|
+
throw new Error("[platform][ecdsa-role-local] publicFacts fields are invalid");
|
|
4275
|
+
}
|
|
4276
|
+
if (Reflect.get(input, "clientParticipantId") !== 1) {
|
|
4277
|
+
throw new Error("[platform][ecdsa-role-local] clientParticipantId must be 1");
|
|
4278
|
+
}
|
|
4279
|
+
if (Reflect.get(input, "relayerParticipantId") !== 2) {
|
|
4280
|
+
throw new Error("[platform][ecdsa-role-local] relayerParticipantId must be 2");
|
|
4281
|
+
}
|
|
4282
|
+
const derivationClientSharePublicKey33B64u = parseEcdsaDerivationClientSharePublicKey(Reflect.get(input, "derivationClientSharePublicKey33B64u"));
|
|
4283
|
+
const relayerPublicKey33B64u = parseRelayerEcdsaDerivationPublicKey(Reflect.get(input, "relayerPublicKey33B64u"));
|
|
4284
|
+
if (String(derivationClientSharePublicKey33B64u) === String(relayerPublicKey33B64u)) {
|
|
4285
|
+
throw new Error("[platform][ecdsa-role-local] relayerPublicKey33B64u must differ from derivationClientSharePublicKey33B64u");
|
|
4286
|
+
}
|
|
4287
|
+
return {
|
|
4288
|
+
walletId: toWalletId(Reflect.get(input, "walletId")),
|
|
4289
|
+
chainTarget: parseChainTarget(Reflect.get(input, "chainTarget")),
|
|
4290
|
+
keyHandle: requiredString3(Reflect.get(input, "keyHandle"), "keyHandle"),
|
|
4291
|
+
ecdsaThresholdKeyId: toEcdsaDerivationThresholdKeyId(Reflect.get(input, "ecdsaThresholdKeyId")),
|
|
4292
|
+
signingRootId: toEcdsaDerivationSigningRootId(Reflect.get(input, "signingRootId")),
|
|
4293
|
+
signingRootVersion: toEcdsaDerivationSigningRootVersion(Reflect.get(input, "signingRootVersion")),
|
|
4294
|
+
applicationBindingDigestB64u: parseBase64UrlBytes(Reflect.get(input, "applicationBindingDigestB64u"), "applicationBindingDigestB64u", 32),
|
|
4295
|
+
clientParticipantId: 1,
|
|
4296
|
+
relayerParticipantId: 2,
|
|
4297
|
+
participantIds: parseParticipantIds(Reflect.get(input, "participantIds")),
|
|
4298
|
+
contextBinding32B64u: parseBase64UrlBytes(Reflect.get(input, "contextBinding32B64u"), "contextBinding32B64u", 32),
|
|
4299
|
+
derivationClientSharePublicKey33B64u,
|
|
4300
|
+
relayerPublicKey33B64u,
|
|
4301
|
+
groupPublicKey33B64u: parseGroupPublicKey(Reflect.get(input, "groupPublicKey33B64u")),
|
|
4302
|
+
ethereumAddress: parseEthereumAddress2(Reflect.get(input, "ethereumAddress")),
|
|
4303
|
+
publicCapability: parseRouterAbEcdsaDerivationPublicCapabilityV1(Reflect.get(input, "publicCapability"))
|
|
5371
4304
|
};
|
|
5372
4305
|
}
|
|
5373
|
-
function
|
|
5374
|
-
|
|
5375
|
-
return wrapFunction(value);
|
|
5376
|
-
if (value instanceof IDBTransaction)
|
|
5377
|
-
cacheDonePromiseForTransaction(value);
|
|
5378
|
-
if (instanceOfAny(value, getIdbProxyableTypes()))
|
|
5379
|
-
return new Proxy(value, idbProxyTraps);
|
|
5380
|
-
return value;
|
|
4306
|
+
function buildEcdsaRoleLocalPublicFacts(input) {
|
|
4307
|
+
return parsePublicFacts(input);
|
|
5381
4308
|
}
|
|
5382
|
-
|
|
5383
|
-
|
|
5384
|
-
|
|
5385
|
-
|
|
5386
|
-
return
|
|
5387
|
-
|
|
5388
|
-
|
|
5389
|
-
|
|
5390
|
-
reverseTransformCache.set(newValue, value);
|
|
4309
|
+
|
|
4310
|
+
// src/core/signingEngine/session/material/ecdsaCapabilityManifest.ts
|
|
4311
|
+
class EcdsaCapabilityManifestProof {
|
|
4312
|
+
retainProof() {
|
|
4313
|
+
return true;
|
|
4314
|
+
}
|
|
4315
|
+
constructor() {
|
|
4316
|
+
this.retainProof();
|
|
5391
4317
|
}
|
|
5392
|
-
return newValue;
|
|
5393
4318
|
}
|
|
5394
|
-
|
|
5395
|
-
|
|
5396
|
-
|
|
5397
|
-
|
|
5398
|
-
|
|
5399
|
-
|
|
5400
|
-
upgrade(wrap(request.result), event.oldVersion, event.newVersion, wrap(request.transaction), event);
|
|
5401
|
-
});
|
|
4319
|
+
|
|
4320
|
+
class EcdsaCapabilityScopeProof extends EcdsaCapabilityManifestProof {
|
|
4321
|
+
constructor(targetMemberships) {
|
|
4322
|
+
super();
|
|
4323
|
+
this.kind = "evm_family";
|
|
4324
|
+
this.targetMemberships = targetMemberships;
|
|
5402
4325
|
}
|
|
5403
|
-
|
|
5404
|
-
|
|
4326
|
+
}
|
|
4327
|
+
|
|
4328
|
+
class EcdsaManifestIdentityProof extends EcdsaCapabilityManifestProof {
|
|
4329
|
+
constructor(fields) {
|
|
4330
|
+
super();
|
|
4331
|
+
this.manifestId = fields.manifestId;
|
|
4332
|
+
this.manifestRevision = fields.manifestRevision;
|
|
5405
4333
|
}
|
|
5406
|
-
openPromise.then((db) => {
|
|
5407
|
-
if (terminated)
|
|
5408
|
-
db.addEventListener("close", () => terminated());
|
|
5409
|
-
if (blocking) {
|
|
5410
|
-
db.addEventListener("versionchange", (event) => blocking(event.oldVersion, event.newVersion, event));
|
|
5411
|
-
}
|
|
5412
|
-
}).catch(() => {});
|
|
5413
|
-
return openPromise;
|
|
5414
4334
|
}
|
|
5415
|
-
|
|
5416
|
-
|
|
5417
|
-
|
|
5418
|
-
|
|
5419
|
-
|
|
5420
|
-
return;
|
|
4335
|
+
|
|
4336
|
+
class NoCurrentEcdsaManifestExpectationProof extends EcdsaCapabilityManifestProof {
|
|
4337
|
+
constructor() {
|
|
4338
|
+
super(...arguments);
|
|
4339
|
+
this.kind = "no_current_manifest";
|
|
5421
4340
|
}
|
|
5422
|
-
|
|
5423
|
-
|
|
5424
|
-
|
|
5425
|
-
|
|
5426
|
-
|
|
5427
|
-
|
|
5428
|
-
|
|
4341
|
+
}
|
|
4342
|
+
|
|
4343
|
+
class ExactEcdsaManifestExpectationProof extends EcdsaCapabilityManifestProof {
|
|
4344
|
+
constructor(identity) {
|
|
4345
|
+
super();
|
|
4346
|
+
this.kind = "exact_manifest";
|
|
4347
|
+
this.manifestId = identity.manifestId;
|
|
4348
|
+
this.manifestRevision = identity.manifestRevision;
|
|
5429
4349
|
}
|
|
5430
|
-
const method = async function(storeName, ...args) {
|
|
5431
|
-
const tx = this.transaction(storeName, isWrite ? "readwrite" : "readonly");
|
|
5432
|
-
let target = tx.store;
|
|
5433
|
-
if (useIndex)
|
|
5434
|
-
target = target.index(args.shift());
|
|
5435
|
-
return (await Promise.all([
|
|
5436
|
-
target[targetFuncName](...args),
|
|
5437
|
-
isWrite && tx.done
|
|
5438
|
-
]))[0];
|
|
5439
|
-
};
|
|
5440
|
-
cachedMethods.set(prop, method);
|
|
5441
|
-
return method;
|
|
5442
4350
|
}
|
|
5443
|
-
|
|
5444
|
-
|
|
5445
|
-
|
|
5446
|
-
|
|
5447
|
-
|
|
5448
|
-
var advanceMethodProps = ["continue", "continuePrimaryKey", "advance"];
|
|
5449
|
-
var methodMap = {};
|
|
5450
|
-
var advanceResults = new WeakMap;
|
|
5451
|
-
var ittrProxiedCursorToOriginalProxy = new WeakMap;
|
|
5452
|
-
var cursorIteratorTraps = {
|
|
5453
|
-
get(target, prop) {
|
|
5454
|
-
if (!advanceMethodProps.includes(prop))
|
|
5455
|
-
return target[prop];
|
|
5456
|
-
let cachedFunc = methodMap[prop];
|
|
5457
|
-
if (!cachedFunc) {
|
|
5458
|
-
cachedFunc = methodMap[prop] = function(...args) {
|
|
5459
|
-
advanceResults.set(this, ittrProxiedCursorToOriginalProxy.get(this)[prop](...args));
|
|
5460
|
-
};
|
|
5461
|
-
}
|
|
5462
|
-
return cachedFunc;
|
|
4351
|
+
|
|
4352
|
+
class NoCurrentEcdsaServerGenerationExpectationProof extends EcdsaCapabilityManifestProof {
|
|
4353
|
+
constructor() {
|
|
4354
|
+
super(...arguments);
|
|
4355
|
+
this.kind = "no_current_generation";
|
|
5463
4356
|
}
|
|
5464
|
-
}
|
|
5465
|
-
|
|
5466
|
-
|
|
5467
|
-
|
|
5468
|
-
|
|
4357
|
+
}
|
|
4358
|
+
|
|
4359
|
+
class ExactEcdsaServerGenerationExpectationProof extends EcdsaCapabilityManifestProof {
|
|
4360
|
+
constructor(serverGeneration) {
|
|
4361
|
+
super();
|
|
4362
|
+
this.kind = "exact_generation";
|
|
4363
|
+
this.serverGeneration = serverGeneration;
|
|
5469
4364
|
}
|
|
5470
|
-
|
|
5471
|
-
|
|
5472
|
-
|
|
5473
|
-
|
|
5474
|
-
|
|
5475
|
-
|
|
5476
|
-
|
|
5477
|
-
|
|
5478
|
-
|
|
5479
|
-
|
|
4365
|
+
}
|
|
4366
|
+
|
|
4367
|
+
class EcdsaRoleLocalMaterialBindingProof extends EcdsaCapabilityManifestProof {
|
|
4368
|
+
constructor(fields) {
|
|
4369
|
+
super();
|
|
4370
|
+
this.kind = "ecdsa_role_local_material_binding";
|
|
4371
|
+
this.keyHandle = fields.keyHandle;
|
|
4372
|
+
this.ecdsaThresholdKeyId = fields.ecdsaThresholdKeyId;
|
|
4373
|
+
this.clientVerifyingPublicKey33B64u = fields.clientVerifyingPublicKey33B64u;
|
|
4374
|
+
this.participantIds = fields.participantIds;
|
|
4375
|
+
this.relayerKeyId = fields.relayerKeyId;
|
|
5480
4376
|
}
|
|
5481
4377
|
}
|
|
5482
|
-
|
|
5483
|
-
|
|
4378
|
+
|
|
4379
|
+
class PreparedEvmFamilySignerProof extends EcdsaCapabilityManifestProof {
|
|
4380
|
+
constructor(fields) {
|
|
4381
|
+
super();
|
|
4382
|
+
this.kind = "prepared_evm_family_signer";
|
|
4383
|
+
this.capability = fields.capability;
|
|
4384
|
+
this.signerId = fields.signerId;
|
|
4385
|
+
this.walletId = fields.authority.walletId;
|
|
4386
|
+
this.authority = fields.authority;
|
|
4387
|
+
this.scope = fields.scope;
|
|
4388
|
+
this.materialOwner = fields.materialOwner;
|
|
4389
|
+
this.signingRootId = fields.signingRootId;
|
|
4390
|
+
this.signingRootVersion = fields.signingRootVersion;
|
|
4391
|
+
}
|
|
5484
4392
|
}
|
|
5485
|
-
|
|
5486
|
-
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
|
|
5490
|
-
|
|
5491
|
-
|
|
5492
|
-
|
|
5493
|
-
|
|
4393
|
+
|
|
4394
|
+
class RegisteredEvmFamilySignerProof extends EcdsaCapabilityManifestProof {
|
|
4395
|
+
constructor(fields) {
|
|
4396
|
+
super();
|
|
4397
|
+
this.kind = "registered_evm_family_signer";
|
|
4398
|
+
this.capability = fields.preparedSigner.capability;
|
|
4399
|
+
this.signerId = fields.preparedSigner.signerId;
|
|
4400
|
+
this.walletId = fields.preparedSigner.walletId;
|
|
4401
|
+
this.authority = fields.preparedSigner.authority;
|
|
4402
|
+
this.scope = fields.preparedSigner.scope;
|
|
4403
|
+
this.materialOwner = fields.preparedSigner.materialOwner;
|
|
4404
|
+
this.signingRootId = fields.preparedSigner.signingRootId;
|
|
4405
|
+
this.signingRootVersion = fields.preparedSigner.signingRootVersion;
|
|
4406
|
+
this.registeredPublicFacts = fields.registeredPublicFacts;
|
|
5494
4407
|
}
|
|
5495
|
-
}
|
|
4408
|
+
}
|
|
5496
4409
|
|
|
5497
|
-
|
|
5498
|
-
|
|
5499
|
-
|
|
5500
|
-
|
|
5501
|
-
|
|
5502
|
-
|
|
5503
|
-
|
|
5504
|
-
|
|
5505
|
-
walletAuthoritySignerMaterials: "wallet_authority_signer_materials",
|
|
5506
|
-
walletAuthorityExportRoots: "wallet_authority_export_roots",
|
|
5507
|
-
walletAuthorityInstallationReceipts: "wallet_authority_installation_receipts",
|
|
5508
|
-
walletSelections: "wallet_selections",
|
|
5509
|
-
walletSigners: "wallet_signers",
|
|
5510
|
-
nearAccountProjections: "near_accounts",
|
|
5511
|
-
signerOpsOutbox: "signer_ops_outbox",
|
|
5512
|
-
nonceLaneLeases: "nonce_lane_leases",
|
|
5513
|
-
nonceLaneLocks: "nonce_lane_locks",
|
|
5514
|
-
keyMaterial: "key_material",
|
|
5515
|
-
signingSessionSeals: "signing_session_seals",
|
|
5516
|
-
signingSessionRestoreLeases: "signing_session_restore_leases",
|
|
5517
|
-
pendingWalletRecoveryCodeBackups: "email_otp_pending_recovery_code_backups",
|
|
5518
|
-
walletSessionAuthorizations: "wallet_session_authorizations",
|
|
5519
|
-
ecdsaCapabilityManifests: "ecdsa_capability_manifests",
|
|
5520
|
-
ecdsaCurrentCapabilityManifests: "ecdsa_current_capability_manifests",
|
|
5521
|
-
ecdsaRoleLocalMaterial: "ecdsa_role_local_material",
|
|
5522
|
-
ecdsaActivationCommitJournals: "ecdsa_activation_commit_journals",
|
|
5523
|
-
ecdsaMaterialSealingKeys: "ecdsa_material_sealing_keys",
|
|
5524
|
-
ecdsaClientPresignatures: "ecdsa_client_presignatures"
|
|
5525
|
-
};
|
|
5526
|
-
var SEAMS_WALLET_INDEXES = {
|
|
5527
|
-
profileId: "profile_id",
|
|
5528
|
-
credentialId: "credential_id",
|
|
5529
|
-
credentialIdB64u: "credential_id_b64u",
|
|
5530
|
-
profileIdCredentialId: "profile_id_credential_id",
|
|
5531
|
-
profileIdSignerSlot: "profile_id_signer_slot",
|
|
5532
|
-
updatedAt: "updated_at",
|
|
5533
|
-
walletId: "wallet_id",
|
|
5534
|
-
walletIdRpId: "wallet_id_rp_id",
|
|
5535
|
-
walletIdKind: "wallet_id_kind",
|
|
5536
|
-
walletKindNearSignerSlot: "wallet_kind_near_signer_slot",
|
|
5537
|
-
walletKindNearEd25519SigningKeyId: "wallet_kind_near_ed25519_signing_key_id",
|
|
5538
|
-
walletKindChainTargetKeyHandle: "wallet_kind_chain_target_key_handle",
|
|
5539
|
-
walletKindChainTargetKeyFacts: "wallet_kind_chain_target_key_facts",
|
|
5540
|
-
walletSignerId: "wallet_signer_id",
|
|
5541
|
-
nearEd25519SigningKeyId: "near_ed25519_signing_key_id",
|
|
5542
|
-
nearAccountId: "near_account_id",
|
|
5543
|
-
rpId: "rp_id",
|
|
5544
|
-
rpIdCredentialId: "rp_id_credential_id",
|
|
5545
|
-
chainIdKey: "chain_id_key",
|
|
5546
|
-
chainIdKeyAccountAddress: "chain_id_key_account_address",
|
|
5547
|
-
profileIdChainIdKey: "profile_id_chain_id_key",
|
|
5548
|
-
chainIdKeyAccountAddressStatus: "chain_id_key_account_address_status",
|
|
5549
|
-
chainTargetKey: "chain_target_key",
|
|
5550
|
-
keyHandle: "key_handle",
|
|
5551
|
-
thresholdOwnerAddress: "threshold_owner_address",
|
|
5552
|
-
ecdsaThresholdKeyId: "ecdsa_threshold_key_id",
|
|
5553
|
-
status: "status",
|
|
5554
|
-
nextAttemptAt: "next_attempt_at",
|
|
5555
|
-
statusNextAttemptAt: "status_next_attempt_at",
|
|
5556
|
-
idempotencyKey: "idempotency_key",
|
|
5557
|
-
laneKey: "lane_key",
|
|
5558
|
-
accountId: "account_id",
|
|
5559
|
-
state: "state",
|
|
5560
|
-
expiresAtMs: "expires_at_ms",
|
|
5561
|
-
recoveryCodesIssuedAtMs: "recovery_codes_issued_at_ms",
|
|
5562
|
-
laneState: "lane_state",
|
|
5563
|
-
walletExpiresAt: "wallet_expires_at",
|
|
5564
|
-
ownerId: "owner_id",
|
|
5565
|
-
chainIdKeyKeyKind: "chain_id_key_key_kind",
|
|
5566
|
-
publicKey: "public_key",
|
|
5567
|
-
userId: "user_id",
|
|
5568
|
-
authMethod: "auth_method",
|
|
5569
|
-
curve: "curve",
|
|
5570
|
-
signingRootId: "signing_root_id",
|
|
5571
|
-
signingRootVersion: "signing_root_version",
|
|
5572
|
-
walletSigningRootAuthMethod: "wallet_signing_root_auth_method",
|
|
5573
|
-
ed25519ThresholdSessionId: "ed25519_threshold_session_id",
|
|
5574
|
-
ecdsaThresholdSessionId: "ecdsa_threshold_session_id",
|
|
5575
|
-
thresholdSessionId: "threshold_session_id",
|
|
5576
|
-
exactSigningLaneIdentityKey: "exact_signing_lane_identity_key",
|
|
5577
|
-
budgetReservationKey: "budget_reservation_key",
|
|
5578
|
-
authSubjectId: "auth_subject_id",
|
|
5579
|
-
enrollmentId: "enrollment_id",
|
|
5580
|
-
walletIdEnrollmentId: "wallet_id_enrollment_id",
|
|
5581
|
-
walletIdAuthSubjectId: "wallet_id_auth_subject_id",
|
|
5582
|
-
walletIdAuthSubjectIdEnrollmentId: "wallet_id_auth_subject_id_enrollment_id",
|
|
5583
|
-
authIdentifierKey: "auth_identifier_key",
|
|
5584
|
-
kindRpIdAuthIdentifier: "kind_rp_id_auth_identifier",
|
|
5585
|
-
passkeyRpIdCredentialId: "passkey_rp_id_credential_id",
|
|
5586
|
-
capabilityWallet: "capability_wallet",
|
|
5587
|
-
capabilityWalletAuthorityState: "capability_wallet_authority_state",
|
|
5588
|
-
capabilityWalletAuthority: "capability_wallet_authority",
|
|
5589
|
-
walletAuthorityId: "wallet_authority_id",
|
|
5590
|
-
walletAuthMethodId: "wallet_auth_method_id",
|
|
5591
|
-
walletIdAuthorityId: "wallet_id_authority_id",
|
|
5592
|
-
walletIdAuthorityStatus: "wallet_id_authority_status",
|
|
5593
|
-
walletIdAuthMethodId: "wallet_id_auth_method_id",
|
|
5594
|
-
walletAuthorityAuthMethodId: "wallet_authority_auth_method_id",
|
|
5595
|
-
activationId: "activation_id",
|
|
5596
|
-
walletAuthorityActivationId: "wallet_authority_activation_id",
|
|
5597
|
-
walletIdDeviceId: "wallet_id_device_id",
|
|
5598
|
-
packageSetDigest: "package_set_digest",
|
|
5599
|
-
walletKeyId: "wallet_key_id",
|
|
5600
|
-
walletIdLockGeneration: "wallet_id_lock_generation",
|
|
5601
|
-
authorityDigest: "authority_digest",
|
|
5602
|
-
revocationEpoch: "revocation_epoch",
|
|
5603
|
-
poolIdentityKey: "pool_identity_key",
|
|
5604
|
-
walletMaterialActivationId: "wallet_material_activation_id"
|
|
5605
|
-
};
|
|
5606
|
-
var SEAMS_WALLET_SCHEMA_MANIFEST = [
|
|
5607
|
-
{
|
|
5608
|
-
store: SEAMS_WALLET_STORES.appState,
|
|
5609
|
-
keyPath: "key",
|
|
5610
|
-
indexes: []
|
|
5611
|
-
},
|
|
5612
|
-
{
|
|
5613
|
-
store: SEAMS_WALLET_STORES.wallets,
|
|
5614
|
-
keyPath: "wallet_id",
|
|
5615
|
-
indexes: [
|
|
5616
|
-
{ name: SEAMS_WALLET_INDEXES.rpId, keyPath: "rp_id", unique: false },
|
|
5617
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5618
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5619
|
-
]
|
|
5620
|
-
},
|
|
5621
|
-
{
|
|
5622
|
-
store: SEAMS_WALLET_STORES.walletAuthorities,
|
|
5623
|
-
keyPath: "authority_id",
|
|
5624
|
-
indexes: [
|
|
5625
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5626
|
-
{ name: SEAMS_WALLET_INDEXES.walletAuthorityId, keyPath: "authority_id", unique: true },
|
|
5627
|
-
{
|
|
5628
|
-
name: SEAMS_WALLET_INDEXES.walletIdAuthorityId,
|
|
5629
|
-
keyPath: ["wallet_id", "authority_id"],
|
|
5630
|
-
unique: true
|
|
5631
|
-
},
|
|
5632
|
-
{
|
|
5633
|
-
name: SEAMS_WALLET_INDEXES.walletIdAuthorityStatus,
|
|
5634
|
-
keyPath: ["wallet_id", "state"],
|
|
5635
|
-
unique: false
|
|
5636
|
-
},
|
|
5637
|
-
{
|
|
5638
|
-
name: SEAMS_WALLET_INDEXES.walletIdDeviceId,
|
|
5639
|
-
keyPath: ["wallet_id", "device_id"],
|
|
5640
|
-
unique: false
|
|
5641
|
-
},
|
|
5642
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5643
|
-
]
|
|
5644
|
-
},
|
|
5645
|
-
{
|
|
5646
|
-
store: SEAMS_WALLET_STORES.walletAuthMethods,
|
|
5647
|
-
keyPath: "wallet_auth_method_id",
|
|
5648
|
-
indexes: [
|
|
5649
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5650
|
-
{
|
|
5651
|
-
name: SEAMS_WALLET_INDEXES.walletIdKind,
|
|
5652
|
-
keyPath: ["wallet_id", "kind"],
|
|
5653
|
-
unique: false
|
|
5654
|
-
},
|
|
5655
|
-
{ name: SEAMS_WALLET_INDEXES.authMethod, keyPath: "auth_method", unique: false },
|
|
5656
|
-
{ name: SEAMS_WALLET_INDEXES.rpId, keyPath: "rp_id", unique: false },
|
|
5657
|
-
{
|
|
5658
|
-
name: SEAMS_WALLET_INDEXES.authIdentifierKey,
|
|
5659
|
-
keyPath: "auth_identifier_key",
|
|
5660
|
-
unique: false
|
|
5661
|
-
},
|
|
5662
|
-
{
|
|
5663
|
-
name: SEAMS_WALLET_INDEXES.kindRpIdAuthIdentifier,
|
|
5664
|
-
keyPath: ["kind", "rp_id", "auth_identifier_key"],
|
|
5665
|
-
unique: false
|
|
5666
|
-
},
|
|
5667
|
-
{
|
|
5668
|
-
name: SEAMS_WALLET_INDEXES.passkeyRpIdCredentialId,
|
|
5669
|
-
keyPath: ["kind", "rp_id", "credential_id_b64u"],
|
|
5670
|
-
unique: true
|
|
5671
|
-
},
|
|
5672
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5673
|
-
{
|
|
5674
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5675
|
-
keyPath: "wallet_authority_id",
|
|
5676
|
-
unique: false
|
|
5677
|
-
},
|
|
5678
|
-
{
|
|
5679
|
-
name: SEAMS_WALLET_INDEXES.walletIdAuthMethodId,
|
|
5680
|
-
keyPath: ["wallet_id", "wallet_auth_method_id"],
|
|
5681
|
-
unique: true
|
|
5682
|
-
},
|
|
5683
|
-
{
|
|
5684
|
-
name: SEAMS_WALLET_INDEXES.walletIdAuthorityStatus,
|
|
5685
|
-
keyPath: ["wallet_id", "wallet_authority_id", "status"],
|
|
5686
|
-
unique: false
|
|
5687
|
-
},
|
|
5688
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5689
|
-
]
|
|
5690
|
-
},
|
|
5691
|
-
{
|
|
5692
|
-
store: SEAMS_WALLET_STORES.walletAuthoritySignerMaterials,
|
|
5693
|
-
keyPath: ["wallet_authority_id", "wallet_auth_method_id", "activation_id"],
|
|
5694
|
-
indexes: [
|
|
5695
|
-
{
|
|
5696
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5697
|
-
keyPath: "wallet_authority_id",
|
|
5698
|
-
unique: false
|
|
5699
|
-
},
|
|
5700
|
-
{
|
|
5701
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityAuthMethodId,
|
|
5702
|
-
keyPath: ["wallet_authority_id", "wallet_auth_method_id"],
|
|
5703
|
-
unique: false
|
|
5704
|
-
},
|
|
5705
|
-
{ name: SEAMS_WALLET_INDEXES.activationId, keyPath: "activation_id", unique: false },
|
|
5706
|
-
{
|
|
5707
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityActivationId,
|
|
5708
|
-
keyPath: ["wallet_authority_id", "activation_id"],
|
|
5709
|
-
unique: true
|
|
5710
|
-
}
|
|
5711
|
-
]
|
|
5712
|
-
},
|
|
5713
|
-
{
|
|
5714
|
-
store: SEAMS_WALLET_STORES.walletAuthorityExportRoots,
|
|
5715
|
-
keyPath: ["wallet_authority_id", "wallet_auth_method_id", "wallet_key_id"],
|
|
5716
|
-
indexes: [
|
|
5717
|
-
{
|
|
5718
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5719
|
-
keyPath: "wallet_authority_id",
|
|
5720
|
-
unique: false
|
|
5721
|
-
},
|
|
5722
|
-
{
|
|
5723
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityAuthMethodId,
|
|
5724
|
-
keyPath: ["wallet_authority_id", "wallet_auth_method_id"],
|
|
5725
|
-
unique: false
|
|
5726
|
-
},
|
|
5727
|
-
{ name: SEAMS_WALLET_INDEXES.walletKeyId, keyPath: "wallet_key_id", unique: false }
|
|
5728
|
-
]
|
|
5729
|
-
},
|
|
5730
|
-
{
|
|
5731
|
-
store: SEAMS_WALLET_STORES.walletAuthorityInstallationReceipts,
|
|
5732
|
-
keyPath: "authority_id",
|
|
5733
|
-
indexes: [
|
|
5734
|
-
{ name: SEAMS_WALLET_INDEXES.walletAuthorityId, keyPath: "authority_id", unique: true },
|
|
5735
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5736
|
-
{
|
|
5737
|
-
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5738
|
-
keyPath: "wallet_auth_method_id",
|
|
5739
|
-
unique: false
|
|
5740
|
-
},
|
|
5741
|
-
{
|
|
5742
|
-
name: SEAMS_WALLET_INDEXES.walletIdDeviceId,
|
|
5743
|
-
keyPath: ["wallet_id", "device_id"],
|
|
5744
|
-
unique: false
|
|
5745
|
-
},
|
|
5746
|
-
{
|
|
5747
|
-
name: SEAMS_WALLET_INDEXES.packageSetDigest,
|
|
5748
|
-
keyPath: "package_set_digest_b64u",
|
|
5749
|
-
unique: false
|
|
5750
|
-
},
|
|
5751
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "installed_at_ms", unique: false }
|
|
5752
|
-
]
|
|
5753
|
-
},
|
|
5754
|
-
{
|
|
5755
|
-
store: SEAMS_WALLET_STORES.walletSelections,
|
|
5756
|
-
keyPath: "wallet_id",
|
|
5757
|
-
indexes: [
|
|
5758
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: true },
|
|
5759
|
-
{
|
|
5760
|
-
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5761
|
-
keyPath: "wallet_auth_method_id",
|
|
5762
|
-
unique: false
|
|
5763
|
-
},
|
|
5764
|
-
{
|
|
5765
|
-
name: SEAMS_WALLET_INDEXES.walletIdLockGeneration,
|
|
5766
|
-
keyPath: ["wallet_id", "lock_generation"],
|
|
5767
|
-
unique: true
|
|
5768
|
-
}
|
|
5769
|
-
]
|
|
5770
|
-
},
|
|
5771
|
-
{
|
|
5772
|
-
store: SEAMS_WALLET_STORES.walletSigners,
|
|
5773
|
-
keyPath: "wallet_signer_id",
|
|
5774
|
-
indexes: [
|
|
5775
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5776
|
-
{
|
|
5777
|
-
name: SEAMS_WALLET_INDEXES.walletIdKind,
|
|
5778
|
-
keyPath: ["wallet_id", "kind"],
|
|
5779
|
-
unique: false
|
|
5780
|
-
},
|
|
5781
|
-
{
|
|
5782
|
-
name: SEAMS_WALLET_INDEXES.walletKindNearSignerSlot,
|
|
5783
|
-
keyPath: ["wallet_id", "kind", "near_signer_slot"],
|
|
5784
|
-
unique: false
|
|
5785
|
-
},
|
|
5786
|
-
{
|
|
5787
|
-
name: SEAMS_WALLET_INDEXES.walletKindNearEd25519SigningKeyId,
|
|
5788
|
-
keyPath: ["wallet_id", "kind", "near_ed25519_signing_key_id"],
|
|
5789
|
-
unique: false
|
|
5790
|
-
},
|
|
5791
|
-
{
|
|
5792
|
-
name: SEAMS_WALLET_INDEXES.walletKindChainTargetKeyHandle,
|
|
5793
|
-
keyPath: ["wallet_id", "kind", "chain_target_key", "key_handle"],
|
|
5794
|
-
unique: true
|
|
5795
|
-
},
|
|
5796
|
-
{
|
|
5797
|
-
name: SEAMS_WALLET_INDEXES.walletKindChainTargetKeyFacts,
|
|
5798
|
-
keyPath: ["wallet_id", "kind", "chain_target_key", "ecdsa_threshold_key_id"],
|
|
5799
|
-
unique: true
|
|
5800
|
-
},
|
|
5801
|
-
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5802
|
-
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5803
|
-
{
|
|
5804
|
-
name: SEAMS_WALLET_INDEXES.thresholdOwnerAddress,
|
|
5805
|
-
keyPath: "threshold_owner_address",
|
|
5806
|
-
unique: false
|
|
5807
|
-
},
|
|
5808
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5809
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5810
|
-
]
|
|
5811
|
-
},
|
|
5812
|
-
{
|
|
5813
|
-
store: SEAMS_WALLET_STORES.nearAccountProjections,
|
|
5814
|
-
keyPath: ["wallet_id", "near_account_id", "signer_slot"],
|
|
5815
|
-
indexes: [
|
|
5816
|
-
{ name: SEAMS_WALLET_INDEXES.nearAccountId, keyPath: "near_account_id", unique: false },
|
|
5817
|
-
{ name: SEAMS_WALLET_INDEXES.profileId, keyPath: "profile_id", unique: false },
|
|
5818
|
-
{ name: SEAMS_WALLET_INDEXES.publicKey, keyPath: "public_key", unique: false },
|
|
5819
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5820
|
-
]
|
|
5821
|
-
},
|
|
5822
|
-
{
|
|
5823
|
-
store: SEAMS_WALLET_STORES.signerOpsOutbox,
|
|
5824
|
-
keyPath: "op_id",
|
|
5825
|
-
indexes: [
|
|
5826
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5827
|
-
{ name: SEAMS_WALLET_INDEXES.nextAttemptAt, keyPath: "next_attempt_at", unique: false },
|
|
5828
|
-
{
|
|
5829
|
-
name: SEAMS_WALLET_INDEXES.statusNextAttemptAt,
|
|
5830
|
-
keyPath: ["status", "next_attempt_at"],
|
|
5831
|
-
unique: false
|
|
5832
|
-
},
|
|
5833
|
-
{ name: SEAMS_WALLET_INDEXES.idempotencyKey, keyPath: "idempotency_key", unique: true },
|
|
5834
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5835
|
-
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false }
|
|
5836
|
-
]
|
|
5837
|
-
},
|
|
5838
|
-
{
|
|
5839
|
-
store: SEAMS_WALLET_STORES.nonceLaneLeases,
|
|
5840
|
-
keyPath: "lease_id",
|
|
5841
|
-
indexes: [
|
|
5842
|
-
{ name: SEAMS_WALLET_INDEXES.laneKey, keyPath: "lane_key", unique: false },
|
|
5843
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5844
|
-
{ name: SEAMS_WALLET_INDEXES.nearAccountId, keyPath: "near_account_id", unique: false },
|
|
5845
|
-
{ name: SEAMS_WALLET_INDEXES.state, keyPath: "state", unique: false },
|
|
5846
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5847
|
-
{ name: SEAMS_WALLET_INDEXES.laneState, keyPath: ["lane_key", "state"], unique: false },
|
|
5848
|
-
{
|
|
5849
|
-
name: SEAMS_WALLET_INDEXES.walletExpiresAt,
|
|
5850
|
-
keyPath: ["wallet_id", "expires_at_ms"],
|
|
5851
|
-
unique: false
|
|
5852
|
-
}
|
|
5853
|
-
]
|
|
5854
|
-
},
|
|
5855
|
-
{
|
|
5856
|
-
store: SEAMS_WALLET_STORES.nonceLaneLocks,
|
|
5857
|
-
keyPath: "lock_key",
|
|
5858
|
-
indexes: [
|
|
5859
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5860
|
-
{ name: SEAMS_WALLET_INDEXES.ownerId, keyPath: "owner_id", unique: false }
|
|
5861
|
-
]
|
|
5862
|
-
},
|
|
5863
|
-
{
|
|
5864
|
-
store: SEAMS_WALLET_STORES.keyMaterial,
|
|
5865
|
-
keyPath: "key_material_id",
|
|
5866
|
-
indexes: [
|
|
5867
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5868
|
-
{ name: SEAMS_WALLET_INDEXES.walletSignerId, keyPath: "wallet_signer_id", unique: false },
|
|
5869
|
-
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5870
|
-
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5871
|
-
{ name: SEAMS_WALLET_INDEXES.publicKey, keyPath: "public_key", unique: false },
|
|
5872
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5873
|
-
]
|
|
5874
|
-
},
|
|
5875
|
-
{
|
|
5876
|
-
store: SEAMS_WALLET_STORES.signingSessionSeals,
|
|
5877
|
-
keyPath: "store_key",
|
|
5878
|
-
indexes: [
|
|
5879
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5880
|
-
{ name: SEAMS_WALLET_INDEXES.authMethod, keyPath: "auth_method", unique: false },
|
|
5881
|
-
{ name: SEAMS_WALLET_INDEXES.curve, keyPath: "curve", unique: false },
|
|
5882
|
-
{
|
|
5883
|
-
name: SEAMS_WALLET_INDEXES.ed25519ThresholdSessionId,
|
|
5884
|
-
keyPath: "ed25519_threshold_session_id",
|
|
5885
|
-
unique: false
|
|
5886
|
-
},
|
|
5887
|
-
{
|
|
5888
|
-
name: SEAMS_WALLET_INDEXES.ecdsaThresholdSessionId,
|
|
5889
|
-
keyPath: "ecdsa_threshold_session_id",
|
|
5890
|
-
unique: false
|
|
5891
|
-
},
|
|
5892
|
-
{
|
|
5893
|
-
name: SEAMS_WALLET_INDEXES.thresholdSessionId,
|
|
5894
|
-
keyPath: "threshold_session_id",
|
|
5895
|
-
unique: false
|
|
5896
|
-
},
|
|
5897
|
-
{ name: SEAMS_WALLET_INDEXES.enrollmentId, keyPath: "enrollmentId", unique: false },
|
|
5898
|
-
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5899
|
-
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5900
|
-
{
|
|
5901
|
-
name: SEAMS_WALLET_INDEXES.exactSigningLaneIdentityKey,
|
|
5902
|
-
keyPath: "exact_signing_lane_identity_key",
|
|
5903
|
-
unique: false
|
|
5904
|
-
},
|
|
5905
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5906
|
-
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5907
|
-
]
|
|
5908
|
-
},
|
|
5909
|
-
{
|
|
5910
|
-
store: SEAMS_WALLET_STORES.signingSessionRestoreLeases,
|
|
5911
|
-
keyPath: "lease_key",
|
|
5912
|
-
indexes: [
|
|
5913
|
-
{
|
|
5914
|
-
name: SEAMS_WALLET_INDEXES.thresholdSessionId,
|
|
5915
|
-
keyPath: "threshold_session_id",
|
|
5916
|
-
unique: false
|
|
5917
|
-
},
|
|
5918
|
-
{ name: SEAMS_WALLET_INDEXES.ownerId, keyPath: "owner_id", unique: false },
|
|
5919
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false }
|
|
5920
|
-
]
|
|
5921
|
-
},
|
|
5922
|
-
{
|
|
5923
|
-
store: SEAMS_WALLET_STORES.pendingWalletRecoveryCodeBackups,
|
|
5924
|
-
keyPath: ["wallet_id", "enrollment_id"],
|
|
5925
|
-
indexes: [
|
|
5926
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5927
|
-
{ name: SEAMS_WALLET_INDEXES.enrollmentId, keyPath: "enrollment_id", unique: false },
|
|
5928
|
-
{
|
|
5929
|
-
name: SEAMS_WALLET_INDEXES.walletIdEnrollmentId,
|
|
5930
|
-
keyPath: ["wallet_id", "enrollment_id"],
|
|
5931
|
-
unique: true
|
|
5932
|
-
},
|
|
5933
|
-
{
|
|
5934
|
-
name: SEAMS_WALLET_INDEXES.recoveryCodesIssuedAtMs,
|
|
5935
|
-
keyPath: "recovery_codes_issued_at_ms",
|
|
5936
|
-
unique: false
|
|
5937
|
-
},
|
|
5938
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false }
|
|
5939
|
-
]
|
|
5940
|
-
},
|
|
5941
|
-
{
|
|
5942
|
-
store: SEAMS_WALLET_STORES.walletSessionAuthorizations,
|
|
5943
|
-
keyPath: "wallet_session_id",
|
|
5944
|
-
indexes: [
|
|
5945
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5946
|
-
{
|
|
5947
|
-
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5948
|
-
keyPath: "wallet_authority_id",
|
|
5949
|
-
unique: false
|
|
5950
|
-
},
|
|
5951
|
-
{
|
|
5952
|
-
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5953
|
-
keyPath: "wallet_auth_method_id",
|
|
5954
|
-
unique: false
|
|
5955
|
-
},
|
|
5956
|
-
{
|
|
5957
|
-
name: SEAMS_WALLET_INDEXES.authorityDigest,
|
|
5958
|
-
keyPath: "authority_digest_b64u",
|
|
5959
|
-
unique: false
|
|
5960
|
-
},
|
|
5961
|
-
{
|
|
5962
|
-
name: SEAMS_WALLET_INDEXES.revocationEpoch,
|
|
5963
|
-
keyPath: "authority_revocation_epoch",
|
|
5964
|
-
unique: false
|
|
5965
|
-
},
|
|
5966
|
-
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5967
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false }
|
|
5968
|
-
]
|
|
5969
|
-
},
|
|
5970
|
-
{
|
|
5971
|
-
store: SEAMS_WALLET_STORES.ecdsaCapabilityManifests,
|
|
5972
|
-
keyPath: "manifest_id",
|
|
5973
|
-
indexes: [
|
|
5974
|
-
{
|
|
5975
|
-
name: SEAMS_WALLET_INDEXES.capabilityWallet,
|
|
5976
|
-
keyPath: ["capability_ref", "wallet_id"],
|
|
5977
|
-
unique: false
|
|
5978
|
-
},
|
|
5979
|
-
{
|
|
5980
|
-
name: SEAMS_WALLET_INDEXES.capabilityWalletAuthorityState,
|
|
5981
|
-
keyPath: ["capability_ref", "wallet_id", "authority_digest", "manifest_state"],
|
|
5982
|
-
unique: false
|
|
5983
|
-
}
|
|
5984
|
-
]
|
|
5985
|
-
},
|
|
5986
|
-
{
|
|
5987
|
-
store: SEAMS_WALLET_STORES.ecdsaCurrentCapabilityManifests,
|
|
5988
|
-
keyPath: ["capability_ref", "wallet_id", "authority_digest"],
|
|
5989
|
-
indexes: [{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false }]
|
|
5990
|
-
},
|
|
5991
|
-
{
|
|
5992
|
-
store: SEAMS_WALLET_STORES.ecdsaRoleLocalMaterial,
|
|
5993
|
-
keyPath: "durable_material_ref",
|
|
5994
|
-
indexes: []
|
|
5995
|
-
},
|
|
5996
|
-
{
|
|
5997
|
-
store: SEAMS_WALLET_STORES.ecdsaActivationCommitJournals,
|
|
5998
|
-
keyPath: "journal_id",
|
|
5999
|
-
indexes: [
|
|
6000
|
-
{
|
|
6001
|
-
name: SEAMS_WALLET_INDEXES.capabilityWalletAuthority,
|
|
6002
|
-
keyPath: ["capability_ref", "wallet_id", "authority_digest"],
|
|
6003
|
-
unique: true
|
|
6004
|
-
}
|
|
6005
|
-
]
|
|
6006
|
-
},
|
|
6007
|
-
{
|
|
6008
|
-
store: SEAMS_WALLET_STORES.ecdsaMaterialSealingKeys,
|
|
6009
|
-
keyPath: "key_id",
|
|
6010
|
-
indexes: []
|
|
6011
|
-
},
|
|
6012
|
-
{
|
|
6013
|
-
store: SEAMS_WALLET_STORES.ecdsaClientPresignatures,
|
|
6014
|
-
keyPath: "record_id",
|
|
6015
|
-
indexes: [
|
|
6016
|
-
{ name: SEAMS_WALLET_INDEXES.poolIdentityKey, keyPath: "pool_identity_key", unique: false },
|
|
6017
|
-
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
6018
|
-
{
|
|
6019
|
-
name: SEAMS_WALLET_INDEXES.walletMaterialActivationId,
|
|
6020
|
-
keyPath: ["wallet_id", "material_activation_id"],
|
|
6021
|
-
unique: false
|
|
6022
|
-
},
|
|
6023
|
-
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
6024
|
-
{
|
|
6025
|
-
name: SEAMS_WALLET_INDEXES.walletExpiresAt,
|
|
6026
|
-
keyPath: ["wallet_id", "expires_at_ms"],
|
|
6027
|
-
unique: false
|
|
6028
|
-
}
|
|
6029
|
-
]
|
|
4410
|
+
class EncryptedEcdsaPendingCandidateProof extends EcdsaCapabilityManifestProof {
|
|
4411
|
+
constructor(fields) {
|
|
4412
|
+
super();
|
|
4413
|
+
this.kind = "encrypted_ecdsa_pending_candidate";
|
|
4414
|
+
this.sealingKeyId = fields.sealingKeyId;
|
|
4415
|
+
this.iv12B64u = fields.iv12B64u;
|
|
4416
|
+
this.ciphertextB64u = fields.ciphertextB64u;
|
|
4417
|
+
this.ciphertextDigest = fields.ciphertextDigest;
|
|
6030
4418
|
}
|
|
6031
|
-
];
|
|
6032
|
-
|
|
6033
|
-
// src/core/indexedDB/seamsWalletDB/schema.ts
|
|
6034
|
-
var SEAMS_WALLET_DB_CONFIG = {
|
|
6035
|
-
dbName: SEAMS_WALLET_DB_NAME,
|
|
6036
|
-
dbVersion: SEAMS_WALLET_DB_VERSION
|
|
6037
|
-
};
|
|
6038
|
-
function keyPathForIndexedDB(keyPath) {
|
|
6039
|
-
return typeof keyPath === "string" ? keyPath : [...keyPath];
|
|
6040
4419
|
}
|
|
6041
|
-
|
|
6042
|
-
|
|
6043
|
-
|
|
6044
|
-
|
|
6045
|
-
|
|
6046
|
-
|
|
4420
|
+
|
|
4421
|
+
class EcdsaActivationBindingProof extends EcdsaCapabilityManifestProof {
|
|
4422
|
+
constructor(fields) {
|
|
4423
|
+
super();
|
|
4424
|
+
this.kind = "ecdsa_activation_binding";
|
|
4425
|
+
this.targetManifest = fields.targetManifest;
|
|
4426
|
+
this.signer = fields.signer;
|
|
4427
|
+
this.roleLocalBinding = fields.roleLocalBinding;
|
|
4428
|
+
this.bindingDigest = fields.bindingDigest;
|
|
4429
|
+
this.durableMaterialRef = fields.durableMaterialRef;
|
|
6047
4430
|
}
|
|
6048
4431
|
}
|
|
6049
|
-
|
|
6050
|
-
|
|
6051
|
-
|
|
6052
|
-
|
|
6053
|
-
|
|
4432
|
+
|
|
4433
|
+
class PreparedEcdsaActivationCandidateProof extends EcdsaCapabilityManifestProof {
|
|
4434
|
+
constructor(fields) {
|
|
4435
|
+
super();
|
|
4436
|
+
this.kind = "prepared_ecdsa_activation_candidate";
|
|
4437
|
+
this.activationBinding = fields.activationBinding;
|
|
4438
|
+
this.encryptedPending = fields.encryptedPending;
|
|
6054
4439
|
}
|
|
6055
4440
|
}
|
|
6056
4441
|
|
|
6057
|
-
|
|
6058
|
-
|
|
6059
|
-
|
|
6060
|
-
|
|
6061
|
-
|
|
6062
|
-
|
|
6063
|
-
|
|
6064
|
-
|
|
6065
|
-
return new Error(message);
|
|
6066
|
-
}
|
|
6067
|
-
async function withTimeout(promise, ms, error, onTimeout) {
|
|
6068
|
-
let settled = false;
|
|
6069
|
-
let timeout = null;
|
|
6070
|
-
const timeoutPromise = new Promise((_resolve, reject) => {
|
|
6071
|
-
timeout = setTimeout(() => {
|
|
6072
|
-
if (settled)
|
|
6073
|
-
return;
|
|
6074
|
-
onTimeout?.();
|
|
6075
|
-
reject(error);
|
|
6076
|
-
}, ms);
|
|
6077
|
-
});
|
|
6078
|
-
try {
|
|
6079
|
-
return await Promise.race([promise, timeoutPromise]);
|
|
6080
|
-
} finally {
|
|
6081
|
-
settled = true;
|
|
6082
|
-
if (timeout)
|
|
6083
|
-
clearTimeout(timeout);
|
|
4442
|
+
class EcdsaServerActivationCommandProof extends EcdsaCapabilityManifestProof {
|
|
4443
|
+
constructor(fields) {
|
|
4444
|
+
super();
|
|
4445
|
+
this.kind = "ecdsa_server_activation_command";
|
|
4446
|
+
this.correlationId = fields.correlationId;
|
|
4447
|
+
this.expectedGeneration = fields.expectedGeneration;
|
|
4448
|
+
this.requestDigest = fields.requestDigest;
|
|
4449
|
+
this.canonicalRequest = fields.canonicalRequest;
|
|
6084
4450
|
}
|
|
6085
4451
|
}
|
|
6086
|
-
async function runIndexedDbTransactionTask(context, task) {
|
|
6087
|
-
const result = await task(context);
|
|
6088
|
-
await context.tx.done;
|
|
6089
|
-
return result;
|
|
6090
|
-
}
|
|
6091
4452
|
|
|
6092
|
-
class
|
|
6093
|
-
constructor(
|
|
6094
|
-
|
|
6095
|
-
this.
|
|
6096
|
-
this.
|
|
6097
|
-
|
|
6098
|
-
|
|
6099
|
-
|
|
6100
|
-
}
|
|
6101
|
-
setDbName(dbName) {
|
|
6102
|
-
if (this.config.dbName === dbName)
|
|
6103
|
-
return;
|
|
6104
|
-
this.close();
|
|
6105
|
-
this.config = { ...this.config, dbName };
|
|
6106
|
-
}
|
|
6107
|
-
setDisabled(disabled) {
|
|
6108
|
-
this.disabled = disabled;
|
|
6109
|
-
if (disabled)
|
|
6110
|
-
this.close();
|
|
6111
|
-
}
|
|
6112
|
-
isDisabled() {
|
|
6113
|
-
return this.disabled;
|
|
6114
|
-
}
|
|
6115
|
-
close() {
|
|
6116
|
-
if (this.dbPromise) {
|
|
6117
|
-
this.dbPromise.then((db) => db.close()).catch(() => {
|
|
6118
|
-
return;
|
|
6119
|
-
});
|
|
6120
|
-
this.dbPromise = null;
|
|
6121
|
-
}
|
|
4453
|
+
class EcdsaServerActivationReceiptProof extends EcdsaCapabilityManifestProof {
|
|
4454
|
+
constructor(fields) {
|
|
4455
|
+
super();
|
|
4456
|
+
this.kind = "ecdsa_server_activation_receipt";
|
|
4457
|
+
this.lifecycleId = fields.lifecycleId;
|
|
4458
|
+
this.activationDigest = fields.activationDigest;
|
|
4459
|
+
this.activatedAt = fields.activatedAt;
|
|
4460
|
+
this.protocolReceipt = fields.protocolReceipt;
|
|
6122
4461
|
}
|
|
6123
|
-
|
|
6124
|
-
|
|
6125
|
-
|
|
6126
|
-
|
|
6127
|
-
|
|
6128
|
-
|
|
6129
|
-
|
|
6130
|
-
|
|
6131
|
-
|
|
6132
|
-
|
|
6133
|
-
rejectBlockedOpen = reject;
|
|
6134
|
-
});
|
|
6135
|
-
const openPromise = openDB(dbName, dbVersion, {
|
|
6136
|
-
upgrade(db) {
|
|
6137
|
-
upgradeSeamsWalletDBSchema(db);
|
|
6138
|
-
},
|
|
6139
|
-
blocked() {
|
|
6140
|
-
console.warn("[SeamsWalletDBManager] IndexedDB open is blocked.", {
|
|
6141
|
-
dbName,
|
|
6142
|
-
dbVersion
|
|
6143
|
-
});
|
|
6144
|
-
blockedTimer = setTimeout(() => {
|
|
6145
|
-
rejectBlockedOpen?.(seamsWalletDbOpenBlockedError(dbName));
|
|
6146
|
-
}, INDEXED_DB_BLOCKED_OPEN_TIMEOUT_MS);
|
|
6147
|
-
},
|
|
6148
|
-
blocking: () => {
|
|
6149
|
-
console.warn("[SeamsWalletDBManager] IndexedDB connection is blocking an upgrade.", {
|
|
6150
|
-
dbName,
|
|
6151
|
-
dbVersion
|
|
6152
|
-
});
|
|
6153
|
-
this.close();
|
|
6154
|
-
},
|
|
6155
|
-
terminated() {
|
|
6156
|
-
console.warn("[SeamsWalletDBManager] IndexedDB connection has been terminated.", {
|
|
6157
|
-
dbName,
|
|
6158
|
-
dbVersion
|
|
6159
|
-
});
|
|
6160
|
-
}
|
|
6161
|
-
});
|
|
6162
|
-
const guardedOpen = withTimeout(Promise.race([openPromise, blockedOpen]).finally(() => {
|
|
6163
|
-
if (blockedTimer)
|
|
6164
|
-
clearTimeout(blockedTimer);
|
|
6165
|
-
}), INDEXED_DB_OPEN_TIMEOUT_MS, indexedDbTimeoutError(`[SeamsWalletDBManager] IndexedDB open timed out for ${dbName}. Close other tabs using this app and retry.`));
|
|
6166
|
-
this.dbPromise = guardedOpen.catch((error) => {
|
|
6167
|
-
this.dbPromise = null;
|
|
6168
|
-
openPromise.then((db) => db.close()).catch(() => {
|
|
6169
|
-
return;
|
|
6170
|
-
});
|
|
6171
|
-
throw error;
|
|
6172
|
-
});
|
|
6173
|
-
}
|
|
6174
|
-
return await this.dbPromise;
|
|
4462
|
+
}
|
|
4463
|
+
|
|
4464
|
+
class EcdsaServerActivationCommitProof extends EcdsaCapabilityManifestProof {
|
|
4465
|
+
constructor(fields) {
|
|
4466
|
+
super();
|
|
4467
|
+
this.kind = "ecdsa_server_activation_commit";
|
|
4468
|
+
this.correlationId = fields.correlationId;
|
|
4469
|
+
this.activationRequestDigest = fields.activationRequestDigest;
|
|
4470
|
+
this.serverGeneration = fields.serverGeneration;
|
|
4471
|
+
this.serverActivationReceipt = fields.serverActivationReceipt;
|
|
6175
4472
|
}
|
|
6176
|
-
|
|
6177
|
-
|
|
6178
|
-
|
|
6179
|
-
|
|
6180
|
-
|
|
6181
|
-
|
|
6182
|
-
|
|
6183
|
-
|
|
6184
|
-
|
|
6185
|
-
|
|
6186
|
-
|
|
6187
|
-
return await withTimeout(runIndexedDbTransactionTask(context, task), INDEXED_DB_TRANSACTION_TIMEOUT_MS, indexedDbTimeoutError(`[SeamsWalletDBManager] IndexedDB transaction timed out for ${this.config.dbName}. Close other tabs using this app and retry.`), () => {
|
|
6188
|
-
try {
|
|
6189
|
-
tx.abort();
|
|
6190
|
-
} catch {}
|
|
6191
|
-
});
|
|
6192
|
-
} catch (error) {
|
|
6193
|
-
try {
|
|
6194
|
-
tx.abort();
|
|
6195
|
-
} catch {}
|
|
6196
|
-
await tx.done.catch(() => {
|
|
6197
|
-
return;
|
|
6198
|
-
});
|
|
6199
|
-
throw error;
|
|
6200
|
-
}
|
|
4473
|
+
}
|
|
4474
|
+
|
|
4475
|
+
class PreparedEcdsaActivationJournalProof extends EcdsaCapabilityManifestProof {
|
|
4476
|
+
constructor(fields) {
|
|
4477
|
+
super();
|
|
4478
|
+
this.kind = "activation_prepared";
|
|
4479
|
+
this.journalId = fields.journalId;
|
|
4480
|
+
this.expectedManifest = fields.expectedManifest;
|
|
4481
|
+
this.activationCommand = fields.activationCommand;
|
|
4482
|
+
this.candidate = fields.candidate;
|
|
4483
|
+
this.createdAt = fields.createdAt;
|
|
6201
4484
|
}
|
|
6202
4485
|
}
|
|
6203
4486
|
|
|
6204
|
-
|
|
6205
|
-
|
|
4487
|
+
class ServerCommittedEcdsaActivationJournalProof extends EcdsaCapabilityManifestProof {
|
|
4488
|
+
constructor(fields) {
|
|
4489
|
+
super();
|
|
4490
|
+
this.kind = "server_activation_committed";
|
|
4491
|
+
this.journalId = fields.journalId;
|
|
4492
|
+
this.expectedManifest = fields.expectedManifest;
|
|
4493
|
+
this.activationCommand = fields.activationCommand;
|
|
4494
|
+
this.candidate = fields.candidate;
|
|
4495
|
+
this.createdAt = fields.createdAt;
|
|
4496
|
+
this.serverActivation = fields.serverActivation;
|
|
4497
|
+
}
|
|
4498
|
+
}
|
|
6206
4499
|
|
|
6207
|
-
|
|
6208
|
-
|
|
6209
|
-
|
|
6210
|
-
|
|
4500
|
+
class DurableEcdsaMaterialBindingProof extends EcdsaCapabilityManifestProof {
|
|
4501
|
+
constructor(fields) {
|
|
4502
|
+
super();
|
|
4503
|
+
this.kind = "durable_ecdsa_material";
|
|
4504
|
+
this.materialActivation = fields.materialActivation;
|
|
4505
|
+
this.routerAbEcdsaDerivationNormalSigning = fields.routerAbEcdsaDerivationNormalSigning;
|
|
4506
|
+
this.roleLocalPublicFacts = fields.roleLocalPublicFacts;
|
|
4507
|
+
this.roleLocalBinding = fields.roleLocalBinding;
|
|
4508
|
+
this.durableMaterialRef = fields.durableMaterialRef;
|
|
4509
|
+
this.bindingDigest = fields.bindingDigest;
|
|
4510
|
+
this.lifecycleId = fields.lifecycleId;
|
|
4511
|
+
this.ciphertextDigest = fields.ciphertextDigest;
|
|
4512
|
+
this.activationDigest = fields.activationDigest;
|
|
4513
|
+
this.activatedAt = fields.activatedAt;
|
|
4514
|
+
this.runtimePolicyScope = fields.runtimePolicyScope;
|
|
6211
4515
|
}
|
|
6212
|
-
return value.trim();
|
|
6213
4516
|
}
|
|
6214
|
-
|
|
6215
|
-
|
|
6216
|
-
|
|
6217
|
-
|
|
6218
|
-
|
|
4517
|
+
|
|
4518
|
+
class ValidatedEncryptedEcdsaReadyMaterialProof extends EcdsaCapabilityManifestProof {
|
|
4519
|
+
constructor(fields) {
|
|
4520
|
+
super();
|
|
4521
|
+
this.kind = "encrypted_ecdsa_ready_material";
|
|
4522
|
+
this.binding = fields.binding;
|
|
4523
|
+
this.sealingKeyId = fields.sealingKeyId;
|
|
4524
|
+
this.iv12B64u = fields.iv12B64u;
|
|
4525
|
+
this.ciphertextB64u = fields.ciphertextB64u;
|
|
6219
4526
|
}
|
|
6220
|
-
return normalized;
|
|
6221
4527
|
}
|
|
6222
|
-
|
|
6223
|
-
|
|
6224
|
-
|
|
6225
|
-
|
|
6226
|
-
|
|
4528
|
+
|
|
4529
|
+
class ActiveEcdsaCapabilityManifestProof extends EcdsaCapabilityManifestProof {
|
|
4530
|
+
constructor(fields) {
|
|
4531
|
+
super();
|
|
4532
|
+
this.kind = "active_ecdsa_capability_manifest";
|
|
4533
|
+
this.identity = fields.identity;
|
|
4534
|
+
this.signer = fields.signer;
|
|
4535
|
+
this.activation = fields.activation;
|
|
4536
|
+
this.durableMaterial = fields.durableMaterial;
|
|
4537
|
+
this.committedAt = fields.committedAt;
|
|
6227
4538
|
}
|
|
6228
|
-
|
|
6229
|
-
|
|
4539
|
+
}
|
|
4540
|
+
|
|
4541
|
+
class ReplacedEcdsaCapabilityManifestProof extends EcdsaCapabilityManifestProof {
|
|
4542
|
+
constructor(fields) {
|
|
4543
|
+
super();
|
|
4544
|
+
this.kind = "replaced_ecdsa_capability_manifest";
|
|
4545
|
+
this.identity = fields.identity;
|
|
4546
|
+
this.signer = fields.signer;
|
|
4547
|
+
this.retirement = fields.retirement;
|
|
6230
4548
|
}
|
|
6231
|
-
return normalized;
|
|
6232
4549
|
}
|
|
6233
|
-
function
|
|
6234
|
-
|
|
4550
|
+
function unwrapDomainId(result) {
|
|
4551
|
+
if (!result.ok)
|
|
4552
|
+
throw new Error(result.error.message);
|
|
4553
|
+
return result.value;
|
|
6235
4554
|
}
|
|
6236
|
-
function
|
|
6237
|
-
|
|
4555
|
+
function buildEcdsaCapabilityScope(input) {
|
|
4556
|
+
assertUniqueEcdsaTargetMemberships(input.targetMemberships);
|
|
4557
|
+
return new EcdsaCapabilityScopeProof([...input.targetMemberships]);
|
|
6238
4558
|
}
|
|
6239
|
-
function
|
|
6240
|
-
return
|
|
4559
|
+
function buildEcdsaManifestIdentity(input) {
|
|
4560
|
+
return new EcdsaManifestIdentityProof(input);
|
|
6241
4561
|
}
|
|
6242
|
-
function
|
|
6243
|
-
|
|
6244
|
-
if (!/^0x[0-9a-f]{40}$/.test(normalized)) {
|
|
6245
|
-
throw new Error("[platform][ecdsa-role-local] ethereumAddress must be an EVM address");
|
|
6246
|
-
}
|
|
6247
|
-
return normalized;
|
|
4562
|
+
function buildNoCurrentEcdsaManifestExpectation() {
|
|
4563
|
+
return new NoCurrentEcdsaManifestExpectationProof;
|
|
6248
4564
|
}
|
|
6249
|
-
function
|
|
6250
|
-
|
|
6251
|
-
throw new Error("[platform][ecdsa-role-local] participantIds must be [1, 2]");
|
|
6252
|
-
}
|
|
6253
|
-
return [1, 2];
|
|
4565
|
+
function buildExactEcdsaManifestExpectation(identity) {
|
|
4566
|
+
return new ExactEcdsaManifestExpectationProof(identity);
|
|
6254
4567
|
}
|
|
6255
|
-
function
|
|
6256
|
-
|
|
6257
|
-
throw new Error("[platform][ecdsa-role-local] chainTarget must be an object");
|
|
6258
|
-
}
|
|
6259
|
-
const kind = requiredString4(Reflect.get(input, "kind"), "chainTarget.kind").toLowerCase();
|
|
6260
|
-
switch (kind) {
|
|
6261
|
-
case "evm": {
|
|
6262
|
-
const fields = Object.keys(input).sort();
|
|
6263
|
-
if (fields.join(",") !== "chainId,kind,namespace,networkSlug") {
|
|
6264
|
-
throw new Error("[platform][ecdsa-role-local] EVM chainTarget fields are invalid");
|
|
6265
|
-
}
|
|
6266
|
-
return thresholdEcdsaChainTargetFromRequest({
|
|
6267
|
-
kind: Reflect.get(input, "kind"),
|
|
6268
|
-
namespace: Reflect.get(input, "namespace"),
|
|
6269
|
-
chainId: Reflect.get(input, "chainId"),
|
|
6270
|
-
networkSlug: Reflect.get(input, "networkSlug")
|
|
6271
|
-
});
|
|
6272
|
-
}
|
|
6273
|
-
case "tempo": {
|
|
6274
|
-
const fields = Object.keys(input).sort();
|
|
6275
|
-
if (fields.join(",") !== "chainId,kind,networkSlug") {
|
|
6276
|
-
throw new Error("[platform][ecdsa-role-local] Tempo chainTarget fields are invalid");
|
|
6277
|
-
}
|
|
6278
|
-
return thresholdEcdsaChainTargetFromRequest({
|
|
6279
|
-
kind: Reflect.get(input, "kind"),
|
|
6280
|
-
chainId: Reflect.get(input, "chainId"),
|
|
6281
|
-
networkSlug: Reflect.get(input, "networkSlug")
|
|
6282
|
-
});
|
|
6283
|
-
}
|
|
6284
|
-
default:
|
|
6285
|
-
throw new Error("[platform][ecdsa-role-local] chainTarget kind is invalid");
|
|
6286
|
-
}
|
|
4568
|
+
function buildNoCurrentEcdsaServerGenerationExpectation() {
|
|
4569
|
+
return new NoCurrentEcdsaServerGenerationExpectationProof;
|
|
6287
4570
|
}
|
|
6288
|
-
function
|
|
6289
|
-
|
|
6290
|
-
throw new Error("[platform][ecdsa-role-local] publicFacts must be an object");
|
|
6291
|
-
}
|
|
6292
|
-
const fields = Object.keys(input).sort();
|
|
6293
|
-
if (fields.join(",") !== "applicationBindingDigestB64u,chainTarget,clientParticipantId,contextBinding32B64u,derivationClientSharePublicKey33B64u,ecdsaThresholdKeyId,ethereumAddress,groupPublicKey33B64u,keyHandle,participantIds,publicCapability,relayerParticipantId,relayerPublicKey33B64u,signingRootId,signingRootVersion,walletId") {
|
|
6294
|
-
throw new Error("[platform][ecdsa-role-local] publicFacts fields are invalid");
|
|
6295
|
-
}
|
|
6296
|
-
if (Reflect.get(input, "clientParticipantId") !== 1) {
|
|
6297
|
-
throw new Error("[platform][ecdsa-role-local] clientParticipantId must be 1");
|
|
6298
|
-
}
|
|
6299
|
-
if (Reflect.get(input, "relayerParticipantId") !== 2) {
|
|
6300
|
-
throw new Error("[platform][ecdsa-role-local] relayerParticipantId must be 2");
|
|
6301
|
-
}
|
|
6302
|
-
const derivationClientSharePublicKey33B64u = parseEcdsaDerivationClientSharePublicKey(Reflect.get(input, "derivationClientSharePublicKey33B64u"));
|
|
6303
|
-
const relayerPublicKey33B64u = parseRelayerEcdsaDerivationPublicKey(Reflect.get(input, "relayerPublicKey33B64u"));
|
|
6304
|
-
if (String(derivationClientSharePublicKey33B64u) === String(relayerPublicKey33B64u)) {
|
|
6305
|
-
throw new Error("[platform][ecdsa-role-local] relayerPublicKey33B64u must differ from derivationClientSharePublicKey33B64u");
|
|
6306
|
-
}
|
|
6307
|
-
return {
|
|
6308
|
-
walletId: toWalletId(Reflect.get(input, "walletId")),
|
|
6309
|
-
chainTarget: parseChainTarget(Reflect.get(input, "chainTarget")),
|
|
6310
|
-
keyHandle: requiredString4(Reflect.get(input, "keyHandle"), "keyHandle"),
|
|
6311
|
-
ecdsaThresholdKeyId: toEcdsaDerivationThresholdKeyId(Reflect.get(input, "ecdsaThresholdKeyId")),
|
|
6312
|
-
signingRootId: toEcdsaDerivationSigningRootId(Reflect.get(input, "signingRootId")),
|
|
6313
|
-
signingRootVersion: toEcdsaDerivationSigningRootVersion(Reflect.get(input, "signingRootVersion")),
|
|
6314
|
-
applicationBindingDigestB64u: parseBase64UrlBytes(Reflect.get(input, "applicationBindingDigestB64u"), "applicationBindingDigestB64u", 32),
|
|
6315
|
-
clientParticipantId: 1,
|
|
6316
|
-
relayerParticipantId: 2,
|
|
6317
|
-
participantIds: parseParticipantIds2(Reflect.get(input, "participantIds")),
|
|
6318
|
-
contextBinding32B64u: parseBase64UrlBytes(Reflect.get(input, "contextBinding32B64u"), "contextBinding32B64u", 32),
|
|
6319
|
-
derivationClientSharePublicKey33B64u,
|
|
6320
|
-
relayerPublicKey33B64u,
|
|
6321
|
-
groupPublicKey33B64u: parseGroupPublicKey(Reflect.get(input, "groupPublicKey33B64u")),
|
|
6322
|
-
ethereumAddress: parseEthereumAddress2(Reflect.get(input, "ethereumAddress")),
|
|
6323
|
-
publicCapability: parseRouterAbEcdsaDerivationPublicCapabilityV1(Reflect.get(input, "publicCapability"))
|
|
6324
|
-
};
|
|
4571
|
+
function buildExactEcdsaServerGenerationExpectation(serverGeneration) {
|
|
4572
|
+
return new ExactEcdsaServerGenerationExpectationProof(serverGeneration);
|
|
6325
4573
|
}
|
|
6326
|
-
function
|
|
6327
|
-
|
|
4574
|
+
function buildEcdsaRoleLocalMaterialBinding(input) {
|
|
4575
|
+
assertUniqueParticipantIds(input.participantIds);
|
|
4576
|
+
return new EcdsaRoleLocalMaterialBindingProof({
|
|
4577
|
+
keyHandle: input.keyHandle,
|
|
4578
|
+
ecdsaThresholdKeyId: input.ecdsaThresholdKeyId,
|
|
4579
|
+
clientVerifyingPublicKey33B64u: input.clientVerifyingPublicKey33B64u,
|
|
4580
|
+
participantIds: [...input.participantIds],
|
|
4581
|
+
relayerKeyId: input.relayerKeyId
|
|
4582
|
+
});
|
|
6328
4583
|
}
|
|
6329
|
-
|
|
6330
|
-
|
|
6331
|
-
|
|
6332
|
-
|
|
6333
|
-
|
|
6334
|
-
|
|
6335
|
-
|
|
6336
|
-
|
|
4584
|
+
function buildPreparedEvmFamilySigner(input) {
|
|
4585
|
+
return new PreparedEvmFamilySignerProof(input);
|
|
4586
|
+
}
|
|
4587
|
+
function buildEncryptedEcdsaPendingCandidate(input) {
|
|
4588
|
+
return new EncryptedEcdsaPendingCandidateProof(input);
|
|
4589
|
+
}
|
|
4590
|
+
function buildEcdsaActivationBinding(input) {
|
|
4591
|
+
return new EcdsaActivationBindingProof(input);
|
|
4592
|
+
}
|
|
4593
|
+
function buildPreparedEcdsaActivationCandidate(input) {
|
|
4594
|
+
return new PreparedEcdsaActivationCandidateProof(input);
|
|
4595
|
+
}
|
|
4596
|
+
function buildPreparedEcdsaActivationJournal(input) {
|
|
4597
|
+
assertTargetManifestTransition(input.expectedManifest, input.candidate.activationBinding.targetManifest);
|
|
4598
|
+
assertExpectedStatePair(input.expectedManifest, input.expectedGeneration);
|
|
4599
|
+
const activationCommand = new EcdsaServerActivationCommandProof({
|
|
4600
|
+
correlationId: input.journalId,
|
|
4601
|
+
expectedGeneration: input.expectedGeneration,
|
|
4602
|
+
requestDigest: input.requestDigest,
|
|
4603
|
+
canonicalRequest: input.canonicalRequest
|
|
4604
|
+
});
|
|
4605
|
+
return new PreparedEcdsaActivationJournalProof({
|
|
4606
|
+
journalId: input.journalId,
|
|
4607
|
+
expectedManifest: input.expectedManifest,
|
|
4608
|
+
activationCommand,
|
|
4609
|
+
candidate: input.candidate,
|
|
4610
|
+
createdAt: input.createdAt
|
|
4611
|
+
});
|
|
4612
|
+
}
|
|
4613
|
+
function buildEcdsaServerActivationCommit(input) {
|
|
4614
|
+
const protocolReceipt = parseRouterAbEcdsaRegistrationActivationReceiptV1(input.serverCommit.protocolReceipt);
|
|
4615
|
+
assertProtocolReceiptMatchesServerCommit(protocolReceipt, input.serverCommit);
|
|
4616
|
+
assertProtocolReceiptMatchesActivationBinding(protocolReceipt, input.activationBinding);
|
|
4617
|
+
const serverActivationReceipt = new EcdsaServerActivationReceiptProof({
|
|
4618
|
+
lifecycleId: lifecycleIdFromProtocolReceipt(protocolReceipt),
|
|
4619
|
+
activationDigest: activationDigestFromProtocolReceipt(protocolReceipt),
|
|
4620
|
+
activatedAt: isoTimestampFromUnixMs(protocolReceipt.ecdsa_activation.activated_at_ms),
|
|
4621
|
+
protocolReceipt
|
|
4622
|
+
});
|
|
4623
|
+
return new EcdsaServerActivationCommitProof({
|
|
4624
|
+
correlationId: input.serverCommit.correlationId,
|
|
4625
|
+
activationRequestDigest: input.serverCommit.activationRequestDigest,
|
|
4626
|
+
serverGeneration: input.serverCommit.serverGeneration,
|
|
4627
|
+
serverActivationReceipt
|
|
4628
|
+
});
|
|
4629
|
+
}
|
|
4630
|
+
function buildServerCommittedEcdsaActivationJournal(input) {
|
|
4631
|
+
assertServerCommitMatchesPreparedCommand(input.serverCommit, input.preparedJournal);
|
|
4632
|
+
const serverActivation = buildEcdsaServerActivationCommit({
|
|
4633
|
+
activationBinding: input.preparedJournal.candidate.activationBinding,
|
|
4634
|
+
serverCommit: input.serverCommit
|
|
4635
|
+
});
|
|
4636
|
+
return new ServerCommittedEcdsaActivationJournalProof({
|
|
4637
|
+
journalId: input.preparedJournal.journalId,
|
|
4638
|
+
expectedManifest: input.preparedJournal.expectedManifest,
|
|
4639
|
+
activationCommand: input.preparedJournal.activationCommand,
|
|
4640
|
+
candidate: input.preparedJournal.candidate,
|
|
4641
|
+
createdAt: input.preparedJournal.createdAt,
|
|
4642
|
+
serverActivation
|
|
4643
|
+
});
|
|
6337
4644
|
}
|
|
6338
|
-
|
|
6339
|
-
|
|
6340
|
-
|
|
6341
|
-
|
|
6342
|
-
|
|
6343
|
-
|
|
4645
|
+
function buildDurableEcdsaMaterialBinding(input) {
|
|
4646
|
+
assertServerActivationMatchesBinding(input.serverActivation, input.activationBinding);
|
|
4647
|
+
const facts = input.roleLocalPublicFacts;
|
|
4648
|
+
const binding = input.activationBinding;
|
|
4649
|
+
const runtimePolicyScope = normalizeRuntimePolicyScope(input.runtimePolicyScope);
|
|
4650
|
+
if (facts.walletId !== binding.signer.walletId || facts.keyHandle !== binding.roleLocalBinding.keyHandle || facts.ecdsaThresholdKeyId !== binding.roleLocalBinding.ecdsaThresholdKeyId || facts.signingRootId !== binding.signer.signingRootId || facts.signingRootVersion !== binding.signer.signingRootVersion || deriveSigningRootId(runtimePolicyScope) !== binding.signer.signingRootId || runtimePolicyScope.signingRootVersion !== binding.signer.signingRootVersion || facts.contextBinding32B64u !== binding.bindingDigest || !participantIdsMatch(facts.participantIds, binding.roleLocalBinding.participantIds) || !binding.signer.scope.targetMemberships.some((target) => ecdsaTargetMembershipKey(target) === ecdsaTargetMembershipKey(facts.chainTarget))) {
|
|
4651
|
+
throw new Error("ECDSA role-local public facts do not match their activation");
|
|
6344
4652
|
}
|
|
4653
|
+
const receipt = input.serverActivation.serverActivationReceipt;
|
|
4654
|
+
assertNormalSigningMatchesActivation({
|
|
4655
|
+
normalSigning: input.routerAbEcdsaDerivationNormalSigning,
|
|
4656
|
+
activationBinding: binding,
|
|
4657
|
+
roleLocalPublicFacts: facts,
|
|
4658
|
+
receipt: receipt.protocolReceipt
|
|
4659
|
+
});
|
|
4660
|
+
return new DurableEcdsaMaterialBindingProof({
|
|
4661
|
+
materialActivation: materialActivationFromCommit(receipt.protocolReceipt),
|
|
4662
|
+
routerAbEcdsaDerivationNormalSigning: input.routerAbEcdsaDerivationNormalSigning,
|
|
4663
|
+
roleLocalPublicFacts: input.roleLocalPublicFacts,
|
|
4664
|
+
roleLocalBinding: input.activationBinding.roleLocalBinding,
|
|
4665
|
+
durableMaterialRef: input.activationBinding.durableMaterialRef,
|
|
4666
|
+
bindingDigest: input.activationBinding.bindingDigest,
|
|
4667
|
+
lifecycleId: receipt.lifecycleId,
|
|
4668
|
+
ciphertextDigest: input.ciphertextDigest,
|
|
4669
|
+
activationDigest: receipt.activationDigest,
|
|
4670
|
+
activatedAt: receipt.activatedAt,
|
|
4671
|
+
runtimePolicyScope
|
|
4672
|
+
});
|
|
6345
4673
|
}
|
|
6346
|
-
|
|
6347
|
-
|
|
6348
|
-
|
|
6349
|
-
|
|
6350
|
-
|
|
6351
|
-
|
|
6352
|
-
}
|
|
4674
|
+
function buildValidatedEncryptedEcdsaReadyMaterial(input) {
|
|
4675
|
+
return new ValidatedEncryptedEcdsaReadyMaterialProof({
|
|
4676
|
+
binding: input.binding,
|
|
4677
|
+
sealingKeyId: input.sealingKeyId,
|
|
4678
|
+
iv12B64u: input.iv12B64u,
|
|
4679
|
+
ciphertextB64u: input.ciphertextB64u
|
|
4680
|
+
});
|
|
6353
4681
|
}
|
|
6354
|
-
|
|
6355
|
-
|
|
6356
|
-
|
|
6357
|
-
|
|
6358
|
-
|
|
6359
|
-
|
|
4682
|
+
function buildActiveEcdsaCapabilityManifest(input) {
|
|
4683
|
+
assertRegisteredPublicFactsMatchBinding(input.registeredPublicFacts, input.activationBinding.roleLocalBinding, input.serverActivation);
|
|
4684
|
+
assertDurableMaterialMatchesActivation(input.durableMaterial, input.activationBinding, input.serverActivation);
|
|
4685
|
+
const signer = new RegisteredEvmFamilySignerProof({
|
|
4686
|
+
preparedSigner: input.activationBinding.signer,
|
|
4687
|
+
registeredPublicFacts: input.registeredPublicFacts
|
|
4688
|
+
});
|
|
4689
|
+
const activation = {
|
|
4690
|
+
kind: "active_ecdsa_material_activation",
|
|
4691
|
+
materialActivation: input.durableMaterial.materialActivation,
|
|
4692
|
+
serverActivation: input.serverActivation,
|
|
4693
|
+
retention: "retained"
|
|
4694
|
+
};
|
|
4695
|
+
return new ActiveEcdsaCapabilityManifestProof({
|
|
4696
|
+
identity: input.activationBinding.targetManifest,
|
|
4697
|
+
signer,
|
|
4698
|
+
activation,
|
|
4699
|
+
durableMaterial: input.durableMaterial,
|
|
4700
|
+
committedAt: input.committedAt
|
|
4701
|
+
});
|
|
6360
4702
|
}
|
|
6361
|
-
|
|
6362
|
-
|
|
6363
|
-
|
|
6364
|
-
|
|
6365
|
-
|
|
6366
|
-
|
|
6367
|
-
|
|
6368
|
-
|
|
4703
|
+
function buildReplacedEcdsaCapabilityManifest(input) {
|
|
4704
|
+
assertValidEcdsaReplacement(input.activeManifest, input.replacementManifest);
|
|
4705
|
+
return new ReplacedEcdsaCapabilityManifestProof({
|
|
4706
|
+
identity: input.activeManifest.identity,
|
|
4707
|
+
signer: input.activeManifest.signer,
|
|
4708
|
+
retirement: {
|
|
4709
|
+
kind: "replaced",
|
|
4710
|
+
replacementManifest: input.replacementManifest.identity,
|
|
4711
|
+
replacementActivation: input.replacementManifest.activation.serverActivation
|
|
4712
|
+
}
|
|
4713
|
+
});
|
|
6369
4714
|
}
|
|
6370
|
-
|
|
6371
|
-
|
|
6372
|
-
|
|
6373
|
-
|
|
6374
|
-
this.kind = "no_current_generation";
|
|
4715
|
+
function assertUniqueEcdsaTargetMemberships(targetMemberships) {
|
|
4716
|
+
const targetKeys = targetMemberships.map(ecdsaTargetMembershipKey);
|
|
4717
|
+
if (new Set(targetKeys).size !== targetKeys.length) {
|
|
4718
|
+
throw new Error("ECDSA capability target memberships must be unique");
|
|
6375
4719
|
}
|
|
6376
4720
|
}
|
|
6377
|
-
|
|
6378
|
-
|
|
6379
|
-
|
|
6380
|
-
|
|
6381
|
-
|
|
6382
|
-
|
|
4721
|
+
function ecdsaTargetMembershipKey(target) {
|
|
4722
|
+
switch (target.kind) {
|
|
4723
|
+
case "evm":
|
|
4724
|
+
return `evm:${target.namespace}:${target.chainId}:${target.networkSlug}`;
|
|
4725
|
+
case "tempo":
|
|
4726
|
+
return `tempo:${target.chainId}:${target.networkSlug}`;
|
|
4727
|
+
default:
|
|
4728
|
+
return assertNever(target);
|
|
6383
4729
|
}
|
|
6384
4730
|
}
|
|
6385
|
-
|
|
6386
|
-
|
|
6387
|
-
|
|
6388
|
-
|
|
6389
|
-
this.kind = "ecdsa_role_local_material_binding";
|
|
6390
|
-
this.keyHandle = fields.keyHandle;
|
|
6391
|
-
this.ecdsaThresholdKeyId = fields.ecdsaThresholdKeyId;
|
|
6392
|
-
this.clientVerifyingPublicKey33B64u = fields.clientVerifyingPublicKey33B64u;
|
|
6393
|
-
this.participantIds = fields.participantIds;
|
|
6394
|
-
this.relayerKeyId = fields.relayerKeyId;
|
|
4731
|
+
function assertUniqueParticipantIds(participantIds) {
|
|
4732
|
+
const normalizedIds = participantIds.map(Number);
|
|
4733
|
+
if (normalizedIds.some((participantId) => !Number.isSafeInteger(participantId) || participantId < 1) || new Set(normalizedIds).size !== normalizedIds.length) {
|
|
4734
|
+
throw new Error("ECDSA participant ids must be unique positive integers");
|
|
6395
4735
|
}
|
|
6396
4736
|
}
|
|
6397
|
-
|
|
6398
|
-
|
|
6399
|
-
|
|
6400
|
-
|
|
6401
|
-
|
|
6402
|
-
|
|
6403
|
-
|
|
6404
|
-
|
|
6405
|
-
|
|
6406
|
-
|
|
6407
|
-
|
|
6408
|
-
|
|
6409
|
-
|
|
4737
|
+
function assertTargetManifestTransition(expected, target) {
|
|
4738
|
+
switch (expected.kind) {
|
|
4739
|
+
case "no_current_manifest":
|
|
4740
|
+
if (Number(target.manifestRevision) !== 1) {
|
|
4741
|
+
throw new Error("Initial ECDSA manifest revision must be 1");
|
|
4742
|
+
}
|
|
4743
|
+
return;
|
|
4744
|
+
case "exact_manifest":
|
|
4745
|
+
if (target.manifestId === expected.manifestId || Number(target.manifestRevision) !== Number(expected.manifestRevision) + 1) {
|
|
4746
|
+
throw new Error("Replacement ECDSA manifest must use a fresh id and next revision");
|
|
4747
|
+
}
|
|
4748
|
+
return;
|
|
4749
|
+
default:
|
|
4750
|
+
return assertNever(expected);
|
|
6410
4751
|
}
|
|
6411
4752
|
}
|
|
6412
|
-
|
|
6413
|
-
|
|
6414
|
-
|
|
6415
|
-
|
|
6416
|
-
|
|
6417
|
-
|
|
6418
|
-
|
|
6419
|
-
|
|
6420
|
-
|
|
6421
|
-
|
|
6422
|
-
|
|
6423
|
-
|
|
6424
|
-
|
|
6425
|
-
|
|
4753
|
+
function assertExpectedStatePair(expectedManifest, expectedGeneration) {
|
|
4754
|
+
switch (expectedManifest.kind) {
|
|
4755
|
+
case "no_current_manifest":
|
|
4756
|
+
if (expectedGeneration.kind !== "no_current_generation") {
|
|
4757
|
+
throw new Error("Initial ECDSA activation cannot expect a server generation");
|
|
4758
|
+
}
|
|
4759
|
+
return;
|
|
4760
|
+
case "exact_manifest":
|
|
4761
|
+
if (expectedGeneration.kind !== "exact_generation") {
|
|
4762
|
+
throw new Error("Replacement ECDSA activation requires an exact server generation");
|
|
4763
|
+
}
|
|
4764
|
+
return;
|
|
4765
|
+
default:
|
|
4766
|
+
return assertNever(expectedManifest);
|
|
6426
4767
|
}
|
|
6427
4768
|
}
|
|
6428
|
-
|
|
6429
|
-
|
|
6430
|
-
|
|
6431
|
-
|
|
6432
|
-
|
|
6433
|
-
this.sealingKeyId = fields.sealingKeyId;
|
|
6434
|
-
this.iv12B64u = fields.iv12B64u;
|
|
6435
|
-
this.ciphertextB64u = fields.ciphertextB64u;
|
|
6436
|
-
this.ciphertextDigest = fields.ciphertextDigest;
|
|
4769
|
+
function assertServerCommitMatchesPreparedCommand(serverCommit, journal) {
|
|
4770
|
+
const canonicalRequest = JSON.parse(journal.activationCommand.canonicalRequest);
|
|
4771
|
+
const requestDigestNamesOuterOperation = canonicalRequest.operation === "wallet_registration_activate_v2";
|
|
4772
|
+
if (serverCommit.correlationId !== journal.activationCommand.correlationId || !requestDigestNamesOuterOperation && serverCommit.activationRequestDigest !== journal.activationCommand.requestDigest) {
|
|
4773
|
+
throw new Error("ECDSA server activation commit does not match the prepared command");
|
|
6437
4774
|
}
|
|
6438
4775
|
}
|
|
6439
|
-
|
|
6440
|
-
|
|
6441
|
-
|
|
6442
|
-
|
|
6443
|
-
|
|
6444
|
-
|
|
6445
|
-
this.signer = fields.signer;
|
|
6446
|
-
this.roleLocalBinding = fields.roleLocalBinding;
|
|
6447
|
-
this.bindingDigest = fields.bindingDigest;
|
|
6448
|
-
this.durableMaterialRef = fields.durableMaterialRef;
|
|
4776
|
+
function assertProtocolReceiptMatchesActivationBinding(receipt, activationBinding) {
|
|
4777
|
+
const publicIdentity = receipt.ecdsa_activation.public_identity;
|
|
4778
|
+
const materialActivation = receipt.ecdsa_activation.material_activation;
|
|
4779
|
+
materialActivationFromCommit(receipt);
|
|
4780
|
+
if (publicIdentity.context_binding_b64u !== String(activationBinding.bindingDigest) || publicIdentity.derivation_client_share_public_key33_b64u !== String(activationBinding.roleLocalBinding.clientVerifyingPublicKey33B64u) || materialActivation.material_owner !== String(activationBinding.signer.materialOwner) || materialActivation.key_binding !== String(activationBinding.bindingDigest) || materialActivation.lifecycle_binding !== receipt.lifecycle_id || materialActivation.signing_worker !== receipt.ecdsa_activation.signing_worker.server_id) {
|
|
4781
|
+
throw new Error("ECDSA activation receipt does not match the prepared material binding");
|
|
6449
4782
|
}
|
|
6450
4783
|
}
|
|
6451
|
-
|
|
6452
|
-
|
|
6453
|
-
|
|
6454
|
-
|
|
6455
|
-
this.kind = "prepared_ecdsa_activation_candidate";
|
|
6456
|
-
this.activationBinding = fields.activationBinding;
|
|
6457
|
-
this.encryptedPending = fields.encryptedPending;
|
|
4784
|
+
function assertProtocolReceiptMatchesServerCommit(receipt, serverCommit) {
|
|
4785
|
+
const receiptRequestDigest = base64UrlEncode(Uint8Array.from(receipt.activation_request_digest.bytes));
|
|
4786
|
+
if (receipt.activation_correlation_id !== serverCommit.correlationId || receiptRequestDigest !== serverCommit.activationRequestDigest || receipt.server_generation !== serverCommit.serverGeneration) {
|
|
4787
|
+
throw new Error("ECDSA activation receipt does not match the server activation commit");
|
|
6458
4788
|
}
|
|
6459
4789
|
}
|
|
6460
|
-
|
|
6461
|
-
|
|
6462
|
-
constructor(fields) {
|
|
6463
|
-
super();
|
|
6464
|
-
this.kind = "ecdsa_server_activation_command";
|
|
6465
|
-
this.correlationId = fields.correlationId;
|
|
6466
|
-
this.expectedGeneration = fields.expectedGeneration;
|
|
6467
|
-
this.requestDigest = fields.requestDigest;
|
|
6468
|
-
this.canonicalRequest = fields.canonicalRequest;
|
|
6469
|
-
}
|
|
4790
|
+
function lifecycleIdFromProtocolReceipt(receipt) {
|
|
4791
|
+
return parseEcdsaLifecycleId(receipt.lifecycle_id);
|
|
6470
4792
|
}
|
|
6471
|
-
|
|
6472
|
-
|
|
6473
|
-
|
|
6474
|
-
|
|
6475
|
-
|
|
6476
|
-
|
|
6477
|
-
|
|
6478
|
-
|
|
6479
|
-
|
|
4793
|
+
function activationDigestFromProtocolReceipt(receipt) {
|
|
4794
|
+
return parseEcdsaActivationDigest(receipt.ecdsa_activation.activation_digest_b64u);
|
|
4795
|
+
}
|
|
4796
|
+
function materialActivationFromCommit(receipt) {
|
|
4797
|
+
return routerAbMpcMaterialActivationRefFromWire(receipt.ecdsa_activation.material_activation);
|
|
4798
|
+
}
|
|
4799
|
+
function assertRegisteredPublicFactsMatchBinding(publicFacts, binding, serverActivation) {
|
|
4800
|
+
const receiptPublicIdentity = serverActivation.serverActivationReceipt.protocolReceipt.ecdsa_activation.public_identity;
|
|
4801
|
+
if (String(publicFacts.keyHandle) !== String(binding.keyHandle) || String(publicFacts.publicKeyB64u) !== receiptPublicIdentity.threshold_public_key33_b64u || String(binding.clientVerifyingPublicKey33B64u) !== receiptPublicIdentity.derivation_client_share_public_key33_b64u || !participantIdsMatch(publicFacts.participantIds, binding.participantIds)) {
|
|
4802
|
+
throw new Error("Registered ECDSA public facts do not match role-local material");
|
|
6480
4803
|
}
|
|
6481
4804
|
}
|
|
6482
|
-
|
|
6483
|
-
|
|
6484
|
-
|
|
6485
|
-
|
|
6486
|
-
this.kind = "ecdsa_server_activation_commit";
|
|
6487
|
-
this.correlationId = fields.correlationId;
|
|
6488
|
-
this.activationRequestDigest = fields.activationRequestDigest;
|
|
6489
|
-
this.serverGeneration = fields.serverGeneration;
|
|
6490
|
-
this.serverActivationReceipt = fields.serverActivationReceipt;
|
|
6491
|
-
}
|
|
4805
|
+
function participantIdsMatch(left, right) {
|
|
4806
|
+
if (left.length !== right.length)
|
|
4807
|
+
return false;
|
|
4808
|
+
return left.every((participantId, index) => Number(participantId) === Number(right[index]));
|
|
6492
4809
|
}
|
|
6493
|
-
|
|
6494
|
-
|
|
6495
|
-
constructor(fields) {
|
|
6496
|
-
super();
|
|
6497
|
-
this.kind = "activation_prepared";
|
|
6498
|
-
this.journalId = fields.journalId;
|
|
6499
|
-
this.expectedManifest = fields.expectedManifest;
|
|
6500
|
-
this.activationCommand = fields.activationCommand;
|
|
6501
|
-
this.candidate = fields.candidate;
|
|
6502
|
-
this.createdAt = fields.createdAt;
|
|
6503
|
-
}
|
|
4810
|
+
function assertServerActivationMatchesBinding(serverActivation, activationBinding) {
|
|
4811
|
+
assertProtocolReceiptMatchesActivationBinding(serverActivation.serverActivationReceipt.protocolReceipt, activationBinding);
|
|
6504
4812
|
}
|
|
6505
|
-
|
|
6506
|
-
|
|
6507
|
-
|
|
6508
|
-
|
|
6509
|
-
|
|
6510
|
-
this.journalId = fields.journalId;
|
|
6511
|
-
this.expectedManifest = fields.expectedManifest;
|
|
6512
|
-
this.activationCommand = fields.activationCommand;
|
|
6513
|
-
this.candidate = fields.candidate;
|
|
6514
|
-
this.createdAt = fields.createdAt;
|
|
6515
|
-
this.serverActivation = fields.serverActivation;
|
|
4813
|
+
function assertDurableMaterialMatchesActivation(durableMaterial, activationBinding, serverActivation) {
|
|
4814
|
+
const receipt = serverActivation.serverActivationReceipt;
|
|
4815
|
+
const committedMaterialActivation = materialActivationFromCommit(receipt.protocolReceipt);
|
|
4816
|
+
if (!mpcMaterialActivationRefsEqual(durableMaterial.materialActivation, committedMaterialActivation) || durableMaterial.roleLocalBinding !== activationBinding.roleLocalBinding || durableMaterial.durableMaterialRef !== activationBinding.durableMaterialRef || durableMaterial.bindingDigest !== activationBinding.bindingDigest || durableMaterial.lifecycleId !== receipt.lifecycleId || durableMaterial.activationDigest !== receipt.activationDigest || durableMaterial.activatedAt !== receipt.activatedAt) {
|
|
4817
|
+
throw new Error("Durable ECDSA material does not match its activation");
|
|
6516
4818
|
}
|
|
4819
|
+
assertNormalSigningMatchesActivation({
|
|
4820
|
+
normalSigning: durableMaterial.routerAbEcdsaDerivationNormalSigning,
|
|
4821
|
+
activationBinding,
|
|
4822
|
+
roleLocalPublicFacts: durableMaterial.roleLocalPublicFacts,
|
|
4823
|
+
receipt: receipt.protocolReceipt
|
|
4824
|
+
});
|
|
6517
4825
|
}
|
|
6518
|
-
|
|
6519
|
-
|
|
6520
|
-
|
|
6521
|
-
|
|
6522
|
-
|
|
6523
|
-
|
|
6524
|
-
|
|
6525
|
-
|
|
6526
|
-
|
|
6527
|
-
|
|
6528
|
-
|
|
6529
|
-
|
|
6530
|
-
|
|
6531
|
-
|
|
6532
|
-
|
|
6533
|
-
this.runtimePolicyScope = fields.runtimePolicyScope;
|
|
4826
|
+
function assertNormalSigningMatchesActivation(input) {
|
|
4827
|
+
const scope = input.normalSigning.scope;
|
|
4828
|
+
const facts = input.roleLocalPublicFacts;
|
|
4829
|
+
const expectedMaterialActivation = materialActivationFromCommit(input.receipt);
|
|
4830
|
+
const expectedMaterialActivationWire = routerAbMpcMaterialActivationRefToWire({
|
|
4831
|
+
kind: expectedMaterialActivation.kind,
|
|
4832
|
+
activationId: expectedMaterialActivation.activationId,
|
|
4833
|
+
capability: expectedMaterialActivation.capability,
|
|
4834
|
+
materialOwner: expectedMaterialActivation.materialOwner,
|
|
4835
|
+
keyBinding: expectedMaterialActivation.keyBinding,
|
|
4836
|
+
lifecycleBinding: expectedMaterialActivation.lifecycleBinding,
|
|
4837
|
+
signingWorker: expectedMaterialActivation.signingWorker
|
|
4838
|
+
});
|
|
4839
|
+
if (scope.wallet_id !== String(input.activationBinding.signer.walletId) || scope.ecdsa_threshold_key_id !== String(input.activationBinding.roleLocalBinding.ecdsaThresholdKeyId) || scope.signing_root_id !== String(input.activationBinding.signer.signingRootId) || scope.signing_root_version !== String(input.activationBinding.signer.signingRootVersion) || scope.context.application_binding_digest_b64u !== input.receipt.ecdsa_activation.context.application_binding_digest_b64u || !sameRouterAbEcdsaDerivationPublicIdentityV1(scope.public_identity, input.receipt.ecdsa_activation.public_identity) || !sameRouterAbServerIdentityV1(scope.signing_worker, input.receipt.ecdsa_activation.signing_worker) || scope.activation_epoch !== input.receipt.ecdsa_activation.activation_epoch || scope.public_identity.context_binding_b64u !== facts.contextBinding32B64u || scope.public_identity.derivation_client_share_public_key33_b64u !== facts.derivationClientSharePublicKey33B64u || scope.public_identity.server_public_key33_b64u !== facts.relayerPublicKey33B64u || scope.public_identity.threshold_public_key33_b64u !== facts.groupPublicKey33B64u || !sameRouterAbMpcMaterialActivationRef(scope.material_activation, expectedMaterialActivationWire)) {
|
|
4840
|
+
throw new Error("ECDSA normal-signing runtime does not match its activation");
|
|
6534
4841
|
}
|
|
6535
4842
|
}
|
|
6536
|
-
|
|
6537
|
-
|
|
6538
|
-
|
|
6539
|
-
super();
|
|
6540
|
-
this.kind = "encrypted_ecdsa_ready_material";
|
|
6541
|
-
this.binding = fields.binding;
|
|
6542
|
-
this.sealingKeyId = fields.sealingKeyId;
|
|
6543
|
-
this.iv12B64u = fields.iv12B64u;
|
|
6544
|
-
this.ciphertextB64u = fields.ciphertextB64u;
|
|
4843
|
+
function assertValidEcdsaReplacement(active, replacement) {
|
|
4844
|
+
if (active.identity.manifestId === replacement.identity.manifestId || Number(replacement.identity.manifestRevision) !== Number(active.identity.manifestRevision) + 1 || active.signer.capability !== replacement.signer.capability || active.signer.signerId !== replacement.signer.signerId || active.signer.walletId !== replacement.signer.walletId || active.signer.authority.authorityDigest !== replacement.signer.authority.authorityDigest || active.signer.materialOwner !== replacement.signer.materialOwner || active.durableMaterial.durableMaterialRef === replacement.durableMaterial.durableMaterialRef || active.activation.serverActivation.serverGeneration === replacement.activation.serverActivation.serverGeneration) {
|
|
4845
|
+
throw new Error("ECDSA replacement manifest does not exactly replace the active manifest");
|
|
6545
4846
|
}
|
|
6546
4847
|
}
|
|
4848
|
+
function assertNever(value) {
|
|
4849
|
+
throw new Error(`Unexpected ECDSA capability branch: ${String(value)}`);
|
|
4850
|
+
}
|
|
6547
4851
|
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
|
|
6551
|
-
|
|
6552
|
-
|
|
6553
|
-
|
|
6554
|
-
|
|
6555
|
-
|
|
6556
|
-
|
|
4852
|
+
// src/core/indexedDB/schemaNames.ts
|
|
4853
|
+
var SEAMS_WALLET_DB_NAME = "seams_wallet";
|
|
4854
|
+
var SEAMS_WALLET_DB_VERSION = 24;
|
|
4855
|
+
var SEAMS_WALLET_STORES = {
|
|
4856
|
+
appState: "app_state",
|
|
4857
|
+
wallets: "wallets",
|
|
4858
|
+
walletAuthorities: "wallet_authorities",
|
|
4859
|
+
walletAuthMethods: "wallet_auth_methods",
|
|
4860
|
+
walletAuthoritySignerMaterials: "wallet_authority_signer_materials",
|
|
4861
|
+
walletAuthorityExportRoots: "wallet_authority_export_roots",
|
|
4862
|
+
walletAuthorityInstallationReceipts: "wallet_authority_installation_receipts",
|
|
4863
|
+
walletSelections: "wallet_selections",
|
|
4864
|
+
walletSigners: "wallet_signers",
|
|
4865
|
+
nearAccountProjections: "near_accounts",
|
|
4866
|
+
signerOpsOutbox: "signer_ops_outbox",
|
|
4867
|
+
nonceLaneLeases: "nonce_lane_leases",
|
|
4868
|
+
nonceLaneLocks: "nonce_lane_locks",
|
|
4869
|
+
keyMaterial: "key_material",
|
|
4870
|
+
signingSessionSeals: "signing_session_seals",
|
|
4871
|
+
signingSessionRestoreLeases: "signing_session_restore_leases",
|
|
4872
|
+
pendingWalletRecoveryCodeBackups: "email_otp_pending_recovery_code_backups",
|
|
4873
|
+
walletSessionAuthorizations: "wallet_session_authorizations",
|
|
4874
|
+
ecdsaCapabilityManifests: "ecdsa_capability_manifests",
|
|
4875
|
+
ecdsaCurrentCapabilityManifests: "ecdsa_current_capability_manifests",
|
|
4876
|
+
ecdsaRoleLocalMaterial: "ecdsa_role_local_material",
|
|
4877
|
+
ecdsaActivationCommitJournals: "ecdsa_activation_commit_journals",
|
|
4878
|
+
ecdsaMaterialSealingKeys: "ecdsa_material_sealing_keys",
|
|
4879
|
+
ecdsaClientPresignatures: "ecdsa_client_presignatures"
|
|
4880
|
+
};
|
|
4881
|
+
var SEAMS_WALLET_INDEXES = {
|
|
4882
|
+
profileId: "profile_id",
|
|
4883
|
+
updatedAt: "updated_at",
|
|
4884
|
+
walletId: "wallet_id",
|
|
4885
|
+
walletIdKind: "wallet_id_kind",
|
|
4886
|
+
walletKindNearSignerSlot: "wallet_kind_near_signer_slot",
|
|
4887
|
+
walletKindNearEd25519SigningKeyId: "wallet_kind_near_ed25519_signing_key_id",
|
|
4888
|
+
walletKindChainTargetKeyHandle: "wallet_kind_chain_target_key_handle",
|
|
4889
|
+
walletKindChainTargetKeyFacts: "wallet_kind_chain_target_key_facts",
|
|
4890
|
+
walletSignerId: "wallet_signer_id",
|
|
4891
|
+
nearAccountId: "near_account_id",
|
|
4892
|
+
rpId: "rp_id",
|
|
4893
|
+
chainTargetKey: "chain_target_key",
|
|
4894
|
+
keyHandle: "key_handle",
|
|
4895
|
+
thresholdOwnerAddress: "threshold_owner_address",
|
|
4896
|
+
status: "status",
|
|
4897
|
+
nextAttemptAt: "next_attempt_at",
|
|
4898
|
+
statusNextAttemptAt: "status_next_attempt_at",
|
|
4899
|
+
idempotencyKey: "idempotency_key",
|
|
4900
|
+
laneKey: "lane_key",
|
|
4901
|
+
state: "state",
|
|
4902
|
+
expiresAtMs: "expires_at_ms",
|
|
4903
|
+
recoveryCodesIssuedAtMs: "recovery_codes_issued_at_ms",
|
|
4904
|
+
laneState: "lane_state",
|
|
4905
|
+
walletExpiresAt: "wallet_expires_at",
|
|
4906
|
+
ownerId: "owner_id",
|
|
4907
|
+
publicKey: "public_key",
|
|
4908
|
+
authMethod: "auth_method",
|
|
4909
|
+
curve: "curve",
|
|
4910
|
+
ed25519ThresholdSessionId: "ed25519_threshold_session_id",
|
|
4911
|
+
ecdsaThresholdSessionId: "ecdsa_threshold_session_id",
|
|
4912
|
+
thresholdSessionId: "threshold_session_id",
|
|
4913
|
+
exactSigningLaneIdentityKey: "exact_signing_lane_identity_key",
|
|
4914
|
+
enrollmentId: "enrollment_id",
|
|
4915
|
+
walletIdEnrollmentId: "wallet_id_enrollment_id",
|
|
4916
|
+
authIdentifierKey: "auth_identifier_key",
|
|
4917
|
+
kindRpIdAuthIdentifier: "kind_rp_id_auth_identifier",
|
|
4918
|
+
passkeyRpIdCredentialId: "passkey_rp_id_credential_id",
|
|
4919
|
+
capabilityWallet: "capability_wallet",
|
|
4920
|
+
capabilityWalletAuthorityState: "capability_wallet_authority_state",
|
|
4921
|
+
capabilityWalletAuthority: "capability_wallet_authority",
|
|
4922
|
+
walletAuthorityId: "wallet_authority_id",
|
|
4923
|
+
walletAuthMethodId: "wallet_auth_method_id",
|
|
4924
|
+
walletIdAuthorityId: "wallet_id_authority_id",
|
|
4925
|
+
walletIdAuthorityStatus: "wallet_id_authority_status",
|
|
4926
|
+
walletIdAuthMethodId: "wallet_id_auth_method_id",
|
|
4927
|
+
walletAuthorityAuthMethodId: "wallet_authority_auth_method_id",
|
|
4928
|
+
activationId: "activation_id",
|
|
4929
|
+
walletAuthorityActivationId: "wallet_authority_activation_id",
|
|
4930
|
+
walletIdDeviceId: "wallet_id_device_id",
|
|
4931
|
+
packageSetDigest: "package_set_digest",
|
|
4932
|
+
walletKeyId: "wallet_key_id",
|
|
4933
|
+
walletIdLockGeneration: "wallet_id_lock_generation",
|
|
4934
|
+
authorityDigest: "authority_digest",
|
|
4935
|
+
revocationEpoch: "revocation_epoch",
|
|
4936
|
+
poolIdentityKey: "pool_identity_key",
|
|
4937
|
+
walletMaterialActivationId: "wallet_material_activation_id"
|
|
4938
|
+
};
|
|
4939
|
+
var SEAMS_WALLET_SCHEMA_MANIFEST = [
|
|
4940
|
+
{
|
|
4941
|
+
store: SEAMS_WALLET_STORES.appState,
|
|
4942
|
+
keyPath: "key",
|
|
4943
|
+
indexes: []
|
|
4944
|
+
},
|
|
4945
|
+
{
|
|
4946
|
+
store: SEAMS_WALLET_STORES.wallets,
|
|
4947
|
+
keyPath: "wallet_id",
|
|
4948
|
+
indexes: [
|
|
4949
|
+
{ name: SEAMS_WALLET_INDEXES.rpId, keyPath: "rp_id", unique: false },
|
|
4950
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
4951
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
4952
|
+
]
|
|
4953
|
+
},
|
|
4954
|
+
{
|
|
4955
|
+
store: SEAMS_WALLET_STORES.walletAuthorities,
|
|
4956
|
+
keyPath: "authority_id",
|
|
4957
|
+
indexes: [
|
|
4958
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
4959
|
+
{ name: SEAMS_WALLET_INDEXES.walletAuthorityId, keyPath: "authority_id", unique: true },
|
|
4960
|
+
{
|
|
4961
|
+
name: SEAMS_WALLET_INDEXES.walletIdAuthorityId,
|
|
4962
|
+
keyPath: ["wallet_id", "authority_id"],
|
|
4963
|
+
unique: true
|
|
4964
|
+
},
|
|
4965
|
+
{
|
|
4966
|
+
name: SEAMS_WALLET_INDEXES.walletIdAuthorityStatus,
|
|
4967
|
+
keyPath: ["wallet_id", "state"],
|
|
4968
|
+
unique: false
|
|
4969
|
+
},
|
|
4970
|
+
{
|
|
4971
|
+
name: SEAMS_WALLET_INDEXES.walletIdDeviceId,
|
|
4972
|
+
keyPath: ["wallet_id", "device_id"],
|
|
4973
|
+
unique: false
|
|
4974
|
+
},
|
|
4975
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
4976
|
+
]
|
|
4977
|
+
},
|
|
4978
|
+
{
|
|
4979
|
+
store: SEAMS_WALLET_STORES.walletAuthMethods,
|
|
4980
|
+
keyPath: "wallet_auth_method_id",
|
|
4981
|
+
indexes: [
|
|
4982
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
4983
|
+
{
|
|
4984
|
+
name: SEAMS_WALLET_INDEXES.walletIdKind,
|
|
4985
|
+
keyPath: ["wallet_id", "kind"],
|
|
4986
|
+
unique: false
|
|
4987
|
+
},
|
|
4988
|
+
{ name: SEAMS_WALLET_INDEXES.authMethod, keyPath: "auth_method", unique: false },
|
|
4989
|
+
{ name: SEAMS_WALLET_INDEXES.rpId, keyPath: "rp_id", unique: false },
|
|
4990
|
+
{
|
|
4991
|
+
name: SEAMS_WALLET_INDEXES.authIdentifierKey,
|
|
4992
|
+
keyPath: "auth_identifier_key",
|
|
4993
|
+
unique: false
|
|
4994
|
+
},
|
|
4995
|
+
{
|
|
4996
|
+
name: SEAMS_WALLET_INDEXES.kindRpIdAuthIdentifier,
|
|
4997
|
+
keyPath: ["kind", "rp_id", "auth_identifier_key"],
|
|
4998
|
+
unique: false
|
|
4999
|
+
},
|
|
5000
|
+
{
|
|
5001
|
+
name: SEAMS_WALLET_INDEXES.passkeyRpIdCredentialId,
|
|
5002
|
+
keyPath: ["kind", "rp_id", "credential_id_b64u"],
|
|
5003
|
+
unique: true
|
|
5004
|
+
},
|
|
5005
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5006
|
+
{
|
|
5007
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5008
|
+
keyPath: "wallet_authority_id",
|
|
5009
|
+
unique: false
|
|
5010
|
+
},
|
|
5011
|
+
{
|
|
5012
|
+
name: SEAMS_WALLET_INDEXES.walletIdAuthMethodId,
|
|
5013
|
+
keyPath: ["wallet_id", "wallet_auth_method_id"],
|
|
5014
|
+
unique: true
|
|
5015
|
+
},
|
|
5016
|
+
{
|
|
5017
|
+
name: SEAMS_WALLET_INDEXES.walletIdAuthorityStatus,
|
|
5018
|
+
keyPath: ["wallet_id", "wallet_authority_id", "status"],
|
|
5019
|
+
unique: false
|
|
5020
|
+
},
|
|
5021
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5022
|
+
]
|
|
5023
|
+
},
|
|
5024
|
+
{
|
|
5025
|
+
store: SEAMS_WALLET_STORES.walletAuthoritySignerMaterials,
|
|
5026
|
+
keyPath: ["wallet_authority_id", "wallet_auth_method_id", "activation_id"],
|
|
5027
|
+
indexes: [
|
|
5028
|
+
{
|
|
5029
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5030
|
+
keyPath: "wallet_authority_id",
|
|
5031
|
+
unique: false
|
|
5032
|
+
},
|
|
5033
|
+
{
|
|
5034
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityAuthMethodId,
|
|
5035
|
+
keyPath: ["wallet_authority_id", "wallet_auth_method_id"],
|
|
5036
|
+
unique: false
|
|
5037
|
+
},
|
|
5038
|
+
{ name: SEAMS_WALLET_INDEXES.activationId, keyPath: "activation_id", unique: false },
|
|
5039
|
+
{
|
|
5040
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityActivationId,
|
|
5041
|
+
keyPath: ["wallet_authority_id", "activation_id"],
|
|
5042
|
+
unique: true
|
|
5043
|
+
}
|
|
5044
|
+
]
|
|
5045
|
+
},
|
|
5046
|
+
{
|
|
5047
|
+
store: SEAMS_WALLET_STORES.walletAuthorityExportRoots,
|
|
5048
|
+
keyPath: ["wallet_authority_id", "wallet_auth_method_id", "wallet_key_id"],
|
|
5049
|
+
indexes: [
|
|
5050
|
+
{
|
|
5051
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5052
|
+
keyPath: "wallet_authority_id",
|
|
5053
|
+
unique: false
|
|
5054
|
+
},
|
|
5055
|
+
{
|
|
5056
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityAuthMethodId,
|
|
5057
|
+
keyPath: ["wallet_authority_id", "wallet_auth_method_id"],
|
|
5058
|
+
unique: false
|
|
5059
|
+
},
|
|
5060
|
+
{ name: SEAMS_WALLET_INDEXES.walletKeyId, keyPath: "wallet_key_id", unique: false }
|
|
5061
|
+
]
|
|
5062
|
+
},
|
|
5063
|
+
{
|
|
5064
|
+
store: SEAMS_WALLET_STORES.walletAuthorityInstallationReceipts,
|
|
5065
|
+
keyPath: "authority_id",
|
|
5066
|
+
indexes: [
|
|
5067
|
+
{ name: SEAMS_WALLET_INDEXES.walletAuthorityId, keyPath: "authority_id", unique: true },
|
|
5068
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5069
|
+
{
|
|
5070
|
+
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5071
|
+
keyPath: "wallet_auth_method_id",
|
|
5072
|
+
unique: false
|
|
5073
|
+
},
|
|
5074
|
+
{
|
|
5075
|
+
name: SEAMS_WALLET_INDEXES.walletIdDeviceId,
|
|
5076
|
+
keyPath: ["wallet_id", "device_id"],
|
|
5077
|
+
unique: false
|
|
5078
|
+
},
|
|
5079
|
+
{
|
|
5080
|
+
name: SEAMS_WALLET_INDEXES.packageSetDigest,
|
|
5081
|
+
keyPath: "package_set_digest_b64u",
|
|
5082
|
+
unique: false
|
|
5083
|
+
},
|
|
5084
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "installed_at_ms", unique: false }
|
|
5085
|
+
]
|
|
5086
|
+
},
|
|
5087
|
+
{
|
|
5088
|
+
store: SEAMS_WALLET_STORES.walletSelections,
|
|
5089
|
+
keyPath: "wallet_id",
|
|
5090
|
+
indexes: [
|
|
5091
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: true },
|
|
5092
|
+
{
|
|
5093
|
+
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5094
|
+
keyPath: "wallet_auth_method_id",
|
|
5095
|
+
unique: false
|
|
5096
|
+
},
|
|
5097
|
+
{
|
|
5098
|
+
name: SEAMS_WALLET_INDEXES.walletIdLockGeneration,
|
|
5099
|
+
keyPath: ["wallet_id", "lock_generation"],
|
|
5100
|
+
unique: true
|
|
5101
|
+
}
|
|
5102
|
+
]
|
|
5103
|
+
},
|
|
5104
|
+
{
|
|
5105
|
+
store: SEAMS_WALLET_STORES.walletSigners,
|
|
5106
|
+
keyPath: "wallet_signer_id",
|
|
5107
|
+
indexes: [
|
|
5108
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5109
|
+
{
|
|
5110
|
+
name: SEAMS_WALLET_INDEXES.walletIdKind,
|
|
5111
|
+
keyPath: ["wallet_id", "kind"],
|
|
5112
|
+
unique: false
|
|
5113
|
+
},
|
|
5114
|
+
{
|
|
5115
|
+
name: SEAMS_WALLET_INDEXES.walletKindNearSignerSlot,
|
|
5116
|
+
keyPath: ["wallet_id", "kind", "near_signer_slot"],
|
|
5117
|
+
unique: false
|
|
5118
|
+
},
|
|
5119
|
+
{
|
|
5120
|
+
name: SEAMS_WALLET_INDEXES.walletKindNearEd25519SigningKeyId,
|
|
5121
|
+
keyPath: ["wallet_id", "kind", "near_ed25519_signing_key_id"],
|
|
5122
|
+
unique: false
|
|
5123
|
+
},
|
|
5124
|
+
{
|
|
5125
|
+
name: SEAMS_WALLET_INDEXES.walletKindChainTargetKeyHandle,
|
|
5126
|
+
keyPath: ["wallet_id", "kind", "chain_target_key", "key_handle"],
|
|
5127
|
+
unique: true
|
|
5128
|
+
},
|
|
5129
|
+
{
|
|
5130
|
+
name: SEAMS_WALLET_INDEXES.walletKindChainTargetKeyFacts,
|
|
5131
|
+
keyPath: ["wallet_id", "kind", "chain_target_key", "ecdsa_threshold_key_id"],
|
|
5132
|
+
unique: true
|
|
5133
|
+
},
|
|
5134
|
+
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5135
|
+
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5136
|
+
{
|
|
5137
|
+
name: SEAMS_WALLET_INDEXES.thresholdOwnerAddress,
|
|
5138
|
+
keyPath: "threshold_owner_address",
|
|
5139
|
+
unique: false
|
|
5140
|
+
},
|
|
5141
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5142
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5143
|
+
]
|
|
5144
|
+
},
|
|
5145
|
+
{
|
|
5146
|
+
store: SEAMS_WALLET_STORES.nearAccountProjections,
|
|
5147
|
+
keyPath: ["wallet_id", "near_account_id", "signer_slot"],
|
|
5148
|
+
indexes: [
|
|
5149
|
+
{ name: SEAMS_WALLET_INDEXES.nearAccountId, keyPath: "near_account_id", unique: false },
|
|
5150
|
+
{ name: SEAMS_WALLET_INDEXES.profileId, keyPath: "profile_id", unique: false },
|
|
5151
|
+
{ name: SEAMS_WALLET_INDEXES.publicKey, keyPath: "public_key", unique: false },
|
|
5152
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5153
|
+
]
|
|
5154
|
+
},
|
|
5155
|
+
{
|
|
5156
|
+
store: SEAMS_WALLET_STORES.signerOpsOutbox,
|
|
5157
|
+
keyPath: "op_id",
|
|
5158
|
+
indexes: [
|
|
5159
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5160
|
+
{ name: SEAMS_WALLET_INDEXES.nextAttemptAt, keyPath: "next_attempt_at", unique: false },
|
|
5161
|
+
{
|
|
5162
|
+
name: SEAMS_WALLET_INDEXES.statusNextAttemptAt,
|
|
5163
|
+
keyPath: ["status", "next_attempt_at"],
|
|
5164
|
+
unique: false
|
|
5165
|
+
},
|
|
5166
|
+
{ name: SEAMS_WALLET_INDEXES.idempotencyKey, keyPath: "idempotency_key", unique: true },
|
|
5167
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5168
|
+
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false }
|
|
5169
|
+
]
|
|
5170
|
+
},
|
|
5171
|
+
{
|
|
5172
|
+
store: SEAMS_WALLET_STORES.nonceLaneLeases,
|
|
5173
|
+
keyPath: "lease_id",
|
|
5174
|
+
indexes: [
|
|
5175
|
+
{ name: SEAMS_WALLET_INDEXES.laneKey, keyPath: "lane_key", unique: false },
|
|
5176
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5177
|
+
{ name: SEAMS_WALLET_INDEXES.nearAccountId, keyPath: "near_account_id", unique: false },
|
|
5178
|
+
{ name: SEAMS_WALLET_INDEXES.state, keyPath: "state", unique: false },
|
|
5179
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5180
|
+
{ name: SEAMS_WALLET_INDEXES.laneState, keyPath: ["lane_key", "state"], unique: false },
|
|
5181
|
+
{
|
|
5182
|
+
name: SEAMS_WALLET_INDEXES.walletExpiresAt,
|
|
5183
|
+
keyPath: ["wallet_id", "expires_at_ms"],
|
|
5184
|
+
unique: false
|
|
5185
|
+
}
|
|
5186
|
+
]
|
|
5187
|
+
},
|
|
5188
|
+
{
|
|
5189
|
+
store: SEAMS_WALLET_STORES.nonceLaneLocks,
|
|
5190
|
+
keyPath: "lock_key",
|
|
5191
|
+
indexes: [
|
|
5192
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5193
|
+
{ name: SEAMS_WALLET_INDEXES.ownerId, keyPath: "owner_id", unique: false }
|
|
5194
|
+
]
|
|
5195
|
+
},
|
|
5196
|
+
{
|
|
5197
|
+
store: SEAMS_WALLET_STORES.keyMaterial,
|
|
5198
|
+
keyPath: "key_material_id",
|
|
5199
|
+
indexes: [
|
|
5200
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5201
|
+
{ name: SEAMS_WALLET_INDEXES.walletSignerId, keyPath: "wallet_signer_id", unique: false },
|
|
5202
|
+
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5203
|
+
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5204
|
+
{ name: SEAMS_WALLET_INDEXES.publicKey, keyPath: "public_key", unique: false },
|
|
5205
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5206
|
+
]
|
|
5207
|
+
},
|
|
5208
|
+
{
|
|
5209
|
+
store: SEAMS_WALLET_STORES.signingSessionSeals,
|
|
5210
|
+
keyPath: "store_key",
|
|
5211
|
+
indexes: [
|
|
5212
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5213
|
+
{ name: SEAMS_WALLET_INDEXES.authMethod, keyPath: "auth_method", unique: false },
|
|
5214
|
+
{ name: SEAMS_WALLET_INDEXES.curve, keyPath: "curve", unique: false },
|
|
5215
|
+
{
|
|
5216
|
+
name: SEAMS_WALLET_INDEXES.ed25519ThresholdSessionId,
|
|
5217
|
+
keyPath: "ed25519_threshold_session_id",
|
|
5218
|
+
unique: false
|
|
5219
|
+
},
|
|
5220
|
+
{
|
|
5221
|
+
name: SEAMS_WALLET_INDEXES.ecdsaThresholdSessionId,
|
|
5222
|
+
keyPath: "ecdsa_threshold_session_id",
|
|
5223
|
+
unique: false
|
|
5224
|
+
},
|
|
5225
|
+
{
|
|
5226
|
+
name: SEAMS_WALLET_INDEXES.thresholdSessionId,
|
|
5227
|
+
keyPath: "threshold_session_id",
|
|
5228
|
+
unique: false
|
|
5229
|
+
},
|
|
5230
|
+
{ name: SEAMS_WALLET_INDEXES.enrollmentId, keyPath: "enrollmentId", unique: false },
|
|
5231
|
+
{ name: SEAMS_WALLET_INDEXES.keyHandle, keyPath: "key_handle", unique: false },
|
|
5232
|
+
{ name: SEAMS_WALLET_INDEXES.chainTargetKey, keyPath: "chain_target_key", unique: false },
|
|
5233
|
+
{
|
|
5234
|
+
name: SEAMS_WALLET_INDEXES.exactSigningLaneIdentityKey,
|
|
5235
|
+
keyPath: "exact_signing_lane_identity_key",
|
|
5236
|
+
unique: false
|
|
5237
|
+
},
|
|
5238
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5239
|
+
{ name: SEAMS_WALLET_INDEXES.updatedAt, keyPath: "updated_at", unique: false }
|
|
5240
|
+
]
|
|
5241
|
+
},
|
|
5242
|
+
{
|
|
5243
|
+
store: SEAMS_WALLET_STORES.signingSessionRestoreLeases,
|
|
5244
|
+
keyPath: "lease_key",
|
|
5245
|
+
indexes: [
|
|
5246
|
+
{
|
|
5247
|
+
name: SEAMS_WALLET_INDEXES.thresholdSessionId,
|
|
5248
|
+
keyPath: "threshold_session_id",
|
|
5249
|
+
unique: false
|
|
5250
|
+
},
|
|
5251
|
+
{ name: SEAMS_WALLET_INDEXES.ownerId, keyPath: "owner_id", unique: false },
|
|
5252
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false }
|
|
5253
|
+
]
|
|
5254
|
+
},
|
|
5255
|
+
{
|
|
5256
|
+
store: SEAMS_WALLET_STORES.pendingWalletRecoveryCodeBackups,
|
|
5257
|
+
keyPath: ["wallet_id", "enrollment_id"],
|
|
5258
|
+
indexes: [
|
|
5259
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5260
|
+
{ name: SEAMS_WALLET_INDEXES.enrollmentId, keyPath: "enrollment_id", unique: false },
|
|
5261
|
+
{
|
|
5262
|
+
name: SEAMS_WALLET_INDEXES.walletIdEnrollmentId,
|
|
5263
|
+
keyPath: ["wallet_id", "enrollment_id"],
|
|
5264
|
+
unique: true
|
|
5265
|
+
},
|
|
5266
|
+
{
|
|
5267
|
+
name: SEAMS_WALLET_INDEXES.recoveryCodesIssuedAtMs,
|
|
5268
|
+
keyPath: "recovery_codes_issued_at_ms",
|
|
5269
|
+
unique: false
|
|
5270
|
+
},
|
|
5271
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false }
|
|
5272
|
+
]
|
|
5273
|
+
},
|
|
5274
|
+
{
|
|
5275
|
+
store: SEAMS_WALLET_STORES.walletSessionAuthorizations,
|
|
5276
|
+
keyPath: "wallet_session_id",
|
|
5277
|
+
indexes: [
|
|
5278
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5279
|
+
{
|
|
5280
|
+
name: SEAMS_WALLET_INDEXES.walletAuthorityId,
|
|
5281
|
+
keyPath: "wallet_authority_id",
|
|
5282
|
+
unique: false
|
|
5283
|
+
},
|
|
5284
|
+
{
|
|
5285
|
+
name: SEAMS_WALLET_INDEXES.walletAuthMethodId,
|
|
5286
|
+
keyPath: "wallet_auth_method_id",
|
|
5287
|
+
unique: false
|
|
5288
|
+
},
|
|
5289
|
+
{
|
|
5290
|
+
name: SEAMS_WALLET_INDEXES.authorityDigest,
|
|
5291
|
+
keyPath: "authority_digest_b64u",
|
|
5292
|
+
unique: false
|
|
5293
|
+
},
|
|
5294
|
+
{
|
|
5295
|
+
name: SEAMS_WALLET_INDEXES.revocationEpoch,
|
|
5296
|
+
keyPath: "authority_revocation_epoch",
|
|
5297
|
+
unique: false
|
|
5298
|
+
},
|
|
5299
|
+
{ name: SEAMS_WALLET_INDEXES.status, keyPath: "status", unique: false },
|
|
5300
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false }
|
|
5301
|
+
]
|
|
5302
|
+
},
|
|
5303
|
+
{
|
|
5304
|
+
store: SEAMS_WALLET_STORES.ecdsaCapabilityManifests,
|
|
5305
|
+
keyPath: "manifest_id",
|
|
5306
|
+
indexes: [
|
|
5307
|
+
{
|
|
5308
|
+
name: SEAMS_WALLET_INDEXES.capabilityWallet,
|
|
5309
|
+
keyPath: ["capability_ref", "wallet_id"],
|
|
5310
|
+
unique: false
|
|
5311
|
+
},
|
|
5312
|
+
{
|
|
5313
|
+
name: SEAMS_WALLET_INDEXES.capabilityWalletAuthorityState,
|
|
5314
|
+
keyPath: ["capability_ref", "wallet_id", "authority_digest", "manifest_state"],
|
|
5315
|
+
unique: false
|
|
5316
|
+
}
|
|
5317
|
+
]
|
|
5318
|
+
},
|
|
5319
|
+
{
|
|
5320
|
+
store: SEAMS_WALLET_STORES.ecdsaCurrentCapabilityManifests,
|
|
5321
|
+
keyPath: ["capability_ref", "wallet_id", "authority_digest"],
|
|
5322
|
+
indexes: [{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false }]
|
|
5323
|
+
},
|
|
5324
|
+
{
|
|
5325
|
+
store: SEAMS_WALLET_STORES.ecdsaRoleLocalMaterial,
|
|
5326
|
+
keyPath: "durable_material_ref",
|
|
5327
|
+
indexes: []
|
|
5328
|
+
},
|
|
5329
|
+
{
|
|
5330
|
+
store: SEAMS_WALLET_STORES.ecdsaActivationCommitJournals,
|
|
5331
|
+
keyPath: "journal_id",
|
|
5332
|
+
indexes: [
|
|
5333
|
+
{
|
|
5334
|
+
name: SEAMS_WALLET_INDEXES.capabilityWalletAuthority,
|
|
5335
|
+
keyPath: ["capability_ref", "wallet_id", "authority_digest"],
|
|
5336
|
+
unique: true
|
|
5337
|
+
}
|
|
5338
|
+
]
|
|
5339
|
+
},
|
|
5340
|
+
{
|
|
5341
|
+
store: SEAMS_WALLET_STORES.ecdsaMaterialSealingKeys,
|
|
5342
|
+
keyPath: "key_id",
|
|
5343
|
+
indexes: []
|
|
5344
|
+
},
|
|
5345
|
+
{
|
|
5346
|
+
store: SEAMS_WALLET_STORES.ecdsaClientPresignatures,
|
|
5347
|
+
keyPath: "record_id",
|
|
5348
|
+
indexes: [
|
|
5349
|
+
{ name: SEAMS_WALLET_INDEXES.poolIdentityKey, keyPath: "pool_identity_key", unique: false },
|
|
5350
|
+
{ name: SEAMS_WALLET_INDEXES.walletId, keyPath: "wallet_id", unique: false },
|
|
5351
|
+
{
|
|
5352
|
+
name: SEAMS_WALLET_INDEXES.walletMaterialActivationId,
|
|
5353
|
+
keyPath: ["wallet_id", "material_activation_id"],
|
|
5354
|
+
unique: false
|
|
5355
|
+
},
|
|
5356
|
+
{ name: SEAMS_WALLET_INDEXES.expiresAtMs, keyPath: "expires_at_ms", unique: false },
|
|
5357
|
+
{
|
|
5358
|
+
name: SEAMS_WALLET_INDEXES.walletExpiresAt,
|
|
5359
|
+
keyPath: ["wallet_id", "expires_at_ms"],
|
|
5360
|
+
unique: false
|
|
5361
|
+
}
|
|
5362
|
+
]
|
|
6557
5363
|
}
|
|
6558
|
-
|
|
5364
|
+
];
|
|
6559
5365
|
|
|
6560
|
-
|
|
6561
|
-
|
|
6562
|
-
|
|
6563
|
-
|
|
6564
|
-
|
|
6565
|
-
|
|
6566
|
-
|
|
6567
|
-
|
|
6568
|
-
|
|
6569
|
-
|
|
6570
|
-
|
|
6571
|
-
|
|
6572
|
-
return result.value;
|
|
6573
|
-
}
|
|
6574
|
-
function buildEcdsaCapabilityScope(input) {
|
|
6575
|
-
assertUniqueEcdsaTargetMemberships(input.targetMemberships);
|
|
6576
|
-
return new EcdsaCapabilityScopeProof([...input.targetMemberships]);
|
|
6577
|
-
}
|
|
6578
|
-
function buildEcdsaManifestIdentity(input) {
|
|
6579
|
-
return new EcdsaManifestIdentityProof(input);
|
|
6580
|
-
}
|
|
6581
|
-
function buildNoCurrentEcdsaManifestExpectation() {
|
|
6582
|
-
return new NoCurrentEcdsaManifestExpectationProof;
|
|
6583
|
-
}
|
|
6584
|
-
function buildExactEcdsaManifestExpectation(identity) {
|
|
6585
|
-
return new ExactEcdsaManifestExpectationProof(identity);
|
|
6586
|
-
}
|
|
6587
|
-
function buildNoCurrentEcdsaServerGenerationExpectation() {
|
|
6588
|
-
return new NoCurrentEcdsaServerGenerationExpectationProof;
|
|
6589
|
-
}
|
|
6590
|
-
function buildExactEcdsaServerGenerationExpectation(serverGeneration) {
|
|
6591
|
-
return new ExactEcdsaServerGenerationExpectationProof(serverGeneration);
|
|
6592
|
-
}
|
|
6593
|
-
function buildEcdsaRoleLocalMaterialBinding(input) {
|
|
6594
|
-
assertUniqueParticipantIds(input.participantIds);
|
|
6595
|
-
return new EcdsaRoleLocalMaterialBindingProof({
|
|
6596
|
-
keyHandle: input.keyHandle,
|
|
6597
|
-
ecdsaThresholdKeyId: input.ecdsaThresholdKeyId,
|
|
6598
|
-
clientVerifyingPublicKey33B64u: input.clientVerifyingPublicKey33B64u,
|
|
6599
|
-
participantIds: [...input.participantIds],
|
|
6600
|
-
relayerKeyId: input.relayerKeyId
|
|
6601
|
-
});
|
|
6602
|
-
}
|
|
6603
|
-
function buildPreparedEvmFamilySigner(input) {
|
|
6604
|
-
return new PreparedEvmFamilySignerProof(input);
|
|
6605
|
-
}
|
|
6606
|
-
function buildEncryptedEcdsaPendingCandidate(input) {
|
|
6607
|
-
return new EncryptedEcdsaPendingCandidateProof(input);
|
|
6608
|
-
}
|
|
6609
|
-
function buildEcdsaActivationBinding(input) {
|
|
6610
|
-
return new EcdsaActivationBindingProof(input);
|
|
6611
|
-
}
|
|
6612
|
-
function buildPreparedEcdsaActivationCandidate(input) {
|
|
6613
|
-
return new PreparedEcdsaActivationCandidateProof(input);
|
|
6614
|
-
}
|
|
6615
|
-
function buildPreparedEcdsaActivationJournal(input) {
|
|
6616
|
-
assertTargetManifestTransition(input.expectedManifest, input.candidate.activationBinding.targetManifest);
|
|
6617
|
-
assertExpectedStatePair(input.expectedManifest, input.expectedGeneration);
|
|
6618
|
-
const activationCommand = new EcdsaServerActivationCommandProof({
|
|
6619
|
-
correlationId: input.journalId,
|
|
6620
|
-
expectedGeneration: input.expectedGeneration,
|
|
6621
|
-
requestDigest: input.requestDigest,
|
|
6622
|
-
canonicalRequest: input.canonicalRequest
|
|
6623
|
-
});
|
|
6624
|
-
return new PreparedEcdsaActivationJournalProof({
|
|
6625
|
-
journalId: input.journalId,
|
|
6626
|
-
expectedManifest: input.expectedManifest,
|
|
6627
|
-
activationCommand,
|
|
6628
|
-
candidate: input.candidate,
|
|
6629
|
-
createdAt: input.createdAt
|
|
6630
|
-
});
|
|
6631
|
-
}
|
|
6632
|
-
function buildEcdsaServerActivationCommit(input) {
|
|
6633
|
-
const protocolReceipt = parseRouterAbEcdsaRegistrationActivationReceiptV1(input.serverCommit.protocolReceipt);
|
|
6634
|
-
assertProtocolReceiptMatchesServerCommit(protocolReceipt, input.serverCommit);
|
|
6635
|
-
assertProtocolReceiptMatchesActivationBinding(protocolReceipt, input.activationBinding);
|
|
6636
|
-
const serverActivationReceipt = new EcdsaServerActivationReceiptProof({
|
|
6637
|
-
lifecycleId: lifecycleIdFromProtocolReceipt(protocolReceipt),
|
|
6638
|
-
activationDigest: activationDigestFromProtocolReceipt(protocolReceipt),
|
|
6639
|
-
activatedAt: isoTimestampFromUnixMs(protocolReceipt.ecdsa_activation.activated_at_ms),
|
|
6640
|
-
protocolReceipt
|
|
6641
|
-
});
|
|
6642
|
-
return new EcdsaServerActivationCommitProof({
|
|
6643
|
-
correlationId: input.serverCommit.correlationId,
|
|
6644
|
-
activationRequestDigest: input.serverCommit.activationRequestDigest,
|
|
6645
|
-
serverGeneration: input.serverCommit.serverGeneration,
|
|
6646
|
-
serverActivationReceipt
|
|
6647
|
-
});
|
|
6648
|
-
}
|
|
6649
|
-
function buildServerCommittedEcdsaActivationJournal(input) {
|
|
6650
|
-
assertServerCommitMatchesPreparedCommand(input.serverCommit, input.preparedJournal);
|
|
6651
|
-
const serverActivation = buildEcdsaServerActivationCommit({
|
|
6652
|
-
activationBinding: input.preparedJournal.candidate.activationBinding,
|
|
6653
|
-
serverCommit: input.serverCommit
|
|
6654
|
-
});
|
|
6655
|
-
return new ServerCommittedEcdsaActivationJournalProof({
|
|
6656
|
-
journalId: input.preparedJournal.journalId,
|
|
6657
|
-
expectedManifest: input.preparedJournal.expectedManifest,
|
|
6658
|
-
activationCommand: input.preparedJournal.activationCommand,
|
|
6659
|
-
candidate: input.preparedJournal.candidate,
|
|
6660
|
-
createdAt: input.preparedJournal.createdAt,
|
|
6661
|
-
serverActivation
|
|
6662
|
-
});
|
|
5366
|
+
// ../../node_modules/idb/build/index.js
|
|
5367
|
+
var instanceOfAny = (object, constructors) => constructors.some((c) => object instanceof c);
|
|
5368
|
+
var idbProxyableTypes;
|
|
5369
|
+
var cursorAdvanceMethods;
|
|
5370
|
+
function getIdbProxyableTypes() {
|
|
5371
|
+
return idbProxyableTypes || (idbProxyableTypes = [
|
|
5372
|
+
IDBDatabase,
|
|
5373
|
+
IDBObjectStore,
|
|
5374
|
+
IDBIndex,
|
|
5375
|
+
IDBCursor,
|
|
5376
|
+
IDBTransaction
|
|
5377
|
+
]);
|
|
6663
5378
|
}
|
|
6664
|
-
function
|
|
6665
|
-
|
|
6666
|
-
|
|
6667
|
-
|
|
6668
|
-
|
|
6669
|
-
|
|
6670
|
-
throw new Error("ECDSA role-local public facts do not match their activation");
|
|
6671
|
-
}
|
|
6672
|
-
const receipt = input.serverActivation.serverActivationReceipt;
|
|
6673
|
-
assertNormalSigningMatchesActivation({
|
|
6674
|
-
normalSigning: input.routerAbEcdsaDerivationNormalSigning,
|
|
6675
|
-
activationBinding: binding,
|
|
6676
|
-
roleLocalPublicFacts: facts,
|
|
6677
|
-
receipt: receipt.protocolReceipt
|
|
6678
|
-
});
|
|
6679
|
-
return new DurableEcdsaMaterialBindingProof({
|
|
6680
|
-
materialActivation: materialActivationFromCommit(receipt.protocolReceipt),
|
|
6681
|
-
routerAbEcdsaDerivationNormalSigning: input.routerAbEcdsaDerivationNormalSigning,
|
|
6682
|
-
roleLocalPublicFacts: input.roleLocalPublicFacts,
|
|
6683
|
-
roleLocalBinding: input.activationBinding.roleLocalBinding,
|
|
6684
|
-
durableMaterialRef: input.activationBinding.durableMaterialRef,
|
|
6685
|
-
bindingDigest: input.activationBinding.bindingDigest,
|
|
6686
|
-
lifecycleId: receipt.lifecycleId,
|
|
6687
|
-
ciphertextDigest: input.ciphertextDigest,
|
|
6688
|
-
activationDigest: receipt.activationDigest,
|
|
6689
|
-
activatedAt: receipt.activatedAt,
|
|
6690
|
-
runtimePolicyScope
|
|
6691
|
-
});
|
|
5379
|
+
function getCursorAdvanceMethods() {
|
|
5380
|
+
return cursorAdvanceMethods || (cursorAdvanceMethods = [
|
|
5381
|
+
IDBCursor.prototype.advance,
|
|
5382
|
+
IDBCursor.prototype.continue,
|
|
5383
|
+
IDBCursor.prototype.continuePrimaryKey
|
|
5384
|
+
]);
|
|
6692
5385
|
}
|
|
6693
|
-
|
|
6694
|
-
|
|
6695
|
-
|
|
6696
|
-
|
|
6697
|
-
|
|
6698
|
-
|
|
5386
|
+
var transactionDoneMap = new WeakMap;
|
|
5387
|
+
var transformCache = new WeakMap;
|
|
5388
|
+
var reverseTransformCache = new WeakMap;
|
|
5389
|
+
function promisifyRequest(request) {
|
|
5390
|
+
const promise = new Promise((resolve, reject) => {
|
|
5391
|
+
const unlisten = () => {
|
|
5392
|
+
request.removeEventListener("success", success);
|
|
5393
|
+
request.removeEventListener("error", error);
|
|
5394
|
+
};
|
|
5395
|
+
const success = () => {
|
|
5396
|
+
resolve(wrap(request.result));
|
|
5397
|
+
unlisten();
|
|
5398
|
+
};
|
|
5399
|
+
const error = () => {
|
|
5400
|
+
reject(request.error);
|
|
5401
|
+
unlisten();
|
|
5402
|
+
};
|
|
5403
|
+
request.addEventListener("success", success);
|
|
5404
|
+
request.addEventListener("error", error);
|
|
6699
5405
|
});
|
|
5406
|
+
reverseTransformCache.set(promise, request);
|
|
5407
|
+
return promise;
|
|
6700
5408
|
}
|
|
6701
|
-
function
|
|
6702
|
-
|
|
6703
|
-
|
|
6704
|
-
const
|
|
6705
|
-
|
|
6706
|
-
|
|
6707
|
-
|
|
6708
|
-
|
|
6709
|
-
|
|
6710
|
-
|
|
6711
|
-
|
|
6712
|
-
|
|
6713
|
-
|
|
6714
|
-
|
|
6715
|
-
|
|
6716
|
-
|
|
6717
|
-
|
|
6718
|
-
|
|
6719
|
-
|
|
5409
|
+
function cacheDonePromiseForTransaction(tx) {
|
|
5410
|
+
if (transactionDoneMap.has(tx))
|
|
5411
|
+
return;
|
|
5412
|
+
const done = new Promise((resolve, reject) => {
|
|
5413
|
+
const unlisten = () => {
|
|
5414
|
+
tx.removeEventListener("complete", complete);
|
|
5415
|
+
tx.removeEventListener("error", error);
|
|
5416
|
+
tx.removeEventListener("abort", error);
|
|
5417
|
+
};
|
|
5418
|
+
const complete = () => {
|
|
5419
|
+
resolve();
|
|
5420
|
+
unlisten();
|
|
5421
|
+
};
|
|
5422
|
+
const error = () => {
|
|
5423
|
+
reject(tx.error || new DOMException("AbortError", "AbortError"));
|
|
5424
|
+
unlisten();
|
|
5425
|
+
};
|
|
5426
|
+
tx.addEventListener("complete", complete);
|
|
5427
|
+
tx.addEventListener("error", error);
|
|
5428
|
+
tx.addEventListener("abort", error);
|
|
6720
5429
|
});
|
|
5430
|
+
transactionDoneMap.set(tx, done);
|
|
6721
5431
|
}
|
|
6722
|
-
|
|
6723
|
-
|
|
6724
|
-
|
|
6725
|
-
|
|
6726
|
-
|
|
6727
|
-
|
|
6728
|
-
|
|
6729
|
-
|
|
6730
|
-
replacementActivation: input.replacementManifest.activation.serverActivation
|
|
5432
|
+
var idbProxyTraps = {
|
|
5433
|
+
get(target, prop, receiver) {
|
|
5434
|
+
if (target instanceof IDBTransaction) {
|
|
5435
|
+
if (prop === "done")
|
|
5436
|
+
return transactionDoneMap.get(target);
|
|
5437
|
+
if (prop === "store") {
|
|
5438
|
+
return receiver.objectStoreNames[1] ? undefined : receiver.objectStore(receiver.objectStoreNames[0]);
|
|
5439
|
+
}
|
|
6731
5440
|
}
|
|
6732
|
-
|
|
6733
|
-
}
|
|
6734
|
-
|
|
6735
|
-
|
|
6736
|
-
|
|
6737
|
-
|
|
5441
|
+
return wrap(target[prop]);
|
|
5442
|
+
},
|
|
5443
|
+
set(target, prop, value) {
|
|
5444
|
+
target[prop] = value;
|
|
5445
|
+
return true;
|
|
5446
|
+
},
|
|
5447
|
+
has(target, prop) {
|
|
5448
|
+
if (target instanceof IDBTransaction && (prop === "done" || prop === "store")) {
|
|
5449
|
+
return true;
|
|
5450
|
+
}
|
|
5451
|
+
return prop in target;
|
|
6738
5452
|
}
|
|
5453
|
+
};
|
|
5454
|
+
function replaceTraps(callback) {
|
|
5455
|
+
idbProxyTraps = callback(idbProxyTraps);
|
|
6739
5456
|
}
|
|
6740
|
-
function
|
|
6741
|
-
|
|
6742
|
-
|
|
6743
|
-
|
|
6744
|
-
|
|
6745
|
-
|
|
6746
|
-
default:
|
|
6747
|
-
return assertNever(target);
|
|
5457
|
+
function wrapFunction(func) {
|
|
5458
|
+
if (getCursorAdvanceMethods().includes(func)) {
|
|
5459
|
+
return function(...args) {
|
|
5460
|
+
func.apply(unwrap(this), args);
|
|
5461
|
+
return wrap(this.request);
|
|
5462
|
+
};
|
|
6748
5463
|
}
|
|
5464
|
+
return function(...args) {
|
|
5465
|
+
return wrap(func.apply(unwrap(this), args));
|
|
5466
|
+
};
|
|
6749
5467
|
}
|
|
6750
|
-
function
|
|
6751
|
-
|
|
6752
|
-
|
|
6753
|
-
|
|
5468
|
+
function transformCachableValue(value) {
|
|
5469
|
+
if (typeof value === "function")
|
|
5470
|
+
return wrapFunction(value);
|
|
5471
|
+
if (value instanceof IDBTransaction)
|
|
5472
|
+
cacheDonePromiseForTransaction(value);
|
|
5473
|
+
if (instanceOfAny(value, getIdbProxyableTypes()))
|
|
5474
|
+
return new Proxy(value, idbProxyTraps);
|
|
5475
|
+
return value;
|
|
5476
|
+
}
|
|
5477
|
+
function wrap(value) {
|
|
5478
|
+
if (value instanceof IDBRequest)
|
|
5479
|
+
return promisifyRequest(value);
|
|
5480
|
+
if (transformCache.has(value))
|
|
5481
|
+
return transformCache.get(value);
|
|
5482
|
+
const newValue = transformCachableValue(value);
|
|
5483
|
+
if (newValue !== value) {
|
|
5484
|
+
transformCache.set(value, newValue);
|
|
5485
|
+
reverseTransformCache.set(newValue, value);
|
|
6754
5486
|
}
|
|
5487
|
+
return newValue;
|
|
6755
5488
|
}
|
|
6756
|
-
|
|
6757
|
-
|
|
6758
|
-
|
|
6759
|
-
|
|
6760
|
-
|
|
6761
|
-
|
|
6762
|
-
|
|
6763
|
-
|
|
6764
|
-
|
|
6765
|
-
|
|
6766
|
-
|
|
6767
|
-
return;
|
|
6768
|
-
default:
|
|
6769
|
-
return assertNever(expected);
|
|
5489
|
+
var unwrap = (value) => reverseTransformCache.get(value);
|
|
5490
|
+
function openDB(name, version, { blocked, upgrade, blocking, terminated } = {}) {
|
|
5491
|
+
const request = indexedDB.open(name, version);
|
|
5492
|
+
const openPromise = wrap(request);
|
|
5493
|
+
if (upgrade) {
|
|
5494
|
+
request.addEventListener("upgradeneeded", (event) => {
|
|
5495
|
+
upgrade(wrap(request.result), event.oldVersion, event.newVersion, wrap(request.transaction), event);
|
|
5496
|
+
});
|
|
5497
|
+
}
|
|
5498
|
+
if (blocked) {
|
|
5499
|
+
request.addEventListener("blocked", (event) => blocked(event.oldVersion, event.newVersion, event));
|
|
6770
5500
|
}
|
|
5501
|
+
openPromise.then((db) => {
|
|
5502
|
+
if (terminated)
|
|
5503
|
+
db.addEventListener("close", () => terminated());
|
|
5504
|
+
if (blocking) {
|
|
5505
|
+
db.addEventListener("versionchange", (event) => blocking(event.oldVersion, event.newVersion, event));
|
|
5506
|
+
}
|
|
5507
|
+
}).catch(() => {});
|
|
5508
|
+
return openPromise;
|
|
6771
5509
|
}
|
|
6772
|
-
|
|
6773
|
-
|
|
6774
|
-
|
|
6775
|
-
|
|
6776
|
-
|
|
6777
|
-
|
|
6778
|
-
|
|
6779
|
-
|
|
6780
|
-
|
|
6781
|
-
|
|
6782
|
-
|
|
6783
|
-
|
|
6784
|
-
|
|
6785
|
-
|
|
5510
|
+
var readMethods = ["get", "getKey", "getAll", "getAllKeys", "count"];
|
|
5511
|
+
var writeMethods = ["put", "add", "delete", "clear"];
|
|
5512
|
+
var cachedMethods = new Map;
|
|
5513
|
+
function getMethod(target, prop) {
|
|
5514
|
+
if (!(target instanceof IDBDatabase && !(prop in target) && typeof prop === "string")) {
|
|
5515
|
+
return;
|
|
5516
|
+
}
|
|
5517
|
+
if (cachedMethods.get(prop))
|
|
5518
|
+
return cachedMethods.get(prop);
|
|
5519
|
+
const targetFuncName = prop.replace(/FromIndex$/, "");
|
|
5520
|
+
const useIndex = prop !== targetFuncName;
|
|
5521
|
+
const isWrite = writeMethods.includes(targetFuncName);
|
|
5522
|
+
if (!(targetFuncName in (useIndex ? IDBIndex : IDBObjectStore).prototype) || !(isWrite || readMethods.includes(targetFuncName))) {
|
|
5523
|
+
return;
|
|
6786
5524
|
}
|
|
5525
|
+
const method = async function(storeName, ...args) {
|
|
5526
|
+
const tx = this.transaction(storeName, isWrite ? "readwrite" : "readonly");
|
|
5527
|
+
let target = tx.store;
|
|
5528
|
+
if (useIndex)
|
|
5529
|
+
target = target.index(args.shift());
|
|
5530
|
+
return (await Promise.all([
|
|
5531
|
+
target[targetFuncName](...args),
|
|
5532
|
+
isWrite && tx.done
|
|
5533
|
+
]))[0];
|
|
5534
|
+
};
|
|
5535
|
+
cachedMethods.set(prop, method);
|
|
5536
|
+
return method;
|
|
6787
5537
|
}
|
|
6788
|
-
|
|
6789
|
-
|
|
6790
|
-
|
|
6791
|
-
|
|
6792
|
-
|
|
5538
|
+
replaceTraps((oldTraps) => ({
|
|
5539
|
+
...oldTraps,
|
|
5540
|
+
get: (target, prop, receiver) => getMethod(target, prop) || oldTraps.get(target, prop, receiver),
|
|
5541
|
+
has: (target, prop) => !!getMethod(target, prop) || oldTraps.has(target, prop)
|
|
5542
|
+
}));
|
|
5543
|
+
var advanceMethodProps = ["continue", "continuePrimaryKey", "advance"];
|
|
5544
|
+
var methodMap = {};
|
|
5545
|
+
var advanceResults = new WeakMap;
|
|
5546
|
+
var ittrProxiedCursorToOriginalProxy = new WeakMap;
|
|
5547
|
+
var cursorIteratorTraps = {
|
|
5548
|
+
get(target, prop) {
|
|
5549
|
+
if (!advanceMethodProps.includes(prop))
|
|
5550
|
+
return target[prop];
|
|
5551
|
+
let cachedFunc = methodMap[prop];
|
|
5552
|
+
if (!cachedFunc) {
|
|
5553
|
+
cachedFunc = methodMap[prop] = function(...args) {
|
|
5554
|
+
advanceResults.set(this, ittrProxiedCursorToOriginalProxy.get(this)[prop](...args));
|
|
5555
|
+
};
|
|
5556
|
+
}
|
|
5557
|
+
return cachedFunc;
|
|
5558
|
+
}
|
|
5559
|
+
};
|
|
5560
|
+
async function* iterate(...args) {
|
|
5561
|
+
let cursor = this;
|
|
5562
|
+
if (!(cursor instanceof IDBCursor)) {
|
|
5563
|
+
cursor = await cursor.openCursor(...args);
|
|
5564
|
+
}
|
|
5565
|
+
if (!cursor)
|
|
5566
|
+
return;
|
|
5567
|
+
cursor = cursor;
|
|
5568
|
+
const proxiedCursor = new Proxy(cursor, cursorIteratorTraps);
|
|
5569
|
+
ittrProxiedCursorToOriginalProxy.set(proxiedCursor, cursor);
|
|
5570
|
+
reverseTransformCache.set(proxiedCursor, unwrap(cursor));
|
|
5571
|
+
while (cursor) {
|
|
5572
|
+
yield proxiedCursor;
|
|
5573
|
+
cursor = await (advanceResults.get(proxiedCursor) || cursor.continue());
|
|
5574
|
+
advanceResults.delete(proxiedCursor);
|
|
6793
5575
|
}
|
|
6794
5576
|
}
|
|
6795
|
-
function
|
|
6796
|
-
|
|
6797
|
-
|
|
6798
|
-
|
|
6799
|
-
|
|
6800
|
-
|
|
5577
|
+
function isIteratorProp(target, prop) {
|
|
5578
|
+
return prop === Symbol.asyncIterator && instanceOfAny(target, [IDBIndex, IDBObjectStore, IDBCursor]) || prop === "iterate" && instanceOfAny(target, [IDBIndex, IDBObjectStore]);
|
|
5579
|
+
}
|
|
5580
|
+
replaceTraps((oldTraps) => ({
|
|
5581
|
+
...oldTraps,
|
|
5582
|
+
get(target, prop, receiver) {
|
|
5583
|
+
if (isIteratorProp(target, prop))
|
|
5584
|
+
return iterate;
|
|
5585
|
+
return oldTraps.get(target, prop, receiver);
|
|
5586
|
+
},
|
|
5587
|
+
has(target, prop) {
|
|
5588
|
+
return isIteratorProp(target, prop) || oldTraps.has(target, prop);
|
|
6801
5589
|
}
|
|
5590
|
+
}));
|
|
5591
|
+
|
|
5592
|
+
// src/core/indexedDB/seamsWalletDB/schema.ts
|
|
5593
|
+
var SEAMS_WALLET_DB_CONFIG = {
|
|
5594
|
+
dbName: SEAMS_WALLET_DB_NAME,
|
|
5595
|
+
dbVersion: SEAMS_WALLET_DB_VERSION
|
|
5596
|
+
};
|
|
5597
|
+
function keyPathForIndexedDB(keyPath) {
|
|
5598
|
+
return typeof keyPath === "string" ? keyPath : [...keyPath];
|
|
6802
5599
|
}
|
|
6803
|
-
function
|
|
6804
|
-
const
|
|
6805
|
-
|
|
6806
|
-
|
|
5600
|
+
function createCanonicalStore(db, definition) {
|
|
5601
|
+
const store = db.createObjectStore(definition.store, {
|
|
5602
|
+
keyPath: keyPathForIndexedDB(definition.keyPath)
|
|
5603
|
+
});
|
|
5604
|
+
for (const index of definition.indexes) {
|
|
5605
|
+
store.createIndex(index.name, keyPathForIndexedDB(index.keyPath), { unique: index.unique });
|
|
6807
5606
|
}
|
|
6808
5607
|
}
|
|
6809
|
-
function
|
|
6810
|
-
|
|
5608
|
+
function upgradeSeamsWalletDBSchema(db) {
|
|
5609
|
+
for (const definition of SEAMS_WALLET_SCHEMA_MANIFEST) {
|
|
5610
|
+
if (db.objectStoreNames.contains(definition.store))
|
|
5611
|
+
continue;
|
|
5612
|
+
createCanonicalStore(db, definition);
|
|
5613
|
+
}
|
|
6811
5614
|
}
|
|
6812
|
-
|
|
6813
|
-
|
|
5615
|
+
|
|
5616
|
+
// src/core/indexedDB/seamsWalletDB/manager.ts
|
|
5617
|
+
var INDEXED_DB_BLOCKED_OPEN_TIMEOUT_MS = 3000;
|
|
5618
|
+
var INDEXED_DB_OPEN_TIMEOUT_MS = 8000;
|
|
5619
|
+
var INDEXED_DB_TRANSACTION_TIMEOUT_MS = 8000;
|
|
5620
|
+
function seamsWalletDbOpenBlockedError(dbName) {
|
|
5621
|
+
return new Error(`[SeamsWalletDBManager] IndexedDB open is blocked for ${dbName}. Close other tabs using this app and retry.`);
|
|
6814
5622
|
}
|
|
6815
|
-
function
|
|
6816
|
-
return
|
|
5623
|
+
function indexedDbTimeoutError(message) {
|
|
5624
|
+
return new Error(message);
|
|
6817
5625
|
}
|
|
6818
|
-
function
|
|
6819
|
-
|
|
6820
|
-
|
|
6821
|
-
|
|
5626
|
+
async function withTimeout(promise, ms, error, onTimeout) {
|
|
5627
|
+
let settled = false;
|
|
5628
|
+
let timeout = null;
|
|
5629
|
+
const timeoutPromise = new Promise((_resolve, reject) => {
|
|
5630
|
+
timeout = setTimeout(() => {
|
|
5631
|
+
if (settled)
|
|
5632
|
+
return;
|
|
5633
|
+
onTimeout?.();
|
|
5634
|
+
reject(error);
|
|
5635
|
+
}, ms);
|
|
5636
|
+
});
|
|
5637
|
+
try {
|
|
5638
|
+
return await Promise.race([promise, timeoutPromise]);
|
|
5639
|
+
} finally {
|
|
5640
|
+
settled = true;
|
|
5641
|
+
if (timeout)
|
|
5642
|
+
clearTimeout(timeout);
|
|
6822
5643
|
}
|
|
6823
5644
|
}
|
|
6824
|
-
function
|
|
6825
|
-
|
|
6826
|
-
|
|
6827
|
-
return
|
|
6828
|
-
}
|
|
6829
|
-
function assertServerActivationMatchesBinding(serverActivation, activationBinding) {
|
|
6830
|
-
assertProtocolReceiptMatchesActivationBinding(serverActivation.serverActivationReceipt.protocolReceipt, activationBinding);
|
|
5645
|
+
async function runIndexedDbTransactionTask(context, task) {
|
|
5646
|
+
const result = await task(context);
|
|
5647
|
+
await context.tx.done;
|
|
5648
|
+
return result;
|
|
6831
5649
|
}
|
|
6832
|
-
|
|
6833
|
-
|
|
6834
|
-
|
|
6835
|
-
|
|
6836
|
-
|
|
5650
|
+
|
|
5651
|
+
class SeamsWalletDBManager {
|
|
5652
|
+
constructor(config = SEAMS_WALLET_DB_CONFIG) {
|
|
5653
|
+
this.dbPromise = null;
|
|
5654
|
+
this.disabled = false;
|
|
5655
|
+
this.config = config;
|
|
6837
5656
|
}
|
|
6838
|
-
|
|
6839
|
-
|
|
6840
|
-
activationBinding,
|
|
6841
|
-
roleLocalPublicFacts: durableMaterial.roleLocalPublicFacts,
|
|
6842
|
-
receipt: receipt.protocolReceipt
|
|
6843
|
-
});
|
|
6844
|
-
}
|
|
6845
|
-
function assertNormalSigningMatchesActivation(input) {
|
|
6846
|
-
const scope = input.normalSigning.scope;
|
|
6847
|
-
const facts = input.roleLocalPublicFacts;
|
|
6848
|
-
const expectedMaterialActivation = materialActivationFromCommit(input.receipt);
|
|
6849
|
-
const expectedMaterialActivationWire = routerAbMpcMaterialActivationRefToWire({
|
|
6850
|
-
kind: expectedMaterialActivation.kind,
|
|
6851
|
-
activationId: expectedMaterialActivation.activationId,
|
|
6852
|
-
capability: expectedMaterialActivation.capability,
|
|
6853
|
-
materialOwner: expectedMaterialActivation.materialOwner,
|
|
6854
|
-
keyBinding: expectedMaterialActivation.keyBinding,
|
|
6855
|
-
lifecycleBinding: expectedMaterialActivation.lifecycleBinding,
|
|
6856
|
-
signingWorker: expectedMaterialActivation.signingWorker
|
|
6857
|
-
});
|
|
6858
|
-
if (scope.wallet_id !== String(input.activationBinding.signer.walletId) || scope.ecdsa_threshold_key_id !== String(input.activationBinding.roleLocalBinding.ecdsaThresholdKeyId) || scope.signing_root_id !== String(input.activationBinding.signer.signingRootId) || scope.signing_root_version !== String(input.activationBinding.signer.signingRootVersion) || scope.context.application_binding_digest_b64u !== input.receipt.ecdsa_activation.context.application_binding_digest_b64u || !sameRouterAbEcdsaDerivationPublicIdentityV1(scope.public_identity, input.receipt.ecdsa_activation.public_identity) || !sameRouterAbServerIdentityV1(scope.signing_worker, input.receipt.ecdsa_activation.signing_worker) || scope.activation_epoch !== input.receipt.ecdsa_activation.activation_epoch || scope.public_identity.context_binding_b64u !== facts.contextBinding32B64u || scope.public_identity.derivation_client_share_public_key33_b64u !== facts.derivationClientSharePublicKey33B64u || scope.public_identity.server_public_key33_b64u !== facts.relayerPublicKey33B64u || scope.public_identity.threshold_public_key33_b64u !== facts.groupPublicKey33B64u || !sameRouterAbMpcMaterialActivationRef(scope.material_activation, expectedMaterialActivationWire)) {
|
|
6859
|
-
throw new Error("ECDSA normal-signing runtime does not match its activation");
|
|
5657
|
+
getDbName() {
|
|
5658
|
+
return this.config.dbName;
|
|
6860
5659
|
}
|
|
6861
|
-
|
|
6862
|
-
|
|
6863
|
-
|
|
6864
|
-
|
|
5660
|
+
setDbName(dbName) {
|
|
5661
|
+
if (this.config.dbName === dbName)
|
|
5662
|
+
return;
|
|
5663
|
+
this.close();
|
|
5664
|
+
this.config = { ...this.config, dbName };
|
|
5665
|
+
}
|
|
5666
|
+
setDisabled(disabled) {
|
|
5667
|
+
this.disabled = disabled;
|
|
5668
|
+
if (disabled)
|
|
5669
|
+
this.close();
|
|
5670
|
+
}
|
|
5671
|
+
isDisabled() {
|
|
5672
|
+
return this.disabled;
|
|
5673
|
+
}
|
|
5674
|
+
close() {
|
|
5675
|
+
if (this.dbPromise) {
|
|
5676
|
+
this.dbPromise.then((db) => db.close()).catch(() => {
|
|
5677
|
+
return;
|
|
5678
|
+
});
|
|
5679
|
+
this.dbPromise = null;
|
|
5680
|
+
}
|
|
5681
|
+
}
|
|
5682
|
+
async getDB() {
|
|
5683
|
+
if (this.disabled) {
|
|
5684
|
+
throw new Error("[SeamsWalletDBManager] IndexedDB is disabled in this environment.");
|
|
5685
|
+
}
|
|
5686
|
+
if (!this.dbPromise) {
|
|
5687
|
+
const dbName = this.config.dbName;
|
|
5688
|
+
const dbVersion = this.config.dbVersion;
|
|
5689
|
+
let blockedTimer = null;
|
|
5690
|
+
let rejectBlockedOpen = null;
|
|
5691
|
+
const blockedOpen = new Promise((_resolve, reject) => {
|
|
5692
|
+
rejectBlockedOpen = reject;
|
|
5693
|
+
});
|
|
5694
|
+
const openPromise = openDB(dbName, dbVersion, {
|
|
5695
|
+
upgrade(db) {
|
|
5696
|
+
upgradeSeamsWalletDBSchema(db);
|
|
5697
|
+
},
|
|
5698
|
+
blocked() {
|
|
5699
|
+
console.warn("[SeamsWalletDBManager] IndexedDB open is blocked.", {
|
|
5700
|
+
dbName,
|
|
5701
|
+
dbVersion
|
|
5702
|
+
});
|
|
5703
|
+
blockedTimer = setTimeout(() => {
|
|
5704
|
+
rejectBlockedOpen?.(seamsWalletDbOpenBlockedError(dbName));
|
|
5705
|
+
}, INDEXED_DB_BLOCKED_OPEN_TIMEOUT_MS);
|
|
5706
|
+
},
|
|
5707
|
+
blocking: () => {
|
|
5708
|
+
console.warn("[SeamsWalletDBManager] IndexedDB connection is blocking an upgrade.", {
|
|
5709
|
+
dbName,
|
|
5710
|
+
dbVersion
|
|
5711
|
+
});
|
|
5712
|
+
this.close();
|
|
5713
|
+
},
|
|
5714
|
+
terminated() {
|
|
5715
|
+
console.warn("[SeamsWalletDBManager] IndexedDB connection has been terminated.", {
|
|
5716
|
+
dbName,
|
|
5717
|
+
dbVersion
|
|
5718
|
+
});
|
|
5719
|
+
}
|
|
5720
|
+
});
|
|
5721
|
+
const guardedOpen = withTimeout(Promise.race([openPromise, blockedOpen]).finally(() => {
|
|
5722
|
+
if (blockedTimer)
|
|
5723
|
+
clearTimeout(blockedTimer);
|
|
5724
|
+
}), INDEXED_DB_OPEN_TIMEOUT_MS, indexedDbTimeoutError(`[SeamsWalletDBManager] IndexedDB open timed out for ${dbName}. Close other tabs using this app and retry.`));
|
|
5725
|
+
this.dbPromise = guardedOpen.catch((error) => {
|
|
5726
|
+
this.dbPromise = null;
|
|
5727
|
+
openPromise.then((db) => db.close()).catch(() => {
|
|
5728
|
+
return;
|
|
5729
|
+
});
|
|
5730
|
+
throw error;
|
|
5731
|
+
});
|
|
5732
|
+
}
|
|
5733
|
+
return await this.dbPromise;
|
|
5734
|
+
}
|
|
5735
|
+
async runTransaction(stores, mode, task, options) {
|
|
5736
|
+
const db = await withTimeout(this.getDB(), INDEXED_DB_OPEN_TIMEOUT_MS, indexedDbTimeoutError(`[SeamsWalletDBManager] IndexedDB connection timed out for ${this.config.dbName}. Close other tabs using this app and retry.`));
|
|
5737
|
+
const tx = db.transaction([...stores], mode, options);
|
|
5738
|
+
const context = {
|
|
5739
|
+
db,
|
|
5740
|
+
tx,
|
|
5741
|
+
store(name) {
|
|
5742
|
+
return tx.objectStore(name);
|
|
5743
|
+
}
|
|
5744
|
+
};
|
|
5745
|
+
try {
|
|
5746
|
+
return await withTimeout(runIndexedDbTransactionTask(context, task), INDEXED_DB_TRANSACTION_TIMEOUT_MS, indexedDbTimeoutError(`[SeamsWalletDBManager] IndexedDB transaction timed out for ${this.config.dbName}. Close other tabs using this app and retry.`), () => {
|
|
5747
|
+
try {
|
|
5748
|
+
tx.abort();
|
|
5749
|
+
} catch {}
|
|
5750
|
+
});
|
|
5751
|
+
} catch (error) {
|
|
5752
|
+
try {
|
|
5753
|
+
tx.abort();
|
|
5754
|
+
} catch {}
|
|
5755
|
+
await tx.done.catch(() => {
|
|
5756
|
+
return;
|
|
5757
|
+
});
|
|
5758
|
+
throw error;
|
|
5759
|
+
}
|
|
6865
5760
|
}
|
|
6866
5761
|
}
|
|
6867
|
-
|
|
6868
|
-
|
|
6869
|
-
|
|
5762
|
+
|
|
5763
|
+
// src/core/indexedDB/singletons.ts
|
|
5764
|
+
var seamsWalletDB = new SeamsWalletDBManager;
|
|
6870
5765
|
|
|
6871
5766
|
// src/core/signingEngine/workerManager/ecdsaPresignPoolIdentity.ts
|
|
6872
5767
|
var FIXED_ECDSA_PRESIGN_PROTOCOL_ID = "seams/router-ab-ecdsa-presign/fixed-2of2/v1";
|
|
@@ -11318,33 +10213,6 @@ function signWalletRecoveryEcdsaMaterialPossessionProof(request) {
|
|
|
11318
10213
|
derivationClientSharePublicKey33B64u
|
|
11319
10214
|
};
|
|
11320
10215
|
}
|
|
11321
|
-
function collectCanonicalEcdsaLaneSourceMaterials() {
|
|
11322
|
-
const candidates = [];
|
|
11323
|
-
for (const material of ecdsaRoleLocalSigningMaterialStore.values()) {
|
|
11324
|
-
if (!material.materialActivation)
|
|
11325
|
-
continue;
|
|
11326
|
-
if (material.activationBinding.kind !== "strict_router_ab_activation_v1")
|
|
11327
|
-
continue;
|
|
11328
|
-
candidates.push({
|
|
11329
|
-
materialActivation: material.materialActivation,
|
|
11330
|
-
stateBlobB64u: material.stateBlobB64u
|
|
11331
|
-
});
|
|
11332
|
-
}
|
|
11333
|
-
return candidates;
|
|
11334
|
-
}
|
|
11335
|
-
var ecdsaLaneHolderSessionFactory = {
|
|
11336
|
-
create(stateBlobB64u) {
|
|
11337
|
-
return new EcdsaLaneHolderSessionV1(stateBlobB64u);
|
|
11338
|
-
}
|
|
11339
|
-
};
|
|
11340
|
-
function prepareEcdsaAdditiveLaneHolder(raw) {
|
|
11341
|
-
const request = parsePrepareEcdsaAdditiveLaneHolderRequestV1(raw);
|
|
11342
|
-
return prepareEcdsaLaneHolderInWorkerV1({
|
|
11343
|
-
request,
|
|
11344
|
-
candidates: collectCanonicalEcdsaLaneSourceMaterials(),
|
|
11345
|
-
sessionFactory: ecdsaLaneHolderSessionFactory
|
|
11346
|
-
});
|
|
11347
|
-
}
|
|
11348
10216
|
function resolveLinkedDeviceEcdsaSourceMaterial(preparation) {
|
|
11349
10217
|
const matches = [];
|
|
11350
10218
|
for (const material of ecdsaRoleLocalSigningMaterialStore.values()) {
|
|
@@ -11806,7 +10674,6 @@ async function initializeEcdsaDerivationOperationWasm(operationType) {
|
|
|
11806
10674
|
case EcdsaDerivationClientCustomRequestType.PrepareThresholdEcdsaDerivationRoleLocalClientBootstrap:
|
|
11807
10675
|
case EcdsaDerivationClientCustomRequestType.FinalizeThresholdEcdsaDerivationRoleLocalClientBootstrap:
|
|
11808
10676
|
case EcdsaDerivationClientCustomRequestType.SignWalletRecoveryEcdsaMaterialPossessionProof:
|
|
11809
|
-
case EcdsaDerivationClientCustomRequestType.PrepareEcdsaAdditiveLaneHolder:
|
|
11810
10677
|
case EcdsaDerivationClientCustomRequestType.PrepareLinkedDeviceEcdsaSourceContribution:
|
|
11811
10678
|
case EcdsaDerivationClientCustomRequestType.StoreLinkedDeviceEcdsaHolderMaterial:
|
|
11812
10679
|
case EcdsaDerivationClientCustomRequestType.CreateEcdsaHolderOrdinaryExportRequest:
|
|
@@ -11906,11 +10773,6 @@ async function executeEcdsaDerivationRequest(request) {
|
|
|
11906
10773
|
type: EcdsaDerivationClientCustomResponseType.FinalizeThresholdEcdsaDerivationRoleLocalClientBootstrapSuccess,
|
|
11907
10774
|
payload: JSON.parse(finalize_ecdsa_client_bootstrap_v1(JSON.stringify(request.payload)))
|
|
11908
10775
|
};
|
|
11909
|
-
case EcdsaDerivationClientCustomRequestType.PrepareEcdsaAdditiveLaneHolder:
|
|
11910
|
-
return {
|
|
11911
|
-
type: EcdsaDerivationClientCustomResponseType.PrepareEcdsaAdditiveLaneHolderSuccess,
|
|
11912
|
-
payload: prepareEcdsaAdditiveLaneHolder(request.payload)
|
|
11913
|
-
};
|
|
11914
10776
|
case EcdsaDerivationClientCustomRequestType.PrepareLinkedDeviceEcdsaSourceContribution:
|
|
11915
10777
|
return {
|
|
11916
10778
|
type: EcdsaDerivationClientCustomResponseType.PrepareLinkedDeviceEcdsaSourceContributionSuccess,
|
|
@@ -11959,7 +10821,6 @@ function parseEcdsaDerivationOperationType(value) {
|
|
|
11959
10821
|
case EcdsaDerivationClientCustomRequestType.SignWalletRecoveryEcdsaMaterialPossessionProof:
|
|
11960
10822
|
case EcdsaDerivationClientCustomRequestType.PrepareThresholdEcdsaDerivationRoleLocalClientBootstrap:
|
|
11961
10823
|
case EcdsaDerivationClientCustomRequestType.FinalizeThresholdEcdsaDerivationRoleLocalClientBootstrap:
|
|
11962
|
-
case EcdsaDerivationClientCustomRequestType.PrepareEcdsaAdditiveLaneHolder:
|
|
11963
10824
|
case EcdsaDerivationClientCustomRequestType.PrepareLinkedDeviceEcdsaSourceContribution:
|
|
11964
10825
|
case EcdsaDerivationClientCustomRequestType.StoreLinkedDeviceEcdsaHolderMaterial:
|
|
11965
10826
|
case EcdsaDerivationClientCustomRequestType.DisposeLinkedDeviceEcdsaHolderMaterials:
|
|
@@ -12345,12 +11206,6 @@ function parseEcdsaDerivationClientWorkerRequest(value) {
|
|
|
12345
11206
|
type: requestType,
|
|
12346
11207
|
payload: parseGeneratedFinalizeEcdsaClientBootstrapCommand(record.payload)
|
|
12347
11208
|
};
|
|
12348
|
-
case EcdsaDerivationClientCustomRequestType.PrepareEcdsaAdditiveLaneHolder:
|
|
12349
|
-
return {
|
|
12350
|
-
id: requestId,
|
|
12351
|
-
type: requestType,
|
|
12352
|
-
payload: parsePrepareEcdsaAdditiveLaneHolderRequestV1(record.payload)
|
|
12353
|
-
};
|
|
12354
11209
|
case EcdsaDerivationClientCustomRequestType.PrepareLinkedDeviceEcdsaSourceContribution:
|
|
12355
11210
|
return {
|
|
12356
11211
|
id: requestId,
|