@aptos-labs/ts-sdk 1.13.3-zeta.0 → 1.13.3
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/common/index.d.ts +1388 -1822
- package/dist/common/index.js +26 -26
- package/dist/common/index.js.map +1 -1
- package/dist/esm/{Ed25519Account-8gJF5t3F.d.mts → Ed25519Account--qjfup2u.d.mts} +12 -10
- package/dist/esm/api/account.d.mts +1 -13
- package/dist/esm/api/account.mjs +1 -1
- package/dist/esm/api/ans.d.mts +2 -2
- package/dist/esm/api/ans.mjs +1 -1
- package/dist/esm/api/aptos.d.mts +8 -14
- package/dist/esm/api/aptos.mjs +1 -1
- package/dist/esm/api/aptosConfig.d.mts +0 -20
- package/dist/esm/api/aptosConfig.mjs +1 -1
- package/dist/esm/api/coin.d.mts +7 -7
- package/dist/esm/api/coin.mjs +1 -1
- package/dist/esm/api/digitalAsset.d.mts +1 -1
- package/dist/esm/api/digitalAsset.mjs +1 -1
- package/dist/esm/api/event.mjs +1 -1
- package/dist/esm/api/faucet.mjs +1 -1
- package/dist/esm/api/fungibleAsset.d.mts +5 -5
- package/dist/esm/api/fungibleAsset.mjs +1 -1
- package/dist/esm/api/general.d.mts +7 -7
- package/dist/esm/api/general.mjs +1 -1
- package/dist/esm/api/index.d.mts +8 -13
- package/dist/esm/api/index.mjs +1 -1
- package/dist/esm/api/staking.mjs +1 -1
- package/dist/esm/api/transaction.d.mts +1 -1
- package/dist/esm/api/transaction.mjs +1 -1
- package/dist/esm/api/transactionSubmission/build.d.mts +2 -2
- package/dist/esm/api/transactionSubmission/build.mjs +1 -1
- package/dist/esm/api/transactionSubmission/management.d.mts +8 -8
- package/dist/esm/api/transactionSubmission/management.mjs +1 -1
- package/dist/esm/api/transactionSubmission/sign.d.mts +1 -1
- 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 +6 -6
- package/dist/esm/api/transactionSubmission/simulate.mjs +1 -1
- 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/entryFunctionBytes.mjs +1 -1
- package/dist/esm/bcs/serializable/fixedBytes.mjs +1 -1
- package/dist/esm/bcs/serializable/movePrimitives.mjs +1 -1
- package/dist/esm/bcs/serializable/moveStructs.mjs +1 -1
- package/dist/esm/bcs/serializer.d.mts +0 -2
- package/dist/esm/bcs/serializer.mjs +1 -1
- package/dist/esm/chunk-24IKVZBK.mjs +2 -0
- package/dist/esm/chunk-24IKVZBK.mjs.map +1 -0
- package/dist/esm/chunk-2HISPUZZ.mjs +2 -0
- package/dist/esm/chunk-2HISPUZZ.mjs.map +1 -0
- package/dist/esm/{chunk-SNQJV7MF.mjs → chunk-3WUGR46O.mjs} +2 -2
- package/dist/esm/{chunk-TVRJ3M7B.mjs → chunk-52C73T26.mjs} +2 -2
- package/dist/esm/{chunk-TVRJ3M7B.mjs.map → chunk-52C73T26.mjs.map} +1 -1
- package/dist/esm/{chunk-3LQPAGL6.mjs → chunk-5P2S2SZZ.mjs} +2 -2
- package/dist/esm/{chunk-CN37OHFT.mjs → chunk-6CFRW26C.mjs} +2 -2
- package/dist/esm/chunk-6CFRW26C.mjs.map +1 -0
- package/dist/esm/chunk-734YX27W.mjs +2 -0
- package/dist/esm/{chunk-WO2KROQ6.mjs.map → chunk-734YX27W.mjs.map} +1 -1
- package/dist/esm/{chunk-6NZNCDDW.mjs → chunk-7QJ6YJXP.mjs} +2 -2
- package/dist/esm/chunk-AD3VLZ7I.mjs +2 -0
- package/dist/esm/chunk-AD3VLZ7I.mjs.map +1 -0
- package/dist/esm/{chunk-MKUAW7KW.mjs → chunk-AU6W5OIH.mjs} +2 -2
- package/dist/esm/{chunk-3CIA6J5L.mjs → chunk-B3R6G6QP.mjs} +2 -2
- package/dist/esm/chunk-B3R6G6QP.mjs.map +1 -0
- package/dist/esm/chunk-B7TQGVGL.mjs +2 -0
- package/dist/esm/{chunk-YGHLXEB4.mjs.map → chunk-B7TQGVGL.mjs.map} +1 -1
- package/dist/esm/{chunk-MWUJCP27.mjs → chunk-BWFJHFBQ.mjs} +2 -2
- package/dist/esm/chunk-CNMQNPNV.mjs +2 -0
- package/dist/esm/chunk-CNMQNPNV.mjs.map +1 -0
- package/dist/esm/{chunk-274CXZ6R.mjs → chunk-CTIN3GTP.mjs} +2 -2
- package/dist/esm/{chunk-W637YAND.mjs → chunk-CU67XZNB.mjs} +2 -2
- package/dist/esm/chunk-CYNQRMO5.mjs +2 -0
- package/dist/esm/chunk-CYNQRMO5.mjs.map +1 -0
- package/dist/esm/{chunk-IEZO4PIG.mjs → chunk-DM44OGQH.mjs} +2 -2
- package/dist/esm/{chunk-3VGX3TXH.mjs → chunk-DMKUAQB7.mjs} +2 -2
- package/dist/esm/{chunk-QMIEBNTP.mjs → chunk-DPV25ZKR.mjs} +2 -2
- package/dist/esm/{chunk-MGOHPDX4.mjs → chunk-DSTKXJMA.mjs} +2 -2
- package/dist/esm/chunk-E7FWVXGX.mjs +1 -0
- package/dist/esm/chunk-EOFJFE4T.mjs +2 -0
- package/dist/esm/chunk-EOFJFE4T.mjs.map +1 -0
- package/dist/esm/chunk-FATWMUXK.mjs +2 -0
- package/dist/esm/chunk-FATWMUXK.mjs.map +1 -0
- package/dist/esm/{chunk-EB7AI4B4.mjs → chunk-FS3NSGBF.mjs} +2 -2
- package/dist/esm/{chunk-E36GTDEB.mjs → chunk-G2O323HP.mjs} +2 -2
- package/dist/esm/{chunk-LDMEIVL6.mjs → chunk-GSD4OOM3.mjs} +2 -2
- package/dist/esm/{chunk-R6PFLI3Z.mjs → chunk-HQ5I4Q3H.mjs} +2 -2
- package/dist/esm/chunk-HQ5I4Q3H.mjs.map +1 -0
- package/dist/esm/{chunk-QXVGXZJX.mjs → chunk-IIPYR7PF.mjs} +2 -2
- package/dist/esm/chunk-IIPYR7PF.mjs.map +1 -0
- package/dist/esm/{chunk-DKLA4F3P.mjs → chunk-IKYIJYBY.mjs} +2 -2
- package/dist/esm/chunk-IKYIJYBY.mjs.map +1 -0
- package/dist/esm/{chunk-T23OVRNF.mjs → chunk-IOSQVDZI.mjs} +2 -2
- package/dist/esm/chunk-KVZ4XMZS.mjs +2 -0
- package/dist/esm/chunk-KVZ4XMZS.mjs.map +1 -0
- package/dist/esm/chunk-LR65XHSF.mjs +2 -0
- package/dist/esm/chunk-LR65XHSF.mjs.map +1 -0
- package/dist/esm/{chunk-HFLWASAB.mjs → chunk-MACC2BLE.mjs} +2 -2
- package/dist/esm/chunk-MC6G725U.mjs +2 -0
- package/dist/esm/chunk-MC6G725U.mjs.map +1 -0
- package/dist/esm/{chunk-Q7TGZJT4.mjs → chunk-MFKMAAWA.mjs} +2 -2
- package/dist/esm/chunk-MLWIHWNH.mjs +1 -0
- package/dist/esm/chunk-NNQJBFRB.mjs +2 -0
- package/dist/esm/{chunk-7STYQ5ZE.mjs → chunk-NPFNYP75.mjs} +2 -2
- package/dist/esm/{chunk-U72H6EST.mjs → chunk-O2F53NKI.mjs} +2 -2
- package/dist/esm/{chunk-7FNHL6LU.mjs → chunk-O4JRPZZM.mjs} +2 -2
- package/dist/esm/chunk-ODRO4CSA.mjs +2 -0
- package/dist/esm/chunk-ODRO4CSA.mjs.map +1 -0
- package/dist/esm/chunk-OVJQWQ2N.mjs +2 -0
- package/dist/esm/chunk-OVJQWQ2N.mjs.map +1 -0
- package/dist/esm/chunk-OWW6SIDP.mjs +2 -0
- package/dist/esm/chunk-OWW6SIDP.mjs.map +1 -0
- package/dist/esm/{chunk-N4B6S6FK.mjs → chunk-PFIMEXNN.mjs} +2 -2
- package/dist/esm/chunk-PFIMEXNN.mjs.map +1 -0
- package/dist/esm/{chunk-Z2ZR4PTF.mjs → chunk-PZGLV5UQ.mjs} +2 -2
- package/dist/esm/{chunk-AKGASNN4.mjs → chunk-Q3TZGQVC.mjs} +2 -2
- package/dist/esm/chunk-Q3TZGQVC.mjs.map +1 -0
- package/dist/esm/{chunk-6RBUXB5I.mjs → chunk-QIAHBEEW.mjs} +2 -2
- package/dist/esm/chunk-QMURTXFM.mjs +2 -0
- package/dist/esm/{chunk-7XHVF3ZX.mjs.map → chunk-QMURTXFM.mjs.map} +1 -1
- package/dist/esm/{chunk-NC5HHEEM.mjs → chunk-QTRYMRYK.mjs} +2 -2
- package/dist/esm/{chunk-STYDBDYL.mjs → chunk-R5QUBEH6.mjs} +2 -2
- package/dist/esm/chunk-R7G3CLRI.mjs +1 -0
- package/dist/esm/{chunk-ZNEBMSNC.mjs → chunk-RHBCVCOS.mjs} +2 -2
- package/dist/esm/{chunk-7H3HRFVM.mjs → chunk-RIUZPGI5.mjs} +2 -2
- package/dist/esm/{chunk-H3LMPXEM.mjs → chunk-SG4MAOCF.mjs} +2 -2
- package/dist/esm/chunk-SUAKPNKQ.mjs +2 -0
- package/dist/esm/chunk-SUAKPNKQ.mjs.map +1 -0
- package/dist/esm/{chunk-3FVRXELT.mjs → chunk-TBMAJ6AW.mjs} +2 -2
- package/dist/esm/chunk-TLOPIURC.mjs +2 -0
- package/dist/esm/chunk-TLOPIURC.mjs.map +1 -0
- package/dist/esm/{chunk-PFFAQZHT.mjs → chunk-U43IJHQN.mjs} +2 -2
- package/dist/esm/{chunk-KNHI66FK.mjs → chunk-UFT7US42.mjs} +2 -2
- package/dist/esm/{chunk-HGZGTBA4.mjs → chunk-UML2VQZT.mjs} +2 -2
- package/dist/esm/chunk-UVSRX4SV.mjs +1 -0
- package/dist/esm/{chunk-T3W5USZC.mjs → chunk-V3Q2KXJU.mjs} +2 -2
- package/dist/esm/chunk-V4SRNEV3.mjs +2 -0
- package/dist/esm/chunk-V4SRNEV3.mjs.map +1 -0
- package/dist/esm/{chunk-3PGVEOWR.mjs → chunk-V6OS74OS.mjs} +2 -2
- package/dist/esm/chunk-VVIG4E7Q.mjs +2 -0
- package/dist/esm/{chunk-APEBWN6Q.mjs → chunk-W4ZW7QHA.mjs} +2 -2
- package/dist/esm/{chunk-COW5IGYC.mjs → chunk-WFZDFFBM.mjs} +2 -2
- package/dist/esm/{chunk-2SD6JLIU.mjs → chunk-WLF5YQM4.mjs} +2 -2
- package/dist/esm/chunk-WLF5YQM4.mjs.map +1 -0
- package/dist/esm/chunk-XDGQTMDV.mjs +2 -0
- package/dist/esm/chunk-XDGQTMDV.mjs.map +1 -0
- package/dist/esm/{chunk-TE7AJKSU.mjs → chunk-XO3HHRJV.mjs} +2 -2
- package/dist/esm/chunk-YFRXBEOC.mjs +2 -0
- package/dist/esm/chunk-YFRXBEOC.mjs.map +1 -0
- package/dist/esm/chunk-YPTF6MLX.mjs +2 -0
- package/dist/esm/chunk-YPTF6MLX.mjs.map +1 -0
- package/dist/esm/{chunk-J2IIPYZG.mjs → chunk-YU3KB3UV.mjs} +2 -2
- package/dist/esm/{chunk-KCVBUZ6L.mjs → chunk-Z5YFM2AW.mjs} +2 -2
- package/dist/esm/chunk-Z5YFM2AW.mjs.map +1 -0
- package/dist/esm/{chunk-C3L4ETUF.mjs → chunk-ZYYK3UXP.mjs} +2 -2
- package/dist/esm/{chunk-H6BRBIMG.mjs → chunk-ZZZZVONX.mjs} +2 -2
- package/dist/esm/client/core.mjs +1 -1
- package/dist/esm/client/get.d.mts +1 -2
- package/dist/esm/client/get.mjs +1 -1
- package/dist/esm/client/index.d.mts +2 -2
- package/dist/esm/client/index.mjs +1 -1
- package/dist/esm/client/post.d.mts +1 -3
- 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/index.d.mts +14 -5
- package/dist/esm/core/account/index.mjs +1 -1
- package/dist/esm/core/account/utils/address.mjs +1 -1
- package/dist/esm/core/account/utils/index.mjs +1 -1
- package/dist/esm/core/accountAddress.mjs +1 -1
- package/dist/esm/core/authenticationKey.mjs +1 -1
- package/dist/esm/core/crypto/ed25519.d.mts +10 -0
- package/dist/esm/core/crypto/ed25519.mjs +1 -1
- package/dist/esm/core/crypto/hdKey.d.mts +1 -15
- package/dist/esm/core/crypto/hdKey.mjs +1 -1
- package/dist/esm/core/crypto/index.d.mts +5 -7
- package/dist/esm/core/crypto/index.mjs +1 -1
- package/dist/esm/core/crypto/multiEd25519.mjs +1 -1
- package/dist/esm/core/crypto/multiKey.d.mts +3 -4
- package/dist/esm/core/crypto/multiKey.mjs +1 -1
- package/dist/esm/core/crypto/publicKey.mjs +1 -1
- package/dist/esm/core/crypto/secp256k1.mjs +1 -1
- package/dist/esm/core/crypto/signature.mjs +1 -1
- package/dist/esm/core/crypto/singleKey.mjs +1 -1
- package/dist/esm/core/index.d.mts +7 -6
- package/dist/esm/core/index.mjs +1 -1
- package/dist/esm/index.d.mts +9 -15
- package/dist/esm/index.mjs +1 -1
- package/dist/esm/internal/account.d.mts +1 -13
- package/dist/esm/internal/account.mjs +1 -1
- package/dist/esm/internal/ans.d.mts +1 -1
- package/dist/esm/internal/ans.mjs +1 -1
- package/dist/esm/internal/coin.d.mts +7 -7
- package/dist/esm/internal/coin.mjs +1 -1
- package/dist/esm/internal/digitalAsset.d.mts +2 -2
- package/dist/esm/internal/digitalAsset.mjs +1 -1
- package/dist/esm/internal/event.d.mts +1 -1
- 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 +5 -5
- 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 +1 -1
- package/dist/esm/internal/transactionSubmission.mjs +1 -1
- package/dist/esm/internal/view.d.mts +7 -7
- package/dist/esm/internal/view.mjs +1 -1
- package/dist/esm/transactions/authenticator/account.d.mts +4 -3
- package/dist/esm/transactions/authenticator/account.mjs +1 -1
- package/dist/esm/transactions/authenticator/index.mjs +1 -1
- package/dist/esm/transactions/authenticator/transaction.mjs +1 -1
- package/dist/esm/transactions/index.d.mts +2 -2
- package/dist/esm/transactions/index.mjs +1 -1
- package/dist/esm/transactions/instances/chainId.mjs +1 -1
- package/dist/esm/transactions/instances/identifier.mjs +1 -1
- 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/multiAgentTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/rawTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/rotationProofChallenge.mjs +1 -1
- package/dist/esm/transactions/instances/signedTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/simpleTransaction.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 +1 -13
- package/dist/esm/transactions/management/accountSequenceNumber.mjs +1 -1
- package/dist/esm/transactions/management/index.d.mts +2 -2
- package/dist/esm/transactions/management/index.mjs +1 -1
- package/dist/esm/transactions/management/transactionWorker.d.mts +1 -1
- package/dist/esm/transactions/management/transactionWorker.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/helpers.d.mts +9 -9
- package/dist/esm/transactions/transactionBuilder/helpers.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/index.d.mts +9 -9
- package/dist/esm/transactions/transactionBuilder/index.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/remoteAbi.d.mts +6 -6
- package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.d.mts +25 -13
- 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 +6 -6
- package/dist/esm/types/index.d.mts +3 -17
- package/dist/esm/types/index.mjs +1 -1
- package/dist/esm/utils/apiEndpoints.d.mts +1 -3
- package/dist/esm/utils/apiEndpoints.mjs +1 -1
- package/dist/esm/utils/const.d.mts +1 -3
- 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/utils/normalizeBundle.mjs +1 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +2 -7
- package/src/api/account.ts +1 -2
- package/src/api/ans.ts +1 -2
- package/src/api/aptos.ts +0 -6
- package/src/api/aptosConfig.ts +1 -46
- package/src/api/digitalAsset.ts +1 -2
- package/src/api/fungibleAsset.ts +1 -2
- package/src/api/transaction.ts +1 -2
- package/src/api/transactionSubmission/management.ts +1 -1
- package/src/api/transactionSubmission/sign.ts +1 -1
- package/src/bcs/serializer.ts +0 -18
- package/src/client/core.ts +0 -8
- package/src/client/get.ts +0 -6
- package/src/client/post.ts +0 -12
- package/src/{account → core/account}/Account.ts +16 -12
- package/src/{account → core/account}/Ed25519Account.ts +7 -13
- package/src/{account → core/account}/SingleKeyAccount.ts +8 -13
- package/src/core/account/index.ts +3 -1
- package/src/core/crypto/ed25519.ts +24 -4
- package/src/core/crypto/hdKey.ts +0 -31
- package/src/core/crypto/index.ts +0 -2
- package/src/core/crypto/multiKey.ts +11 -21
- package/src/core/crypto/singleKey.ts +0 -11
- package/src/core/index.ts +1 -0
- package/src/index.ts +0 -1
- package/src/internal/account.ts +1 -1
- package/src/internal/ans.ts +1 -2
- package/src/internal/digitalAsset.ts +1 -2
- package/src/internal/fungibleAsset.ts +1 -2
- package/src/internal/transactionSubmission.ts +7 -8
- package/src/transactions/authenticator/account.ts +11 -6
- package/src/transactions/management/accountSequenceNumber.ts +1 -1
- package/src/transactions/management/transactionWorker.ts +2 -8
- package/src/transactions/transactionBuilder/index.ts +0 -1
- package/src/transactions/transactionBuilder/transactionBuilder.ts +70 -41
- package/src/types/index.ts +0 -19
- package/src/utils/apiEndpoints.ts +0 -14
- package/src/utils/const.ts +0 -2
- package/src/version.ts +1 -1
- package/dist/esm/account/Account.d.mts +0 -34
- package/dist/esm/account/Account.mjs +0 -2
- package/dist/esm/account/Ed25519Account.d.mts +0 -34
- package/dist/esm/account/Ed25519Account.mjs +0 -2
- package/dist/esm/account/EphemeralKeyPair.d.mts +0 -46
- package/dist/esm/account/EphemeralKeyPair.mjs +0 -2
- package/dist/esm/account/KeylessAccount.d.mts +0 -87
- package/dist/esm/account/KeylessAccount.mjs +0 -2
- package/dist/esm/account/MultiKeyAccount.d.mts +0 -99
- package/dist/esm/account/MultiKeyAccount.mjs +0 -2
- package/dist/esm/account/SingleKeyAccount.d.mts +0 -34
- package/dist/esm/account/SingleKeyAccount.mjs +0 -2
- package/dist/esm/account/index.d.mts +0 -39
- package/dist/esm/account/index.mjs +0 -2
- package/dist/esm/api/keyless.d.mts +0 -65
- package/dist/esm/api/keyless.mjs +0 -2
- package/dist/esm/api/keyless.mjs.map +0 -1
- package/dist/esm/chunk-2M7KHFEG.mjs +0 -2
- package/dist/esm/chunk-2M7KHFEG.mjs.map +0 -1
- package/dist/esm/chunk-2SD6JLIU.mjs.map +0 -1
- package/dist/esm/chunk-2YDIOWRJ.mjs +0 -2
- package/dist/esm/chunk-2YDIOWRJ.mjs.map +0 -1
- package/dist/esm/chunk-3CIA6J5L.mjs.map +0 -1
- package/dist/esm/chunk-5VSMDXZ6.mjs +0 -2
- package/dist/esm/chunk-5VSMDXZ6.mjs.map +0 -1
- package/dist/esm/chunk-6GQAHQGW.mjs +0 -2
- package/dist/esm/chunk-6GQAHQGW.mjs.map +0 -1
- package/dist/esm/chunk-6NMHAFIO.mjs +0 -2
- package/dist/esm/chunk-6NMHAFIO.mjs.map +0 -1
- package/dist/esm/chunk-7MPJPZ73.mjs +0 -2
- package/dist/esm/chunk-7MPJPZ73.mjs.map +0 -1
- package/dist/esm/chunk-7XHVF3ZX.mjs +0 -2
- package/dist/esm/chunk-7Z6DYLCA.mjs +0 -1
- package/dist/esm/chunk-7Z6DYLCA.mjs.map +0 -1
- package/dist/esm/chunk-AKGASNN4.mjs.map +0 -1
- package/dist/esm/chunk-AQ4I7VVB.mjs +0 -1
- package/dist/esm/chunk-AQ4I7VVB.mjs.map +0 -1
- package/dist/esm/chunk-CN37OHFT.mjs.map +0 -1
- package/dist/esm/chunk-CQJ4WN7M.mjs +0 -2
- package/dist/esm/chunk-CQJ4WN7M.mjs.map +0 -1
- package/dist/esm/chunk-DKLA4F3P.mjs.map +0 -1
- package/dist/esm/chunk-E4Z5IEZP.mjs +0 -2
- package/dist/esm/chunk-E4Z5IEZP.mjs.map +0 -1
- package/dist/esm/chunk-EQKI6NJR.mjs +0 -2
- package/dist/esm/chunk-EQKI6NJR.mjs.map +0 -1
- package/dist/esm/chunk-F6QCHPVS.mjs +0 -2
- package/dist/esm/chunk-F6QCHPVS.mjs.map +0 -1
- package/dist/esm/chunk-FLYEALDB.mjs +0 -2
- package/dist/esm/chunk-FLYEALDB.mjs.map +0 -1
- package/dist/esm/chunk-HQWIGPYQ.mjs +0 -2
- package/dist/esm/chunk-HQWIGPYQ.mjs.map +0 -1
- package/dist/esm/chunk-HURQZGUZ.mjs +0 -2
- package/dist/esm/chunk-HURQZGUZ.mjs.map +0 -1
- package/dist/esm/chunk-JEUAQVXW.mjs +0 -2
- package/dist/esm/chunk-JEUAQVXW.mjs.map +0 -1
- package/dist/esm/chunk-JOYJUVSE.mjs +0 -2
- package/dist/esm/chunk-JOYJUVSE.mjs.map +0 -1
- package/dist/esm/chunk-JXCZTOYC.mjs +0 -1
- package/dist/esm/chunk-JXCZTOYC.mjs.map +0 -1
- package/dist/esm/chunk-KCVBUZ6L.mjs.map +0 -1
- package/dist/esm/chunk-LX7N4NUS.mjs +0 -2
- package/dist/esm/chunk-LX7N4NUS.mjs.map +0 -1
- package/dist/esm/chunk-N4B6S6FK.mjs.map +0 -1
- package/dist/esm/chunk-NMVZP3Q2.mjs +0 -2
- package/dist/esm/chunk-NMVZP3Q2.mjs.map +0 -1
- package/dist/esm/chunk-NNA5VEB2.mjs +0 -2
- package/dist/esm/chunk-NNA5VEB2.mjs.map +0 -1
- package/dist/esm/chunk-OKRUEVF3.mjs +0 -2
- package/dist/esm/chunk-OKRUEVF3.mjs.map +0 -1
- package/dist/esm/chunk-PLPCOELE.mjs +0 -2
- package/dist/esm/chunk-PLPCOELE.mjs.map +0 -1
- package/dist/esm/chunk-QHIQLTBS.mjs +0 -2
- package/dist/esm/chunk-QHIQLTBS.mjs.map +0 -1
- package/dist/esm/chunk-QXVGXZJX.mjs.map +0 -1
- package/dist/esm/chunk-R6PFLI3Z.mjs.map +0 -1
- package/dist/esm/chunk-RFSO3JRG.mjs +0 -1
- package/dist/esm/chunk-RFSO3JRG.mjs.map +0 -1
- package/dist/esm/chunk-RPXN7HGR.mjs +0 -2
- package/dist/esm/chunk-RPXN7HGR.mjs.map +0 -1
- package/dist/esm/chunk-S5HG2QUD.mjs +0 -2
- package/dist/esm/chunk-S5HG2QUD.mjs.map +0 -1
- package/dist/esm/chunk-SRLCFTZR.mjs +0 -2
- package/dist/esm/chunk-SRLCFTZR.mjs.map +0 -1
- package/dist/esm/chunk-TBG3MIIE.mjs +0 -2
- package/dist/esm/chunk-TBG3MIIE.mjs.map +0 -1
- package/dist/esm/chunk-TJPWYYNO.mjs +0 -2
- package/dist/esm/chunk-TJPWYYNO.mjs.map +0 -1
- package/dist/esm/chunk-W76IQV5K.mjs +0 -2
- package/dist/esm/chunk-W76IQV5K.mjs.map +0 -1
- package/dist/esm/chunk-WO2KROQ6.mjs +0 -2
- package/dist/esm/chunk-X56CTMYB.mjs +0 -2
- package/dist/esm/chunk-XEXWFQNP.mjs +0 -2
- package/dist/esm/chunk-YE5B2S5L.mjs +0 -2
- package/dist/esm/chunk-YE5B2S5L.mjs.map +0 -1
- package/dist/esm/chunk-YGHLXEB4.mjs +0 -2
- package/dist/esm/core/crypto/ephemeral.d.mts +0 -77
- package/dist/esm/core/crypto/ephemeral.mjs +0 -2
- package/dist/esm/core/crypto/ephemeral.mjs.map +0 -1
- package/dist/esm/core/crypto/keyless.d.mts +0 -217
- package/dist/esm/core/crypto/keyless.mjs +0 -2
- package/dist/esm/core/crypto/keyless.mjs.map +0 -1
- package/dist/esm/core/crypto/poseidon.d.mts +0 -7
- package/dist/esm/core/crypto/poseidon.mjs +0 -2
- package/dist/esm/core/crypto/poseidon.mjs.map +0 -1
- package/dist/esm/internal/keyless.d.mts +0 -65
- package/dist/esm/internal/keyless.mjs +0 -2
- package/dist/esm/internal/keyless.mjs.map +0 -1
- package/dist/esm/transactions/transactionBuilder/signingMessage.d.mts +0 -47
- package/dist/esm/transactions/transactionBuilder/signingMessage.mjs +0 -2
- package/dist/esm/transactions/transactionBuilder/signingMessage.mjs.map +0 -1
- package/dist/esm/types/keyless.d.mts +0 -14
- package/dist/esm/types/keyless.mjs +0 -1
- package/dist/esm/types/keyless.mjs.map +0 -1
- package/src/account/EphemeralKeyPair.ts +0 -115
- package/src/account/KeylessAccount.ts +0 -240
- package/src/account/MultiKeyAccount.ts +0 -119
- package/src/account/index.ts +0 -6
- package/src/api/keyless.ts +0 -34
- package/src/core/crypto/ephemeral.ts +0 -149
- package/src/core/crypto/keyless.ts +0 -508
- package/src/core/crypto/poseidon.ts +0 -134
- package/src/internal/keyless.ts +0 -185
- package/src/transactions/transactionBuilder/signingMessage.ts +0 -70
- package/src/types/keyless.ts +0 -6
- /package/dist/esm/{chunk-SNQJV7MF.mjs.map → chunk-3WUGR46O.mjs.map} +0 -0
- /package/dist/esm/{chunk-3LQPAGL6.mjs.map → chunk-5P2S2SZZ.mjs.map} +0 -0
- /package/dist/esm/{chunk-6NZNCDDW.mjs.map → chunk-7QJ6YJXP.mjs.map} +0 -0
- /package/dist/esm/{chunk-MKUAW7KW.mjs.map → chunk-AU6W5OIH.mjs.map} +0 -0
- /package/dist/esm/{chunk-MWUJCP27.mjs.map → chunk-BWFJHFBQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-274CXZ6R.mjs.map → chunk-CTIN3GTP.mjs.map} +0 -0
- /package/dist/esm/{chunk-W637YAND.mjs.map → chunk-CU67XZNB.mjs.map} +0 -0
- /package/dist/esm/{chunk-IEZO4PIG.mjs.map → chunk-DM44OGQH.mjs.map} +0 -0
- /package/dist/esm/{chunk-3VGX3TXH.mjs.map → chunk-DMKUAQB7.mjs.map} +0 -0
- /package/dist/esm/{chunk-QMIEBNTP.mjs.map → chunk-DPV25ZKR.mjs.map} +0 -0
- /package/dist/esm/{chunk-MGOHPDX4.mjs.map → chunk-DSTKXJMA.mjs.map} +0 -0
- /package/dist/esm/{account/Account.mjs.map → chunk-E7FWVXGX.mjs.map} +0 -0
- /package/dist/esm/{chunk-EB7AI4B4.mjs.map → chunk-FS3NSGBF.mjs.map} +0 -0
- /package/dist/esm/{chunk-E36GTDEB.mjs.map → chunk-G2O323HP.mjs.map} +0 -0
- /package/dist/esm/{chunk-LDMEIVL6.mjs.map → chunk-GSD4OOM3.mjs.map} +0 -0
- /package/dist/esm/{chunk-T23OVRNF.mjs.map → chunk-IOSQVDZI.mjs.map} +0 -0
- /package/dist/esm/{chunk-HFLWASAB.mjs.map → chunk-MACC2BLE.mjs.map} +0 -0
- /package/dist/esm/{chunk-Q7TGZJT4.mjs.map → chunk-MFKMAAWA.mjs.map} +0 -0
- /package/dist/esm/{account/Ed25519Account.mjs.map → chunk-MLWIHWNH.mjs.map} +0 -0
- /package/dist/esm/{chunk-XEXWFQNP.mjs.map → chunk-NNQJBFRB.mjs.map} +0 -0
- /package/dist/esm/{chunk-7STYQ5ZE.mjs.map → chunk-NPFNYP75.mjs.map} +0 -0
- /package/dist/esm/{chunk-U72H6EST.mjs.map → chunk-O2F53NKI.mjs.map} +0 -0
- /package/dist/esm/{chunk-7FNHL6LU.mjs.map → chunk-O4JRPZZM.mjs.map} +0 -0
- /package/dist/esm/{chunk-Z2ZR4PTF.mjs.map → chunk-PZGLV5UQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-6RBUXB5I.mjs.map → chunk-QIAHBEEW.mjs.map} +0 -0
- /package/dist/esm/{chunk-NC5HHEEM.mjs.map → chunk-QTRYMRYK.mjs.map} +0 -0
- /package/dist/esm/{chunk-STYDBDYL.mjs.map → chunk-R5QUBEH6.mjs.map} +0 -0
- /package/dist/esm/{account/EphemeralKeyPair.mjs.map → chunk-R7G3CLRI.mjs.map} +0 -0
- /package/dist/esm/{chunk-ZNEBMSNC.mjs.map → chunk-RHBCVCOS.mjs.map} +0 -0
- /package/dist/esm/{chunk-7H3HRFVM.mjs.map → chunk-RIUZPGI5.mjs.map} +0 -0
- /package/dist/esm/{chunk-H3LMPXEM.mjs.map → chunk-SG4MAOCF.mjs.map} +0 -0
- /package/dist/esm/{chunk-3FVRXELT.mjs.map → chunk-TBMAJ6AW.mjs.map} +0 -0
- /package/dist/esm/{chunk-PFFAQZHT.mjs.map → chunk-U43IJHQN.mjs.map} +0 -0
- /package/dist/esm/{chunk-KNHI66FK.mjs.map → chunk-UFT7US42.mjs.map} +0 -0
- /package/dist/esm/{chunk-HGZGTBA4.mjs.map → chunk-UML2VQZT.mjs.map} +0 -0
- /package/dist/esm/{account/KeylessAccount.mjs.map → chunk-UVSRX4SV.mjs.map} +0 -0
- /package/dist/esm/{chunk-T3W5USZC.mjs.map → chunk-V3Q2KXJU.mjs.map} +0 -0
- /package/dist/esm/{chunk-3PGVEOWR.mjs.map → chunk-V6OS74OS.mjs.map} +0 -0
- /package/dist/esm/{chunk-X56CTMYB.mjs.map → chunk-VVIG4E7Q.mjs.map} +0 -0
- /package/dist/esm/{chunk-APEBWN6Q.mjs.map → chunk-W4ZW7QHA.mjs.map} +0 -0
- /package/dist/esm/{chunk-COW5IGYC.mjs.map → chunk-WFZDFFBM.mjs.map} +0 -0
- /package/dist/esm/{chunk-TE7AJKSU.mjs.map → chunk-XO3HHRJV.mjs.map} +0 -0
- /package/dist/esm/{chunk-J2IIPYZG.mjs.map → chunk-YU3KB3UV.mjs.map} +0 -0
- /package/dist/esm/{chunk-C3L4ETUF.mjs.map → chunk-ZYYK3UXP.mjs.map} +0 -0
- /package/dist/esm/{chunk-H6BRBIMG.mjs.map → chunk-ZZZZVONX.mjs.map} +0 -0
- /package/dist/esm/{account/MultiKeyAccount.mjs.map → core/account/Account.mjs.map} +0 -0
- /package/dist/esm/{account/SingleKeyAccount.mjs.map → core/account/Ed25519Account.mjs.map} +0 -0
- /package/dist/esm/{account/index.mjs.map → core/account/SingleKeyAccount.mjs.map} +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/utils/const.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * Type of API endpoint for request routing\n */\nexport enum AptosApiType {\n FULLNODE = \"Fullnode\",\n INDEXER = \"Indexer\",\n FAUCET = \"Faucet\",\n PEPPER = \"Pepper\",\n PROVER = \"Prover\",\n}\n\n/**\n * The default max gas amount when none is given.\n *\n * This is the maximum number of gas units that will be used by a transaction before being rejected.\n *\n * Note that max gas amount varies based on the transaction. A larger transaction will go over this\n * default gas amount, and the value will need to be changed for the specific transaction.\n */\nexport const DEFAULT_MAX_GAS_AMOUNT = 200000;\n\n/**\n * The default transaction expiration seconds from now.\n *\n * This time is how long until the blockchain nodes will reject the transaction.\n *\n * Note that the transaction expiration time varies based on network connection and network load. It may need to be\n * increased for the transaction to be processed.\n */\nexport const DEFAULT_TXN_EXP_SEC_FROM_NOW = 20;\n\n/**\n * The default number of seconds to wait for a transaction to be processed.\n *\n * This time is the amount of time that the SDK will wait for a transaction to be processed when waiting for\n * the results of the transaction. It may take longer based on network connection and network load.\n */\nexport const DEFAULT_TXN_TIMEOUT_SEC = 20;\n\n/**\n * The default gas currency for the network.\n */\nexport const APTOS_COIN = \"0x1::aptos_coin::AptosCoin\";\n\nexport const RAW_TRANSACTION_SALT = \"APTOS::RawTransaction\";\nexport const RAW_TRANSACTION_WITH_DATA_SALT = \"APTOS::RawTransactionWithData\";\n\n/**\n * The list of supported Processor types for our indexer api.\n *\n * These can be found from the processor_status table in the indexer database.\n * {@link https://cloud.hasura.io/public/graphiql?endpoint=https://api.mainnet.aptoslabs.com/v1/graphql}\n */\nexport enum ProcessorType {\n ACCOUNT_TRANSACTION_PROCESSOR = \"account_transactions_processor\",\n DEFAULT = \"default_processor\",\n EVENTS_PROCESSOR = \"events_processor\",\n // Fungible asset processor also handles coins\n FUNGIBLE_ASSET_PROCESSOR = \"fungible_asset_processor\",\n STAKE_PROCESSOR = \"stake_processor\",\n // Token V2 processor replaces Token processor (not only for digital assets)\n TOKEN_V2_PROCESSOR = \"token_v2_processor\",\n USER_TRANSACTION_PROCESSOR = \"user_transaction_processor\",\n}\n"],"mappings":"AAMO,IAAKA,OACVA,EAAA,SAAW,WACXA,EAAA,QAAU,UACVA,EAAA,OAAS,SACTA,EAAA,OAAS,SACTA,EAAA,OAAS,SALCA,OAAA,IAgBCC,EAAyB,IAUzBC,EAA+B,GAQ/BC,EAA0B,GAK1BC,EAAa,6BAEbC,EAAuB,wBACvBC,EAAiC,gCAQlCC,OACVA,EAAA,8BAAgC,iCAChCA,EAAA,QAAU,oBACVA,EAAA,iBAAmB,mBAEnBA,EAAA,yBAA2B,2BAC3BA,EAAA,gBAAkB,kBAElBA,EAAA,mBAAqB,qBACrBA,EAAA,2BAA6B,6BATnBA,OAAA","names":["AptosApiType","DEFAULT_MAX_GAS_AMOUNT","DEFAULT_TXN_EXP_SEC_FROM_NOW","DEFAULT_TXN_TIMEOUT_SEC","APTOS_COIN","RAW_TRANSACTION_SALT","RAW_TRANSACTION_WITH_DATA_SALT","ProcessorType"]}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
2
|
-
import { Serializer } from '../../bcs/serializer.mjs';
|
|
3
|
-
import { EphemeralPublicKeyVariant, HexInput } from '../../types/index.mjs';
|
|
4
|
-
import { P as PublicKey } from '../../publicKey-lq5djCIY.mjs';
|
|
5
|
-
import { Signature } from './signature.mjs';
|
|
6
|
-
import { Ed25519PublicKey } from './ed25519.mjs';
|
|
7
|
-
import '../../utils/apiEndpoints.mjs';
|
|
8
|
-
import '../../types/indexer.mjs';
|
|
9
|
-
import '../../types/generated/operations.mjs';
|
|
10
|
-
import '../../types/generated/types.mjs';
|
|
11
|
-
import '../hex.mjs';
|
|
12
|
-
import '../common.mjs';
|
|
13
|
-
import '../accountAddress.mjs';
|
|
14
|
-
import '../../transactions/instances/transactionArgument.mjs';
|
|
15
|
-
import './privateKey.mjs';
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* Represents ephemeral keys and signatures for Aptos Keyless accounts.
|
|
19
|
-
*
|
|
20
|
-
* TODO
|
|
21
|
-
*/
|
|
22
|
-
declare class EphemeralPublicKey extends PublicKey {
|
|
23
|
-
/**
|
|
24
|
-
* Reference to the inner public key
|
|
25
|
-
*/
|
|
26
|
-
readonly publicKey: PublicKey;
|
|
27
|
-
readonly variant: EphemeralPublicKeyVariant;
|
|
28
|
-
constructor(publicKey: PublicKey);
|
|
29
|
-
/**
|
|
30
|
-
* Get the public key in bytes (Uint8Array).
|
|
31
|
-
*
|
|
32
|
-
* @returns Uint8Array representation of the public key
|
|
33
|
-
*/
|
|
34
|
-
toUint8Array(): Uint8Array;
|
|
35
|
-
/**
|
|
36
|
-
* Get the public key as a hex string with the 0x prefix.
|
|
37
|
-
*
|
|
38
|
-
* @returns string representation of the public key
|
|
39
|
-
*/
|
|
40
|
-
toString(): string;
|
|
41
|
-
/**
|
|
42
|
-
* Verifies a signed data with a public key
|
|
43
|
-
*
|
|
44
|
-
* @param args.message message
|
|
45
|
-
* @param args.signature The signature
|
|
46
|
-
* @returns true if the signature is valid
|
|
47
|
-
*/
|
|
48
|
-
verifySignature(args: {
|
|
49
|
-
message: HexInput;
|
|
50
|
-
signature: EphemeralSignature;
|
|
51
|
-
}): boolean;
|
|
52
|
-
serialize(serializer: Serializer): void;
|
|
53
|
-
static deserialize(deserializer: Deserializer): EphemeralPublicKey;
|
|
54
|
-
static isPublicKey(publicKey: PublicKey): publicKey is EphemeralPublicKey;
|
|
55
|
-
isEd25519(): this is Ed25519PublicKey;
|
|
56
|
-
}
|
|
57
|
-
declare class EphemeralSignature extends Signature {
|
|
58
|
-
readonly signature: Signature;
|
|
59
|
-
constructor(signature: Signature);
|
|
60
|
-
/**
|
|
61
|
-
* Get the public key in bytes (Uint8Array).
|
|
62
|
-
*
|
|
63
|
-
* @returns Uint8Array representation of the public key
|
|
64
|
-
*/
|
|
65
|
-
toUint8Array(): Uint8Array;
|
|
66
|
-
/**
|
|
67
|
-
* Get the public key as a hex string with the 0x prefix.
|
|
68
|
-
*
|
|
69
|
-
* @returns string representation of the public key
|
|
70
|
-
*/
|
|
71
|
-
toString(): string;
|
|
72
|
-
static fromHex(hexInput: HexInput): EphemeralSignature;
|
|
73
|
-
serialize(serializer: Serializer): void;
|
|
74
|
-
static deserialize(deserializer: Deserializer): EphemeralSignature;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
export { EphemeralPublicKey, EphemeralSignature };
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b}from"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as EphemeralPublicKey,b as EphemeralSignature};
|
|
2
|
-
//# sourceMappingURL=ephemeral.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,217 +0,0 @@
|
|
|
1
|
-
import { a as AccountPublicKey, A as AuthenticationKey, P as PublicKey } from '../../publicKey-lq5djCIY.mjs';
|
|
2
|
-
import { Signature } from './signature.mjs';
|
|
3
|
-
import { Deserializer } from '../../bcs/deserializer.mjs';
|
|
4
|
-
import { Serializer, Serializable } from '../../bcs/serializer.mjs';
|
|
5
|
-
import { HexInput } from '../../types/index.mjs';
|
|
6
|
-
import { EphemeralSignature, EphemeralPublicKey } from './ephemeral.mjs';
|
|
7
|
-
import '../accountAddress.mjs';
|
|
8
|
-
import '../common.mjs';
|
|
9
|
-
import '../../transactions/instances/transactionArgument.mjs';
|
|
10
|
-
import '../hex.mjs';
|
|
11
|
-
import '../../utils/apiEndpoints.mjs';
|
|
12
|
-
import '../../types/indexer.mjs';
|
|
13
|
-
import '../../types/generated/operations.mjs';
|
|
14
|
-
import '../../types/generated/types.mjs';
|
|
15
|
-
import './ed25519.mjs';
|
|
16
|
-
import './privateKey.mjs';
|
|
17
|
-
|
|
18
|
-
declare const EPK_HORIZON_SECS = 10000000;
|
|
19
|
-
declare const MAX_AUD_VAL_BYTES = 120;
|
|
20
|
-
declare const MAX_UID_KEY_BYTES = 30;
|
|
21
|
-
declare const MAX_UID_VAL_BYTES = 330;
|
|
22
|
-
declare const MAX_ISS_VAL_BYTES = 120;
|
|
23
|
-
declare const MAX_EXTRA_FIELD_BYTES = 350;
|
|
24
|
-
declare const MAX_JWT_HEADER_B64_BYTES = 300;
|
|
25
|
-
declare const MAX_COMMITED_EPK_BYTES = 93;
|
|
26
|
-
/**
|
|
27
|
-
* Represents the KeylessPublicKey public key
|
|
28
|
-
*
|
|
29
|
-
* KeylessPublicKey authentication key is represented in the SDK as `AnyPublicKey`.
|
|
30
|
-
*/
|
|
31
|
-
declare class KeylessPublicKey extends AccountPublicKey {
|
|
32
|
-
static readonly ADDRESS_SEED_LENGTH: number;
|
|
33
|
-
readonly iss: string;
|
|
34
|
-
readonly addressSeed: Uint8Array;
|
|
35
|
-
constructor(iss: string, addressSeed: HexInput);
|
|
36
|
-
authKey(): AuthenticationKey;
|
|
37
|
-
/**
|
|
38
|
-
* Get the public key in bytes (Uint8Array).
|
|
39
|
-
*
|
|
40
|
-
* @returns Uint8Array representation of the public key
|
|
41
|
-
*/
|
|
42
|
-
toUint8Array(): Uint8Array;
|
|
43
|
-
/**
|
|
44
|
-
* Get the public key as a hex string with the 0x prefix.
|
|
45
|
-
*
|
|
46
|
-
* @returns string representation of the public key
|
|
47
|
-
*/
|
|
48
|
-
toString(): string;
|
|
49
|
-
/**
|
|
50
|
-
* Verifies a signed data with a public key
|
|
51
|
-
*
|
|
52
|
-
* @param args.message message
|
|
53
|
-
* @param args.signature The signature
|
|
54
|
-
* @returns true if the signature is valid
|
|
55
|
-
*/
|
|
56
|
-
verifySignature(args: {
|
|
57
|
-
message: HexInput;
|
|
58
|
-
signature: KeylessSignature;
|
|
59
|
-
}): boolean;
|
|
60
|
-
serialize(serializer: Serializer): void;
|
|
61
|
-
static deserialize(deserializer: Deserializer): KeylessPublicKey;
|
|
62
|
-
static load(deserializer: Deserializer): KeylessPublicKey;
|
|
63
|
-
static isPublicKey(publicKey: PublicKey): publicKey is KeylessPublicKey;
|
|
64
|
-
static create(args: {
|
|
65
|
-
iss: string;
|
|
66
|
-
uidKey: string;
|
|
67
|
-
uidVal: string;
|
|
68
|
-
aud: string;
|
|
69
|
-
pepper: HexInput;
|
|
70
|
-
}): KeylessPublicKey;
|
|
71
|
-
}
|
|
72
|
-
declare function computeAddressSeed(args: {
|
|
73
|
-
uidKey: string;
|
|
74
|
-
uidVal: string;
|
|
75
|
-
aud: string;
|
|
76
|
-
pepper: HexInput;
|
|
77
|
-
}): Uint8Array;
|
|
78
|
-
declare class OpenIdSignatureOrZkProof extends Signature {
|
|
79
|
-
readonly signature: Signature;
|
|
80
|
-
constructor(signature: Signature);
|
|
81
|
-
/**
|
|
82
|
-
* Get the public key in bytes (Uint8Array).
|
|
83
|
-
*
|
|
84
|
-
* @returns Uint8Array representation of the public key
|
|
85
|
-
*/
|
|
86
|
-
toUint8Array(): Uint8Array;
|
|
87
|
-
/**
|
|
88
|
-
* Get the public key as a hex string with the 0x prefix.
|
|
89
|
-
*
|
|
90
|
-
* @returns string representation of the public key
|
|
91
|
-
*/
|
|
92
|
-
toString(): string;
|
|
93
|
-
serialize(serializer: Serializer): void;
|
|
94
|
-
static deserialize(deserializer: Deserializer): OpenIdSignatureOrZkProof;
|
|
95
|
-
}
|
|
96
|
-
declare class Groth16Zkp extends Serializable {
|
|
97
|
-
a: Uint8Array;
|
|
98
|
-
b: Uint8Array;
|
|
99
|
-
c: Uint8Array;
|
|
100
|
-
constructor(args: {
|
|
101
|
-
a: HexInput;
|
|
102
|
-
b: HexInput;
|
|
103
|
-
c: HexInput;
|
|
104
|
-
});
|
|
105
|
-
toUint8Array(): Uint8Array;
|
|
106
|
-
serialize(serializer: Serializer): void;
|
|
107
|
-
static deserialize(deserializer: Deserializer): Groth16Zkp;
|
|
108
|
-
}
|
|
109
|
-
declare class SignedGroth16Signature extends Signature {
|
|
110
|
-
readonly proof: Groth16Zkp;
|
|
111
|
-
readonly expHorizonSecs: bigint;
|
|
112
|
-
readonly extraField?: string;
|
|
113
|
-
readonly overrideAudVal?: string;
|
|
114
|
-
readonly trainingWheelsSignature?: EphemeralSignature;
|
|
115
|
-
constructor(args: {
|
|
116
|
-
proof: Groth16Zkp;
|
|
117
|
-
expHorizonSecs?: bigint;
|
|
118
|
-
extraField?: string;
|
|
119
|
-
overrideAudVal?: string;
|
|
120
|
-
trainingWheelsSignature?: EphemeralSignature;
|
|
121
|
-
});
|
|
122
|
-
/**
|
|
123
|
-
* Get the signature in bytes (Uint8Array).
|
|
124
|
-
*
|
|
125
|
-
* @returns Uint8Array representation of the signature
|
|
126
|
-
*/
|
|
127
|
-
toUint8Array(): Uint8Array;
|
|
128
|
-
/**
|
|
129
|
-
* Get the signature as a hex string with the 0x prefix.
|
|
130
|
-
*
|
|
131
|
-
* @returns string representation of the signature
|
|
132
|
-
*/
|
|
133
|
-
toString(): string;
|
|
134
|
-
serialize(serializer: Serializer): void;
|
|
135
|
-
static deserialize(deserializer: Deserializer): SignedGroth16Signature;
|
|
136
|
-
static load(deserializer: Deserializer): SignedGroth16Signature;
|
|
137
|
-
}
|
|
138
|
-
/**
|
|
139
|
-
* A OpenId signature which contains the private inputs to an OIDB proof.
|
|
140
|
-
*/
|
|
141
|
-
declare class OpenIdSignature extends Signature {
|
|
142
|
-
readonly jwtSignature: string;
|
|
143
|
-
readonly jwtPayloadJson: string;
|
|
144
|
-
readonly uidKey: string;
|
|
145
|
-
readonly epkBlinder: Uint8Array;
|
|
146
|
-
readonly pepper: Uint8Array;
|
|
147
|
-
readonly overrideAudValue?: string;
|
|
148
|
-
/**
|
|
149
|
-
* Create a new Signature instance from a Uint8Array or String.
|
|
150
|
-
*
|
|
151
|
-
* @param hexInput A HexInput (string or Uint8Array)
|
|
152
|
-
*/
|
|
153
|
-
constructor(args: {
|
|
154
|
-
jwtSignature: string;
|
|
155
|
-
jwtPayloadJson: string;
|
|
156
|
-
uidKey?: string;
|
|
157
|
-
epkBlinder: Uint8Array;
|
|
158
|
-
pepper: Uint8Array;
|
|
159
|
-
overrideAudValue?: string;
|
|
160
|
-
});
|
|
161
|
-
/**
|
|
162
|
-
* Get the signature in bytes (Uint8Array).
|
|
163
|
-
*
|
|
164
|
-
* @returns Uint8Array representation of the signature
|
|
165
|
-
*/
|
|
166
|
-
toUint8Array(): Uint8Array;
|
|
167
|
-
/**
|
|
168
|
-
* Get the signature as a hex string with the 0x prefix.
|
|
169
|
-
*
|
|
170
|
-
* @returns string representation of the signature
|
|
171
|
-
*/
|
|
172
|
-
toString(): string;
|
|
173
|
-
serialize(serializer: Serializer): void;
|
|
174
|
-
static deserialize(deserializer: Deserializer): OpenIdSignature;
|
|
175
|
-
static load(deserializer: Deserializer): OpenIdSignature;
|
|
176
|
-
static isSignature(signature: Signature): signature is OpenIdSignature;
|
|
177
|
-
}
|
|
178
|
-
/**
|
|
179
|
-
* A signature of a message signed via OIDC that uses proofs or the jwt token to authenticate.
|
|
180
|
-
*/
|
|
181
|
-
declare class KeylessSignature extends Signature {
|
|
182
|
-
readonly openIdSignatureOrZkProof: OpenIdSignatureOrZkProof;
|
|
183
|
-
readonly jwtHeader: string;
|
|
184
|
-
readonly expiryDateSecs: bigint | number;
|
|
185
|
-
readonly ephemeralPublicKey: EphemeralPublicKey;
|
|
186
|
-
readonly ephemeralSignature: EphemeralSignature;
|
|
187
|
-
/**
|
|
188
|
-
* Create a new Signature instance from a Uint8Array or String.
|
|
189
|
-
*
|
|
190
|
-
* @param hexInput A HexInput (string or Uint8Array)
|
|
191
|
-
*/
|
|
192
|
-
constructor(args: {
|
|
193
|
-
jwtHeader: string;
|
|
194
|
-
openIdSignatureOrZkProof: OpenIdSignatureOrZkProof;
|
|
195
|
-
expiryDateSecs: bigint | number;
|
|
196
|
-
ephemeralPublicKey: EphemeralPublicKey;
|
|
197
|
-
ephemeralSignature: EphemeralSignature;
|
|
198
|
-
});
|
|
199
|
-
/**
|
|
200
|
-
* Get the signature in bytes (Uint8Array).
|
|
201
|
-
*
|
|
202
|
-
* @returns Uint8Array representation of the signature
|
|
203
|
-
*/
|
|
204
|
-
toUint8Array(): Uint8Array;
|
|
205
|
-
/**
|
|
206
|
-
* Get the signature as a hex string with the 0x prefix.
|
|
207
|
-
*
|
|
208
|
-
* @returns string representation of the signature
|
|
209
|
-
*/
|
|
210
|
-
toString(): string;
|
|
211
|
-
serialize(serializer: Serializer): void;
|
|
212
|
-
static deserialize(deserializer: Deserializer): KeylessSignature;
|
|
213
|
-
static load(deserializer: Deserializer): KeylessSignature;
|
|
214
|
-
static isSignature(signature: Signature): signature is KeylessSignature;
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
export { EPK_HORIZON_SECS, Groth16Zkp, KeylessPublicKey, KeylessSignature, MAX_AUD_VAL_BYTES, MAX_COMMITED_EPK_BYTES, MAX_EXTRA_FIELD_BYTES, MAX_ISS_VAL_BYTES, MAX_JWT_HEADER_B64_BYTES, MAX_UID_KEY_BYTES, MAX_UID_VAL_BYTES, OpenIdSignature, OpenIdSignatureOrZkProof, SignedGroth16Signature, computeAddressSeed };
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b,c,d,e,f,g,h,i,j,k,l,m,n,o}from"../../chunk-6NMHAFIO.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as EPK_HORIZON_SECS,l as Groth16Zkp,i as KeylessPublicKey,o as KeylessSignature,b as MAX_AUD_VAL_BYTES,h as MAX_COMMITED_EPK_BYTES,f as MAX_EXTRA_FIELD_BYTES,e as MAX_ISS_VAL_BYTES,g as MAX_JWT_HEADER_B64_BYTES,c as MAX_UID_KEY_BYTES,d as MAX_UID_VAL_BYTES,n as OpenIdSignature,k as OpenIdSignatureOrZkProof,m as SignedGroth16Signature,j as computeAddressSeed};
|
|
2
|
-
//# sourceMappingURL=keyless.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
declare function hashASCIIStrToField(str: string, maxSizeBytes: number): bigint;
|
|
2
|
-
declare function padAndPackBytesWithLen(bytes: Uint8Array, maxSizeBytes: number): bigint[];
|
|
3
|
-
declare function bytesToBigIntLE(bytes: Uint8Array): bigint;
|
|
4
|
-
declare function bigIntToBytesLE(value: bigint, length: number): Uint8Array;
|
|
5
|
-
declare function poseidonHash(inputs: (number | bigint | string)[]): bigint;
|
|
6
|
-
|
|
7
|
-
export { bigIntToBytesLE, bytesToBigIntLE, hashASCIIStrToField, padAndPackBytesWithLen, poseidonHash };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import { AptosConfig } from '../api/aptosConfig.mjs';
|
|
2
|
-
import { HexInput } from '../types/index.mjs';
|
|
3
|
-
import { SignedGroth16Signature } from '../core/crypto/keyless.mjs';
|
|
4
|
-
import { KeylessAccount } from '../account/KeylessAccount.mjs';
|
|
5
|
-
import { EphemeralKeyPair } from '../account/EphemeralKeyPair.mjs';
|
|
6
|
-
import '../utils/apiEndpoints.mjs';
|
|
7
|
-
import '../utils/const.mjs';
|
|
8
|
-
import '../types/indexer.mjs';
|
|
9
|
-
import '../types/generated/operations.mjs';
|
|
10
|
-
import '../types/generated/types.mjs';
|
|
11
|
-
import '../publicKey-lq5djCIY.mjs';
|
|
12
|
-
import '../bcs/serializer.mjs';
|
|
13
|
-
import '../core/hex.mjs';
|
|
14
|
-
import '../core/common.mjs';
|
|
15
|
-
import '../core/accountAddress.mjs';
|
|
16
|
-
import '../bcs/deserializer.mjs';
|
|
17
|
-
import '../transactions/instances/transactionArgument.mjs';
|
|
18
|
-
import '../core/crypto/signature.mjs';
|
|
19
|
-
import '../core/crypto/ephemeral.mjs';
|
|
20
|
-
import '../core/crypto/ed25519.mjs';
|
|
21
|
-
import '../core/crypto/privateKey.mjs';
|
|
22
|
-
import '../Ed25519Account-8gJF5t3F.mjs';
|
|
23
|
-
import '../transactions/authenticator/account.mjs';
|
|
24
|
-
import '../core/crypto/multiEd25519.mjs';
|
|
25
|
-
import '../core/crypto/multiKey.mjs';
|
|
26
|
-
import '../core/crypto/singleKey.mjs';
|
|
27
|
-
import '../transactions/types.mjs';
|
|
28
|
-
import '../bcs/serializable/moveStructs.mjs';
|
|
29
|
-
import '../bcs/serializable/movePrimitives.mjs';
|
|
30
|
-
import '../bcs/serializable/fixedBytes.mjs';
|
|
31
|
-
import '../transactions/instances/rawTransaction.mjs';
|
|
32
|
-
import '../transactions/instances/chainId.mjs';
|
|
33
|
-
import '../transactions/instances/transactionPayload.mjs';
|
|
34
|
-
import '../transactions/instances/identifier.mjs';
|
|
35
|
-
import '../transactions/instances/moduleId.mjs';
|
|
36
|
-
import '../transactions/typeTag/index.mjs';
|
|
37
|
-
import '../transactions/instances/simpleTransaction.mjs';
|
|
38
|
-
import '../transactions/instances/multiAgentTransaction.mjs';
|
|
39
|
-
|
|
40
|
-
declare function getPepper(args: {
|
|
41
|
-
aptosConfig: AptosConfig;
|
|
42
|
-
jwt: string;
|
|
43
|
-
ephemeralKeyPair: EphemeralKeyPair;
|
|
44
|
-
uidKey?: string;
|
|
45
|
-
derivationPath?: string;
|
|
46
|
-
verify?: boolean;
|
|
47
|
-
}): Promise<Uint8Array>;
|
|
48
|
-
declare function getProof(args: {
|
|
49
|
-
aptosConfig: AptosConfig;
|
|
50
|
-
jwt: string;
|
|
51
|
-
ephemeralKeyPair: EphemeralKeyPair;
|
|
52
|
-
pepper: HexInput;
|
|
53
|
-
uidKey?: string;
|
|
54
|
-
extraFieldKey?: string;
|
|
55
|
-
}): Promise<SignedGroth16Signature>;
|
|
56
|
-
declare function deriveKeylessAccount(args: {
|
|
57
|
-
aptosConfig: AptosConfig;
|
|
58
|
-
jwt: string;
|
|
59
|
-
ephemeralKeyPair: EphemeralKeyPair;
|
|
60
|
-
uidKey?: string;
|
|
61
|
-
pepper?: HexInput;
|
|
62
|
-
extraFieldKey?: string;
|
|
63
|
-
}): Promise<KeylessAccount>;
|
|
64
|
-
|
|
65
|
-
export { deriveKeylessAccount, getPepper, getProof };
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b,c}from"../chunk-NNA5VEB2.mjs";import"../chunk-7Z6DYLCA.mjs";import"../chunk-N2FKVZ4D.mjs";import"../chunk-NMVZP3Q2.mjs";import"../chunk-7XHVF3ZX.mjs";import"../chunk-WO2KROQ6.mjs";import"../chunk-GED6IT3S.mjs";import"../chunk-ROXFCLDT.mjs";import"../chunk-6FBKUTGF.mjs";import"../chunk-5VSMDXZ6.mjs";import"../chunk-YGHLXEB4.mjs";import"../chunk-DKLA4F3P.mjs";import"../chunk-LX7N4NUS.mjs";import"../chunk-HQWIGPYQ.mjs";import"../chunk-2M7KHFEG.mjs";import"../chunk-W76IQV5K.mjs";import"../chunk-TJPWYYNO.mjs";import"../chunk-2YDIOWRJ.mjs";import"../chunk-4NMDYPUD.mjs";import"../chunk-W637YAND.mjs";import"../chunk-NC5HHEEM.mjs";import"../chunk-X56CTMYB.mjs";import"../chunk-E36GTDEB.mjs";import"../chunk-E4Z5IEZP.mjs";import"../chunk-MKUAW7KW.mjs";import"../chunk-Z2ZR4PTF.mjs";import"../chunk-IEZO4PIG.mjs";import"../chunk-3VGX3TXH.mjs";import"../chunk-ZNEBMSNC.mjs";import"../chunk-UYVPNUH3.mjs";import"../chunk-MWUJCP27.mjs";import"../chunk-MGOHPDX4.mjs";import"../chunk-RFSO3JRG.mjs";import"../chunk-YE5B2S5L.mjs";import"../chunk-AQ4I7VVB.mjs";import"../chunk-TE7AJKSU.mjs";import"../chunk-F6QCHPVS.mjs";import"../chunk-KUX6GQ2E.mjs";import"../chunk-HURQZGUZ.mjs";import"../chunk-7FNHL6LU.mjs";import"../chunk-6NMHAFIO.mjs";import"../chunk-FLYEALDB.mjs";import"../chunk-7MPJPZ73.mjs";import"../chunk-CQJ4WN7M.mjs";import"../chunk-TJDC5PWD.mjs";import"../chunk-COW5IGYC.mjs";import"../chunk-STYDBDYL.mjs";import"../chunk-S5HG2QUD.mjs";import"../chunk-7STYQ5ZE.mjs";import"../chunk-T23OVRNF.mjs";import"../chunk-FZY4PMEE.mjs";import"../chunk-C3L4ETUF.mjs";import"../chunk-3FVRXELT.mjs";import"../chunk-EB7AI4B4.mjs";import"../chunk-6RBUXB5I.mjs";import"../chunk-6IFMQ5AS.mjs";import"../chunk-OKRUEVF3.mjs";import"../chunk-4WPQQPUF.mjs";import"../chunk-TVRJ3M7B.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{c as deriveKeylessAccount,a as getPepper,b as getProof};
|
|
2
|
-
//# sourceMappingURL=keyless.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { AnyRawTransaction, AnyRawTransactionInstance } from '../types.mjs';
|
|
2
|
-
import { Serializable } from '../../bcs/serializer.mjs';
|
|
3
|
-
import '../../api/aptosConfig.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
|
-
import '../../utils/const.mjs';
|
|
10
|
-
import '../../bcs/serializable/moveStructs.mjs';
|
|
11
|
-
import '../../bcs/serializable/movePrimitives.mjs';
|
|
12
|
-
import '../../bcs/deserializer.mjs';
|
|
13
|
-
import '../instances/transactionArgument.mjs';
|
|
14
|
-
import '../../core/hex.mjs';
|
|
15
|
-
import '../../core/common.mjs';
|
|
16
|
-
import '../../bcs/serializable/fixedBytes.mjs';
|
|
17
|
-
import '../../core/accountAddress.mjs';
|
|
18
|
-
import '../../publicKey-lq5djCIY.mjs';
|
|
19
|
-
import '../../core/crypto/signature.mjs';
|
|
20
|
-
import '../instances/rawTransaction.mjs';
|
|
21
|
-
import '../instances/chainId.mjs';
|
|
22
|
-
import '../instances/transactionPayload.mjs';
|
|
23
|
-
import '../instances/identifier.mjs';
|
|
24
|
-
import '../instances/moduleId.mjs';
|
|
25
|
-
import '../typeTag/index.mjs';
|
|
26
|
-
import '../authenticator/account.mjs';
|
|
27
|
-
import '../../core/crypto/ed25519.mjs';
|
|
28
|
-
import '../../core/crypto/privateKey.mjs';
|
|
29
|
-
import '../../core/crypto/multiEd25519.mjs';
|
|
30
|
-
import '../../core/crypto/multiKey.mjs';
|
|
31
|
-
import '../../core/crypto/singleKey.mjs';
|
|
32
|
-
import '../instances/simpleTransaction.mjs';
|
|
33
|
-
import '../instances/multiAgentTransaction.mjs';
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
* Derive the raw transaction type - FeePayerRawTransaction or MultiAgentRawTransaction or RawTransaction
|
|
37
|
-
*
|
|
38
|
-
* @param transaction A aptos transaction type
|
|
39
|
-
*
|
|
40
|
-
* @returns FeePayerRawTransaction | MultiAgentRawTransaction | RawTransaction
|
|
41
|
-
*/
|
|
42
|
-
declare function deriveTransactionType(transaction: AnyRawTransaction): AnyRawTransactionInstance;
|
|
43
|
-
declare function generateSigningMessage(bytes: Uint8Array, domainSeparator: string): Uint8Array;
|
|
44
|
-
declare function generateSigningMessageForSerializable(obj: Serializable): Uint8Array;
|
|
45
|
-
declare function generateSigningMessageForTransaction(transaction: AnyRawTransaction): Uint8Array;
|
|
46
|
-
|
|
47
|
-
export { deriveTransactionType, generateSigningMessage, generateSigningMessageForSerializable, generateSigningMessageForTransaction };
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a,b,c,d}from"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-X56CTMYB.mjs";import"../../chunk-E36GTDEB.mjs";import"../../chunk-E4Z5IEZP.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-TE7AJKSU.mjs";import"../../chunk-F6QCHPVS.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-HURQZGUZ.mjs";import"../../chunk-7FNHL6LU.mjs";import"../../chunk-6NMHAFIO.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as deriveTransactionType,b as generateSigningMessage,c as generateSigningMessageForSerializable,d as generateSigningMessageForTransaction};
|
|
2
|
-
//# sourceMappingURL=signingMessage.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
type ProverResponse = {
|
|
2
|
-
proof: {
|
|
3
|
-
a: string;
|
|
4
|
-
b: string;
|
|
5
|
-
c: string;
|
|
6
|
-
};
|
|
7
|
-
public_inputs_hash: string;
|
|
8
|
-
training_wheels_signature: string;
|
|
9
|
-
};
|
|
10
|
-
type PepperFetchResponse = {
|
|
11
|
-
signature: string;
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export type { PepperFetchResponse, ProverResponse };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=keyless.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
// Copyright © Aptos Foundation
|
|
2
|
-
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
-
|
|
4
|
-
import { randomBytes } from "@noble/hashes/utils";
|
|
5
|
-
|
|
6
|
-
import {
|
|
7
|
-
EPK_HORIZON_SECS,
|
|
8
|
-
Ed25519PrivateKey,
|
|
9
|
-
EphemeralPublicKey,
|
|
10
|
-
EphemeralSignature,
|
|
11
|
-
PrivateKey,
|
|
12
|
-
} from "../core/crypto";
|
|
13
|
-
import { Hex } from "../core/hex";
|
|
14
|
-
import { bytesToBigIntLE, padAndPackBytesWithLen, poseidonHash } from "../core/crypto/poseidon";
|
|
15
|
-
import { EphemeralPublicKeyVariant, HexInput, SigningSchemeInput } from "../types";
|
|
16
|
-
import { Deserializer, Serializable, Serializer } from "../bcs";
|
|
17
|
-
|
|
18
|
-
export class EphemeralKeyPair extends Serializable {
|
|
19
|
-
readonly blinder: Uint8Array;
|
|
20
|
-
|
|
21
|
-
readonly expiryDateSecs: bigint | number;
|
|
22
|
-
|
|
23
|
-
readonly nonce: string;
|
|
24
|
-
|
|
25
|
-
private privateKey: PrivateKey;
|
|
26
|
-
|
|
27
|
-
private publicKey: EphemeralPublicKey;
|
|
28
|
-
|
|
29
|
-
constructor(args: { privateKey: PrivateKey; expiryDateSecs?: bigint | number; blinder?: HexInput }) {
|
|
30
|
-
super();
|
|
31
|
-
const { privateKey, expiryDateSecs, blinder } = args;
|
|
32
|
-
this.privateKey = privateKey;
|
|
33
|
-
this.publicKey = new EphemeralPublicKey(privateKey.publicKey());
|
|
34
|
-
this.expiryDateSecs = expiryDateSecs || BigInt(floorToWholeHour(currentTimeInSeconds() + EPK_HORIZON_SECS));
|
|
35
|
-
this.blinder = blinder !== undefined ? Hex.fromHexInput(blinder).toUint8Array() : generateBlinder();
|
|
36
|
-
this.nonce = this.generateNonce();
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
getPublicKey(): EphemeralPublicKey {
|
|
40
|
-
return this.publicKey;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
serialize(serializer: Serializer): void {
|
|
44
|
-
serializer.serializeU32AsUleb128(this.publicKey.variant);
|
|
45
|
-
serializer.serializeBytes(this.privateKey.toUint8Array());
|
|
46
|
-
serializer.serializeU64(this.expiryDateSecs);
|
|
47
|
-
serializer.serializeFixedBytes(this.blinder);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
static deserialize(deserializer: Deserializer): EphemeralKeyPair {
|
|
51
|
-
const variantIndex = deserializer.deserializeUleb128AsU32();
|
|
52
|
-
let privateKey: PrivateKey;
|
|
53
|
-
switch (variantIndex) {
|
|
54
|
-
case EphemeralPublicKeyVariant.Ed25519:
|
|
55
|
-
privateKey = Ed25519PrivateKey.deserialize(deserializer);
|
|
56
|
-
break;
|
|
57
|
-
default:
|
|
58
|
-
throw new Error(`Unknown variant index for EphemeralPublicKey: ${variantIndex}`);
|
|
59
|
-
}
|
|
60
|
-
const expiryDateSecs = deserializer.deserializeU64();
|
|
61
|
-
const blinder = deserializer.deserializeFixedBytes(31);
|
|
62
|
-
return new EphemeralKeyPair({ privateKey, expiryDateSecs, blinder });
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
static fromBytes(bytes: Uint8Array): EphemeralKeyPair {
|
|
66
|
-
return EphemeralKeyPair.deserialize(new Deserializer(bytes));
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
static generate(args?: { scheme: SigningSchemeInput }): EphemeralKeyPair {
|
|
70
|
-
let privateKey: PrivateKey;
|
|
71
|
-
|
|
72
|
-
switch (args?.scheme) {
|
|
73
|
-
case SigningSchemeInput.Ed25519:
|
|
74
|
-
default:
|
|
75
|
-
privateKey = Ed25519PrivateKey.generate();
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
return new EphemeralKeyPair({ privateKey });
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
generateNonce(): string {
|
|
82
|
-
const fields = padAndPackBytesWithLen(this.publicKey.bcsToBytes(), 93);
|
|
83
|
-
fields.push(BigInt(this.expiryDateSecs));
|
|
84
|
-
fields.push(bytesToBigIntLE(this.blinder));
|
|
85
|
-
const nonceHash = poseidonHash(fields);
|
|
86
|
-
return nonceHash.toString();
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
/**
|
|
90
|
-
* Sign the given message with the private key.
|
|
91
|
-
* *
|
|
92
|
-
* @param data in HexInput format
|
|
93
|
-
* @returns EphemeralSignature
|
|
94
|
-
*/
|
|
95
|
-
sign(data: HexInput): EphemeralSignature {
|
|
96
|
-
return new EphemeralSignature(this.privateKey.sign(data));
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
function generateBlinder(): Uint8Array {
|
|
101
|
-
return randomBytes(31);
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
function currentTimeInSeconds(): number {
|
|
105
|
-
return Math.floor(new Date().getTime() / 1000);
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
function floorToWholeHour(timestampInSeconds: number): number {
|
|
109
|
-
const date = new Date(timestampInSeconds * 1000);
|
|
110
|
-
// Reset minutes and seconds to zero
|
|
111
|
-
date.setMinutes(0);
|
|
112
|
-
date.setSeconds(0);
|
|
113
|
-
date.setMilliseconds(0);
|
|
114
|
-
return Math.floor(date.getTime() / 1000);
|
|
115
|
-
}
|