@cedros/login-react 0.0.12 → 0.0.14
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 +68 -0
- package/dist/AdminDepositList-CyT4VBH8.js +311 -0
- package/dist/AdminDepositList-CyT4VBH8.js.map +1 -0
- package/dist/AdminDepositList-b2AXtLg0.cjs +1 -0
- package/dist/AdminDepositList-b2AXtLg0.cjs.map +1 -0
- package/dist/AdminWithdrawalHistory-Cud-yuWy.js +916 -0
- package/dist/AdminWithdrawalHistory-Cud-yuWy.js.map +1 -0
- package/dist/AdminWithdrawalHistory-DL9zbu2b.cjs +1 -0
- package/dist/AdminWithdrawalHistory-DL9zbu2b.cjs.map +1 -0
- package/dist/AuthenticationSettings-D739nNul.cjs +1 -0
- package/dist/AuthenticationSettings-D739nNul.cjs.map +1 -0
- package/dist/AuthenticationSettings-DtLoxQ2z.cjs +1 -0
- package/dist/AuthenticationSettings-DtLoxQ2z.cjs.map +1 -0
- package/dist/AuthenticationSettings-Dx3JCI3m.js +9 -0
- package/dist/AuthenticationSettings-Dx3JCI3m.js.map +1 -0
- package/dist/AuthenticationSettings-vowmQPXz.js +525 -0
- package/dist/AuthenticationSettings-vowmQPXz.js.map +1 -0
- package/dist/AutosaveStatus-CCrZszKA.cjs +1 -0
- package/dist/AutosaveStatus-CCrZszKA.cjs.map +1 -0
- package/dist/AutosaveStatus-Ciyt350A.js +1497 -0
- package/dist/AutosaveStatus-Ciyt350A.js.map +1 -0
- package/dist/CreditSystemSettings-BQ3h4CyM.js +210 -0
- package/dist/CreditSystemSettings-BQ3h4CyM.js.map +1 -0
- package/dist/CreditSystemSettings-C6dUsu72.cjs +1 -0
- package/dist/CreditSystemSettings-C6dUsu72.cjs.map +1 -0
- package/dist/CreditSystemSettings-CBot8EPW.cjs +1 -0
- package/dist/CreditSystemSettings-CBot8EPW.cjs.map +1 -0
- package/dist/CreditSystemSettings-bVuNLsqp.js +9 -0
- package/dist/CreditSystemSettings-bVuNLsqp.js.map +1 -0
- package/dist/DepositsSection-BkKUS4vk.cjs +1 -0
- package/dist/DepositsSection-BkKUS4vk.cjs.map +1 -0
- package/dist/{DepositsSection-0Hqr0yDm.js → DepositsSection-DD9MKUFt.js} +20 -14
- package/dist/DepositsSection-DD9MKUFt.js.map +1 -0
- package/dist/EmailRegisterForm-Pvm3I8GP.cjs +1 -0
- package/dist/EmailRegisterForm-Pvm3I8GP.cjs.map +1 -0
- package/dist/EmailRegisterForm-nI0BOIxR.js +927 -0
- package/dist/EmailRegisterForm-nI0BOIxR.js.map +1 -0
- package/dist/EmailSettings-B9qwPSiM.cjs +1 -0
- package/dist/EmailSettings-B9qwPSiM.cjs.map +1 -0
- package/dist/EmailSettings-CCA8dNCi.js +17 -0
- package/dist/EmailSettings-CCA8dNCi.js.map +1 -0
- package/dist/EmailSettings-RbgAq9FB.cjs +1 -0
- package/dist/EmailSettings-RbgAq9FB.cjs.map +1 -0
- package/dist/{AuthenticationSettings-BSoIQ58T.js → EmailSettings-mxlKNcPl.js} +3 -3
- package/dist/EmailSettings-mxlKNcPl.js.map +1 -0
- package/dist/EmbeddedWalletSettings-B4h-8rxB.cjs +1 -0
- package/dist/EmbeddedWalletSettings-B4h-8rxB.cjs.map +1 -0
- package/dist/EmbeddedWalletSettings-BInZvFZf.js +79 -0
- package/dist/EmbeddedWalletSettings-BInZvFZf.js.map +1 -0
- package/dist/{EmbeddedWalletSettings-iVf_3pn3.js → EmbeddedWalletSettings-CXlZFFDw.js} +3 -3
- package/dist/EmbeddedWalletSettings-CXlZFFDw.js.map +1 -0
- package/dist/EmbeddedWalletSettings-D5JXae1L.cjs +1 -0
- package/dist/EmbeddedWalletSettings-D5JXae1L.cjs.map +1 -0
- package/dist/ErrorMessage-CHbYbVi2.cjs +1 -0
- package/dist/ErrorMessage-CHbYbVi2.cjs.map +1 -0
- package/dist/ErrorMessage-CcEK0pYO.js +64 -0
- package/dist/ErrorMessage-CcEK0pYO.js.map +1 -0
- package/dist/{GoogleLoginButton-BzHr545L.js → GoogleLoginButton-CXwp4LsQ.js} +4 -3
- package/dist/{GoogleLoginButton-BzHr545L.js.map → GoogleLoginButton-CXwp4LsQ.js.map} +1 -1
- package/dist/GoogleLoginButton-zS_69-KV.cjs +1 -0
- package/dist/{GoogleLoginButton-DoAdOqb3.cjs.map → GoogleLoginButton-zS_69-KV.cjs.map} +1 -1
- package/dist/LoadingSpinner-6vml-zwr.js +79 -0
- package/dist/LoadingSpinner-6vml-zwr.js.map +1 -0
- package/dist/LoadingSpinner-d6sSxgQN.cjs +1 -0
- package/dist/LoadingSpinner-d6sSxgQN.cjs.map +1 -0
- package/dist/PermissionsSection-BPbE-hNx.cjs +1 -0
- package/dist/PermissionsSection-BPbE-hNx.cjs.map +1 -0
- package/dist/PermissionsSection-CighC1p6.js +1026 -0
- package/dist/PermissionsSection-CighC1p6.js.map +1 -0
- package/dist/ServerSettings-BE8fsE5k.js +84 -0
- package/dist/ServerSettings-BE8fsE5k.js.map +1 -0
- package/dist/ServerSettings-CYTlQ2xy.cjs +1 -0
- package/dist/ServerSettings-CYTlQ2xy.cjs.map +1 -0
- package/dist/ServerSettings-DFs9jQ3f.cjs +1 -0
- package/dist/ServerSettings-DFs9jQ3f.cjs.map +1 -0
- package/dist/{ServerSettings-C_osdbiX.js → ServerSettings-pSmWDC1d.js} +3 -3
- package/dist/ServerSettings-pSmWDC1d.js.map +1 -0
- package/dist/SettingsPageLayout--GZ_iHLc.js +50 -0
- package/dist/SettingsPageLayout--GZ_iHLc.js.map +1 -0
- package/dist/SettingsPageLayout-j5lMjEID.cjs +1 -0
- package/dist/SettingsPageLayout-j5lMjEID.cjs.map +1 -0
- package/dist/SolanaLoginButton-BjOxpE1C.cjs +1 -0
- package/dist/{SolanaLoginButton-CPzms0kf.cjs.map → SolanaLoginButton-BjOxpE1C.cjs.map} +1 -1
- package/dist/{SolanaLoginButton-C-CfZxAZ.js → SolanaLoginButton-P22QjBaO.js} +5 -4
- package/dist/{SolanaLoginButton-C-CfZxAZ.js.map → SolanaLoginButton-P22QjBaO.js.map} +1 -1
- package/dist/StatsBar-BX-hHtTq.js +66 -0
- package/dist/StatsBar-BX-hHtTq.js.map +1 -0
- package/dist/StatsBar-DTUZCwDD.cjs +1 -0
- package/dist/StatsBar-DTUZCwDD.cjs.map +1 -0
- package/dist/{TeamSection-Bjt72upx.js → TeamSection-BIECkp7g.js} +27 -26
- package/dist/TeamSection-BIECkp7g.js.map +1 -0
- package/dist/TeamSection-BOH9pv_E.cjs +1 -0
- package/dist/TeamSection-BOH9pv_E.cjs.map +1 -0
- package/dist/UsersSection-e6q7FHzx.cjs +1 -0
- package/dist/UsersSection-e6q7FHzx.cjs.map +1 -0
- package/dist/UsersSection-t-zm0jZW.js +33 -0
- package/dist/UsersSection-t-zm0jZW.js.map +1 -0
- package/dist/{WebhookSettings-IyhyTFes.js → WebhookSettings-Bb70MbFj.js} +4 -4
- package/dist/WebhookSettings-Bb70MbFj.js.map +1 -0
- package/dist/WebhookSettings-C-gvNAW1.cjs +1 -0
- package/dist/WebhookSettings-C-gvNAW1.cjs.map +1 -0
- package/dist/WebhookSettings-CGyDKjrm.cjs +1 -0
- package/dist/WebhookSettings-CGyDKjrm.cjs.map +1 -0
- package/dist/WebhookSettings-kIstSjZi.js +17 -0
- package/dist/WebhookSettings-kIstSjZi.js.map +1 -0
- package/dist/WithdrawalsSection-sljIyeaz.cjs +1 -0
- package/dist/WithdrawalsSection-sljIyeaz.cjs.map +1 -0
- package/dist/WithdrawalsSection-yRDTVFsb.js +27 -0
- package/dist/WithdrawalsSection-yRDTVFsb.js.map +1 -0
- package/dist/admin-only.cjs +1 -0
- package/dist/admin-only.cjs.map +1 -0
- package/dist/{admin/types.d.ts → admin-only.d.ts} +228 -167
- package/dist/admin-only.js +8 -0
- package/dist/admin-only.js.map +1 -0
- package/dist/assets/argon2Worker-Bi5TuQvD.js.map +1 -1
- package/dist/email-only.cjs +1 -1
- package/dist/email-only.d.ts +645 -16
- package/dist/email-only.js +16 -13
- package/dist/email-only.js.map +1 -1
- package/dist/google-only.cjs +1 -1
- package/dist/google-only.d.ts +554 -13
- package/dist/google-only.js +11 -8
- package/dist/google-only.js.map +1 -1
- package/dist/index.cjs +2061 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +5030 -144
- package/dist/index.js +13482 -117
- package/dist/index.js.map +1 -1
- package/dist/login-react.css +1 -1
- package/dist/plugin-8_dpq7tC.cjs +1 -0
- package/dist/plugin-8_dpq7tC.cjs.map +1 -0
- package/dist/plugin-D1NdppqC.js +596 -0
- package/dist/plugin-D1NdppqC.js.map +1 -0
- package/dist/sanitization-Bo_tn-L2.cjs +1 -0
- package/dist/sanitization-Bo_tn-L2.cjs.map +1 -0
- package/dist/sanitization-CQ-H1MSg.js +39 -0
- package/dist/sanitization-CQ-H1MSg.js.map +1 -0
- package/dist/shamir-4DyQMJCk.cjs +1 -0
- package/dist/shamir-4DyQMJCk.cjs.map +1 -0
- package/dist/{solanaKeypair-BlXol3nh.js → shamir-L-s-Tp1Z.js} +765 -757
- package/dist/shamir-L-s-Tp1Z.js.map +1 -0
- package/dist/silentWalletEnroll-BgTb4H5I.cjs +1 -0
- package/dist/silentWalletEnroll-BgTb4H5I.cjs.map +1 -0
- package/dist/silentWalletEnroll-DWt6Pr3B.js +41 -0
- package/dist/silentWalletEnroll-DWt6Pr3B.js.map +1 -0
- package/dist/solana-only.cjs +1 -1
- package/dist/solana-only.d.ts +605 -13
- package/dist/solana-only.js +12 -9
- package/dist/solana-only.js.map +1 -1
- package/dist/style.d.ts +1 -0
- package/dist/useAdminDeposits-BTSyeAfg.js +151 -0
- package/dist/useAdminDeposits-BTSyeAfg.js.map +1 -0
- package/dist/useAdminDeposits-BkkCwHWp.cjs +1 -0
- package/dist/useAdminDeposits-BkkCwHWp.cjs.map +1 -0
- package/dist/{ErrorMessage-DU2VBb85.js → useAuth-C3dpk0po.js} +1005 -1241
- package/dist/useAuth-C3dpk0po.js.map +1 -0
- package/dist/useAuth-D3Pk_H3z.cjs +1 -0
- package/dist/useAuth-D3Pk_H3z.cjs.map +1 -0
- package/dist/useCedrosLogin-C9MrcZvh.cjs +1 -0
- package/dist/useCedrosLogin-C9MrcZvh.cjs.map +1 -0
- package/dist/useCedrosLogin-_94MmGGq.js +216 -0
- package/dist/useCedrosLogin-_94MmGGq.js.map +1 -0
- package/dist/useOrgs-C3pzMA9h.js +215 -0
- package/dist/useOrgs-C3pzMA9h.js.map +1 -0
- package/dist/useOrgs-DDVRCaVi.cjs +1 -0
- package/dist/useOrgs-DDVRCaVi.cjs.map +1 -0
- package/dist/useSystemSettings-DBlAMjFi.js +97 -0
- package/dist/useSystemSettings-DBlAMjFi.js.map +1 -0
- package/dist/useSystemSettings-DRrreszl.cjs +1 -0
- package/dist/useSystemSettings-DRrreszl.cjs.map +1 -0
- package/dist/useUsersStatsSummary-8qY7iP4G.cjs +1 -0
- package/dist/useUsersStatsSummary-8qY7iP4G.cjs.map +1 -0
- package/dist/useUsersStatsSummary-NjEFvWuz.js +1246 -0
- package/dist/useUsersStatsSummary-NjEFvWuz.js.map +1 -0
- package/dist/{validation-BebL7hMF.js → validation-B8kMV3BL.js} +1 -1
- package/dist/{validation-BebL7hMF.js.map → validation-B8kMV3BL.js.map} +1 -1
- package/dist/{validation-BeXIfuHB.cjs → validation-BuGQrA-K.cjs} +1 -1
- package/dist/{validation-BeXIfuHB.cjs.map → validation-BuGQrA-K.cjs.map} +1 -1
- package/package.json +11 -1
- package/dist/AuthenticationSettings-BSoIQ58T.js.map +0 -1
- package/dist/AuthenticationSettings-CNmWEPFV.cjs +0 -1
- package/dist/AuthenticationSettings-CNmWEPFV.cjs.map +0 -1
- package/dist/CreditSystemSettings-BYxoFwaP.js +0 -9
- package/dist/CreditSystemSettings-BYxoFwaP.js.map +0 -1
- package/dist/CreditSystemSettings-D2fLorNx.cjs +0 -1
- package/dist/CreditSystemSettings-D2fLorNx.cjs.map +0 -1
- package/dist/DepositsSection-0Hqr0yDm.js.map +0 -1
- package/dist/DepositsSection-CGKCzM-H.cjs +0 -1
- package/dist/DepositsSection-CGKCzM-H.cjs.map +0 -1
- package/dist/EmailRegisterForm-C0PStlj5.js +0 -961
- package/dist/EmailRegisterForm-C0PStlj5.js.map +0 -1
- package/dist/EmailRegisterForm-DaPLGws2.cjs +0 -1
- package/dist/EmailRegisterForm-DaPLGws2.cjs.map +0 -1
- package/dist/EmailSettings-CiLDwzNb.cjs +0 -1
- package/dist/EmailSettings-CiLDwzNb.cjs.map +0 -1
- package/dist/EmailSettings-DTjpO65J.js +0 -9
- package/dist/EmailSettings-DTjpO65J.js.map +0 -1
- package/dist/EmbeddedWalletSettings-CX7sYiPy.cjs +0 -1
- package/dist/EmbeddedWalletSettings-CX7sYiPy.cjs.map +0 -1
- package/dist/EmbeddedWalletSettings-iVf_3pn3.js.map +0 -1
- package/dist/ErrorMessage-BXHiYibN.cjs +0 -1
- package/dist/ErrorMessage-BXHiYibN.cjs.map +0 -1
- package/dist/ErrorMessage-DU2VBb85.js.map +0 -1
- package/dist/GoogleLoginButton-DoAdOqb3.cjs +0 -1
- package/dist/ServerSettings-C_osdbiX.js.map +0 -1
- package/dist/ServerSettings-HqSb_VDj.cjs +0 -1
- package/dist/ServerSettings-HqSb_VDj.cjs.map +0 -1
- package/dist/SolanaLoginButton-CPzms0kf.cjs +0 -1
- package/dist/TeamSection-Bjt72upx.js.map +0 -1
- package/dist/TeamSection-DZeWHkLd.cjs +0 -1
- package/dist/TeamSection-DZeWHkLd.cjs.map +0 -1
- package/dist/UsersSection-DU86czWP.cjs +0 -1
- package/dist/UsersSection-DU86czWP.cjs.map +0 -1
- package/dist/UsersSection-hAcyfSZk.js +0 -81
- package/dist/UsersSection-hAcyfSZk.js.map +0 -1
- package/dist/WebhookSettings-Br9bakAL.cjs +0 -1
- package/dist/WebhookSettings-Br9bakAL.cjs.map +0 -1
- package/dist/WebhookSettings-IyhyTFes.js.map +0 -1
- package/dist/WithdrawalsSection-B1415d-G.js +0 -20
- package/dist/WithdrawalsSection-B1415d-G.js.map +0 -1
- package/dist/WithdrawalsSection-iZJBuZ7O.cjs +0 -1
- package/dist/WithdrawalsSection-iZJBuZ7O.cjs.map +0 -1
- package/dist/admin/AdminShell.d.ts +0 -38
- package/dist/admin/icons.d.ts +0 -2
- package/dist/admin/index.d.ts +0 -10
- package/dist/admin/plugin.d.ts +0 -3
- package/dist/admin/sections/AuthenticationSettings.d.ts +0 -3
- package/dist/admin/sections/CreditSystemSettings.d.ts +0 -3
- package/dist/admin/sections/DepositsSection.d.ts +0 -3
- package/dist/admin/sections/EmailSettings.d.ts +0 -3
- package/dist/admin/sections/EmbeddedWalletSettings.d.ts +0 -3
- package/dist/admin/sections/FeatureSettings.d.ts +0 -3
- package/dist/admin/sections/InvitesSection.d.ts +0 -3
- package/dist/admin/sections/MembersSection.d.ts +0 -3
- package/dist/admin/sections/ServerSettings.d.ts +0 -3
- package/dist/admin/sections/SettingsSections.d.ts +0 -7
- package/dist/admin/sections/TeamSection.d.ts +0 -3
- package/dist/admin/sections/UsersSection.d.ts +0 -3
- package/dist/admin/sections/WebhookSettings.d.ts +0 -3
- package/dist/admin/sections/WithdrawalsSection.d.ts +0 -3
- package/dist/components/LoginButton.d.ts +0 -23
- package/dist/components/LoginForm.d.ts +0 -9
- package/dist/components/LoginModal.d.ts +0 -9
- package/dist/components/admin/AdminUserDetail.d.ts +0 -23
- package/dist/components/admin/AdminUserList.d.ts +0 -21
- package/dist/components/admin/CedrosAdminDashboard.d.ts +0 -52
- package/dist/components/admin/PermissionsSection.d.ts +0 -7
- package/dist/components/admin/ProfileDropdown.d.ts +0 -34
- package/dist/components/admin/SetupWizard.d.ts +0 -30
- package/dist/components/admin/StatsBar.d.ts +0 -17
- package/dist/components/admin/SystemSettings.d.ts +0 -19
- package/dist/components/admin/settings/AuthenticationSettings.d.ts +0 -4
- package/dist/components/admin/settings/AutosaveStatus.d.ts +0 -6
- package/dist/components/admin/settings/CreditSystemSettings.d.ts +0 -6
- package/dist/components/admin/settings/EmailSettings.d.ts +0 -4
- package/dist/components/admin/settings/EmbeddedWalletSettings.d.ts +0 -4
- package/dist/components/admin/settings/FeatureSettings.d.ts +0 -4
- package/dist/components/admin/settings/MessagingSettings.d.ts +0 -4
- package/dist/components/admin/settings/SecuritySettings.d.ts +0 -4
- package/dist/components/admin/settings/ServerSettings.d.ts +0 -4
- package/dist/components/admin/settings/SettingsPageLayout.d.ts +0 -16
- package/dist/components/admin/settings/SsoProvidersSettings.d.ts +0 -4
- package/dist/components/admin/settings/WebhookSettings.d.ts +0 -4
- package/dist/components/admin/settings/index.d.ts +0 -31
- package/dist/components/admin/settings/settingsInputs.d.ts +0 -79
- package/dist/components/admin/settings/settingsMetadata.d.ts +0 -18
- package/dist/components/apple/AppleLoginButton.d.ts +0 -29
- package/dist/components/deposit/CreditBalance.d.ts +0 -19
- package/dist/components/deposit/DepositFlow.d.ts +0 -118
- package/dist/components/deposit/FeeConfigDisplay.d.ts +0 -15
- package/dist/components/deposit/History.d.ts +0 -21
- package/dist/components/deposit/TieredAmountSlider.d.ts +0 -19
- package/dist/components/deposit/TokenSelector.d.ts +0 -23
- package/dist/components/deposit/admin/AdminDepositList.d.ts +0 -21
- package/dist/components/deposit/admin/AdminDepositStats.d.ts +0 -15
- package/dist/components/deposit/admin/AdminPrivacyPeriodDeposits.d.ts +0 -19
- package/dist/components/deposit/admin/AdminWithdrawalHistory.d.ts +0 -19
- package/dist/components/deposit/admin/AdminWithdrawalQueue.d.ts +0 -23
- package/dist/components/deposit/admin/AdminWithdrawalStats.d.ts +0 -10
- package/dist/components/deposit/admin/FeatureDisabledMessage.d.ts +0 -15
- package/dist/components/deposit/admin/PrivacySystemStatus.d.ts +0 -15
- package/dist/components/deposit/admin/featureDisabled.d.ts +0 -14
- package/dist/components/deposit/admin/index.d.ts +0 -22
- package/dist/components/deposit/index.d.ts +0 -12
- package/dist/components/deposit/tierUtils.d.ts +0 -8
- package/dist/components/deposit/tokens.d.ts +0 -19
- package/dist/components/email/EmailLoginForm.d.ts +0 -11
- package/dist/components/email/EmailRegisterForm.d.ts +0 -14
- package/dist/components/email/ForgotPasswordForm.d.ts +0 -17
- package/dist/components/email/PasswordInput.d.ts +0 -14
- package/dist/components/email/ResetPasswordForm.d.ts +0 -22
- package/dist/components/google/GoogleLoginButton.d.ts +0 -12
- package/dist/components/invites/InviteForm.d.ts +0 -38
- package/dist/components/invites/InviteList.d.ts +0 -40
- package/dist/components/members/MemberList.d.ts +0 -47
- package/dist/components/org/CreateOrgForm.d.ts +0 -7
- package/dist/components/org/OrgAvatar.d.ts +0 -7
- package/dist/components/org/OrgListView.d.ts +0 -9
- package/dist/components/org/OrgSelector.d.ts +0 -52
- package/dist/components/org/OrgSwitcher.d.ts +0 -47
- package/dist/components/org/icons.d.ts +0 -8
- package/dist/components/profile/UserProfileSettings.d.ts +0 -35
- package/dist/components/profile/index.d.ts +0 -2
- package/dist/components/sessions/SessionList.d.ts +0 -33
- package/dist/components/shared/ErrorBoundary.d.ts +0 -38
- package/dist/components/shared/ErrorMessage.d.ts +0 -14
- package/dist/components/shared/LoadingSpinner.d.ts +0 -16
- package/dist/components/solana/SolanaLoginButton.d.ts +0 -49
- package/dist/components/templates/FullPageLayout.d.ts +0 -40
- package/dist/components/templates/SplitPageLayout.d.ts +0 -44
- package/dist/components/templates/index.d.ts +0 -4
- package/dist/components/totp/OtpInput.d.ts +0 -32
- package/dist/components/totp/QrCode.d.ts +0 -21
- package/dist/components/totp/TotpSettings.d.ts +0 -38
- package/dist/components/totp/TotpSetup.d.ts +0 -23
- package/dist/components/totp/TotpVerify.d.ts +0 -25
- package/dist/components/totp/index.d.ts +0 -10
- package/dist/components/wallet/CapabilityWarning.d.ts +0 -11
- package/dist/components/wallet/PasskeyPrompt.d.ts +0 -34
- package/dist/components/wallet/RecoveryPhraseDisplay.d.ts +0 -18
- package/dist/components/wallet/RecoveryPhraseInput.d.ts +0 -21
- package/dist/components/wallet/WalletAddressRow.d.ts +0 -10
- package/dist/components/wallet/WalletEnrollment.d.ts +0 -15
- package/dist/components/wallet/WalletManager.d.ts +0 -9
- package/dist/components/wallet/WalletRecovery.d.ts +0 -19
- package/dist/components/wallet/WalletStatus.d.ts +0 -28
- package/dist/components/wallet/WalletUnlock.d.ts +0 -23
- package/dist/components/wallet/index.d.ts +0 -23
- package/dist/components/webauthn/PasskeyLoginButton.d.ts +0 -8
- package/dist/context/CedrosLoginContext.d.ts +0 -24
- package/dist/context/CedrosLoginProvider.d.ts +0 -17
- package/dist/context/EmbeddedWalletExposure.d.ts +0 -19
- package/dist/context/useCedrosLogin.d.ts +0 -12
- package/dist/crypto/aesGcm.d.ts +0 -89
- package/dist/crypto/argon2.d.ts +0 -65
- package/dist/crypto/argon2Worker.d.ts +0 -1
- package/dist/crypto/argon2WorkerClient.d.ts +0 -28
- package/dist/crypto/bip39.d.ts +0 -106
- package/dist/crypto/capabilities.d.ts +0 -35
- package/dist/crypto/entropy.d.ts +0 -56
- package/dist/crypto/hkdf.d.ts +0 -38
- package/dist/crypto/index.d.ts +0 -30
- package/dist/crypto/secureWipe.d.ts +0 -71
- package/dist/crypto/shamir.d.ts +0 -52
- package/dist/crypto/solanaKeypair.d.ts +0 -63
- package/dist/crypto/types.d.ts +0 -134
- package/dist/crypto/webauthnPrf.d.ts +0 -108
- package/dist/hooks/useAdminDeposits.d.ts +0 -10
- package/dist/hooks/useAdminUsers.d.ts +0 -28
- package/dist/hooks/useAppleAuth.d.ts +0 -52
- package/dist/hooks/useAuth.d.ts +0 -34
- package/dist/hooks/useAuthSession.d.ts +0 -19
- package/dist/hooks/useAuthorize.d.ts +0 -62
- package/dist/hooks/useCredits.d.ts +0 -11
- package/dist/hooks/useDashboardPermissions.d.ts +0 -45
- package/dist/hooks/useDeposit.d.ts +0 -16
- package/dist/hooks/useEmailAuth.d.ts +0 -60
- package/dist/hooks/useGoogleAuth.d.ts +0 -67
- package/dist/hooks/useInstantLink.d.ts +0 -42
- package/dist/hooks/useInvites.d.ts +0 -57
- package/dist/hooks/useMembers.d.ts +0 -52
- package/dist/hooks/useOrgs.d.ts +0 -49
- package/dist/hooks/usePasswordReset.d.ts +0 -32
- package/dist/hooks/usePendingRecovery.d.ts +0 -34
- package/dist/hooks/useProfile.d.ts +0 -35
- package/dist/hooks/useRateLimiter.d.ts +0 -58
- package/dist/hooks/useServerFeatures.d.ts +0 -55
- package/dist/hooks/useSessions.d.ts +0 -45
- package/dist/hooks/useSettingsAutosave.d.ts +0 -29
- package/dist/hooks/useSetup.d.ts +0 -25
- package/dist/hooks/useSolanaAuth.d.ts +0 -30
- package/dist/hooks/useSsoProviders.d.ts +0 -52
- package/dist/hooks/useSystemSettings.d.ts +0 -47
- package/dist/hooks/useThemeManager.d.ts +0 -11
- package/dist/hooks/useTotp.d.ts +0 -52
- package/dist/hooks/useTotpVerify.d.ts +0 -38
- package/dist/hooks/useTransactionSigning.d.ts +0 -45
- package/dist/hooks/useWallet.d.ts +0 -10
- package/dist/hooks/useWalletDiscovery.d.ts +0 -24
- package/dist/hooks/useWalletEnrollment.d.ts +0 -9
- package/dist/hooks/useWalletMaterial.d.ts +0 -10
- package/dist/hooks/useWalletRecovery.d.ts +0 -9
- package/dist/hooks/useWalletSigning.d.ts +0 -31
- package/dist/hooks/useWebAuthn.d.ts +0 -25
- package/dist/i18n/I18nProvider.d.ts +0 -16
- package/dist/i18n/context.d.ts +0 -6
- package/dist/i18n/index.d.ts +0 -5
- package/dist/i18n/translations.d.ts +0 -66
- package/dist/i18n/useI18n.d.ts +0 -9
- package/dist/index-ZS9AwAal.cjs +0 -2061
- package/dist/index-ZS9AwAal.cjs.map +0 -1
- package/dist/index-dgg5tlO7.js +0 -19650
- package/dist/index-dgg5tlO7.js.map +0 -1
- package/dist/silentWalletEnroll-C3JRAD9_.js +0 -42
- package/dist/silentWalletEnroll-C3JRAD9_.js.map +0 -1
- package/dist/silentWalletEnroll-DRYQAQfg.cjs +0 -1
- package/dist/silentWalletEnroll-DRYQAQfg.cjs.map +0 -1
- package/dist/solanaKeypair-BlXol3nh.js.map +0 -1
- package/dist/solanaKeypair-C-lIR1JY.cjs +0 -1
- package/dist/solanaKeypair-C-lIR1JY.cjs.map +0 -1
- package/dist/types/adminUser.d.ts +0 -168
- package/dist/types/auth.d.ts +0 -122
- package/dist/types/config.d.ts +0 -266
- package/dist/types/deposit.d.ts +0 -490
- package/dist/types/index.d.ts +0 -13
- package/dist/types/invite.d.ts +0 -71
- package/dist/types/member.d.ts +0 -45
- package/dist/types/org.d.ts +0 -133
- package/dist/types/profile.d.ts +0 -56
- package/dist/types/session.d.ts +0 -28
- package/dist/types/setup.d.ts +0 -47
- package/dist/types/systemSettings.d.ts +0 -85
- package/dist/types/totp.d.ts +0 -52
- package/dist/types/wallet.d.ts +0 -309
- package/dist/utils/adminUserApi.d.ts +0 -60
- package/dist/utils/apiClient.d.ts +0 -78
- package/dist/utils/cryptoShim.d.ts +0 -17
- package/dist/utils/csrf.d.ts +0 -1
- package/dist/utils/deviceDetection.d.ts +0 -17
- package/dist/utils/embeddedWallet.d.ts +0 -75
- package/dist/utils/inviteApi.d.ts +0 -31
- package/dist/utils/memberApi.d.ts +0 -23
- package/dist/utils/orgApi.d.ts +0 -36
- package/dist/utils/profileApi.d.ts +0 -26
- package/dist/utils/sanitization.d.ts +0 -66
- package/dist/utils/sessionApi.d.ts +0 -16
- package/dist/utils/setupApi.d.ts +0 -21
- package/dist/utils/silentWalletEnroll.d.ts +0 -41
- package/dist/utils/systemSettingsApi.d.ts +0 -18
- package/dist/utils/tabSync.d.ts +0 -46
- package/dist/utils/tokenManager.d.ts +0 -107
- package/dist/utils/unlockCredential.d.ts +0 -5
- package/dist/utils/validation.d.ts +0 -48
- package/dist/utils/walletDetection.d.ts +0 -23
- package/dist/utils/webauthnJson.d.ts +0 -21
package/dist/crypto/aesGcm.d.ts
DELETED
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
import { EncryptionKey, AesNonce } from './types';
|
|
2
|
-
/** Result of AES-GCM encryption */
|
|
3
|
-
export interface AesGcmEncryptResult {
|
|
4
|
-
/** Ciphertext including authentication tag */
|
|
5
|
-
ciphertext: Uint8Array;
|
|
6
|
-
/** 12-byte nonce used */
|
|
7
|
-
nonce: AesNonce;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Encrypt plaintext using AES-256-GCM
|
|
11
|
-
*
|
|
12
|
-
* @param plaintext - Data to encrypt
|
|
13
|
-
* @param key - 32-byte encryption key
|
|
14
|
-
* @param nonce - Optional 12-byte nonce (generated if not provided)
|
|
15
|
-
* @returns Ciphertext and nonce
|
|
16
|
-
* @throws Error if encryption fails
|
|
17
|
-
*/
|
|
18
|
-
export declare function aesGcmEncrypt(plaintext: Uint8Array, key: EncryptionKey, nonce?: AesNonce): Promise<AesGcmEncryptResult>;
|
|
19
|
-
/**
|
|
20
|
-
* Decrypt ciphertext using AES-256-GCM
|
|
21
|
-
*
|
|
22
|
-
* @param ciphertext - Data to decrypt (includes auth tag)
|
|
23
|
-
* @param key - 32-byte encryption key
|
|
24
|
-
* @param nonce - 12-byte nonce used during encryption
|
|
25
|
-
* @returns Decrypted plaintext
|
|
26
|
-
* @throws Error if decryption or authentication fails
|
|
27
|
-
*/
|
|
28
|
-
export declare function aesGcmDecrypt(ciphertext: Uint8Array, key: EncryptionKey, nonce: AesNonce): Promise<Uint8Array>;
|
|
29
|
-
/**
|
|
30
|
-
* Encrypt plaintext and return base64-encoded results
|
|
31
|
-
*
|
|
32
|
-
* @param plaintext - Data to encrypt
|
|
33
|
-
* @param key - 32-byte encryption key
|
|
34
|
-
* @returns Base64-encoded ciphertext and nonce
|
|
35
|
-
*/
|
|
36
|
-
export declare function aesGcmEncryptToBase64(plaintext: Uint8Array, key: EncryptionKey): Promise<{
|
|
37
|
-
ciphertext: string;
|
|
38
|
-
nonce: string;
|
|
39
|
-
}>;
|
|
40
|
-
/**
|
|
41
|
-
* Decrypt base64-encoded ciphertext
|
|
42
|
-
*
|
|
43
|
-
* @param ciphertextB64 - Base64-encoded ciphertext
|
|
44
|
-
* @param nonceB64 - Base64-encoded nonce
|
|
45
|
-
* @param key - 32-byte encryption key
|
|
46
|
-
* @returns Decrypted plaintext
|
|
47
|
-
*/
|
|
48
|
-
export declare function aesGcmDecryptFromBase64(ciphertextB64: string, nonceB64: string, key: EncryptionKey): Promise<Uint8Array>;
|
|
49
|
-
/**
|
|
50
|
-
* Encrypt with automatic key derivation from password
|
|
51
|
-
*
|
|
52
|
-
* This is a convenience wrapper that combines Argon2 KDF with AES-GCM.
|
|
53
|
-
* For more control, use argon2 and aesGcmEncrypt separately.
|
|
54
|
-
*
|
|
55
|
-
* @param plaintext - Data to encrypt
|
|
56
|
-
* @param passwordKey - Key derived from password via Argon2
|
|
57
|
-
* @returns Encrypted result with nonce
|
|
58
|
-
*/
|
|
59
|
-
export declare function encryptWithPasswordKey(plaintext: Uint8Array, passwordKey: Uint8Array): Promise<AesGcmEncryptResult>;
|
|
60
|
-
/**
|
|
61
|
-
* Decrypt with password-derived key
|
|
62
|
-
*
|
|
63
|
-
* @param ciphertext - Data to decrypt
|
|
64
|
-
* @param nonce - Nonce used during encryption
|
|
65
|
-
* @param passwordKey - Key derived from password via Argon2
|
|
66
|
-
* @returns Decrypted plaintext
|
|
67
|
-
*/
|
|
68
|
-
export declare function decryptWithPasswordKey(ciphertext: Uint8Array, nonce: AesNonce, passwordKey: Uint8Array): Promise<Uint8Array>;
|
|
69
|
-
/**
|
|
70
|
-
* Convert Uint8Array to base64 string
|
|
71
|
-
*
|
|
72
|
-
* MAINT-01: Uses chunked String.fromCharCode for O(n) performance.
|
|
73
|
-
* Simple concatenation (`binary += char`) would be O(n²).
|
|
74
|
-
*/
|
|
75
|
-
export declare function uint8ArrayToBase64(bytes: Uint8Array): string;
|
|
76
|
-
/**
|
|
77
|
-
* Convert base64 string to Uint8Array
|
|
78
|
-
*
|
|
79
|
-
* @throws Error if input is not valid base64
|
|
80
|
-
*/
|
|
81
|
-
export declare function base64ToUint8Array(base64: string): Uint8Array;
|
|
82
|
-
/**
|
|
83
|
-
* Encrypt and securely wipe plaintext after encryption
|
|
84
|
-
*
|
|
85
|
-
* @param plaintext - Data to encrypt (will be wiped)
|
|
86
|
-
* @param key - Encryption key
|
|
87
|
-
* @returns Encrypted result
|
|
88
|
-
*/
|
|
89
|
-
export declare function encryptAndWipe(plaintext: Uint8Array, key: EncryptionKey): Promise<AesGcmEncryptResult>;
|
package/dist/crypto/argon2.d.ts
DELETED
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import { EncryptionKey, Argon2Salt, KdfParams } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Derive an encryption key from a password using Argon2id
|
|
4
|
-
*
|
|
5
|
-
* @security H-01: The password string cannot be wiped from memory after use.
|
|
6
|
-
* For sensitive applications, prefer argon2DeriveFromBytes() which accepts
|
|
7
|
-
* Uint8Array that CAN be securely wiped.
|
|
8
|
-
*
|
|
9
|
-
* @param password - User password or PIN
|
|
10
|
-
* @param salt - Unique salt (16+ bytes)
|
|
11
|
-
* @param params - KDF parameters (memory, time, parallelism)
|
|
12
|
-
* @returns 32-byte encryption key
|
|
13
|
-
*/
|
|
14
|
-
export declare function argon2Derive(password: string, salt: Argon2Salt, params?: KdfParams): Promise<EncryptionKey>;
|
|
15
|
-
/**
|
|
16
|
-
* Derive key from password bytes (for non-string passwords like PINs)
|
|
17
|
-
*
|
|
18
|
-
* @param passwordBytes - Password as bytes
|
|
19
|
-
* @param salt - Unique salt
|
|
20
|
-
* @param params - KDF parameters
|
|
21
|
-
* @returns 32-byte encryption key
|
|
22
|
-
*/
|
|
23
|
-
export declare function argon2DeriveFromBytes(passwordBytes: Uint8Array, salt: Argon2Salt, params?: KdfParams): Promise<EncryptionKey>;
|
|
24
|
-
/**
|
|
25
|
-
* Validate KDF parameters are within safe bounds
|
|
26
|
-
*
|
|
27
|
-
* Prevents DoS attacks via excessive resource consumption.
|
|
28
|
-
*
|
|
29
|
-
* @param params - Parameters to validate
|
|
30
|
-
* @throws Error if parameters are out of bounds
|
|
31
|
-
*/
|
|
32
|
-
export declare function validateKdfParams(params: KdfParams): void;
|
|
33
|
-
/**
|
|
34
|
-
* Check if Argon2 WASM is available and working
|
|
35
|
-
*
|
|
36
|
-
* @returns true if Argon2 can be used
|
|
37
|
-
*/
|
|
38
|
-
export declare function isArgon2Supported(): Promise<boolean>;
|
|
39
|
-
/**
|
|
40
|
-
* Verify a password against stored parameters
|
|
41
|
-
*
|
|
42
|
-
* This is primarily for testing/validation, not for authentication
|
|
43
|
-
* (the server handles authentication).
|
|
44
|
-
*
|
|
45
|
-
* M-06: Timing Leak Note
|
|
46
|
-
* The length check at the start of comparison returns early on mismatch,
|
|
47
|
-
* creating a timing side-channel. This is acceptable because:
|
|
48
|
-
* 1. Server handles real authentication (not this client-side code)
|
|
49
|
-
* 2. Key lengths are fixed (32 bytes), so mismatch indicates corruption not attack
|
|
50
|
-
* 3. Argon2 derivation dominates timing regardless of comparison path
|
|
51
|
-
*
|
|
52
|
-
* @param password - Password to verify
|
|
53
|
-
* @param salt - Salt used during original derivation
|
|
54
|
-
* @param params - KDF parameters used
|
|
55
|
-
* @param expectedKey - Expected derived key
|
|
56
|
-
* @returns true if password produces the same key
|
|
57
|
-
*/
|
|
58
|
-
export declare function verifyPassword(password: string, salt: Argon2Salt, params: KdfParams, expectedKey: Uint8Array): Promise<boolean>;
|
|
59
|
-
/**
|
|
60
|
-
* Get recommended KDF parameters based on target duration
|
|
61
|
-
*
|
|
62
|
-
* @param targetMs - Target duration in milliseconds (default: 500ms)
|
|
63
|
-
* @returns Recommended parameters
|
|
64
|
-
*/
|
|
65
|
-
export declare function getRecommendedParams(targetMs?: number): KdfParams;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { Argon2Salt, EncryptionKey, KdfParams } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Derive an encryption key from password using Argon2id in a Web Worker.
|
|
4
|
-
*
|
|
5
|
-
* Offloads CPU-intensive Argon2id KDF to a background thread to avoid
|
|
6
|
-
* blocking the main thread. Falls back to synchronous derivation if
|
|
7
|
-
* Web Workers are not available.
|
|
8
|
-
*
|
|
9
|
-
* @param password - User's password
|
|
10
|
-
* @param salt - 16-byte random salt
|
|
11
|
-
* @param params - KDF parameters (memory, iterations, parallelism)
|
|
12
|
-
* @returns 32-byte encryption key
|
|
13
|
-
*
|
|
14
|
-
* @security **CALLER MUST WIPE RETURNED KEY AFTER USE**
|
|
15
|
-
* The returned key contains sensitive cryptographic material.
|
|
16
|
-
* Callers are responsible for wiping it when no longer needed:
|
|
17
|
-
* ```ts
|
|
18
|
-
* const key = await argon2DeriveInWorker(password, salt);
|
|
19
|
-
* try {
|
|
20
|
-
* // use key for encryption/decryption
|
|
21
|
-
* } finally {
|
|
22
|
-
* wipeBytes(key);
|
|
23
|
-
* }
|
|
24
|
-
* ```
|
|
25
|
-
* Failure to wipe may leave key material in memory, vulnerable to memory
|
|
26
|
-
* dump attacks.
|
|
27
|
-
*/
|
|
28
|
-
export declare function argon2DeriveInWorker(password: string, salt: Argon2Salt, params?: KdfParams): Promise<EncryptionKey>;
|
package/dist/crypto/bip39.d.ts
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import { Seed, ShamirShare } from './types';
|
|
2
|
-
/** Number of words in recovery phrase (12 = 128 bits, standard Solana format) */
|
|
3
|
-
export declare const MNEMONIC_WORD_COUNT = 12;
|
|
4
|
-
/**
|
|
5
|
-
* Encode a Shamir share as a BIP-39 mnemonic phrase
|
|
6
|
-
*
|
|
7
|
-
* @param share - 16-byte share to encode
|
|
8
|
-
* @returns Array of 12 mnemonic words
|
|
9
|
-
*/
|
|
10
|
-
export declare function shareToMnemonic(share: ShamirShare): string[];
|
|
11
|
-
/**
|
|
12
|
-
* Decode a BIP-39 mnemonic phrase back to a Shamir share
|
|
13
|
-
*
|
|
14
|
-
* @param words - Array of 12 mnemonic words
|
|
15
|
-
* @returns 16-byte share
|
|
16
|
-
* @throws Error if mnemonic is invalid
|
|
17
|
-
*/
|
|
18
|
-
export declare function mnemonicToShare(words: string[]): ShamirShare;
|
|
19
|
-
/**
|
|
20
|
-
* Encode a 16-byte seed as a BIP-39 mnemonic phrase
|
|
21
|
-
*
|
|
22
|
-
* This is used for the recovery phrase which encodes the FULL SEED
|
|
23
|
-
* (not a Shamir share) to allow complete wallet recovery.
|
|
24
|
-
*
|
|
25
|
-
* @param seed - 16-byte seed to encode
|
|
26
|
-
* @returns Array of 12 mnemonic words
|
|
27
|
-
*/
|
|
28
|
-
export declare function seedToMnemonic(seed: Seed): string[];
|
|
29
|
-
/**
|
|
30
|
-
* Decode a BIP-39 mnemonic phrase back to a seed
|
|
31
|
-
*
|
|
32
|
-
* This is used during recovery to restore the full wallet seed.
|
|
33
|
-
*
|
|
34
|
-
* @param words - Array of 12 mnemonic words
|
|
35
|
-
* @returns 16-byte seed
|
|
36
|
-
* @throws Error if mnemonic is invalid
|
|
37
|
-
*/
|
|
38
|
-
export declare function mnemonicToSeed(words: string[]): Seed;
|
|
39
|
-
/**
|
|
40
|
-
* Validate a mnemonic phrase without decoding
|
|
41
|
-
*
|
|
42
|
-
* @param words - Array of words to validate
|
|
43
|
-
* @returns true if valid BIP-39 mnemonic
|
|
44
|
-
*/
|
|
45
|
-
export declare function isValidMnemonic(words: string[]): boolean;
|
|
46
|
-
/**
|
|
47
|
-
* Check if a single word is in the BIP-39 wordlist
|
|
48
|
-
*
|
|
49
|
-
* @param word - Word to check
|
|
50
|
-
* @returns true if word is in the wordlist
|
|
51
|
-
*/
|
|
52
|
-
export declare function isValidWord(word: string): boolean;
|
|
53
|
-
/**
|
|
54
|
-
* Get word suggestions for autocomplete
|
|
55
|
-
*
|
|
56
|
-
* @param prefix - Partial word input
|
|
57
|
-
* @param limit - Maximum number of suggestions
|
|
58
|
-
* @returns Array of matching words from wordlist
|
|
59
|
-
*/
|
|
60
|
-
export declare function getWordSuggestions(prefix: string, limit?: number): string[];
|
|
61
|
-
/**
|
|
62
|
-
* Generate a random mnemonic for testing purposes
|
|
63
|
-
*
|
|
64
|
-
* WARNING: Do not use this for actual wallet generation.
|
|
65
|
-
* Use the proper enrollment flow which generates a seed and splits it.
|
|
66
|
-
*
|
|
67
|
-
* @returns Array of 12 random words
|
|
68
|
-
*/
|
|
69
|
-
export declare function generateRandomMnemonic(): string[];
|
|
70
|
-
/**
|
|
71
|
-
* Format mnemonic words for display (groups of 4)
|
|
72
|
-
*
|
|
73
|
-
* @param words - Array of mnemonic words
|
|
74
|
-
* @returns Array of word groups
|
|
75
|
-
*/
|
|
76
|
-
export declare function formatMnemonicForDisplay(words: string[]): string[][];
|
|
77
|
-
/**
|
|
78
|
-
* Parse user input into word array, handling various formats
|
|
79
|
-
*
|
|
80
|
-
* @param input - User input (space/comma/newline separated)
|
|
81
|
-
* @returns Array of normalized words
|
|
82
|
-
*/
|
|
83
|
-
export declare function parseMnemonicInput(input: string): string[];
|
|
84
|
-
/**
|
|
85
|
-
* Securely wipe mnemonic array
|
|
86
|
-
*
|
|
87
|
-
* @security CRYPTO-2: This is BEST-EFFORT only. JavaScript strings are immutable
|
|
88
|
-
* and the original word values WILL persist in memory until garbage collected.
|
|
89
|
-
* See secureWipe.ts wipeString() for details on JS string wiping limitations.
|
|
90
|
-
*
|
|
91
|
-
* @param words - Array of words to wipe
|
|
92
|
-
*/
|
|
93
|
-
export declare function wipeMnemonic(words: string[]): void;
|
|
94
|
-
/**
|
|
95
|
-
* Get the BIP-39 wordlist for UI purposes (e.g., validation indicators)
|
|
96
|
-
*
|
|
97
|
-
* @returns Copy of the wordlist
|
|
98
|
-
*/
|
|
99
|
-
export declare function getWordlist(): readonly string[];
|
|
100
|
-
/**
|
|
101
|
-
* Calculate the index of a word in the wordlist
|
|
102
|
-
*
|
|
103
|
-
* @param word - Word to look up
|
|
104
|
-
* @returns Index (0-2047) or -1 if not found
|
|
105
|
-
*/
|
|
106
|
-
export declare function getWordIndex(word: string): number;
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { CryptoCapabilities } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Check all required crypto capabilities
|
|
4
|
-
*
|
|
5
|
-
* @returns Capability check results
|
|
6
|
-
*/
|
|
7
|
-
export declare function checkCryptoCapabilities(): Promise<CryptoCapabilities>;
|
|
8
|
-
/**
|
|
9
|
-
* Get a human-readable message about missing capabilities
|
|
10
|
-
*
|
|
11
|
-
* @param capabilities - Capability check results
|
|
12
|
-
* @returns Error message describing what's missing, or null if all supported
|
|
13
|
-
*/
|
|
14
|
-
export declare function getMissingCapabilitiesMessage(capabilities: CryptoCapabilities): string | null;
|
|
15
|
-
/**
|
|
16
|
-
* Check if the browser is known to support all required features
|
|
17
|
-
*
|
|
18
|
-
* @returns Object with browser info and support status
|
|
19
|
-
*/
|
|
20
|
-
export declare function getBrowserSupportInfo(): {
|
|
21
|
-
browser: string;
|
|
22
|
-
version: string;
|
|
23
|
-
likelySupported: boolean;
|
|
24
|
-
};
|
|
25
|
-
/**
|
|
26
|
-
* Get cached capabilities or check if not cached
|
|
27
|
-
*
|
|
28
|
-
* @param forceRefresh - If true, bypass cache and recheck
|
|
29
|
-
* @returns Capability check results
|
|
30
|
-
*/
|
|
31
|
-
export declare function getCryptoCapabilities(forceRefresh?: boolean): Promise<CryptoCapabilities>;
|
|
32
|
-
/**
|
|
33
|
-
* Clear the capability cache (useful for testing)
|
|
34
|
-
*/
|
|
35
|
-
export declare function clearCapabilityCache(): void;
|
package/dist/crypto/entropy.d.ts
DELETED
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { Seed, AesNonce, Argon2Salt, PrfSalt } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Get cryptographically secure random bytes
|
|
4
|
-
*
|
|
5
|
-
* @param length - Number of bytes to generate
|
|
6
|
-
* @returns Random bytes
|
|
7
|
-
* @throws Error if WebCrypto is not available
|
|
8
|
-
*/
|
|
9
|
-
export declare function getRandomBytes(length: number): Uint8Array;
|
|
10
|
-
/**
|
|
11
|
-
* Generate a cryptographically secure 16-byte seed for wallet derivation
|
|
12
|
-
*
|
|
13
|
-
* Note: 16 bytes (128 bits) matches standard Solana wallet format.
|
|
14
|
-
*
|
|
15
|
-
* @returns 16-byte seed
|
|
16
|
-
* @throws Error if WebCrypto is not available
|
|
17
|
-
*/
|
|
18
|
-
export declare function generateSeed(): Seed;
|
|
19
|
-
/**
|
|
20
|
-
* Generate a 12-byte nonce for AES-GCM encryption
|
|
21
|
-
*
|
|
22
|
-
* Security: AES-GCM requires a unique nonce per encryption with the same key.
|
|
23
|
-
* Using random nonces is safe for reasonable message counts (< 2^32).
|
|
24
|
-
*
|
|
25
|
-
* CRYPTO-03: For high-volume encryption scenarios (>2^30 messages with same key),
|
|
26
|
-
* the birthday bound risk of nonce collision increases. Recommendations:
|
|
27
|
-
* 1. Rotate encryption keys periodically (e.g., every 2^20 encryptions)
|
|
28
|
-
* 2. Use counter-based nonces instead of random for sequential encryption
|
|
29
|
-
* 3. Monitor encryption count and trigger re-keying before limits are reached
|
|
30
|
-
*
|
|
31
|
-
* For typical wallet use cases (encrypting seed once), random nonces are safe.
|
|
32
|
-
*
|
|
33
|
-
* @returns 12-byte nonce
|
|
34
|
-
* @throws Error if WebCrypto is not available
|
|
35
|
-
*/
|
|
36
|
-
export declare function generateNonce(): AesNonce;
|
|
37
|
-
/**
|
|
38
|
-
* Generate a 16-byte salt for Argon2id KDF
|
|
39
|
-
*
|
|
40
|
-
* Security: Salt must be unique per user/password combination.
|
|
41
|
-
* 16 bytes provides sufficient uniqueness.
|
|
42
|
-
*
|
|
43
|
-
* @returns 16-byte salt
|
|
44
|
-
* @throws Error if WebCrypto is not available
|
|
45
|
-
*/
|
|
46
|
-
export declare function generateArgon2Salt(): Argon2Salt;
|
|
47
|
-
/**
|
|
48
|
-
* Generate a 32-byte salt for WebAuthn PRF extension
|
|
49
|
-
*
|
|
50
|
-
* Security: PRF salt is used as input to the PRF to derive unique
|
|
51
|
-
* per-credential keys. Must be stored alongside encrypted share.
|
|
52
|
-
*
|
|
53
|
-
* @returns 32-byte PRF salt
|
|
54
|
-
* @throws Error if WebCrypto is not available
|
|
55
|
-
*/
|
|
56
|
-
export declare function generatePrfSalt(): PrfSalt;
|
package/dist/crypto/hkdf.d.ts
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { EncryptionKey } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Derive an encryption key using HKDF-SHA256
|
|
4
|
-
*
|
|
5
|
-
* @param inputKeyMaterial - Raw key material (e.g., from PRF)
|
|
6
|
-
* @param salt - Optional salt (if not provided, uses zero-filled buffer)
|
|
7
|
-
* @param info - Context/application-specific info string
|
|
8
|
-
* @param outputLength - Desired output key length in bytes (default: 32)
|
|
9
|
-
* @returns Derived key
|
|
10
|
-
*/
|
|
11
|
-
export declare function hkdfDerive(inputKeyMaterial: Uint8Array, salt: Uint8Array | undefined, info: string, outputLength?: number): Promise<Uint8Array>;
|
|
12
|
-
/**
|
|
13
|
-
* Derive a 256-bit encryption key from PRF output
|
|
14
|
-
*
|
|
15
|
-
* @param prfOutput - Output from WebAuthn PRF extension (typically 32 bytes)
|
|
16
|
-
* @param prfSalt - Salt used with PRF (stored with encrypted share)
|
|
17
|
-
* @returns 32-byte encryption key suitable for AES-256-GCM
|
|
18
|
-
*/
|
|
19
|
-
export declare function deriveKeyFromPrf(prfOutput: Uint8Array, prfSalt: Uint8Array): Promise<EncryptionKey>;
|
|
20
|
-
/**
|
|
21
|
-
* Derive a key with domain separation for different purposes
|
|
22
|
-
*
|
|
23
|
-
* @param inputKeyMaterial - Base key material
|
|
24
|
-
* @param domain - Domain separator string (e.g., 'signing', 'encryption')
|
|
25
|
-
* @param salt - Optional salt
|
|
26
|
-
* @returns Derived key
|
|
27
|
-
*
|
|
28
|
-
* @security Domain strings MUST be unique across the codebase. Using the same
|
|
29
|
-
* domain with the same input key material will produce identical keys, which
|
|
30
|
-
* could lead to key reuse vulnerabilities. See module-level docs for reserved domains.
|
|
31
|
-
*/
|
|
32
|
-
export declare function deriveKeyWithDomain(inputKeyMaterial: Uint8Array, domain: string, salt?: Uint8Array): Promise<Uint8Array>;
|
|
33
|
-
/**
|
|
34
|
-
* Check if HKDF is supported in the current environment
|
|
35
|
-
*
|
|
36
|
-
* @returns true if HKDF is available
|
|
37
|
-
*/
|
|
38
|
-
export declare function isHkdfSupported(): Promise<boolean>;
|
package/dist/crypto/index.d.ts
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Crypto module exports for SSS wallet implementation
|
|
3
|
-
*
|
|
4
|
-
* This module provides all cryptographic primitives needed for the
|
|
5
|
-
* non-custodial Solana wallet feature using Shamir Secret Sharing.
|
|
6
|
-
*
|
|
7
|
-
* Key components:
|
|
8
|
-
* - Entropy: Secure random number generation
|
|
9
|
-
* - Shamir: Secret splitting and reconstruction
|
|
10
|
-
* - AES-GCM: Authenticated encryption
|
|
11
|
-
* - Argon2: Password-based key derivation
|
|
12
|
-
* - HKDF: Key derivation from PRF output
|
|
13
|
-
* - BIP-39: Mnemonic encoding for recovery phrase
|
|
14
|
-
* - WebAuthn PRF: Device key derivation via passkeys
|
|
15
|
-
* - Solana Keypair: Ed25519 keypair derivation
|
|
16
|
-
* - Secure Wipe: Memory cleanup utilities
|
|
17
|
-
* - Capabilities: Feature detection
|
|
18
|
-
*/
|
|
19
|
-
export * from './types';
|
|
20
|
-
export { getRandomBytes, generateSeed, generateNonce, generateArgon2Salt, generatePrfSalt, } from './entropy';
|
|
21
|
-
export { wipeBytes, wipeAll, withSecureCleanup, withSecureCleanupSync, createSecureContainer, type SecureContainer, } from './secureWipe';
|
|
22
|
-
export { aesGcmEncrypt, aesGcmDecrypt, aesGcmEncryptToBase64, aesGcmDecryptFromBase64, encryptWithPasswordKey, decryptWithPasswordKey, encryptAndWipe, uint8ArrayToBase64, base64ToUint8Array, type AesGcmEncryptResult, } from './aesGcm';
|
|
23
|
-
export { hkdfDerive, deriveKeyFromPrf, deriveKeyWithDomain, isHkdfSupported } from './hkdf';
|
|
24
|
-
export { argon2Derive, argon2DeriveFromBytes, validateKdfParams, isArgon2Supported, verifyPassword, getRecommendedParams, } from './argon2';
|
|
25
|
-
export { argon2DeriveInWorker } from './argon2WorkerClient';
|
|
26
|
-
export { splitSecret, combineShares, verifyShares, getShareIndex, padToLength, SHAMIR_THRESHOLD, SHAMIR_TOTAL, type ShareId, type ShamirSplitResult, } from './shamir';
|
|
27
|
-
export { shareToMnemonic, mnemonicToShare, seedToMnemonic, mnemonicToSeed, isValidMnemonic, isValidWord, getWordSuggestions, generateRandomMnemonic, formatMnemonicForDisplay, parseMnemonicInput, wipeMnemonic, getWordlist, getWordIndex, MNEMONIC_WORD_COUNT, } from './bip39';
|
|
28
|
-
export { isWebAuthnAvailable, isPrfSupported, registerPasskeyWithPrf, authenticateWithPrf, authenticateWithDiscoverablePrf, getEncryptionKeyFromPasskey, isCredentialAvailable, type PasskeyRegistrationResult, type PasskeyAuthResult, } from './webauthnPrf';
|
|
29
|
-
export { deriveKeypairFromSeed, getPublicKeyFromSeed, publicKeyToBase58, base58ToPublicKey, isValidSolanaAddress, type SolanaKeypair, } from './solanaKeypair';
|
|
30
|
-
export { checkCryptoCapabilities, getMissingCapabilitiesMessage, getBrowserSupportInfo, getCryptoCapabilities, clearCapabilityCache, } from './capabilities';
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Secure memory wiping utilities
|
|
3
|
-
*
|
|
4
|
-
* Security: JavaScript does not guarantee memory clearing due to GC and
|
|
5
|
-
* JIT optimization. These functions provide best-effort clearing of
|
|
6
|
-
* sensitive data. For truly sensitive operations, consider using
|
|
7
|
-
* WebAssembly with explicit memory management.
|
|
8
|
-
*
|
|
9
|
-
* IMPORTANT - String vs Uint8Array:
|
|
10
|
-
* - Uint8Array CAN be wiped (wipeBytes) - use for keys, seeds, passwords
|
|
11
|
-
* - Strings CANNOT be wiped in JavaScript - they are immutable
|
|
12
|
-
* - Always prefer Uint8Array for sensitive cryptographic material
|
|
13
|
-
*
|
|
14
|
-
* Best practices:
|
|
15
|
-
* - Call wipe functions as soon as sensitive data is no longer needed
|
|
16
|
-
* - Use try/finally blocks to ensure wiping on errors
|
|
17
|
-
* - Keep sensitive data lifetime as short as possible
|
|
18
|
-
* - Convert sensitive strings to Uint8Array immediately, wipe after use
|
|
19
|
-
*/
|
|
20
|
-
/**
|
|
21
|
-
* Best-effort wipe of a Uint8Array by zeroing all bytes
|
|
22
|
-
*
|
|
23
|
-
* Warning: JavaScript JIT may optimize away this operation. This provides
|
|
24
|
-
* defense-in-depth but is not a guarantee against memory inspection.
|
|
25
|
-
*
|
|
26
|
-
* @param data - Array to wipe
|
|
27
|
-
*/
|
|
28
|
-
export declare function wipeBytes(data: Uint8Array): void;
|
|
29
|
-
/**
|
|
30
|
-
* Wipe multiple byte arrays
|
|
31
|
-
*
|
|
32
|
-
* @param arrays - Arrays to wipe
|
|
33
|
-
*/
|
|
34
|
-
export declare function wipeAll(...arrays: (Uint8Array | undefined | null)[]): void;
|
|
35
|
-
/**
|
|
36
|
-
* Execute a function with automatic cleanup of byte arrays
|
|
37
|
-
*
|
|
38
|
-
* @param arrays - Arrays to wipe after function completes
|
|
39
|
-
* @param fn - Function to execute
|
|
40
|
-
* @returns Result of function
|
|
41
|
-
*/
|
|
42
|
-
export declare function withSecureCleanup<T>(arrays: Uint8Array[], fn: () => Promise<T>): Promise<T>;
|
|
43
|
-
/**
|
|
44
|
-
* Execute a synchronous function with automatic cleanup of byte arrays
|
|
45
|
-
*
|
|
46
|
-
* @param arrays - Arrays to wipe after function completes
|
|
47
|
-
* @param fn - Function to execute
|
|
48
|
-
* @returns Result of function
|
|
49
|
-
*/
|
|
50
|
-
export declare function withSecureCleanupSync<T>(arrays: Uint8Array[], fn: () => T): T;
|
|
51
|
-
/**
|
|
52
|
-
* Create a scoped container for sensitive byte data with automatic cleanup
|
|
53
|
-
*
|
|
54
|
-
* Usage:
|
|
55
|
-
* ```typescript
|
|
56
|
-
* const container = createSecureContainer();
|
|
57
|
-
* try {
|
|
58
|
-
* const key = container.track(generateKey());
|
|
59
|
-
* // use key...
|
|
60
|
-
* } finally {
|
|
61
|
-
* container.wipeAll();
|
|
62
|
-
* }
|
|
63
|
-
* ```
|
|
64
|
-
*/
|
|
65
|
-
export declare function createSecureContainer(): SecureContainer;
|
|
66
|
-
export interface SecureContainer {
|
|
67
|
-
/** Track a byte array for later cleanup */
|
|
68
|
-
track<T extends Uint8Array>(data: T): T;
|
|
69
|
-
/** Wipe all tracked arrays */
|
|
70
|
-
wipeAll(): void;
|
|
71
|
-
}
|
package/dist/crypto/shamir.d.ts
DELETED
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { Seed, ShamirShare } from './types';
|
|
2
|
-
/** Shamir threshold (minimum shares to reconstruct) */
|
|
3
|
-
export declare const SHAMIR_THRESHOLD = 2;
|
|
4
|
-
/** Total number of shares */
|
|
5
|
-
export declare const SHAMIR_TOTAL = 3;
|
|
6
|
-
/** Share identifiers */
|
|
7
|
-
export type ShareId = 'A' | 'B' | 'C';
|
|
8
|
-
/** Result of splitting a secret into shares */
|
|
9
|
-
export interface ShamirSplitResult {
|
|
10
|
-
/** Share A (for password encryption) */
|
|
11
|
-
shareA: ShamirShare;
|
|
12
|
-
/** Share B (for device PRF encryption) */
|
|
13
|
-
shareB: ShamirShare;
|
|
14
|
-
/** Share C (for recovery phrase) */
|
|
15
|
-
shareC: ShamirShare;
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* Split a 16-byte seed into 3 shares using Shamir's Secret Sharing
|
|
19
|
-
*
|
|
20
|
-
* @param seed - 16-byte seed to split
|
|
21
|
-
* @returns Three shares (any 2 can reconstruct the seed)
|
|
22
|
-
*/
|
|
23
|
-
export declare function splitSecret(seed: Seed): ShamirSplitResult;
|
|
24
|
-
/**
|
|
25
|
-
* Combine 2 shares to reconstruct the original seed
|
|
26
|
-
*
|
|
27
|
-
* @param share1 - First share
|
|
28
|
-
* @param share2 - Second share (must be different from first)
|
|
29
|
-
* @returns Reconstructed 16-byte seed (MAINT-03: fixed from incorrect "32-byte")
|
|
30
|
-
* @throws Error if shares are invalid or cannot reconstruct
|
|
31
|
-
*/
|
|
32
|
-
export declare function combineShares(share1: ShamirShare, share2: ShamirShare): Seed;
|
|
33
|
-
/**
|
|
34
|
-
* Verify that shares can successfully reconstruct a seed
|
|
35
|
-
*
|
|
36
|
-
* @param share1 - First share
|
|
37
|
-
* @param share2 - Second share
|
|
38
|
-
* @param expectedSeed - Expected seed after reconstruction
|
|
39
|
-
* @returns true if shares reconstruct to expected seed
|
|
40
|
-
*/
|
|
41
|
-
export declare function verifyShares(share1: ShamirShare, share2: ShamirShare, expectedSeed: Seed): boolean;
|
|
42
|
-
/**
|
|
43
|
-
* Extract share index from a share (useful for debugging)
|
|
44
|
-
*
|
|
45
|
-
* @param share - Share to inspect
|
|
46
|
-
* @returns Share index (1-based)
|
|
47
|
-
*/
|
|
48
|
-
export declare function getShareIndex(share: ShamirShare): number;
|
|
49
|
-
/**
|
|
50
|
-
* Pad a Uint8Array to a specific length
|
|
51
|
-
*/
|
|
52
|
-
export declare function padToLength(data: Uint8Array, targetLength: number): Uint8Array;
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { Seed } from './types';
|
|
2
|
-
/** Solana keypair with public and secret key */
|
|
3
|
-
export interface SolanaKeypair {
|
|
4
|
-
/** 32-byte Ed25519 public key */
|
|
5
|
-
publicKey: Uint8Array;
|
|
6
|
-
/** 64-byte Ed25519 secret key (32-byte expanded seed + 32-byte public key) */
|
|
7
|
-
secretKey: Uint8Array;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Derive an Ed25519 keypair from a 16-byte seed
|
|
11
|
-
*
|
|
12
|
-
* The 16-byte seed is expanded to 32 bytes using SHA-256, then used for
|
|
13
|
-
* Ed25519 derivation which internally:
|
|
14
|
-
* - Hashes expanded seed with SHA-512
|
|
15
|
-
* - Clamps lower 32 bytes to form scalar
|
|
16
|
-
* - Multiplies by Ed25519 base point
|
|
17
|
-
*
|
|
18
|
-
* @param seed - 16-byte seed (128-bit entropy)
|
|
19
|
-
* @returns Keypair with 32-byte public key and 64-byte secret key
|
|
20
|
-
*
|
|
21
|
-
* @security **CALLER MUST WIPE secretKey AFTER USE**
|
|
22
|
-
* The returned `secretKey` contains sensitive cryptographic material.
|
|
23
|
-
* Callers are responsible for wiping it when no longer needed:
|
|
24
|
-
* ```ts
|
|
25
|
-
* const keypair = deriveKeypairFromSeed(seed);
|
|
26
|
-
* try {
|
|
27
|
-
* // use keypair.secretKey for signing
|
|
28
|
-
* } finally {
|
|
29
|
-
* wipeBytes(keypair.secretKey);
|
|
30
|
-
* }
|
|
31
|
-
* ```
|
|
32
|
-
* Failure to wipe may leave key material in memory, vulnerable to memory
|
|
33
|
-
* dump attacks. The internal `expandedSeed` is automatically wiped.
|
|
34
|
-
*/
|
|
35
|
-
export declare function deriveKeypairFromSeed(seed: Seed): SolanaKeypair;
|
|
36
|
-
/**
|
|
37
|
-
* Get the public key from a seed without returning the secret key
|
|
38
|
-
*
|
|
39
|
-
* @param seed - 32-byte seed
|
|
40
|
-
* @returns 32-byte Ed25519 public key
|
|
41
|
-
*/
|
|
42
|
-
export declare function getPublicKeyFromSeed(seed: Seed): Uint8Array;
|
|
43
|
-
/**
|
|
44
|
-
* Encode a public key as a Base58 Solana address
|
|
45
|
-
*
|
|
46
|
-
* @param publicKey - 32-byte public key
|
|
47
|
-
* @returns Base58-encoded address string
|
|
48
|
-
*/
|
|
49
|
-
export declare function publicKeyToBase58(publicKey: Uint8Array): string;
|
|
50
|
-
/**
|
|
51
|
-
* Decode a Base58 Solana address to public key bytes
|
|
52
|
-
*
|
|
53
|
-
* @param address - Base58-encoded address
|
|
54
|
-
* @returns 32-byte public key
|
|
55
|
-
*/
|
|
56
|
-
export declare function base58ToPublicKey(address: string): Uint8Array;
|
|
57
|
-
/**
|
|
58
|
-
* Validate a Solana address format
|
|
59
|
-
*
|
|
60
|
-
* @param address - Address string to validate
|
|
61
|
-
* @returns true if valid Base58 and correct length
|
|
62
|
-
*/
|
|
63
|
-
export declare function isValidSolanaAddress(address: string): boolean;
|