@aptos-labs/ts-sdk 1.7.0 → 1.9.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/dist/browser/index.d.ts +1226 -975
- package/dist/browser/index.global.js +32 -30
- package/dist/browser/index.global.js.map +1 -1
- package/dist/common/index.d.ts +1226 -975
- package/dist/common/index.js +27 -25
- package/dist/common/index.js.map +1 -1
- package/dist/esm/api/account.d.mts +12 -6
- package/dist/esm/api/account.mjs +1 -1
- package/dist/esm/api/ans.d.mts +11 -12
- package/dist/esm/api/ans.mjs +1 -1
- package/dist/esm/api/aptos.d.mts +13 -14
- package/dist/esm/api/aptos.mjs +1 -1
- package/dist/esm/api/aptosConfig.mjs +1 -1
- package/dist/esm/api/coin.d.mts +13 -13
- package/dist/esm/api/coin.mjs +1 -1
- package/dist/esm/api/digitalAsset.d.mts +20 -10
- package/dist/esm/api/digitalAsset.mjs +1 -1
- package/dist/esm/api/event.d.mts +14 -1
- package/dist/esm/api/event.mjs +1 -1
- package/dist/esm/api/faucet.mjs +1 -1
- package/dist/esm/api/fungibleAsset.d.mts +9 -10
- package/dist/esm/api/fungibleAsset.mjs +1 -1
- package/dist/esm/api/general.mjs +1 -1
- package/dist/esm/api/index.d.mts +13 -14
- package/dist/esm/api/index.mjs +1 -1
- package/dist/esm/api/staking.mjs +1 -1
- package/dist/esm/api/transaction.d.mts +5 -6
- package/dist/esm/api/transaction.mjs +1 -1
- package/dist/esm/api/transactionSubmission/build.d.mts +8 -8
- package/dist/esm/api/transactionSubmission/build.mjs +1 -1
- package/dist/esm/api/transactionSubmission/management.d.mts +11 -12
- package/dist/esm/api/transactionSubmission/management.mjs +1 -1
- package/dist/esm/api/transactionSubmission/sign.d.mts +11 -12
- package/dist/esm/api/transactionSubmission/sign.mjs +1 -1
- package/dist/esm/api/transactionSubmission/sign.mjs.map +1 -1
- package/dist/esm/api/transactionSubmission/simulate.d.mts +11 -11
- package/dist/esm/api/transactionSubmission/simulate.mjs +1 -1
- package/dist/esm/api/transactionSubmission/submit.d.mts +6 -6
- package/dist/esm/api/transactionSubmission/submit.mjs +1 -1
- package/dist/esm/api/utils.mjs +1 -1
- package/dist/esm/bcs/index.mjs +1 -1
- package/dist/esm/bcs/serializable/movePrimitives.mjs +1 -1
- package/dist/esm/bcs/serializable/moveStructs.mjs +1 -1
- package/dist/esm/chunk-2E2JOGE5.mjs +2 -0
- package/dist/esm/chunk-2E2JOGE5.mjs.map +1 -0
- package/dist/esm/chunk-3EUOBVCT.mjs +2 -0
- package/dist/esm/{chunk-A2QH4A6D.mjs.map → chunk-3EUOBVCT.mjs.map} +1 -1
- package/dist/esm/{chunk-RNO5ZG3C.mjs → chunk-52RTAMN7.mjs} +2 -2
- package/dist/esm/chunk-7BDYKJXX.mjs +2 -0
- package/dist/esm/chunk-7BDYKJXX.mjs.map +1 -0
- package/dist/esm/{chunk-WQI2RH2S.mjs → chunk-7U36LMP4.mjs} +2 -2
- package/dist/esm/{chunk-NWRKJFHV.mjs → chunk-ARIC32W7.mjs} +2 -2
- package/dist/esm/{chunk-RIL4SHXC.mjs → chunk-B7M3OWHV.mjs} +2 -2
- package/dist/esm/{chunk-C7ZX475J.mjs → chunk-BBUAAJRA.mjs} +2 -2
- package/dist/esm/chunk-C3HM7HQP.mjs +2 -0
- package/dist/esm/chunk-C3HM7HQP.mjs.map +1 -0
- package/dist/esm/{chunk-DRF6AMEZ.mjs → chunk-CHA5DSSD.mjs} +2 -2
- package/dist/esm/chunk-CVEJHRAU.mjs +2 -0
- package/dist/esm/chunk-CVEJHRAU.mjs.map +1 -0
- package/dist/esm/chunk-DE5OOOVY.mjs +2 -0
- package/dist/esm/{chunk-3UYBNX3P.mjs.map → chunk-DE5OOOVY.mjs.map} +1 -1
- package/dist/esm/{chunk-IKCBGNRD.mjs → chunk-DGOT2VR5.mjs} +2 -2
- package/dist/esm/{chunk-GVHOHNHT.mjs → chunk-EF2F7NWO.mjs} +2 -2
- package/dist/esm/{chunk-J6RCCKOA.mjs → chunk-EQZ757ES.mjs} +2 -2
- package/dist/esm/{chunk-CX5ULWJQ.mjs → chunk-F67Y7YH6.mjs} +2 -2
- package/dist/esm/{chunk-JLL7BCD4.mjs → chunk-FVMVV4V3.mjs} +2 -2
- package/dist/esm/chunk-FWDKABRW.mjs +2 -0
- package/dist/esm/chunk-FWDKABRW.mjs.map +1 -0
- package/dist/esm/chunk-G62HQC77.mjs +2 -0
- package/dist/esm/chunk-G62HQC77.mjs.map +1 -0
- package/dist/esm/{chunk-ESX5X52V.mjs → chunk-GQOOXOTN.mjs} +2 -2
- package/dist/esm/chunk-GRJJBGHT.mjs +2 -0
- package/dist/esm/chunk-GRJJBGHT.mjs.map +1 -0
- package/dist/esm/chunk-HEPV52CH.mjs +2 -0
- package/dist/esm/chunk-HEPV52CH.mjs.map +1 -0
- package/dist/esm/{chunk-XQIWF5HY.mjs → chunk-I3TCHVQQ.mjs} +2 -2
- package/dist/esm/{chunk-3NOQE6U3.mjs → chunk-ILJWEPDW.mjs} +2 -2
- package/dist/esm/chunk-INORE66K.mjs +2 -0
- package/dist/esm/chunk-INORE66K.mjs.map +1 -0
- package/dist/esm/{chunk-5L6SRCJP.mjs → chunk-J6MWD4XN.mjs} +2 -2
- package/dist/esm/{chunk-YGMT4GQ5.mjs → chunk-JEHR6GKW.mjs} +2 -2
- package/dist/esm/chunk-JEHR6GKW.mjs.map +1 -0
- package/dist/esm/chunk-KUX6GQ2E.mjs +1 -0
- package/dist/esm/{chunk-6UNBJAV6.mjs → chunk-KWJTVJ7C.mjs} +2 -2
- package/dist/esm/chunk-KWJTVJ7C.mjs.map +1 -0
- package/dist/esm/{chunk-WK36MJRI.mjs → chunk-LLL2LFYH.mjs} +2 -2
- package/dist/esm/chunk-LMXP3JUU.mjs +2 -0
- package/dist/esm/chunk-LMXP3JUU.mjs.map +1 -0
- package/dist/esm/{chunk-5WXR2O3T.mjs → chunk-N65SOKJQ.mjs} +2 -2
- package/dist/esm/{chunk-XOBXX273.mjs → chunk-NL3XVNS5.mjs} +2 -2
- package/dist/esm/{chunk-Q7JKS6WV.mjs → chunk-NURFZOR4.mjs} +2 -2
- package/dist/esm/{chunk-MKERJNYN.mjs → chunk-OG56TYZE.mjs} +2 -2
- package/dist/esm/chunk-Q6WOHF4A.mjs +2 -0
- package/dist/esm/chunk-Q6WOHF4A.mjs.map +1 -0
- package/dist/esm/chunk-QA4XWNIH.mjs +2 -0
- package/dist/esm/chunk-QA4XWNIH.mjs.map +1 -0
- package/dist/esm/chunk-QE4ASJ5K.mjs +1 -0
- package/dist/esm/chunk-QR72RXBS.mjs +2 -0
- package/dist/esm/chunk-QR72RXBS.mjs.map +1 -0
- package/dist/esm/{chunk-TVURQPLA.mjs → chunk-R4VJDSIP.mjs} +2 -2
- package/dist/esm/{chunk-O57QZZF2.mjs → chunk-S2F6CSH4.mjs} +2 -2
- package/dist/esm/chunk-S2F6CSH4.mjs.map +1 -0
- package/dist/esm/{chunk-BQSE5HHW.mjs → chunk-S4SEFF4K.mjs} +3 -1
- package/dist/esm/chunk-S4SEFF4K.mjs.map +1 -0
- package/dist/esm/{chunk-OVSV4Y32.mjs → chunk-SXIFL5DQ.mjs} +2 -2
- package/dist/esm/{chunk-OVSV4Y32.mjs.map → chunk-SXIFL5DQ.mjs.map} +1 -1
- package/dist/esm/{chunk-Z6XNTGNK.mjs → chunk-TN5BUH4F.mjs} +2 -2
- package/dist/esm/chunk-TNVR7SNR.mjs +2 -0
- package/dist/esm/chunk-TNVR7SNR.mjs.map +1 -0
- package/dist/esm/chunk-TX7UK75Q.mjs +2 -0
- package/dist/esm/chunk-TX7UK75Q.mjs.map +1 -0
- package/dist/esm/{chunk-YE3DZD6T.mjs → chunk-UIUSDBCL.mjs} +2 -2
- package/dist/esm/{chunk-7JTOGYO7.mjs → chunk-UMLDKLDL.mjs} +2 -2
- package/dist/esm/chunk-UVSRX4SV.mjs +1 -0
- package/dist/esm/{chunk-6Y3VBRMN.mjs → chunk-VEVBHH3M.mjs} +2 -2
- package/dist/esm/{chunk-T5IFXLOP.mjs → chunk-VMXBMAYK.mjs} +2 -2
- package/dist/esm/chunk-WKUXBIYB.mjs +2 -0
- package/dist/esm/chunk-WKUXBIYB.mjs.map +1 -0
- package/dist/esm/chunk-WME5D6YR.mjs +2 -0
- package/dist/esm/chunk-WME5D6YR.mjs.map +1 -0
- package/dist/esm/chunk-WTHNSNAX.mjs +2 -0
- package/dist/esm/chunk-WTHNSNAX.mjs.map +1 -0
- package/dist/esm/{chunk-WC2WSKYZ.mjs → chunk-X5C3LYI7.mjs} +2 -2
- package/dist/esm/chunk-XKD7W5NO.mjs +2 -0
- package/dist/esm/{chunk-UJAX75ON.mjs.map → chunk-XKD7W5NO.mjs.map} +1 -1
- package/dist/esm/{chunk-OWZLBIDD.mjs → chunk-XTPFQ4MH.mjs} +2 -2
- package/dist/esm/{chunk-D2GNCG27.mjs → chunk-Y5AJLNUD.mjs} +2 -2
- package/dist/esm/chunk-YDAA4RG4.mjs +2 -0
- package/dist/esm/chunk-YDAA4RG4.mjs.map +1 -0
- package/dist/esm/{chunk-ZFPA45OK.mjs → chunk-YR2R3LW4.mjs} +2 -2
- package/dist/esm/chunk-YZZO6VDC.mjs +2 -0
- package/dist/esm/chunk-YZZO6VDC.mjs.map +1 -0
- package/dist/esm/client/core.mjs +1 -1
- package/dist/esm/client/get.mjs +1 -1
- package/dist/esm/client/index.mjs +1 -1
- package/dist/esm/client/post.mjs +1 -1
- package/dist/esm/core/account/Account.d.mts +20 -0
- package/dist/esm/core/account/Account.mjs +2 -0
- package/dist/esm/core/account/Ed25519Account.d.mts +20 -0
- package/dist/esm/core/account/Ed25519Account.mjs +2 -0
- package/dist/esm/core/account/SingleKeyAccount.d.mts +20 -0
- package/dist/esm/core/account/SingleKeyAccount.mjs +2 -0
- package/dist/esm/core/account/SingleKeyAccount.mjs.map +1 -0
- package/dist/esm/core/account/index.d.mts +305 -0
- package/dist/esm/core/account/index.mjs +2 -0
- package/dist/esm/core/account/index.mjs.map +1 -0
- package/dist/esm/core/accountAddress.mjs +1 -1
- package/dist/esm/core/authenticationKey.d.mts +7 -68
- package/dist/esm/core/authenticationKey.mjs +1 -1
- package/dist/esm/core/crypto/ed25519.d.mts +49 -61
- package/dist/esm/core/crypto/ed25519.mjs +1 -1
- package/dist/esm/core/crypto/index.d.mts +9 -6
- package/dist/esm/core/crypto/index.mjs +1 -1
- package/dist/esm/core/crypto/multiEd25519.d.mts +17 -14
- package/dist/esm/core/crypto/multiEd25519.mjs +1 -1
- package/dist/esm/core/crypto/multiKey.d.mts +70 -17
- package/dist/esm/core/crypto/multiKey.mjs +1 -1
- package/dist/esm/core/crypto/privateKey.d.mts +35 -0
- package/dist/esm/core/crypto/privateKey.mjs +2 -0
- package/dist/esm/core/crypto/privateKey.mjs.map +1 -0
- package/dist/esm/core/crypto/publicKey.d.mts +13 -0
- package/dist/esm/core/crypto/publicKey.mjs +2 -0
- package/dist/esm/core/crypto/publicKey.mjs.map +1 -0
- package/dist/esm/core/crypto/secp256k1.d.mts +43 -67
- package/dist/esm/core/crypto/secp256k1.mjs +1 -1
- package/dist/esm/core/crypto/signature.d.mts +28 -0
- package/dist/esm/core/crypto/signature.mjs +2 -0
- package/dist/esm/core/crypto/signature.mjs.map +1 -0
- package/dist/esm/core/crypto/singleKey.d.mts +68 -0
- package/dist/esm/core/crypto/singleKey.mjs +2 -0
- package/dist/esm/core/crypto/singleKey.mjs.map +1 -0
- package/dist/esm/core/index.d.mts +9 -8
- package/dist/esm/core/index.mjs +1 -1
- package/dist/esm/index.d.mts +9 -9
- package/dist/esm/index.mjs +1 -1
- package/dist/esm/internal/account.d.mts +9 -3
- package/dist/esm/internal/account.mjs +1 -1
- package/dist/esm/internal/ans.d.mts +10 -11
- package/dist/esm/internal/ans.mjs +1 -1
- package/dist/esm/internal/coin.d.mts +9 -9
- package/dist/esm/internal/coin.mjs +1 -1
- package/dist/esm/internal/digitalAsset.d.mts +15 -12
- package/dist/esm/internal/digitalAsset.mjs +1 -1
- package/dist/esm/internal/event.d.mts +7 -2
- package/dist/esm/internal/event.mjs +1 -1
- package/dist/esm/internal/faucet.d.mts +1 -1
- package/dist/esm/internal/faucet.mjs +1 -1
- package/dist/esm/internal/fungibleAsset.d.mts +9 -10
- package/dist/esm/internal/fungibleAsset.mjs +1 -1
- package/dist/esm/internal/general.mjs +1 -1
- package/dist/esm/internal/staking.d.mts +1 -1
- package/dist/esm/internal/staking.mjs +1 -1
- package/dist/esm/internal/transaction.mjs +1 -1
- package/dist/esm/internal/transactionSubmission.d.mts +10 -11
- package/dist/esm/internal/transactionSubmission.mjs +1 -1
- package/dist/esm/publicKey-lq5djCIY.d.mts +113 -0
- package/dist/esm/transactions/authenticator/account.d.mts +6 -4
- package/dist/esm/transactions/authenticator/account.mjs +1 -1
- package/dist/esm/transactions/authenticator/index.d.mts +6 -6
- package/dist/esm/transactions/authenticator/index.mjs +1 -1
- package/dist/esm/transactions/authenticator/transaction.d.mts +5 -5
- package/dist/esm/transactions/authenticator/transaction.mjs +1 -1
- package/dist/esm/transactions/index.d.mts +6 -7
- package/dist/esm/transactions/index.mjs +1 -1
- package/dist/esm/transactions/instances/index.d.mts +4 -4
- package/dist/esm/transactions/instances/index.mjs +1 -1
- package/dist/esm/transactions/instances/moduleId.d.mts +1 -1
- package/dist/esm/transactions/instances/moduleId.mjs +1 -1
- package/dist/esm/transactions/instances/rawTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/rotationProofChallenge.d.mts +2 -1
- package/dist/esm/transactions/instances/rotationProofChallenge.mjs +1 -1
- package/dist/esm/transactions/instances/signedTransaction.d.mts +8 -8
- package/dist/esm/transactions/instances/signedTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/transactionPayload.d.mts +1 -1
- package/dist/esm/transactions/instances/transactionPayload.mjs +1 -1
- package/dist/esm/transactions/management/accountSequenceNumber.d.mts +11 -5
- package/dist/esm/transactions/management/accountSequenceNumber.mjs +1 -1
- package/dist/esm/transactions/management/index.d.mts +11 -12
- package/dist/esm/transactions/management/index.mjs +1 -1
- package/dist/esm/transactions/management/transactionWorker.d.mts +11 -12
- package/dist/esm/transactions/management/transactionWorker.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/helpers.d.mts +10 -10
- package/dist/esm/transactions/transactionBuilder/helpers.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/index.d.mts +9 -10
- package/dist/esm/transactions/transactionBuilder/index.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/remoteAbi.d.mts +8 -8
- package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.d.mts +9 -10
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.mjs +1 -1
- package/dist/esm/transactions/typeTag/index.mjs +1 -1
- package/dist/esm/transactions/typeTag/parser.mjs +1 -1
- package/dist/esm/transactions/types.d.mts +9 -9
- package/dist/esm/types/generated/operations.d.mts +6 -0
- package/dist/esm/types/generated/queries.d.mts +6 -6
- package/dist/esm/types/generated/queries.mjs +1 -1
- package/dist/esm/types/generated/types.d.mts +594 -56
- package/dist/esm/types/generated/types.mjs +1 -1
- package/dist/esm/types/generated/types.mjs.map +1 -1
- package/dist/esm/types/index.d.mts +35 -6
- package/dist/esm/types/index.mjs +1 -1
- package/dist/esm/utils/const.d.mts +1 -2
- package/dist/esm/utils/const.mjs +1 -1
- package/dist/esm/utils/index.d.mts +1 -1
- package/dist/esm/utils/index.mjs +1 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +16 -16
- package/src/api/aptosConfig.ts +2 -2
- package/src/api/digitalAsset.ts +20 -0
- package/src/api/event.ts +27 -1
- package/src/core/account/Account.ts +245 -0
- package/src/core/account/Ed25519Account.ts +88 -0
- package/src/core/account/SingleKeyAccount.ts +120 -0
- package/src/core/account/index.ts +3 -0
- package/src/core/authenticationKey.ts +18 -52
- package/src/core/crypto/ed25519.ts +118 -104
- package/src/core/crypto/index.ts +6 -5
- package/src/core/crypto/multiEd25519.ts +98 -44
- package/src/core/crypto/multiKey.ts +192 -34
- package/src/core/crypto/privateKey.ts +25 -0
- package/src/core/crypto/publicKey.ts +52 -0
- package/src/core/crypto/secp256k1.ts +108 -111
- package/src/core/crypto/signature.ts +46 -0
- package/src/core/crypto/singleKey.ts +180 -0
- package/src/internal/account.ts +5 -3
- package/src/internal/digitalAsset.ts +26 -0
- package/src/internal/event.ts +33 -1
- package/src/internal/queries/currentTokenOwnershipFieldsFragment.graphql +1 -0
- package/src/internal/queries/getTokenData.graphql +1 -0
- package/src/transactions/authenticator/account.ts +1 -2
- package/src/transactions/instances/rotationProofChallenge.ts +1 -1
- package/src/transactions/transactionBuilder/transactionBuilder.ts +3 -21
- package/src/transactions/types.ts +1 -1
- package/src/types/generated/operations.ts +6 -0
- package/src/types/generated/queries.ts +2 -0
- package/src/types/generated/types.ts +662 -55
- package/src/types/index.ts +40 -4
- package/src/utils/const.ts +0 -4
- package/src/version.ts +1 -1
- package/dist/esm/chunk-2QV6HI3M.mjs +0 -2
- package/dist/esm/chunk-2QV6HI3M.mjs.map +0 -1
- package/dist/esm/chunk-3UYBNX3P.mjs +0 -2
- package/dist/esm/chunk-4SAUEZTN.mjs +0 -2
- package/dist/esm/chunk-4SAUEZTN.mjs.map +0 -1
- package/dist/esm/chunk-6UNBJAV6.mjs.map +0 -1
- package/dist/esm/chunk-7IGH7N52.mjs +0 -2
- package/dist/esm/chunk-7IGH7N52.mjs.map +0 -1
- package/dist/esm/chunk-A2QH4A6D.mjs +0 -2
- package/dist/esm/chunk-AA3GRJNL.mjs +0 -2
- package/dist/esm/chunk-AA3GRJNL.mjs.map +0 -1
- package/dist/esm/chunk-ALFESCPU.mjs +0 -2
- package/dist/esm/chunk-ALFESCPU.mjs.map +0 -1
- package/dist/esm/chunk-BQSE5HHW.mjs.map +0 -1
- package/dist/esm/chunk-CCUD52OF.mjs +0 -2
- package/dist/esm/chunk-CCUD52OF.mjs.map +0 -1
- package/dist/esm/chunk-ERWQOVBF.mjs +0 -2
- package/dist/esm/chunk-ERWQOVBF.mjs.map +0 -1
- package/dist/esm/chunk-FBFMQZTM.mjs +0 -2
- package/dist/esm/chunk-FBFMQZTM.mjs.map +0 -1
- package/dist/esm/chunk-FP5DPRYL.mjs +0 -2
- package/dist/esm/chunk-FP5DPRYL.mjs.map +0 -1
- package/dist/esm/chunk-HHJBCGAQ.mjs +0 -2
- package/dist/esm/chunk-HHJBCGAQ.mjs.map +0 -1
- package/dist/esm/chunk-I7WRJY7K.mjs +0 -2
- package/dist/esm/chunk-I7WRJY7K.mjs.map +0 -1
- package/dist/esm/chunk-INV6U3KS.mjs +0 -2
- package/dist/esm/chunk-INV6U3KS.mjs.map +0 -1
- package/dist/esm/chunk-O57QZZF2.mjs.map +0 -1
- package/dist/esm/chunk-SBMJNU2O.mjs +0 -2
- package/dist/esm/chunk-SBMJNU2O.mjs.map +0 -1
- package/dist/esm/chunk-SZYATFM7.mjs +0 -2
- package/dist/esm/chunk-SZYATFM7.mjs.map +0 -1
- package/dist/esm/chunk-UCHGKGCF.mjs +0 -2
- package/dist/esm/chunk-UCHGKGCF.mjs.map +0 -1
- package/dist/esm/chunk-UIVJXLRM.mjs +0 -1
- package/dist/esm/chunk-UJAX75ON.mjs +0 -2
- package/dist/esm/chunk-V6JFR2CB.mjs +0 -2
- package/dist/esm/chunk-V6JFR2CB.mjs.map +0 -1
- package/dist/esm/chunk-YGMT4GQ5.mjs.map +0 -1
- package/dist/esm/chunk-ZFIMVSCR.mjs +0 -2
- package/dist/esm/chunk-ZFIMVSCR.mjs.map +0 -1
- package/dist/esm/chunk-ZIZ7PVK2.mjs +0 -2
- package/dist/esm/chunk-ZIZ7PVK2.mjs.map +0 -1
- package/dist/esm/core/account.d.mts +0 -184
- package/dist/esm/core/account.mjs +0 -2
- package/dist/esm/core/crypto/anyPublicKey.d.mts +0 -59
- package/dist/esm/core/crypto/anyPublicKey.mjs +0 -2
- package/dist/esm/core/crypto/anySignature.d.mts +0 -31
- package/dist/esm/core/crypto/anySignature.mjs +0 -2
- package/dist/esm/core/crypto/asymmetricCrypto.d.mts +0 -74
- package/dist/esm/core/crypto/asymmetricCrypto.mjs +0 -2
- package/src/core/account.ts +0 -282
- package/src/core/crypto/anyPublicKey.ts +0 -92
- package/src/core/crypto/anySignature.ts +0 -56
- package/src/core/crypto/asymmetricCrypto.ts +0 -77
- /package/dist/esm/{chunk-RNO5ZG3C.mjs.map → chunk-52RTAMN7.mjs.map} +0 -0
- /package/dist/esm/{chunk-WQI2RH2S.mjs.map → chunk-7U36LMP4.mjs.map} +0 -0
- /package/dist/esm/{chunk-NWRKJFHV.mjs.map → chunk-ARIC32W7.mjs.map} +0 -0
- /package/dist/esm/{chunk-RIL4SHXC.mjs.map → chunk-B7M3OWHV.mjs.map} +0 -0
- /package/dist/esm/{chunk-C7ZX475J.mjs.map → chunk-BBUAAJRA.mjs.map} +0 -0
- /package/dist/esm/{chunk-DRF6AMEZ.mjs.map → chunk-CHA5DSSD.mjs.map} +0 -0
- /package/dist/esm/{chunk-IKCBGNRD.mjs.map → chunk-DGOT2VR5.mjs.map} +0 -0
- /package/dist/esm/{chunk-GVHOHNHT.mjs.map → chunk-EF2F7NWO.mjs.map} +0 -0
- /package/dist/esm/{chunk-J6RCCKOA.mjs.map → chunk-EQZ757ES.mjs.map} +0 -0
- /package/dist/esm/{chunk-CX5ULWJQ.mjs.map → chunk-F67Y7YH6.mjs.map} +0 -0
- /package/dist/esm/{chunk-JLL7BCD4.mjs.map → chunk-FVMVV4V3.mjs.map} +0 -0
- /package/dist/esm/{chunk-ESX5X52V.mjs.map → chunk-GQOOXOTN.mjs.map} +0 -0
- /package/dist/esm/{chunk-XQIWF5HY.mjs.map → chunk-I3TCHVQQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-3NOQE6U3.mjs.map → chunk-ILJWEPDW.mjs.map} +0 -0
- /package/dist/esm/{chunk-5L6SRCJP.mjs.map → chunk-J6MWD4XN.mjs.map} +0 -0
- /package/dist/esm/{chunk-UIVJXLRM.mjs.map → chunk-KUX6GQ2E.mjs.map} +0 -0
- /package/dist/esm/{chunk-WK36MJRI.mjs.map → chunk-LLL2LFYH.mjs.map} +0 -0
- /package/dist/esm/{chunk-5WXR2O3T.mjs.map → chunk-N65SOKJQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-XOBXX273.mjs.map → chunk-NL3XVNS5.mjs.map} +0 -0
- /package/dist/esm/{chunk-Q7JKS6WV.mjs.map → chunk-NURFZOR4.mjs.map} +0 -0
- /package/dist/esm/{chunk-MKERJNYN.mjs.map → chunk-OG56TYZE.mjs.map} +0 -0
- /package/dist/esm/{core/account.mjs.map → chunk-QE4ASJ5K.mjs.map} +0 -0
- /package/dist/esm/{chunk-TVURQPLA.mjs.map → chunk-R4VJDSIP.mjs.map} +0 -0
- /package/dist/esm/{chunk-Z6XNTGNK.mjs.map → chunk-TN5BUH4F.mjs.map} +0 -0
- /package/dist/esm/{chunk-YE3DZD6T.mjs.map → chunk-UIUSDBCL.mjs.map} +0 -0
- /package/dist/esm/{chunk-7JTOGYO7.mjs.map → chunk-UMLDKLDL.mjs.map} +0 -0
- /package/dist/esm/{core/crypto/anyPublicKey.mjs.map → chunk-UVSRX4SV.mjs.map} +0 -0
- /package/dist/esm/{chunk-6Y3VBRMN.mjs.map → chunk-VEVBHH3M.mjs.map} +0 -0
- /package/dist/esm/{chunk-T5IFXLOP.mjs.map → chunk-VMXBMAYK.mjs.map} +0 -0
- /package/dist/esm/{chunk-WC2WSKYZ.mjs.map → chunk-X5C3LYI7.mjs.map} +0 -0
- /package/dist/esm/{chunk-OWZLBIDD.mjs.map → chunk-XTPFQ4MH.mjs.map} +0 -0
- /package/dist/esm/{chunk-D2GNCG27.mjs.map → chunk-Y5AJLNUD.mjs.map} +0 -0
- /package/dist/esm/{chunk-ZFPA45OK.mjs.map → chunk-YR2R3LW4.mjs.map} +0 -0
- /package/dist/esm/core/{crypto/anySignature.mjs.map → account/Account.mjs.map} +0 -0
- /package/dist/esm/core/{crypto/asymmetricCrypto.mjs.map → account/Ed25519Account.mjs.map} +0 -0
|
@@ -1,19 +1,23 @@
|
|
|
1
|
-
import { PublicKey, Signature } from './asymmetricCrypto.mjs';
|
|
2
1
|
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
3
2
|
import { Serializer } from '../../bcs/serializer.mjs';
|
|
3
|
+
import { a as AccountPublicKey, V as VerifySignatureArgs, A as AuthenticationKey } from '../../publicKey-lq5djCIY.mjs';
|
|
4
4
|
import { Ed25519PublicKey, Ed25519Signature } from './ed25519.mjs';
|
|
5
|
-
import {
|
|
5
|
+
import { Signature } from './signature.mjs';
|
|
6
|
+
import '../../types/index.mjs';
|
|
6
7
|
import '../../utils/apiEndpoints.mjs';
|
|
7
8
|
import '../../types/indexer.mjs';
|
|
8
9
|
import '../../types/generated/operations.mjs';
|
|
9
10
|
import '../../types/generated/types.mjs';
|
|
10
11
|
import '../hex.mjs';
|
|
11
12
|
import '../common.mjs';
|
|
13
|
+
import '../accountAddress.mjs';
|
|
14
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
15
|
+
import './privateKey.mjs';
|
|
12
16
|
|
|
13
17
|
/**
|
|
14
18
|
* Represents the public key of a K-of-N Ed25519 multi-sig transaction.
|
|
15
19
|
*/
|
|
16
|
-
declare class MultiEd25519PublicKey extends
|
|
20
|
+
declare class MultiEd25519PublicKey extends AccountPublicKey {
|
|
17
21
|
/**
|
|
18
22
|
* Maximum number of public keys supported
|
|
19
23
|
*/
|
|
@@ -27,7 +31,7 @@ declare class MultiEd25519PublicKey extends PublicKey {
|
|
|
27
31
|
*/
|
|
28
32
|
static readonly MIN_THRESHOLD = 1;
|
|
29
33
|
/**
|
|
30
|
-
* List of Ed25519 public keys for this
|
|
34
|
+
* List of Ed25519 public keys for this LegacyMultiEd25519PublicKey
|
|
31
35
|
*/
|
|
32
36
|
readonly publicKeys: Ed25519PublicKey[];
|
|
33
37
|
/**
|
|
@@ -49,15 +53,12 @@ declare class MultiEd25519PublicKey extends PublicKey {
|
|
|
49
53
|
publicKeys: Ed25519PublicKey[];
|
|
50
54
|
threshold: number;
|
|
51
55
|
});
|
|
56
|
+
verifySignature(args: VerifySignatureArgs): boolean;
|
|
57
|
+
authKey(): AuthenticationKey;
|
|
52
58
|
/**
|
|
53
59
|
* Converts a PublicKeys into Uint8Array (bytes) with: bytes = p1_bytes | ... | pn_bytes | threshold
|
|
54
60
|
*/
|
|
55
61
|
toUint8Array(): Uint8Array;
|
|
56
|
-
toString(): string;
|
|
57
|
-
verifySignature(args: {
|
|
58
|
-
message: HexInput;
|
|
59
|
-
signature: MultiEd25519Signature;
|
|
60
|
-
}): boolean;
|
|
61
62
|
serialize(serializer: Serializer): void;
|
|
62
63
|
static deserialize(deserializer: Deserializer): MultiEd25519PublicKey;
|
|
63
64
|
}
|
|
@@ -91,17 +92,21 @@ declare class MultiEd25519Signature extends Signature {
|
|
|
91
92
|
*
|
|
92
93
|
* @param args.signatures A list of signatures
|
|
93
94
|
* @param args.bitmap 4 bytes, at most 32 signatures are supported. If Nth bit value is `1`, the Nth
|
|
94
|
-
* signature should be provided in `signatures`. Bits are read from left to right
|
|
95
|
+
* signature should be provided in `signatures`. Bits are read from left to right.
|
|
96
|
+
* Alternatively, you can specify an array of bitmap positions.
|
|
97
|
+
* Valid position should range between 0 and 31.
|
|
98
|
+
* @see MultiEd25519Signature.createBitmap
|
|
95
99
|
*/
|
|
96
100
|
constructor(args: {
|
|
97
101
|
signatures: Ed25519Signature[];
|
|
98
|
-
bitmap: Uint8Array;
|
|
102
|
+
bitmap: Uint8Array | number[];
|
|
99
103
|
});
|
|
100
104
|
/**
|
|
101
105
|
* Converts a MultiSignature into Uint8Array (bytes) with `bytes = s1_bytes | ... | sn_bytes | bitmap`
|
|
102
106
|
*/
|
|
103
107
|
toUint8Array(): Uint8Array;
|
|
104
|
-
|
|
108
|
+
serialize(serializer: Serializer): void;
|
|
109
|
+
static deserialize(deserializer: Deserializer): MultiEd25519Signature;
|
|
105
110
|
/**
|
|
106
111
|
* Helper method to create a bitmap out of the specified bit positions
|
|
107
112
|
* @param args.bits The bitmap positions that should be set. A position starts at index 0.
|
|
@@ -119,8 +124,6 @@ declare class MultiEd25519Signature extends Signature {
|
|
|
119
124
|
static createBitmap(args: {
|
|
120
125
|
bits: number[];
|
|
121
126
|
}): Uint8Array;
|
|
122
|
-
serialize(serializer: Serializer): void;
|
|
123
|
-
static deserialize(deserializer: Deserializer): MultiEd25519Signature;
|
|
124
127
|
}
|
|
125
128
|
|
|
126
129
|
export { MultiEd25519PublicKey, MultiEd25519Signature };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b}from"../../chunk-
|
|
1
|
+
import{a,b}from"../../chunk-C3HM7HQP.mjs";import"../../chunk-7BDYKJXX.mjs";import"../../chunk-WKUXBIYB.mjs";import"../../chunk-WME5D6YR.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-LMXP3JUU.mjs";import"../../chunk-F7CR75CJ.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as MultiEd25519PublicKey,b as MultiEd25519Signature};
|
|
2
2
|
//# sourceMappingURL=multiEd25519.mjs.map
|
|
@@ -1,19 +1,26 @@
|
|
|
1
|
-
import { HexInput } from '../../types/index.mjs';
|
|
2
1
|
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
3
2
|
import { Serializer } from '../../bcs/serializer.mjs';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
3
|
+
import { a as AccountPublicKey, P as PublicKey, V as VerifySignatureArgs, A as AuthenticationKey } from '../../publicKey-lq5djCIY.mjs';
|
|
4
|
+
import { Signature } from './signature.mjs';
|
|
5
|
+
import { AnyPublicKey, AnySignature } from './singleKey.mjs';
|
|
6
|
+
import '../../types/index.mjs';
|
|
7
7
|
import '../../utils/apiEndpoints.mjs';
|
|
8
8
|
import '../../types/indexer.mjs';
|
|
9
9
|
import '../../types/generated/operations.mjs';
|
|
10
10
|
import '../../types/generated/types.mjs';
|
|
11
11
|
import '../hex.mjs';
|
|
12
12
|
import '../common.mjs';
|
|
13
|
-
import '
|
|
14
|
-
import '
|
|
13
|
+
import '../accountAddress.mjs';
|
|
14
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
15
15
|
|
|
16
|
-
|
|
16
|
+
/**
|
|
17
|
+
* Represents the public key of a multi-agent account.
|
|
18
|
+
*
|
|
19
|
+
* The public keys of each individual agent can be any type of public key supported by Aptos.
|
|
20
|
+
* Since [AIP-55](https://github.com/aptos-foundation/AIPs/pull/263) Aptos supports
|
|
21
|
+
* `Legacy` and `Unified` authentication keys.
|
|
22
|
+
*/
|
|
23
|
+
declare class MultiKey extends AccountPublicKey {
|
|
17
24
|
/**
|
|
18
25
|
* List of any public keys
|
|
19
26
|
*/
|
|
@@ -23,10 +30,14 @@ declare class MultiKey extends PublicKey {
|
|
|
23
30
|
*/
|
|
24
31
|
readonly signaturesRequired: number;
|
|
25
32
|
constructor(args: {
|
|
26
|
-
publicKeys: PublicKey
|
|
33
|
+
publicKeys: Array<PublicKey>;
|
|
27
34
|
signaturesRequired: number;
|
|
28
35
|
});
|
|
36
|
+
verifySignature(args: VerifySignatureArgs): boolean;
|
|
37
|
+
authKey(): AuthenticationKey;
|
|
29
38
|
toUint8Array(): Uint8Array;
|
|
39
|
+
serialize(serializer: Serializer): void;
|
|
40
|
+
static deserialize(deserializer: Deserializer): MultiKey;
|
|
30
41
|
/**
|
|
31
42
|
* Create a bitmap that holds the mapping from the original public keys
|
|
32
43
|
* to the signatures passed in
|
|
@@ -37,18 +48,60 @@ declare class MultiKey extends PublicKey {
|
|
|
37
48
|
createBitmap(args: {
|
|
38
49
|
bits: number[];
|
|
39
50
|
}): Uint8Array;
|
|
51
|
+
}
|
|
52
|
+
declare class MultiKeySignature extends Signature {
|
|
53
|
+
/**
|
|
54
|
+
* Number of bytes in the bitmap representing who signed the transaction (32-bits)
|
|
55
|
+
*/
|
|
56
|
+
static BITMAP_LEN: number;
|
|
57
|
+
/**
|
|
58
|
+
* Maximum number of Ed25519 signatures supported
|
|
59
|
+
*/
|
|
60
|
+
static MAX_SIGNATURES_SUPPORTED: number;
|
|
61
|
+
/**
|
|
62
|
+
* The list of underlying Ed25519 signatures
|
|
63
|
+
*/
|
|
64
|
+
readonly signatures: AnySignature[];
|
|
65
|
+
/**
|
|
66
|
+
* 32-bit Bitmap representing who signed the transaction
|
|
67
|
+
*
|
|
68
|
+
* This is represented where each public key can be masked to determine whether the message was signed by that key.
|
|
69
|
+
*/
|
|
70
|
+
readonly bitmap: Uint8Array;
|
|
40
71
|
/**
|
|
41
|
-
*
|
|
72
|
+
* Signature for a K-of-N multi-sig transaction.
|
|
73
|
+
*
|
|
74
|
+
* @see {@link
|
|
75
|
+
* https://aptos.dev/integration/creating-a-signed-transaction/#multisignature-transactions | Creating a Signed Transaction}
|
|
42
76
|
*
|
|
43
|
-
* @
|
|
77
|
+
* @param args.signatures A list of signatures
|
|
78
|
+
* @param args.bitmap 4 bytes, at most 32 signatures are supported. If Nth bit value is `1`, the Nth
|
|
79
|
+
* signature should be provided in `signatures`. Bits are read from left to right
|
|
44
80
|
*/
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
81
|
+
constructor(args: {
|
|
82
|
+
signatures: Array<Signature | AnySignature>;
|
|
83
|
+
bitmap: Uint8Array | number[];
|
|
84
|
+
});
|
|
85
|
+
/**
|
|
86
|
+
* Helper method to create a bitmap out of the specified bit positions
|
|
87
|
+
* @param args.bits The bitmap positions that should be set. A position starts at index 0.
|
|
88
|
+
* Valid position should range between 0 and 31.
|
|
89
|
+
* @example
|
|
90
|
+
* Here's an example of valid `bits`
|
|
91
|
+
* ```
|
|
92
|
+
* [0, 2, 31]
|
|
93
|
+
* ```
|
|
94
|
+
* `[0, 2, 31]` means the 1st, 3rd and 32nd bits should be set in the bitmap.
|
|
95
|
+
* The result bitmap should be 0b1010000000000000000000000000001
|
|
96
|
+
*
|
|
97
|
+
* @returns bitmap that is 32bit long
|
|
98
|
+
*/
|
|
99
|
+
static createBitmap(args: {
|
|
100
|
+
bits: number[];
|
|
101
|
+
}): Uint8Array;
|
|
102
|
+
toUint8Array(): Uint8Array;
|
|
50
103
|
serialize(serializer: Serializer): void;
|
|
51
|
-
static deserialize(deserializer: Deserializer):
|
|
104
|
+
static deserialize(deserializer: Deserializer): MultiKeySignature;
|
|
52
105
|
}
|
|
53
106
|
|
|
54
|
-
export { MultiKey };
|
|
107
|
+
export { MultiKey, MultiKeySignature };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a,b}from"../../chunk-Q6WOHF4A.mjs";import"../../chunk-TX7UK75Q.mjs";import"../../chunk-QR72RXBS.mjs";import"../../chunk-7BDYKJXX.mjs";import"../../chunk-WKUXBIYB.mjs";import"../../chunk-WME5D6YR.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-LMXP3JUU.mjs";import"../../chunk-F7CR75CJ.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as MultiKey,b as MultiKeySignature};
|
|
2
2
|
//# sourceMappingURL=multiKey.mjs.map
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { HexInput } from '../../types/index.mjs';
|
|
2
|
+
import { P as PublicKey } from '../../publicKey-lq5djCIY.mjs';
|
|
3
|
+
import { Signature } from './signature.mjs';
|
|
4
|
+
import '../../utils/apiEndpoints.mjs';
|
|
5
|
+
import '../../types/indexer.mjs';
|
|
6
|
+
import '../../types/generated/operations.mjs';
|
|
7
|
+
import '../../types/generated/types.mjs';
|
|
8
|
+
import '../../bcs/serializer.mjs';
|
|
9
|
+
import '../hex.mjs';
|
|
10
|
+
import '../common.mjs';
|
|
11
|
+
import '../accountAddress.mjs';
|
|
12
|
+
import '../../bcs/deserializer.mjs';
|
|
13
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* An abstract representation of a private key.
|
|
17
|
+
* It is associated to a signature scheme and provides signing capabilities.
|
|
18
|
+
*/
|
|
19
|
+
interface PrivateKey {
|
|
20
|
+
/**
|
|
21
|
+
* Sign the given message with the private key.
|
|
22
|
+
* @param message in HexInput format
|
|
23
|
+
*/
|
|
24
|
+
sign(message: HexInput): Signature;
|
|
25
|
+
/**
|
|
26
|
+
* Derive the public key associated with the private key
|
|
27
|
+
*/
|
|
28
|
+
publicKey(): PublicKey;
|
|
29
|
+
/**
|
|
30
|
+
* Get the private key in bytes (Uint8Array).
|
|
31
|
+
*/
|
|
32
|
+
toUint8Array(): Uint8Array;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export type { PrivateKey };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import '../../types/index.mjs';
|
|
2
|
+
import '../../bcs/serializer.mjs';
|
|
3
|
+
export { a as AccountPublicKey, P as PublicKey, V as VerifySignatureArgs } from '../../publicKey-lq5djCIY.mjs';
|
|
4
|
+
import './signature.mjs';
|
|
5
|
+
import '../../utils/apiEndpoints.mjs';
|
|
6
|
+
import '../../types/indexer.mjs';
|
|
7
|
+
import '../../types/generated/operations.mjs';
|
|
8
|
+
import '../../types/generated/types.mjs';
|
|
9
|
+
import '../hex.mjs';
|
|
10
|
+
import '../common.mjs';
|
|
11
|
+
import '../accountAddress.mjs';
|
|
12
|
+
import '../../bcs/deserializer.mjs';
|
|
13
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b}from"../../chunk-WKUXBIYB.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{b as AccountPublicKey,a as PublicKey};
|
|
2
|
+
//# sourceMappingURL=publicKey.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
import { PublicKey, PrivateKey, Signature } from './asymmetricCrypto.mjs';
|
|
2
1
|
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
3
|
-
import { Serializer } from '../../bcs/serializer.mjs';
|
|
2
|
+
import { Serializer, Serializable } from '../../bcs/serializer.mjs';
|
|
4
3
|
import { HexInput } from '../../types/index.mjs';
|
|
4
|
+
import { PrivateKey } from './privateKey.mjs';
|
|
5
|
+
import { P as PublicKey, V as VerifySignatureArgs } from '../../publicKey-lq5djCIY.mjs';
|
|
6
|
+
import { Signature } from './signature.mjs';
|
|
5
7
|
import '../../utils/apiEndpoints.mjs';
|
|
6
8
|
import '../../types/indexer.mjs';
|
|
7
9
|
import '../../types/generated/operations.mjs';
|
|
8
10
|
import '../../types/generated/types.mjs';
|
|
9
11
|
import '../hex.mjs';
|
|
10
12
|
import '../common.mjs';
|
|
13
|
+
import '../accountAddress.mjs';
|
|
14
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
11
15
|
|
|
12
16
|
/**
|
|
13
17
|
* Represents the Secp256k1 ecdsa public key
|
|
@@ -23,38 +27,20 @@ declare class Secp256k1PublicKey extends PublicKey {
|
|
|
23
27
|
* @param hexInput A HexInput (string or Uint8Array)
|
|
24
28
|
*/
|
|
25
29
|
constructor(hexInput: HexInput);
|
|
26
|
-
|
|
27
|
-
* Get the public key in bytes (Uint8Array).
|
|
28
|
-
*
|
|
29
|
-
* @returns Uint8Array representation of the public key
|
|
30
|
-
*/
|
|
30
|
+
verifySignature(args: VerifySignatureArgs): boolean;
|
|
31
31
|
toUint8Array(): Uint8Array;
|
|
32
|
-
/**
|
|
33
|
-
* Get the public key as a hex string with the 0x prefix.
|
|
34
|
-
*
|
|
35
|
-
* @returns string representation of the public key
|
|
36
|
-
*/
|
|
37
|
-
toString(): string;
|
|
38
|
-
/**
|
|
39
|
-
* Verifies a signed data with a public key
|
|
40
|
-
*
|
|
41
|
-
* @param args.message message
|
|
42
|
-
* @param args.signature The signature
|
|
43
|
-
* @returns true if the signature is valid
|
|
44
|
-
*/
|
|
45
|
-
verifySignature(args: {
|
|
46
|
-
message: HexInput;
|
|
47
|
-
signature: Secp256k1Signature;
|
|
48
|
-
}): boolean;
|
|
49
32
|
serialize(serializer: Serializer): void;
|
|
50
33
|
static deserialize(deserializer: Deserializer): Secp256k1PublicKey;
|
|
51
|
-
|
|
34
|
+
/**
|
|
35
|
+
* @deprecated use `instanceof Secp256k1PublicKey` instead
|
|
36
|
+
* @param publicKey
|
|
37
|
+
*/
|
|
52
38
|
static isPublicKey(publicKey: PublicKey): publicKey is Secp256k1PublicKey;
|
|
53
39
|
}
|
|
54
40
|
/**
|
|
55
41
|
* A Secp256k1 ecdsa private key
|
|
56
42
|
*/
|
|
57
|
-
declare class Secp256k1PrivateKey extends PrivateKey {
|
|
43
|
+
declare class Secp256k1PrivateKey extends Serializable implements PrivateKey {
|
|
58
44
|
/**
|
|
59
45
|
* Length of Secp256k1 ecdsa private key
|
|
60
46
|
*/
|
|
@@ -70,39 +56,12 @@ declare class Secp256k1PrivateKey extends PrivateKey {
|
|
|
70
56
|
* @param hexInput A HexInput (string or Uint8Array)
|
|
71
57
|
*/
|
|
72
58
|
constructor(hexInput: HexInput);
|
|
73
|
-
/**
|
|
74
|
-
* Get the private key in bytes (Uint8Array).
|
|
75
|
-
*
|
|
76
|
-
* @returns
|
|
77
|
-
*/
|
|
78
|
-
toUint8Array(): Uint8Array;
|
|
79
|
-
/**
|
|
80
|
-
* Get the private key as a hex string with the 0x prefix.
|
|
81
|
-
*
|
|
82
|
-
* @returns string representation of the private key
|
|
83
|
-
*/
|
|
84
|
-
toString(): string;
|
|
85
|
-
/**
|
|
86
|
-
* Sign the given message with the private key.
|
|
87
|
-
*
|
|
88
|
-
* @param message in HexInput format
|
|
89
|
-
* @returns Signature
|
|
90
|
-
*/
|
|
91
|
-
sign(message: HexInput): Secp256k1Signature;
|
|
92
|
-
serialize(serializer: Serializer): void;
|
|
93
|
-
static deserialize(deserializer: Deserializer): Secp256k1PrivateKey;
|
|
94
59
|
/**
|
|
95
60
|
* Generate a new random private key.
|
|
96
61
|
*
|
|
97
62
|
* @returns Secp256k1PrivateKey
|
|
98
63
|
*/
|
|
99
64
|
static generate(): Secp256k1PrivateKey;
|
|
100
|
-
/**
|
|
101
|
-
* Derive the Secp256k1PublicKey from this private key.
|
|
102
|
-
*
|
|
103
|
-
* @returns Secp256k1PublicKey
|
|
104
|
-
*/
|
|
105
|
-
publicKey(): Secp256k1PublicKey;
|
|
106
65
|
/**
|
|
107
66
|
* Derives a private key from a mnemonic seed phrase.
|
|
108
67
|
*
|
|
@@ -122,10 +81,40 @@ declare class Secp256k1PrivateKey extends PrivateKey {
|
|
|
122
81
|
* @returns The generated key
|
|
123
82
|
*/
|
|
124
83
|
private static fromDerivationPathInner;
|
|
84
|
+
/**
|
|
85
|
+
* Sign the given message with the private key.
|
|
86
|
+
*
|
|
87
|
+
* @param message in HexInput format
|
|
88
|
+
* @returns Signature
|
|
89
|
+
*/
|
|
90
|
+
sign(message: HexInput): Secp256k1Signature;
|
|
91
|
+
/**
|
|
92
|
+
* Derive the Secp256k1PublicKey from this private key.
|
|
93
|
+
*
|
|
94
|
+
* @returns Secp256k1PublicKey
|
|
95
|
+
*/
|
|
96
|
+
publicKey(): Secp256k1PublicKey;
|
|
97
|
+
/**
|
|
98
|
+
* Get the private key in bytes (Uint8Array).
|
|
99
|
+
*
|
|
100
|
+
* @returns
|
|
101
|
+
*/
|
|
102
|
+
toUint8Array(): Uint8Array;
|
|
103
|
+
/**
|
|
104
|
+
* Get the private key as a hex string with the 0x prefix.
|
|
105
|
+
*
|
|
106
|
+
* @returns string representation of the private key
|
|
107
|
+
*/
|
|
108
|
+
toString(): string;
|
|
109
|
+
serialize(serializer: Serializer): void;
|
|
110
|
+
static deserialize(deserializer: Deserializer): Secp256k1PrivateKey;
|
|
111
|
+
/**
|
|
112
|
+
* @deprecated use `instanceof Secp256k1PrivateKey` instead
|
|
113
|
+
*/
|
|
125
114
|
static isPrivateKey(privateKey: PrivateKey): privateKey is Secp256k1PrivateKey;
|
|
126
115
|
}
|
|
127
116
|
/**
|
|
128
|
-
* A signature of a message signed using
|
|
117
|
+
* A signature of a message signed using a Secp256k1 ecdsa private key
|
|
129
118
|
*/
|
|
130
119
|
declare class Secp256k1Signature extends Signature {
|
|
131
120
|
/**
|
|
@@ -143,22 +132,9 @@ declare class Secp256k1Signature extends Signature {
|
|
|
143
132
|
* @param hexInput A HexInput (string or Uint8Array)
|
|
144
133
|
*/
|
|
145
134
|
constructor(hexInput: HexInput);
|
|
146
|
-
/**
|
|
147
|
-
* Get the signature in bytes (Uint8Array).
|
|
148
|
-
*
|
|
149
|
-
* @returns Uint8Array representation of the signature
|
|
150
|
-
*/
|
|
151
135
|
toUint8Array(): Uint8Array;
|
|
152
|
-
/**
|
|
153
|
-
* Get the signature as a hex string with the 0x prefix.
|
|
154
|
-
*
|
|
155
|
-
* @returns string representation of the signature
|
|
156
|
-
*/
|
|
157
|
-
toString(): string;
|
|
158
136
|
serialize(serializer: Serializer): void;
|
|
159
137
|
static deserialize(deserializer: Deserializer): Secp256k1Signature;
|
|
160
|
-
static load(deserializer: Deserializer): Secp256k1Signature;
|
|
161
|
-
static isSignature(signature: Signature): signature is Secp256k1Signature;
|
|
162
138
|
}
|
|
163
139
|
|
|
164
140
|
export { Secp256k1PrivateKey, Secp256k1PublicKey, Secp256k1Signature };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c}from"../../chunk-
|
|
1
|
+
import{a,b,c}from"../../chunk-QR72RXBS.mjs";import"../../chunk-WKUXBIYB.mjs";import"../../chunk-WME5D6YR.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{b as Secp256k1PrivateKey,a as Secp256k1PublicKey,c as Secp256k1Signature};
|
|
2
2
|
//# sourceMappingURL=secp256k1.mjs.map
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Serializable } from '../../bcs/serializer.mjs';
|
|
2
|
+
import '../hex.mjs';
|
|
3
|
+
import '../common.mjs';
|
|
4
|
+
import '../../types/index.mjs';
|
|
5
|
+
import '../../utils/apiEndpoints.mjs';
|
|
6
|
+
import '../../types/indexer.mjs';
|
|
7
|
+
import '../../types/generated/operations.mjs';
|
|
8
|
+
import '../../types/generated/types.mjs';
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* An abstract representation of a crypto signature,
|
|
12
|
+
* associated to a specific signature scheme e.g. Ed25519 or Secp256k1
|
|
13
|
+
*
|
|
14
|
+
* This is the product of signing a message directly from a PrivateKey
|
|
15
|
+
* and can be verified against a CryptoPublicKey.
|
|
16
|
+
*/
|
|
17
|
+
declare abstract class Signature extends Serializable {
|
|
18
|
+
/**
|
|
19
|
+
* Get the raw signature bytes
|
|
20
|
+
*/
|
|
21
|
+
abstract toUint8Array(): Uint8Array;
|
|
22
|
+
/**
|
|
23
|
+
* Get the signature as a hex string with a 0x prefix e.g. 0x123456...
|
|
24
|
+
*/
|
|
25
|
+
toString(): string;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export { Signature };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"../../chunk-WME5D6YR.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Signature};
|
|
2
|
+
//# sourceMappingURL=signature.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
2
|
+
import { Serializer } from '../../bcs/serializer.mjs';
|
|
3
|
+
import { AnyPublicKeyVariant } from '../../types/index.mjs';
|
|
4
|
+
import { a as AccountPublicKey, P as PublicKey, V as VerifySignatureArgs, A as AuthenticationKey } from '../../publicKey-lq5djCIY.mjs';
|
|
5
|
+
import { Signature } from './signature.mjs';
|
|
6
|
+
import '../../utils/apiEndpoints.mjs';
|
|
7
|
+
import '../../types/indexer.mjs';
|
|
8
|
+
import '../../types/generated/operations.mjs';
|
|
9
|
+
import '../../types/generated/types.mjs';
|
|
10
|
+
import '../hex.mjs';
|
|
11
|
+
import '../common.mjs';
|
|
12
|
+
import '../accountAddress.mjs';
|
|
13
|
+
import '../../transactions/instances/transactionArgument.mjs';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Represents any public key supported by Aptos.
|
|
17
|
+
*
|
|
18
|
+
* Since [AIP-55](https://github.com/aptos-foundation/AIPs/pull/263) Aptos supports
|
|
19
|
+
* `Legacy` and `Unified` authentication keys.
|
|
20
|
+
*
|
|
21
|
+
* Any unified authentication key is represented in the SDK as `AnyPublicKey`.
|
|
22
|
+
*/
|
|
23
|
+
declare class AnyPublicKey extends AccountPublicKey {
|
|
24
|
+
/**
|
|
25
|
+
* Reference to the inner public key
|
|
26
|
+
*/
|
|
27
|
+
readonly publicKey: PublicKey;
|
|
28
|
+
/**
|
|
29
|
+
* Index of the underlying enum variant
|
|
30
|
+
*/
|
|
31
|
+
readonly variant: AnyPublicKeyVariant;
|
|
32
|
+
constructor(publicKey: PublicKey);
|
|
33
|
+
verifySignature(args: VerifySignatureArgs): boolean;
|
|
34
|
+
authKey(): AuthenticationKey;
|
|
35
|
+
toUint8Array(): Uint8Array;
|
|
36
|
+
serialize(serializer: Serializer): void;
|
|
37
|
+
static deserialize(deserializer: Deserializer): AnyPublicKey;
|
|
38
|
+
/**
|
|
39
|
+
* @deprecated use `instanceof AnyPublicKey` instead.
|
|
40
|
+
*/
|
|
41
|
+
static isPublicKey(publicKey: AccountPublicKey): publicKey is AnyPublicKey;
|
|
42
|
+
/**
|
|
43
|
+
* @deprecated use `publicKey instanceof Ed25519PublicKey` instead.
|
|
44
|
+
*/
|
|
45
|
+
isEd25519(): boolean;
|
|
46
|
+
/**
|
|
47
|
+
* @deprecated use `publicKey instanceof Secp256k1PublicKey` instead.
|
|
48
|
+
*/
|
|
49
|
+
isSecp256k1PublicKey(): boolean;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Instance of signature that uses the SingleKey authentication scheme.
|
|
53
|
+
* This signature can only be generated by a `SingleKeySigner`, since it uses the
|
|
54
|
+
* same authentication scheme.
|
|
55
|
+
*/
|
|
56
|
+
declare class AnySignature extends Signature {
|
|
57
|
+
readonly signature: Signature;
|
|
58
|
+
/**
|
|
59
|
+
* Index of the underlying enum variant
|
|
60
|
+
*/
|
|
61
|
+
private readonly variant;
|
|
62
|
+
constructor(signature: Signature);
|
|
63
|
+
toUint8Array(): Uint8Array;
|
|
64
|
+
serialize(serializer: Serializer): void;
|
|
65
|
+
static deserialize(deserializer: Deserializer): AnySignature;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export { AnyPublicKey, AnySignature };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b}from"../../chunk-TX7UK75Q.mjs";import"../../chunk-QR72RXBS.mjs";import"../../chunk-7BDYKJXX.mjs";import"../../chunk-WKUXBIYB.mjs";import"../../chunk-WME5D6YR.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-PPTG6BDV.mjs";import"../../chunk-B2ZKW23W.mjs";import"../../chunk-F7MOQC7Z.mjs";import"../../chunk-VRSUCKJA.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-LMXP3JUU.mjs";import"../../chunk-F7CR75CJ.mjs";import"../../chunk-N4RBQZ2B.mjs";import"../../chunk-NL72WE3E.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-CVEJHRAU.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as AnyPublicKey,b as AnySignature};
|
|
2
|
+
//# sourceMappingURL=singleKey.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,21 +1,22 @@
|
|
|
1
|
-
export { Account } from './account.mjs';
|
|
1
|
+
export { Account, CreateAccountFromPrivateKeyArgs, CreateEd25519AccountFromPrivateKeyArgs, CreateEd25519SingleKeyAccountFromPrivateKeyArgs, CreateSingleKeyAccountFromPrivateKeyArgs, Ed25519Account, Ed25519SignerConstructorArgs, Ed25519SignerFromDerivationPathArgs, GenerateAccountArgs, GenerateEd25519AccountArgs, GenerateEd25519SingleKeyAccountArgs, GenerateSingleKeyAccountArgs, PrivateKeyFromDerivationPathArgs, SingleKeyAccount, SingleKeySignerConstructorArgs, SingleKeySignerFromDerivationPathArgs, SingleKeySignerGenerateArgs, VerifyEd25519SignatureArgs, VerifySingleKeySignatureArgs } from './account/index.mjs';
|
|
2
2
|
export { AccountAddress, AccountAddressInput, AddressInvalidReason } from './accountAddress.mjs';
|
|
3
|
-
export { AuthenticationKey } from '
|
|
3
|
+
export { a as AccountPublicKey, A as AuthenticationKey, P as PublicKey, V as VerifySignatureArgs } from '../publicKey-lq5djCIY.mjs';
|
|
4
4
|
export { ParsingError, ParsingResult } from './common.mjs';
|
|
5
|
-
export { PrivateKey, PublicKey, Signature } from './crypto/asymmetricCrypto.mjs';
|
|
6
5
|
export { Ed25519PrivateKey, Ed25519PublicKey, Ed25519Signature } from './crypto/ed25519.mjs';
|
|
6
|
+
export { APTOS_BIP44_REGEX, APTOS_HARDENED_REGEX, CKDPriv, DerivedKeys, HARDENED_OFFSET, KeyType, deriveKey, isValidBIP44Path, isValidHardenedPath, mnemonicToSeed, splitPath } from './crypto/hdKey.mjs';
|
|
7
7
|
export { MultiEd25519PublicKey, MultiEd25519Signature } from './crypto/multiEd25519.mjs';
|
|
8
|
+
export { MultiKey, MultiKeySignature } from './crypto/multiKey.mjs';
|
|
9
|
+
export { PrivateKey } from './crypto/privateKey.mjs';
|
|
8
10
|
export { Secp256k1PrivateKey, Secp256k1PublicKey, Secp256k1Signature } from './crypto/secp256k1.mjs';
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
-
export { AnyPublicKey } from './crypto/anyPublicKey.mjs';
|
|
12
|
-
export { AnySignature } from './crypto/anySignature.mjs';
|
|
11
|
+
export { Signature } from './crypto/signature.mjs';
|
|
12
|
+
export { AnyPublicKey, AnySignature } from './crypto/singleKey.mjs';
|
|
13
13
|
export { Hex, HexInvalidReason } from './hex.mjs';
|
|
14
|
+
import '../transactions/authenticator/account.mjs';
|
|
15
|
+
import '../bcs/deserializer.mjs';
|
|
14
16
|
import '../types/index.mjs';
|
|
15
17
|
import '../utils/apiEndpoints.mjs';
|
|
16
18
|
import '../types/indexer.mjs';
|
|
17
19
|
import '../types/generated/operations.mjs';
|
|
18
20
|
import '../types/generated/types.mjs';
|
|
19
21
|
import '../bcs/serializer.mjs';
|
|
20
|
-
import '../bcs/deserializer.mjs';
|
|
21
22
|
import '../transactions/instances/transactionArgument.mjs';
|
package/dist/esm/core/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../chunk-E7FWVXGX.mjs";import"../chunk-
|
|
1
|
+
import"../chunk-E7FWVXGX.mjs";import"../chunk-QE4ASJ5K.mjs";import{a as H}from"../chunk-TNVR7SNR.mjs";import{a as F}from"../chunk-WTHNSNAX.mjs";import{a as G}from"../chunk-GRJJBGHT.mjs";import"../chunk-YZZO6VDC.mjs";import"../chunk-UVSRX4SV.mjs";import{a as w,b as x}from"../chunk-C3HM7HQP.mjs";import{a as D,b as E}from"../chunk-Q6WOHF4A.mjs";import"../chunk-KUX6GQ2E.mjs";import{a as B,b as C}from"../chunk-TX7UK75Q.mjs";import{a as y,b as z,c as A}from"../chunk-QR72RXBS.mjs";import{a as t,b as u,c as v}from"../chunk-7BDYKJXX.mjs";import{a as q,b as r}from"../chunk-WKUXBIYB.mjs";import{a as s}from"../chunk-WME5D6YR.mjs";import{a as g,b as h,c as i,d as j,e as k,f as l,g as m,h as n,i as o,j as p}from"../chunk-LR65XHSF.mjs";import"../chunk-FZY4PMEE.mjs";import"../chunk-PPTG6BDV.mjs";import"../chunk-B2ZKW23W.mjs";import"../chunk-F7MOQC7Z.mjs";import"../chunk-VRSUCKJA.mjs";import"../chunk-6IFMQ5AS.mjs";import{a as f}from"../chunk-LMXP3JUU.mjs";import{a as d,b as e}from"../chunk-F7CR75CJ.mjs";import"../chunk-N4RBQZ2B.mjs";import{a as b,b as c}from"../chunk-NL72WE3E.mjs";import{a}from"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-CVEJHRAU.mjs";import"../chunk-4WPQQPUF.mjs";import"../chunk-FVA2OPG4.mjs";export{h as APTOS_BIP44_REGEX,g as APTOS_HARDENED_REGEX,H as Account,e as AccountAddress,r as AccountPublicKey,d as AddressInvalidReason,B as AnyPublicKey,C as AnySignature,f as AuthenticationKey,n as CKDPriv,F as Ed25519Account,u as Ed25519PrivateKey,t as Ed25519PublicKey,v as Ed25519Signature,j as HARDENED_OFFSET,c as Hex,b as HexInvalidReason,i as KeyType,w as MultiEd25519PublicKey,x as MultiEd25519Signature,D as MultiKey,E as MultiKeySignature,a as ParsingError,q as PublicKey,z as Secp256k1PrivateKey,y as Secp256k1PublicKey,A as Secp256k1Signature,s as Signature,G as SingleKeyAccount,m as deriveKey,k as isValidBIP44Path,l as isValidHardenedPath,p as mnemonicToSeed,o as splitPath};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|