quantumcoin 6.14.4 → 7.0.1
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/.github/workflows/publish-npmjs.yaml +22 -0
- package/.gitignore +12 -0
- package/{LICENSE.md → LICENSE} +1 -1
- package/README-SDK.md +700 -0
- package/README.md +84 -89
- package/config.d.ts +50 -0
- package/config.js +115 -0
- package/examples/events.js +35 -0
- package/examples/example.js +61 -0
- package/examples/package-lock.json +1150 -0
- package/examples/package.json +17 -0
- package/examples/read-operations.js +28 -0
- package/examples/wallet-offline.js +29 -0
- package/generate-sdk.js +888 -0
- package/index.js +12 -0
- package/package.json +44 -120
- package/src/abi/fragments.d.ts +42 -0
- package/src/abi/fragments.js +63 -0
- package/src/abi/index.d.ts +13 -0
- package/src/abi/index.js +9 -0
- package/src/abi/interface.d.ts +114 -0
- package/src/abi/interface.js +352 -0
- package/src/constants.d.ts +61 -0
- package/src/constants.js +94 -0
- package/src/contract/contract-factory.d.ts +28 -0
- package/src/contract/contract-factory.js +93 -0
- package/src/contract/contract.d.ts +105 -0
- package/src/contract/contract.js +312 -0
- package/src/contract/index.d.ts +9 -0
- package/src/contract/index.js +9 -0
- package/src/errors/index.d.ts +92 -0
- package/src/errors/index.js +188 -0
- package/src/generator/index.js +426 -0
- package/src/index.d.ts +111 -0
- package/src/index.js +41 -0
- package/src/internal/hex.d.ts +61 -0
- package/src/internal/hex.js +144 -0
- package/src/providers/extra-providers.d.ts +128 -0
- package/src/providers/extra-providers.js +575 -0
- package/src/providers/index.d.ts +16 -0
- package/src/providers/index.js +10 -0
- package/src/providers/json-rpc-provider.d.ts +12 -0
- package/src/providers/json-rpc-provider.js +79 -0
- package/src/providers/provider.d.ts +194 -0
- package/src/providers/provider.js +359 -0
- package/src/utils/address.d.ts +72 -0
- package/src/utils/address.js +182 -0
- package/src/utils/encoding.d.ts +120 -0
- package/src/utils/encoding.js +306 -0
- package/src/utils/hashing.d.ts +76 -0
- package/src/utils/hashing.js +298 -0
- package/src/utils/index.d.ts +55 -0
- package/src/utils/index.js +13 -0
- package/src/utils/result.d.ts +57 -0
- package/src/utils/result.js +128 -0
- package/src/utils/rlp.d.ts +12 -0
- package/src/utils/rlp.js +200 -0
- package/src/utils/units.d.ts +29 -0
- package/src/utils/units.js +107 -0
- package/src/wallet/index.d.ts +10 -0
- package/src/wallet/index.js +8 -0
- package/src/wallet/wallet.d.ts +160 -0
- package/src/wallet/wallet.js +489 -0
- package/test/e2e/helpers.js +47 -0
- package/test/e2e/transactional.test.js +191 -0
- package/test/e2e/typed-generator.e2e.test.js +402 -0
- package/test/fixtures/ConstructorParam.sol +23 -0
- package/test/fixtures/MultiContracts.sol +37 -0
- package/test/fixtures/SimpleStorage.sol +18 -0
- package/test/fixtures/StakingContract.abi.json +1 -0
- package/test/integration/ipc-provider.test.js +44 -0
- package/test/integration/provider.test.js +72 -0
- package/test/integration/ws-provider.test.js +33 -0
- package/test/security/malformed-input.test.js +31 -0
- package/test/unit/abi-interface.test.js +98 -0
- package/test/unit/address-wallet.test.js +257 -0
- package/test/unit/browser-provider.test.js +82 -0
- package/test/unit/contract.test.js +82 -0
- package/test/unit/encoding-units-rlp.test.js +89 -0
- package/test/unit/errors.test.js +74 -0
- package/test/unit/filter-by-blockhash.test.js +52 -0
- package/test/unit/generate-contract-cli.test.js +38 -0
- package/test/unit/generate-sdk-artifacts-json.test.js +65 -0
- package/test/unit/generator.test.js +98 -0
- package/test/unit/hashing.test.js +54 -0
- package/test/unit/init.test.js +36 -0
- package/test/unit/interface.test.js +53 -0
- package/test/unit/internal-hex.test.js +47 -0
- package/test/unit/providers.test.js +144 -0
- package/test/unit/result.test.js +77 -0
- package/test/unit/utils.test.js +54 -0
- package/CHANGELOG.md +0 -442
- package/FUNDING.json +0 -10
- package/SECURITY.md +0 -34
- package/dist/README.md +0 -22
- package/lib.commonjs/README.md +0 -16
- package/lib.commonjs/_version.d.ts +0 -5
- package/lib.commonjs/_version.d.ts.map +0 -1
- package/lib.commonjs/_version.js +0 -9
- package/lib.commonjs/_version.js.map +0 -1
- package/lib.commonjs/abi/abi-coder.d.ts +0 -61
- package/lib.commonjs/abi/abi-coder.d.ts.map +0 -1
- package/lib.commonjs/abi/abi-coder.js +0 -210
- package/lib.commonjs/abi/abi-coder.js.map +0 -1
- package/lib.commonjs/abi/bytes32.d.ts +0 -15
- package/lib.commonjs/abi/bytes32.d.ts.map +0 -1
- package/lib.commonjs/abi/bytes32.js +0 -45
- package/lib.commonjs/abi/bytes32.js.map +0 -1
- package/lib.commonjs/abi/coders/abstract-coder.d.ts +0 -124
- package/lib.commonjs/abi/coders/abstract-coder.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/abstract-coder.js +0 -472
- package/lib.commonjs/abi/coders/abstract-coder.js.map +0 -1
- package/lib.commonjs/abi/coders/address.d.ts +0 -13
- package/lib.commonjs/abi/coders/address.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/address.js +0 -33
- package/lib.commonjs/abi/coders/address.js.map +0 -1
- package/lib.commonjs/abi/coders/anonymous.d.ts +0 -15
- package/lib.commonjs/abi/coders/anonymous.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/anonymous.js +0 -27
- package/lib.commonjs/abi/coders/anonymous.js.map +0 -1
- package/lib.commonjs/abi/coders/array.d.ts +0 -25
- package/lib.commonjs/abi/coders/array.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/array.js +0 -165
- package/lib.commonjs/abi/coders/array.js.map +0 -1
- package/lib.commonjs/abi/coders/boolean.d.ts +0 -13
- package/lib.commonjs/abi/coders/boolean.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/boolean.js +0 -25
- package/lib.commonjs/abi/coders/boolean.js.map +0 -1
- package/lib.commonjs/abi/coders/bytes.d.ts +0 -19
- package/lib.commonjs/abi/coders/bytes.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/bytes.js +0 -39
- package/lib.commonjs/abi/coders/bytes.js.map +0 -1
- package/lib.commonjs/abi/coders/fixed-bytes.d.ts +0 -15
- package/lib.commonjs/abi/coders/fixed-bytes.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/fixed-bytes.js +0 -32
- package/lib.commonjs/abi/coders/fixed-bytes.js.map +0 -1
- package/lib.commonjs/abi/coders/null.d.ts +0 -12
- package/lib.commonjs/abi/coders/null.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/null.js +0 -28
- package/lib.commonjs/abi/coders/null.js.map +0 -1
- package/lib.commonjs/abi/coders/number.d.ts +0 -16
- package/lib.commonjs/abi/coders/number.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/number.js +0 -49
- package/lib.commonjs/abi/coders/number.js.map +0 -1
- package/lib.commonjs/abi/coders/string.d.ts +0 -13
- package/lib.commonjs/abi/coders/string.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/string.js +0 -25
- package/lib.commonjs/abi/coders/string.js.map +0 -1
- package/lib.commonjs/abi/coders/tuple.d.ts +0 -16
- package/lib.commonjs/abi/coders/tuple.d.ts.map +0 -1
- package/lib.commonjs/abi/coders/tuple.js +0 -67
- package/lib.commonjs/abi/coders/tuple.js.map +0 -1
- package/lib.commonjs/abi/fragments.d.ts +0 -466
- package/lib.commonjs/abi/fragments.d.ts.map +0 -1
- package/lib.commonjs/abi/fragments.js +0 -1331
- package/lib.commonjs/abi/fragments.js.map +0 -1
- package/lib.commonjs/abi/index.d.ts +0 -18
- package/lib.commonjs/abi/index.d.ts.map +0 -1
- package/lib.commonjs/abi/index.js +0 -40
- package/lib.commonjs/abi/index.js.map +0 -1
- package/lib.commonjs/abi/interface.d.ts +0 -382
- package/lib.commonjs/abi/interface.d.ts.map +0 -1
- package/lib.commonjs/abi/interface.js +0 -1110
- package/lib.commonjs/abi/interface.js.map +0 -1
- package/lib.commonjs/abi/typed.d.ts +0 -570
- package/lib.commonjs/abi/typed.d.ts.map +0 -1
- package/lib.commonjs/abi/typed.js +0 -606
- package/lib.commonjs/abi/typed.js.map +0 -1
- package/lib.commonjs/address/address.d.ts +0 -36
- package/lib.commonjs/address/address.d.ts.map +0 -1
- package/lib.commonjs/address/address.js +0 -133
- package/lib.commonjs/address/address.js.map +0 -1
- package/lib.commonjs/address/checks.d.ts +0 -81
- package/lib.commonjs/address/checks.d.ts.map +0 -1
- package/lib.commonjs/address/checks.js +0 -120
- package/lib.commonjs/address/checks.js.map +0 -1
- package/lib.commonjs/address/contract-address.d.ts +0 -48
- package/lib.commonjs/address/contract-address.d.ts.map +0 -1
- package/lib.commonjs/address/contract-address.js +0 -74
- package/lib.commonjs/address/contract-address.js.map +0 -1
- package/lib.commonjs/address/index.d.ts +0 -49
- package/lib.commonjs/address/index.d.ts.map +0 -1
- package/lib.commonjs/address/index.js +0 -28
- package/lib.commonjs/address/index.js.map +0 -1
- package/lib.commonjs/constants/addresses.d.ts +0 -7
- package/lib.commonjs/constants/addresses.d.ts.map +0 -1
- package/lib.commonjs/constants/addresses.js +0 -10
- package/lib.commonjs/constants/addresses.js.map +0 -1
- package/lib.commonjs/constants/hashes.d.ts +0 -7
- package/lib.commonjs/constants/hashes.d.ts.map +0 -1
- package/lib.commonjs/constants/hashes.js +0 -10
- package/lib.commonjs/constants/hashes.js.map +0 -1
- package/lib.commonjs/constants/index.d.ts +0 -10
- package/lib.commonjs/constants/index.d.ts.map +0 -1
- package/lib.commonjs/constants/index.js +0 -22
- package/lib.commonjs/constants/index.js.map +0 -1
- package/lib.commonjs/constants/numbers.d.ts +0 -31
- package/lib.commonjs/constants/numbers.d.ts.map +0 -1
- package/lib.commonjs/constants/numbers.js +0 -34
- package/lib.commonjs/constants/numbers.js.map +0 -1
- package/lib.commonjs/constants/strings.d.ts +0 -13
- package/lib.commonjs/constants/strings.d.ts.map +0 -1
- package/lib.commonjs/constants/strings.js +0 -17
- package/lib.commonjs/constants/strings.js.map +0 -1
- package/lib.commonjs/contract/contract.d.ts +0 -168
- package/lib.commonjs/contract/contract.d.ts.map +0 -1
- package/lib.commonjs/contract/contract.js +0 -960
- package/lib.commonjs/contract/contract.js.map +0 -1
- package/lib.commonjs/contract/factory.d.ts +0 -62
- package/lib.commonjs/contract/factory.d.ts.map +0 -1
- package/lib.commonjs/contract/factory.js +0 -116
- package/lib.commonjs/contract/factory.js.map +0 -1
- package/lib.commonjs/contract/index.d.ts +0 -13
- package/lib.commonjs/contract/index.d.ts.map +0 -1
- package/lib.commonjs/contract/index.js +0 -24
- package/lib.commonjs/contract/index.js.map +0 -1
- package/lib.commonjs/contract/types.d.ts +0 -193
- package/lib.commonjs/contract/types.d.ts.map +0 -1
- package/lib.commonjs/contract/types.js +0 -6
- package/lib.commonjs/contract/types.js.map +0 -1
- package/lib.commonjs/contract/wrappers.d.ts +0 -143
- package/lib.commonjs/contract/wrappers.d.ts.map +0 -1
- package/lib.commonjs/contract/wrappers.js +0 -186
- package/lib.commonjs/contract/wrappers.js.map +0 -1
- package/lib.commonjs/crypto/crypto-browser.d.ts +0 -15
- package/lib.commonjs/crypto/crypto-browser.d.ts.map +0 -1
- package/lib.commonjs/crypto/crypto-browser.js +0 -55
- package/lib.commonjs/crypto/crypto-browser.js.map +0 -1
- package/lib.commonjs/crypto/crypto.d.ts +0 -2
- package/lib.commonjs/crypto/crypto.d.ts.map +0 -1
- package/lib.commonjs/crypto/crypto.js +0 -9
- package/lib.commonjs/crypto/crypto.js.map +0 -1
- package/lib.commonjs/crypto/hmac.d.ts +0 -25
- package/lib.commonjs/crypto/hmac.d.ts.map +0 -1
- package/lib.commonjs/crypto/hmac.js +0 -51
- package/lib.commonjs/crypto/hmac.js.map +0 -1
- package/lib.commonjs/crypto/index.d.ts +0 -25
- package/lib.commonjs/crypto/index.d.ts.map +0 -1
- package/lib.commonjs/crypto/index.js +0 -49
- package/lib.commonjs/crypto/index.js.map +0 -1
- package/lib.commonjs/crypto/keccak.d.ts +0 -35
- package/lib.commonjs/crypto/keccak.d.ts.map +0 -1
- package/lib.commonjs/crypto/keccak.js +0 -52
- package/lib.commonjs/crypto/keccak.js.map +0 -1
- package/lib.commonjs/crypto/pbkdf2.d.ts +0 -35
- package/lib.commonjs/crypto/pbkdf2.d.ts.map +0 -1
- package/lib.commonjs/crypto/pbkdf2.js +0 -53
- package/lib.commonjs/crypto/pbkdf2.js.map +0 -1
- package/lib.commonjs/crypto/random.d.ts +0 -14
- package/lib.commonjs/crypto/random.d.ts.map +0 -1
- package/lib.commonjs/crypto/random.js +0 -38
- package/lib.commonjs/crypto/random.js.map +0 -1
- package/lib.commonjs/crypto/ripemd160.d.ts +0 -25
- package/lib.commonjs/crypto/ripemd160.d.ts.map +0 -1
- package/lib.commonjs/crypto/ripemd160.js +0 -42
- package/lib.commonjs/crypto/ripemd160.js.map +0 -1
- package/lib.commonjs/crypto/scrypt.d.ts +0 -82
- package/lib.commonjs/crypto/scrypt.d.ts.map +0 -1
- package/lib.commonjs/crypto/scrypt.js +0 -104
- package/lib.commonjs/crypto/scrypt.js.map +0 -1
- package/lib.commonjs/crypto/sha2.d.ts +0 -47
- package/lib.commonjs/crypto/sha2.d.ts.map +0 -1
- package/lib.commonjs/crypto/sha2.js +0 -76
- package/lib.commonjs/crypto/sha2.js.map +0 -1
- package/lib.commonjs/crypto/signature.d.ts +0 -145
- package/lib.commonjs/crypto/signature.d.ts.map +0 -1
- package/lib.commonjs/crypto/signature.js +0 -302
- package/lib.commonjs/crypto/signature.js.map +0 -1
- package/lib.commonjs/crypto/signing-key.d.ts +0 -63
- package/lib.commonjs/crypto/signing-key.d.ts.map +0 -1
- package/lib.commonjs/crypto/signing-key.js +0 -102
- package/lib.commonjs/crypto/signing-key.js.map +0 -1
- package/lib.commonjs/hash/authorization.d.ts +0 -18
- package/lib.commonjs/hash/authorization.d.ts.map +0 -1
- package/lib.commonjs/hash/authorization.js +0 -30
- package/lib.commonjs/hash/authorization.js.map +0 -1
- package/lib.commonjs/hash/id.d.ts +0 -13
- package/lib.commonjs/hash/id.d.ts.map +0 -1
- package/lib.commonjs/hash/id.js +0 -21
- package/lib.commonjs/hash/id.js.map +0 -1
- package/lib.commonjs/hash/index.d.ts +0 -15
- package/lib.commonjs/hash/index.d.ts.map +0 -1
- package/lib.commonjs/hash/index.js +0 -30
- package/lib.commonjs/hash/index.js.map +0 -1
- package/lib.commonjs/hash/message.d.ts +0 -36
- package/lib.commonjs/hash/message.d.ts.map +0 -1
- package/lib.commonjs/hash/message.js +0 -56
- package/lib.commonjs/hash/message.js.map +0 -1
- package/lib.commonjs/hash/namehash.d.ts +0 -20
- package/lib.commonjs/hash/namehash.d.ts.map +0 -1
- package/lib.commonjs/hash/namehash.js +0 -91
- package/lib.commonjs/hash/namehash.js.map +0 -1
- package/lib.commonjs/hash/solidity.d.ts +0 -31
- package/lib.commonjs/hash/solidity.d.ts.map +0 -1
- package/lib.commonjs/hash/solidity.js +0 -109
- package/lib.commonjs/hash/solidity.js.map +0 -1
- package/lib.commonjs/hash/typed-data.d.ts +0 -150
- package/lib.commonjs/hash/typed-data.d.ts.map +0 -1
- package/lib.commonjs/hash/typed-data.js +0 -524
- package/lib.commonjs/hash/typed-data.js.map +0 -1
- package/lib.commonjs/index.d.ts +0 -11
- package/lib.commonjs/index.d.ts.map +0 -1
- package/lib.commonjs/index.js +0 -15
- package/lib.commonjs/index.js.map +0 -1
- package/lib.commonjs/package.json +0 -12
- package/lib.commonjs/providers/abstract-provider.d.ts +0 -451
- package/lib.commonjs/providers/abstract-provider.d.ts.map +0 -1
- package/lib.commonjs/providers/abstract-provider.js +0 -1409
- package/lib.commonjs/providers/abstract-provider.js.map +0 -1
- package/lib.commonjs/providers/abstract-signer.d.ts +0 -69
- package/lib.commonjs/providers/abstract-signer.d.ts.map +0 -1
- package/lib.commonjs/providers/abstract-signer.js +0 -249
- package/lib.commonjs/providers/abstract-signer.js.map +0 -1
- package/lib.commonjs/providers/community.d.ts +0 -29
- package/lib.commonjs/providers/community.d.ts.map +0 -1
- package/lib.commonjs/providers/community.js +0 -40
- package/lib.commonjs/providers/community.js.map +0 -1
- package/lib.commonjs/providers/contracts.d.ts +0 -36
- package/lib.commonjs/providers/contracts.d.ts.map +0 -1
- package/lib.commonjs/providers/contracts.js +0 -3
- package/lib.commonjs/providers/contracts.js.map +0 -1
- package/lib.commonjs/providers/default-provider.d.ts +0 -41
- package/lib.commonjs/providers/default-provider.d.ts.map +0 -1
- package/lib.commonjs/providers/default-provider.js +0 -92
- package/lib.commonjs/providers/default-provider.js.map +0 -1
- package/lib.commonjs/providers/ens-resolver.d.ts +0 -147
- package/lib.commonjs/providers/ens-resolver.d.ts.map +0 -1
- package/lib.commonjs/providers/ens-resolver.js +0 -502
- package/lib.commonjs/providers/ens-resolver.js.map +0 -1
- package/lib.commonjs/providers/format.d.ts +0 -15
- package/lib.commonjs/providers/format.d.ts.map +0 -1
- package/lib.commonjs/providers/format.js +0 -298
- package/lib.commonjs/providers/format.js.map +0 -1
- package/lib.commonjs/providers/formatting.d.ts +0 -318
- package/lib.commonjs/providers/formatting.d.ts.map +0 -1
- package/lib.commonjs/providers/formatting.js +0 -10
- package/lib.commonjs/providers/formatting.js.map +0 -1
- package/lib.commonjs/providers/index.d.ts +0 -41
- package/lib.commonjs/providers/index.d.ts.map +0 -1
- package/lib.commonjs/providers/index.js +0 -64
- package/lib.commonjs/providers/index.js.map +0 -1
- package/lib.commonjs/providers/network.d.ts +0 -99
- package/lib.commonjs/providers/network.d.ts.map +0 -1
- package/lib.commonjs/providers/network.js +0 -269
- package/lib.commonjs/providers/network.js.map +0 -1
- package/lib.commonjs/providers/pagination.d.ts +0 -6
- package/lib.commonjs/providers/pagination.d.ts.map +0 -1
- package/lib.commonjs/providers/pagination.js +0 -3
- package/lib.commonjs/providers/pagination.js.map +0 -1
- package/lib.commonjs/providers/plugin-fallback.d.ts +0 -13
- package/lib.commonjs/providers/plugin-fallback.d.ts.map +0 -1
- package/lib.commonjs/providers/plugin-fallback.js +0 -31
- package/lib.commonjs/providers/plugin-fallback.js.map +0 -1
- package/lib.commonjs/providers/plugins-network.d.ts +0 -170
- package/lib.commonjs/providers/plugins-network.d.ts.map +0 -1
- package/lib.commonjs/providers/plugins-network.js +0 -216
- package/lib.commonjs/providers/plugins-network.js.map +0 -1
- package/lib.commonjs/providers/provider-browser.d.ts +0 -108
- package/lib.commonjs/providers/provider-browser.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-browser.js +0 -204
- package/lib.commonjs/providers/provider-browser.js.map +0 -1
- package/lib.commonjs/providers/provider-fallback.d.ts +0 -115
- package/lib.commonjs/providers/provider-fallback.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-fallback.js +0 -624
- package/lib.commonjs/providers/provider-fallback.js.map +0 -1
- package/lib.commonjs/providers/provider-ipcsocket-browser.d.ts +0 -3
- package/lib.commonjs/providers/provider-ipcsocket-browser.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-ipcsocket-browser.js +0 -6
- package/lib.commonjs/providers/provider-ipcsocket-browser.js.map +0 -1
- package/lib.commonjs/providers/provider-ipcsocket.d.ts +0 -21
- package/lib.commonjs/providers/provider-ipcsocket.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-ipcsocket.js +0 -72
- package/lib.commonjs/providers/provider-ipcsocket.js.map +0 -1
- package/lib.commonjs/providers/provider-jsonrpc.d.ts +0 -361
- package/lib.commonjs/providers/provider-jsonrpc.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-jsonrpc.js +0 -980
- package/lib.commonjs/providers/provider-jsonrpc.js.map +0 -1
- package/lib.commonjs/providers/provider-socket.d.ts +0 -113
- package/lib.commonjs/providers/provider-socket.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-socket.js +0 -309
- package/lib.commonjs/providers/provider-socket.js.map +0 -1
- package/lib.commonjs/providers/provider-websocket.d.ts +0 -37
- package/lib.commonjs/providers/provider-websocket.d.ts.map +0 -1
- package/lib.commonjs/providers/provider-websocket.js +0 -80
- package/lib.commonjs/providers/provider-websocket.js.map +0 -1
- package/lib.commonjs/providers/provider.d.ts +0 -1223
- package/lib.commonjs/providers/provider.d.ts.map +0 -1
- package/lib.commonjs/providers/provider.js +0 -1321
- package/lib.commonjs/providers/provider.js.map +0 -1
- package/lib.commonjs/providers/signer-noncemanager.d.ts +0 -38
- package/lib.commonjs/providers/signer-noncemanager.d.ts.map +0 -1
- package/lib.commonjs/providers/signer-noncemanager.js +0 -78
- package/lib.commonjs/providers/signer-noncemanager.js.map +0 -1
- package/lib.commonjs/providers/signer.d.ts +0 -131
- package/lib.commonjs/providers/signer.d.ts.map +0 -1
- package/lib.commonjs/providers/signer.js +0 -3
- package/lib.commonjs/providers/signer.js.map +0 -1
- package/lib.commonjs/providers/subscriber-connection.d.ts +0 -25
- package/lib.commonjs/providers/subscriber-connection.d.ts.map +0 -1
- package/lib.commonjs/providers/subscriber-connection.js +0 -56
- package/lib.commonjs/providers/subscriber-connection.js.map +0 -1
- package/lib.commonjs/providers/subscriber-filterid.d.ts +0 -64
- package/lib.commonjs/providers/subscriber-filterid.d.ts.map +0 -1
- package/lib.commonjs/providers/subscriber-filterid.js +0 -180
- package/lib.commonjs/providers/subscriber-filterid.js.map +0 -1
- package/lib.commonjs/providers/subscriber-polling.d.ts +0 -100
- package/lib.commonjs/providers/subscriber-polling.d.ts.map +0 -1
- package/lib.commonjs/providers/subscriber-polling.js +0 -303
- package/lib.commonjs/providers/subscriber-polling.js.map +0 -1
- package/lib.commonjs/providers/ws-browser.d.ts +0 -3
- package/lib.commonjs/providers/ws-browser.d.ts.map +0 -1
- package/lib.commonjs/providers/ws-browser.js +0 -19
- package/lib.commonjs/providers/ws-browser.js.map +0 -1
- package/lib.commonjs/providers/ws.d.ts +0 -2
- package/lib.commonjs/providers/ws.d.ts.map +0 -1
- package/lib.commonjs/providers/ws.js +0 -6
- package/lib.commonjs/providers/ws.js.map +0 -1
- package/lib.commonjs/quantumcoin.d.ts +0 -24
- package/lib.commonjs/quantumcoin.d.ts.map +0 -1
- package/lib.commonjs/quantumcoin.js +0 -199
- package/lib.commonjs/quantumcoin.js.map +0 -1
- package/lib.commonjs/transaction/accesslist.d.ts +0 -6
- package/lib.commonjs/transaction/accesslist.d.ts.map +0 -1
- package/lib.commonjs/transaction/accesslist.js +0 -41
- package/lib.commonjs/transaction/accesslist.js.map +0 -1
- package/lib.commonjs/transaction/address.d.ts +0 -15
- package/lib.commonjs/transaction/address.d.ts.map +0 -1
- package/lib.commonjs/transaction/address.js +0 -39
- package/lib.commonjs/transaction/address.js.map +0 -1
- package/lib.commonjs/transaction/authorization.d.ts +0 -3
- package/lib.commonjs/transaction/authorization.d.ts.map +0 -1
- package/lib.commonjs/transaction/authorization.js +0 -16
- package/lib.commonjs/transaction/authorization.js.map +0 -1
- package/lib.commonjs/transaction/index.d.ts +0 -40
- package/lib.commonjs/transaction/index.d.ts.map +0 -1
- package/lib.commonjs/transaction/index.js +0 -19
- package/lib.commonjs/transaction/index.js.map +0 -1
- package/lib.commonjs/transaction/transaction.d.ts +0 -400
- package/lib.commonjs/transaction/transaction.d.ts.map +0 -1
- package/lib.commonjs/transaction/transaction.js +0 -1148
- package/lib.commonjs/transaction/transaction.js.map +0 -1
- package/lib.commonjs/utils/base58.d.ts +0 -23
- package/lib.commonjs/utils/base58.d.ts.map +0 -1
- package/lib.commonjs/utils/base58.js +0 -68
- package/lib.commonjs/utils/base58.js.map +0 -1
- package/lib.commonjs/utils/base64-browser.d.ts +0 -4
- package/lib.commonjs/utils/base64-browser.d.ts.map +0 -1
- package/lib.commonjs/utils/base64-browser.js +0 -24
- package/lib.commonjs/utils/base64-browser.js.map +0 -1
- package/lib.commonjs/utils/base64.d.ts +0 -40
- package/lib.commonjs/utils/base64.d.ts.map +0 -1
- package/lib.commonjs/utils/base64.js +0 -58
- package/lib.commonjs/utils/base64.js.map +0 -1
- package/lib.commonjs/utils/data.d.ts +0 -93
- package/lib.commonjs/utils/data.d.ts.map +0 -1
- package/lib.commonjs/utils/data.js +0 -184
- package/lib.commonjs/utils/data.js.map +0 -1
- package/lib.commonjs/utils/errors.d.ts +0 -512
- package/lib.commonjs/utils/errors.d.ts.map +0 -1
- package/lib.commonjs/utils/errors.js +0 -235
- package/lib.commonjs/utils/errors.js.map +0 -1
- package/lib.commonjs/utils/events.d.ts +0 -77
- package/lib.commonjs/utils/events.d.ts.map +0 -1
- package/lib.commonjs/utils/events.js +0 -46
- package/lib.commonjs/utils/events.js.map +0 -1
- package/lib.commonjs/utils/fetch.d.ts +0 -363
- package/lib.commonjs/utils/fetch.d.ts.map +0 -1
- package/lib.commonjs/utils/fetch.js +0 -858
- package/lib.commonjs/utils/fetch.js.map +0 -1
- package/lib.commonjs/utils/fixednumber.d.ts +0 -252
- package/lib.commonjs/utils/fixednumber.d.ts.map +0 -1
- package/lib.commonjs/utils/fixednumber.js +0 -530
- package/lib.commonjs/utils/fixednumber.js.map +0 -1
- package/lib.commonjs/utils/geturl-browser.d.ts +0 -4
- package/lib.commonjs/utils/geturl-browser.d.ts.map +0 -1
- package/lib.commonjs/utils/geturl-browser.js +0 -67
- package/lib.commonjs/utils/geturl-browser.js.map +0 -1
- package/lib.commonjs/utils/geturl.d.ts +0 -10
- package/lib.commonjs/utils/geturl.d.ts.map +0 -1
- package/lib.commonjs/utils/geturl.js +0 -120
- package/lib.commonjs/utils/geturl.js.map +0 -1
- package/lib.commonjs/utils/index.d.ts +0 -30
- package/lib.commonjs/utils/index.d.ts.map +0 -1
- package/lib.commonjs/utils/index.js +0 -78
- package/lib.commonjs/utils/index.js.map +0 -1
- package/lib.commonjs/utils/maths.d.ts +0 -66
- package/lib.commonjs/utils/maths.d.ts.map +0 -1
- package/lib.commonjs/utils/maths.js +0 -229
- package/lib.commonjs/utils/maths.js.map +0 -1
- package/lib.commonjs/utils/properties.d.ts +0 -23
- package/lib.commonjs/utils/properties.d.ts.map +0 -1
- package/lib.commonjs/utils/properties.js +0 -59
- package/lib.commonjs/utils/properties.js.map +0 -1
- package/lib.commonjs/utils/rlp-decode.d.ts +0 -6
- package/lib.commonjs/utils/rlp-decode.d.ts.map +0 -1
- package/lib.commonjs/utils/rlp-decode.js +0 -83
- package/lib.commonjs/utils/rlp-decode.js.map +0 -1
- package/lib.commonjs/utils/rlp-encode.d.ts +0 -6
- package/lib.commonjs/utils/rlp-encode.d.ts.map +0 -1
- package/lib.commonjs/utils/rlp-encode.js +0 -53
- package/lib.commonjs/utils/rlp-encode.js.map +0 -1
- package/lib.commonjs/utils/rlp.d.ts +0 -17
- package/lib.commonjs/utils/rlp.d.ts.map +0 -1
- package/lib.commonjs/utils/rlp.js +0 -14
- package/lib.commonjs/utils/rlp.js.map +0 -1
- package/lib.commonjs/utils/units.d.ts +0 -24
- package/lib.commonjs/utils/units.d.ts.map +0 -1
- package/lib.commonjs/utils/units.js +0 -90
- package/lib.commonjs/utils/units.js.map +0 -1
- package/lib.commonjs/utils/utf8.d.ts +0 -96
- package/lib.commonjs/utils/utf8.d.ts.map +0 -1
- package/lib.commonjs/utils/utf8.js +0 -227
- package/lib.commonjs/utils/utf8.js.map +0 -1
- package/lib.commonjs/utils/uuid.d.ts +0 -8
- package/lib.commonjs/utils/uuid.d.ts.map +0 -1
- package/lib.commonjs/utils/uuid.js +0 -34
- package/lib.commonjs/utils/uuid.js.map +0 -1
- package/lib.commonjs/wallet/base-wallet.d.ts +0 -57
- package/lib.commonjs/wallet/base-wallet.d.ts.map +0 -1
- package/lib.commonjs/wallet/base-wallet.js +0 -127
- package/lib.commonjs/wallet/base-wallet.js.map +0 -1
- package/lib.commonjs/wallet/index.d.ts +0 -23
- package/lib.commonjs/wallet/index.d.ts.map +0 -1
- package/lib.commonjs/wallet/index.js +0 -30
- package/lib.commonjs/wallet/index.js.map +0 -1
- package/lib.commonjs/wallet/json-keystore.d.ts +0 -40
- package/lib.commonjs/wallet/json-keystore.d.ts.map +0 -1
- package/lib.commonjs/wallet/json-keystore.js +0 -90
- package/lib.commonjs/wallet/json-keystore.js.map +0 -1
- package/lib.commonjs/wallet/utils.d.ts +0 -8
- package/lib.commonjs/wallet/utils.d.ts.map +0 -1
- package/lib.commonjs/wallet/utils.js +0 -149
- package/lib.commonjs/wallet/utils.js.map +0 -1
- package/lib.commonjs/wallet/wallet.d.ts +0 -62
- package/lib.commonjs/wallet/wallet.d.ts.map +0 -1
- package/lib.commonjs/wallet/wallet.js +0 -109
- package/lib.commonjs/wallet/wallet.js.map +0 -1
- package/lib.commonjs/wordlists/bit-reader.d.ts +0 -5
- package/lib.commonjs/wordlists/bit-reader.d.ts.map +0 -1
- package/lib.commonjs/wordlists/bit-reader.js +0 -36
- package/lib.commonjs/wordlists/bit-reader.js.map +0 -1
- package/lib.commonjs/wordlists/decode-owl.d.ts +0 -9
- package/lib.commonjs/wordlists/decode-owl.d.ts.map +0 -1
- package/lib.commonjs/wordlists/decode-owl.js +0 -60
- package/lib.commonjs/wordlists/decode-owl.js.map +0 -1
- package/lib.commonjs/wordlists/decode-owla.d.ts +0 -5
- package/lib.commonjs/wordlists/decode-owla.d.ts.map +0 -1
- package/lib.commonjs/wordlists/decode-owla.js +0 -32
- package/lib.commonjs/wordlists/decode-owla.js.map +0 -1
- package/lib.commonjs/wordlists/generation/encode-latin.d.ts +0 -25
- package/lib.commonjs/wordlists/generation/encode-latin.d.ts.map +0 -1
- package/lib.commonjs/wordlists/generation/encode-latin.js +0 -351
- package/lib.commonjs/wordlists/generation/encode-latin.js.map +0 -1
- package/lib.commonjs/wordlists/index.d.ts +0 -25
- package/lib.commonjs/wordlists/index.d.ts.map +0 -1
- package/lib.commonjs/wordlists/index.js +0 -33
- package/lib.commonjs/wordlists/index.js.map +0 -1
- package/lib.commonjs/wordlists/lang-cz.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-cz.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-cz.js +0 -35
- package/lib.commonjs/wordlists/lang-cz.js.map +0 -1
- package/lib.commonjs/wordlists/lang-en.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-en.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-en.js +0 -35
- package/lib.commonjs/wordlists/lang-en.js.map +0 -1
- package/lib.commonjs/wordlists/lang-es.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-es.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-es.js +0 -36
- package/lib.commonjs/wordlists/lang-es.js.map +0 -1
- package/lib.commonjs/wordlists/lang-fr.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-fr.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-fr.js +0 -36
- package/lib.commonjs/wordlists/lang-fr.js.map +0 -1
- package/lib.commonjs/wordlists/lang-it.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-it.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-it.js +0 -35
- package/lib.commonjs/wordlists/lang-it.js.map +0 -1
- package/lib.commonjs/wordlists/lang-ja.d.ts +0 -27
- package/lib.commonjs/wordlists/lang-ja.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-ja.js +0 -158
- package/lib.commonjs/wordlists/lang-ja.js.map +0 -1
- package/lib.commonjs/wordlists/lang-ko.d.ts +0 -25
- package/lib.commonjs/wordlists/lang-ko.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-ko.js +0 -93
- package/lib.commonjs/wordlists/lang-ko.js.map +0 -1
- package/lib.commonjs/wordlists/lang-pt.d.ts +0 -23
- package/lib.commonjs/wordlists/lang-pt.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-pt.js +0 -35
- package/lib.commonjs/wordlists/lang-pt.js.map +0 -1
- package/lib.commonjs/wordlists/lang-zh.d.ts +0 -32
- package/lib.commonjs/wordlists/lang-zh.d.ts.map +0 -1
- package/lib.commonjs/wordlists/lang-zh.js +0 -96
- package/lib.commonjs/wordlists/lang-zh.js.map +0 -1
- package/lib.commonjs/wordlists/wordlist-owl.d.ts +0 -32
- package/lib.commonjs/wordlists/wordlist-owl.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlist-owl.js +0 -70
- package/lib.commonjs/wordlists/wordlist-owl.js.map +0 -1
- package/lib.commonjs/wordlists/wordlist-owla.d.ts +0 -30
- package/lib.commonjs/wordlists/wordlist-owla.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlist-owla.js +0 -40
- package/lib.commonjs/wordlists/wordlist-owla.js.map +0 -1
- package/lib.commonjs/wordlists/wordlist.d.ts +0 -47
- package/lib.commonjs/wordlists/wordlist.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlist.js +0 -46
- package/lib.commonjs/wordlists/wordlist.js.map +0 -1
- package/lib.commonjs/wordlists/wordlists-browser.d.ts +0 -3
- package/lib.commonjs/wordlists/wordlists-browser.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlists-browser.js +0 -8
- package/lib.commonjs/wordlists/wordlists-browser.js.map +0 -1
- package/lib.commonjs/wordlists/wordlists-extra.d.ts +0 -9
- package/lib.commonjs/wordlists/wordlists-extra.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlists-extra.js +0 -20
- package/lib.commonjs/wordlists/wordlists-extra.js.map +0 -1
- package/lib.commonjs/wordlists/wordlists.d.ts +0 -16
- package/lib.commonjs/wordlists/wordlists.d.ts.map +0 -1
- package/lib.commonjs/wordlists/wordlists.js +0 -38
- package/lib.commonjs/wordlists/wordlists.js.map +0 -1
- package/lib.esm/README.md +0 -16
- package/lib.esm/_version.d.ts +0 -5
- package/lib.esm/_version.d.ts.map +0 -1
- package/lib.esm/_version.js +0 -6
- package/lib.esm/_version.js.map +0 -1
- package/lib.esm/abi/abi-coder.d.ts +0 -61
- package/lib.esm/abi/abi-coder.d.ts.map +0 -1
- package/lib.esm/abi/abi-coder.js +0 -206
- package/lib.esm/abi/abi-coder.js.map +0 -1
- package/lib.esm/abi/bytes32.d.ts +0 -15
- package/lib.esm/abi/bytes32.d.ts.map +0 -1
- package/lib.esm/abi/bytes32.js +0 -40
- package/lib.esm/abi/bytes32.js.map +0 -1
- package/lib.esm/abi/coders/abstract-coder.d.ts +0 -124
- package/lib.esm/abi/coders/abstract-coder.d.ts.map +0 -1
- package/lib.esm/abi/coders/abstract-coder.js +0 -466
- package/lib.esm/abi/coders/abstract-coder.js.map +0 -1
- package/lib.esm/abi/coders/address.d.ts +0 -13
- package/lib.esm/abi/coders/address.d.ts.map +0 -1
- package/lib.esm/abi/coders/address.js +0 -29
- package/lib.esm/abi/coders/address.js.map +0 -1
- package/lib.esm/abi/coders/anonymous.d.ts +0 -15
- package/lib.esm/abi/coders/anonymous.d.ts.map +0 -1
- package/lib.esm/abi/coders/anonymous.js +0 -23
- package/lib.esm/abi/coders/anonymous.js.map +0 -1
- package/lib.esm/abi/coders/array.d.ts +0 -25
- package/lib.esm/abi/coders/array.d.ts.map +0 -1
- package/lib.esm/abi/coders/array.js +0 -159
- package/lib.esm/abi/coders/array.js.map +0 -1
- package/lib.esm/abi/coders/boolean.d.ts +0 -13
- package/lib.esm/abi/coders/boolean.d.ts.map +0 -1
- package/lib.esm/abi/coders/boolean.js +0 -21
- package/lib.esm/abi/coders/boolean.js.map +0 -1
- package/lib.esm/abi/coders/bytes.d.ts +0 -19
- package/lib.esm/abi/coders/bytes.d.ts.map +0 -1
- package/lib.esm/abi/coders/bytes.js +0 -34
- package/lib.esm/abi/coders/bytes.js.map +0 -1
- package/lib.esm/abi/coders/fixed-bytes.d.ts +0 -15
- package/lib.esm/abi/coders/fixed-bytes.d.ts.map +0 -1
- package/lib.esm/abi/coders/fixed-bytes.js +0 -28
- package/lib.esm/abi/coders/fixed-bytes.js.map +0 -1
- package/lib.esm/abi/coders/null.d.ts +0 -12
- package/lib.esm/abi/coders/null.d.ts.map +0 -1
- package/lib.esm/abi/coders/null.js +0 -24
- package/lib.esm/abi/coders/null.js.map +0 -1
- package/lib.esm/abi/coders/number.d.ts +0 -16
- package/lib.esm/abi/coders/number.d.ts.map +0 -1
- package/lib.esm/abi/coders/number.js +0 -45
- package/lib.esm/abi/coders/number.js.map +0 -1
- package/lib.esm/abi/coders/string.d.ts +0 -13
- package/lib.esm/abi/coders/string.d.ts.map +0 -1
- package/lib.esm/abi/coders/string.js +0 -21
- package/lib.esm/abi/coders/string.js.map +0 -1
- package/lib.esm/abi/coders/tuple.d.ts +0 -16
- package/lib.esm/abi/coders/tuple.d.ts.map +0 -1
- package/lib.esm/abi/coders/tuple.js +0 -63
- package/lib.esm/abi/coders/tuple.js.map +0 -1
- package/lib.esm/abi/fragments.d.ts +0 -466
- package/lib.esm/abi/fragments.d.ts.map +0 -1
- package/lib.esm/abi/fragments.js +0 -1319
- package/lib.esm/abi/fragments.js.map +0 -1
- package/lib.esm/abi/index.d.ts +0 -18
- package/lib.esm/abi/index.d.ts.map +0 -1
- package/lib.esm/abi/index.js +0 -17
- package/lib.esm/abi/index.js.map +0 -1
- package/lib.esm/abi/interface.d.ts +0 -382
- package/lib.esm/abi/interface.d.ts.map +0 -1
- package/lib.esm/abi/interface.js +0 -1101
- package/lib.esm/abi/interface.js.map +0 -1
- package/lib.esm/abi/typed.d.ts +0 -570
- package/lib.esm/abi/typed.d.ts.map +0 -1
- package/lib.esm/abi/typed.js +0 -602
- package/lib.esm/abi/typed.js.map +0 -1
- package/lib.esm/address/address.d.ts +0 -36
- package/lib.esm/address/address.d.ts.map +0 -1
- package/lib.esm/address/address.js +0 -129
- package/lib.esm/address/address.js.map +0 -1
- package/lib.esm/address/checks.d.ts +0 -81
- package/lib.esm/address/checks.d.ts.map +0 -1
- package/lib.esm/address/checks.js +0 -114
- package/lib.esm/address/checks.js.map +0 -1
- package/lib.esm/address/contract-address.d.ts +0 -48
- package/lib.esm/address/contract-address.d.ts.map +0 -1
- package/lib.esm/address/contract-address.js +0 -69
- package/lib.esm/address/contract-address.js.map +0 -1
- package/lib.esm/address/index.d.ts +0 -49
- package/lib.esm/address/index.d.ts.map +0 -1
- package/lib.esm/address/index.js +0 -19
- package/lib.esm/address/index.js.map +0 -1
- package/lib.esm/constants/addresses.d.ts +0 -7
- package/lib.esm/constants/addresses.d.ts.map +0 -1
- package/lib.esm/constants/addresses.js +0 -7
- package/lib.esm/constants/addresses.js.map +0 -1
- package/lib.esm/constants/hashes.d.ts +0 -7
- package/lib.esm/constants/hashes.d.ts.map +0 -1
- package/lib.esm/constants/hashes.js +0 -7
- package/lib.esm/constants/hashes.js.map +0 -1
- package/lib.esm/constants/index.d.ts +0 -10
- package/lib.esm/constants/index.d.ts.map +0 -1
- package/lib.esm/constants/index.js +0 -10
- package/lib.esm/constants/index.js.map +0 -1
- package/lib.esm/constants/numbers.d.ts +0 -31
- package/lib.esm/constants/numbers.d.ts.map +0 -1
- package/lib.esm/constants/numbers.js +0 -31
- package/lib.esm/constants/numbers.js.map +0 -1
- package/lib.esm/constants/strings.d.ts +0 -13
- package/lib.esm/constants/strings.d.ts.map +0 -1
- package/lib.esm/constants/strings.js +0 -14
- package/lib.esm/constants/strings.js.map +0 -1
- package/lib.esm/contract/contract.d.ts +0 -168
- package/lib.esm/contract/contract.d.ts.map +0 -1
- package/lib.esm/contract/contract.js +0 -953
- package/lib.esm/contract/contract.js.map +0 -1
- package/lib.esm/contract/factory.d.ts +0 -62
- package/lib.esm/contract/factory.d.ts.map +0 -1
- package/lib.esm/contract/factory.js +0 -112
- package/lib.esm/contract/factory.js.map +0 -1
- package/lib.esm/contract/index.d.ts +0 -13
- package/lib.esm/contract/index.d.ts.map +0 -1
- package/lib.esm/contract/index.js +0 -12
- package/lib.esm/contract/index.js.map +0 -1
- package/lib.esm/contract/types.d.ts +0 -193
- package/lib.esm/contract/types.d.ts.map +0 -1
- package/lib.esm/contract/types.js +0 -5
- package/lib.esm/contract/types.js.map +0 -1
- package/lib.esm/contract/wrappers.d.ts +0 -143
- package/lib.esm/contract/wrappers.d.ts.map +0 -1
- package/lib.esm/contract/wrappers.js +0 -177
- package/lib.esm/contract/wrappers.js.map +0 -1
- package/lib.esm/crypto/crypto-browser.d.ts +0 -15
- package/lib.esm/crypto/crypto-browser.d.ts.map +0 -1
- package/lib.esm/crypto/crypto-browser.js +0 -48
- package/lib.esm/crypto/crypto-browser.js.map +0 -1
- package/lib.esm/crypto/crypto.d.ts +0 -2
- package/lib.esm/crypto/crypto.d.ts.map +0 -1
- package/lib.esm/crypto/crypto.js +0 -2
- package/lib.esm/crypto/crypto.js.map +0 -1
- package/lib.esm/crypto/hmac.d.ts +0 -25
- package/lib.esm/crypto/hmac.d.ts.map +0 -1
- package/lib.esm/crypto/hmac.js +0 -47
- package/lib.esm/crypto/hmac.js.map +0 -1
- package/lib.esm/crypto/index.d.ts +0 -25
- package/lib.esm/crypto/index.d.ts.map +0 -1
- package/lib.esm/crypto/index.js +0 -36
- package/lib.esm/crypto/index.js.map +0 -1
- package/lib.esm/crypto/keccak.d.ts +0 -35
- package/lib.esm/crypto/keccak.d.ts.map +0 -1
- package/lib.esm/crypto/keccak.js +0 -48
- package/lib.esm/crypto/keccak.js.map +0 -1
- package/lib.esm/crypto/pbkdf2.d.ts +0 -35
- package/lib.esm/crypto/pbkdf2.d.ts.map +0 -1
- package/lib.esm/crypto/pbkdf2.js +0 -49
- package/lib.esm/crypto/pbkdf2.js.map +0 -1
- package/lib.esm/crypto/random.d.ts +0 -14
- package/lib.esm/crypto/random.d.ts.map +0 -1
- package/lib.esm/crypto/random.js +0 -34
- package/lib.esm/crypto/random.js.map +0 -1
- package/lib.esm/crypto/ripemd160.d.ts +0 -25
- package/lib.esm/crypto/ripemd160.d.ts.map +0 -1
- package/lib.esm/crypto/ripemd160.js +0 -38
- package/lib.esm/crypto/ripemd160.js.map +0 -1
- package/lib.esm/crypto/scrypt.d.ts +0 -82
- package/lib.esm/crypto/scrypt.d.ts.map +0 -1
- package/lib.esm/crypto/scrypt.js +0 -99
- package/lib.esm/crypto/scrypt.js.map +0 -1
- package/lib.esm/crypto/sha2.d.ts +0 -47
- package/lib.esm/crypto/sha2.d.ts.map +0 -1
- package/lib.esm/crypto/sha2.js +0 -71
- package/lib.esm/crypto/sha2.js.map +0 -1
- package/lib.esm/crypto/signature.d.ts +0 -145
- package/lib.esm/crypto/signature.d.ts.map +0 -1
- package/lib.esm/crypto/signature.js +0 -300
- package/lib.esm/crypto/signature.js.map +0 -1
- package/lib.esm/crypto/signing-key.d.ts +0 -63
- package/lib.esm/crypto/signing-key.d.ts.map +0 -1
- package/lib.esm/crypto/signing-key.js +0 -97
- package/lib.esm/crypto/signing-key.js.map +0 -1
- package/lib.esm/hash/authorization.d.ts +0 -18
- package/lib.esm/hash/authorization.d.ts.map +0 -1
- package/lib.esm/hash/authorization.js +0 -25
- package/lib.esm/hash/authorization.js.map +0 -1
- package/lib.esm/hash/id.d.ts +0 -13
- package/lib.esm/hash/id.d.ts.map +0 -1
- package/lib.esm/hash/id.js +0 -17
- package/lib.esm/hash/id.js.map +0 -1
- package/lib.esm/hash/index.d.ts +0 -15
- package/lib.esm/hash/index.d.ts.map +0 -1
- package/lib.esm/hash/index.js +0 -13
- package/lib.esm/hash/index.js.map +0 -1
- package/lib.esm/hash/message.d.ts +0 -36
- package/lib.esm/hash/message.d.ts.map +0 -1
- package/lib.esm/hash/message.js +0 -51
- package/lib.esm/hash/message.js.map +0 -1
- package/lib.esm/hash/namehash.d.ts +0 -20
- package/lib.esm/hash/namehash.d.ts.map +0 -1
- package/lib.esm/hash/namehash.js +0 -84
- package/lib.esm/hash/namehash.js.map +0 -1
- package/lib.esm/hash/solidity.d.ts +0 -31
- package/lib.esm/hash/solidity.d.ts.map +0 -1
- package/lib.esm/hash/solidity.js +0 -103
- package/lib.esm/hash/solidity.js.map +0 -1
- package/lib.esm/hash/typed-data.d.ts +0 -150
- package/lib.esm/hash/typed-data.d.ts.map +0 -1
- package/lib.esm/hash/typed-data.js +0 -519
- package/lib.esm/hash/typed-data.js.map +0 -1
- package/lib.esm/index.d.ts +0 -11
- package/lib.esm/index.d.ts.map +0 -1
- package/lib.esm/index.js +0 -11
- package/lib.esm/index.js.map +0 -1
- package/lib.esm/package.json +0 -12
- package/lib.esm/providers/abstract-provider.d.ts +0 -451
- package/lib.esm/providers/abstract-provider.d.ts.map +0 -1
- package/lib.esm/providers/abstract-provider.js +0 -1404
- package/lib.esm/providers/abstract-provider.js.map +0 -1
- package/lib.esm/providers/abstract-signer.d.ts +0 -69
- package/lib.esm/providers/abstract-signer.d.ts.map +0 -1
- package/lib.esm/providers/abstract-signer.js +0 -244
- package/lib.esm/providers/abstract-signer.js.map +0 -1
- package/lib.esm/providers/community.d.ts +0 -29
- package/lib.esm/providers/community.d.ts.map +0 -1
- package/lib.esm/providers/community.js +0 -36
- package/lib.esm/providers/community.js.map +0 -1
- package/lib.esm/providers/contracts.d.ts +0 -36
- package/lib.esm/providers/contracts.d.ts.map +0 -1
- package/lib.esm/providers/contracts.js +0 -2
- package/lib.esm/providers/contracts.js.map +0 -1
- package/lib.esm/providers/default-provider.d.ts +0 -41
- package/lib.esm/providers/default-provider.d.ts.map +0 -1
- package/lib.esm/providers/default-provider.js +0 -88
- package/lib.esm/providers/default-provider.js.map +0 -1
- package/lib.esm/providers/ens-resolver.d.ts +0 -147
- package/lib.esm/providers/ens-resolver.d.ts.map +0 -1
- package/lib.esm/providers/ens-resolver.js +0 -496
- package/lib.esm/providers/ens-resolver.js.map +0 -1
- package/lib.esm/providers/format.d.ts +0 -15
- package/lib.esm/providers/format.d.ts.map +0 -1
- package/lib.esm/providers/format.js +0 -283
- package/lib.esm/providers/format.js.map +0 -1
- package/lib.esm/providers/formatting.d.ts +0 -318
- package/lib.esm/providers/formatting.d.ts.map +0 -1
- package/lib.esm/providers/formatting.js +0 -9
- package/lib.esm/providers/formatting.js.map +0 -1
- package/lib.esm/providers/index.d.ts +0 -41
- package/lib.esm/providers/index.d.ts.map +0 -1
- package/lib.esm/providers/index.js +0 -31
- package/lib.esm/providers/index.js.map +0 -1
- package/lib.esm/providers/network.d.ts +0 -99
- package/lib.esm/providers/network.d.ts.map +0 -1
- package/lib.esm/providers/network.js +0 -265
- package/lib.esm/providers/network.js.map +0 -1
- package/lib.esm/providers/pagination.d.ts +0 -6
- package/lib.esm/providers/pagination.d.ts.map +0 -1
- package/lib.esm/providers/pagination.js +0 -2
- package/lib.esm/providers/pagination.js.map +0 -1
- package/lib.esm/providers/plugin-fallback.d.ts +0 -13
- package/lib.esm/providers/plugin-fallback.d.ts.map +0 -1
- package/lib.esm/providers/plugin-fallback.js +0 -26
- package/lib.esm/providers/plugin-fallback.js.map +0 -1
- package/lib.esm/providers/plugins-network.d.ts +0 -170
- package/lib.esm/providers/plugins-network.d.ts.map +0 -1
- package/lib.esm/providers/plugins-network.js +0 -208
- package/lib.esm/providers/plugins-network.js.map +0 -1
- package/lib.esm/providers/provider-browser.d.ts +0 -108
- package/lib.esm/providers/provider-browser.d.ts.map +0 -1
- package/lib.esm/providers/provider-browser.js +0 -200
- package/lib.esm/providers/provider-browser.js.map +0 -1
- package/lib.esm/providers/provider-fallback.d.ts +0 -115
- package/lib.esm/providers/provider-fallback.d.ts.map +0 -1
- package/lib.esm/providers/provider-fallback.js +0 -620
- package/lib.esm/providers/provider-fallback.js.map +0 -1
- package/lib.esm/providers/provider-ipcsocket-browser.d.ts +0 -3
- package/lib.esm/providers/provider-ipcsocket-browser.d.ts.map +0 -1
- package/lib.esm/providers/provider-ipcsocket-browser.js +0 -3
- package/lib.esm/providers/provider-ipcsocket-browser.js.map +0 -1
- package/lib.esm/providers/provider-ipcsocket.d.ts +0 -21
- package/lib.esm/providers/provider-ipcsocket.d.ts.map +0 -1
- package/lib.esm/providers/provider-ipcsocket.js +0 -68
- package/lib.esm/providers/provider-ipcsocket.js.map +0 -1
- package/lib.esm/providers/provider-jsonrpc.d.ts +0 -361
- package/lib.esm/providers/provider-jsonrpc.d.ts.map +0 -1
- package/lib.esm/providers/provider-jsonrpc.js +0 -973
- package/lib.esm/providers/provider-jsonrpc.js.map +0 -1
- package/lib.esm/providers/provider-socket.d.ts +0 -113
- package/lib.esm/providers/provider-socket.d.ts.map +0 -1
- package/lib.esm/providers/provider-socket.js +0 -301
- package/lib.esm/providers/provider-socket.js.map +0 -1
- package/lib.esm/providers/provider-websocket.d.ts +0 -37
- package/lib.esm/providers/provider-websocket.d.ts.map +0 -1
- package/lib.esm/providers/provider-websocket.js +0 -76
- package/lib.esm/providers/provider-websocket.js.map +0 -1
- package/lib.esm/providers/provider.d.ts +0 -1223
- package/lib.esm/providers/provider.d.ts.map +0 -1
- package/lib.esm/providers/provider.js +0 -1312
- package/lib.esm/providers/provider.js.map +0 -1
- package/lib.esm/providers/signer-noncemanager.d.ts +0 -38
- package/lib.esm/providers/signer-noncemanager.d.ts.map +0 -1
- package/lib.esm/providers/signer-noncemanager.js +0 -74
- package/lib.esm/providers/signer-noncemanager.js.map +0 -1
- package/lib.esm/providers/signer.d.ts +0 -131
- package/lib.esm/providers/signer.d.ts.map +0 -1
- package/lib.esm/providers/signer.js +0 -2
- package/lib.esm/providers/signer.js.map +0 -1
- package/lib.esm/providers/subscriber-connection.d.ts +0 -25
- package/lib.esm/providers/subscriber-connection.d.ts.map +0 -1
- package/lib.esm/providers/subscriber-connection.js +0 -52
- package/lib.esm/providers/subscriber-connection.js.map +0 -1
- package/lib.esm/providers/subscriber-filterid.d.ts +0 -64
- package/lib.esm/providers/subscriber-filterid.d.ts.map +0 -1
- package/lib.esm/providers/subscriber-filterid.js +0 -174
- package/lib.esm/providers/subscriber-filterid.js.map +0 -1
- package/lib.esm/providers/subscriber-polling.d.ts +0 -100
- package/lib.esm/providers/subscriber-polling.d.ts.map +0 -1
- package/lib.esm/providers/subscriber-polling.js +0 -293
- package/lib.esm/providers/subscriber-polling.js.map +0 -1
- package/lib.esm/providers/ws-browser.d.ts +0 -3
- package/lib.esm/providers/ws-browser.d.ts.map +0 -1
- package/lib.esm/providers/ws-browser.js +0 -16
- package/lib.esm/providers/ws-browser.js.map +0 -1
- package/lib.esm/providers/ws.d.ts +0 -2
- package/lib.esm/providers/ws.d.ts.map +0 -1
- package/lib.esm/providers/ws.js +0 -2
- package/lib.esm/providers/ws.js.map +0 -1
- package/lib.esm/quantumcoin.d.ts +0 -24
- package/lib.esm/quantumcoin.d.ts.map +0 -1
- package/lib.esm/quantumcoin.js +0 -22
- package/lib.esm/quantumcoin.js.map +0 -1
- package/lib.esm/transaction/accesslist.d.ts +0 -6
- package/lib.esm/transaction/accesslist.d.ts.map +0 -1
- package/lib.esm/transaction/accesslist.js +0 -37
- package/lib.esm/transaction/accesslist.js.map +0 -1
- package/lib.esm/transaction/address.d.ts +0 -15
- package/lib.esm/transaction/address.d.ts.map +0 -1
- package/lib.esm/transaction/address.js +0 -34
- package/lib.esm/transaction/address.js.map +0 -1
- package/lib.esm/transaction/authorization.d.ts +0 -3
- package/lib.esm/transaction/authorization.d.ts.map +0 -1
- package/lib.esm/transaction/authorization.js +0 -12
- package/lib.esm/transaction/authorization.js.map +0 -1
- package/lib.esm/transaction/index.d.ts +0 -40
- package/lib.esm/transaction/index.d.ts.map +0 -1
- package/lib.esm/transaction/index.js +0 -11
- package/lib.esm/transaction/index.js.map +0 -1
- package/lib.esm/transaction/transaction.d.ts +0 -400
- package/lib.esm/transaction/transaction.d.ts.map +0 -1
- package/lib.esm/transaction/transaction.js +0 -1144
- package/lib.esm/transaction/transaction.js.map +0 -1
- package/lib.esm/utils/base58.d.ts +0 -23
- package/lib.esm/utils/base58.d.ts.map +0 -1
- package/lib.esm/utils/base58.js +0 -63
- package/lib.esm/utils/base58.js.map +0 -1
- package/lib.esm/utils/base64-browser.d.ts +0 -4
- package/lib.esm/utils/base64-browser.d.ts.map +0 -1
- package/lib.esm/utils/base64-browser.js +0 -19
- package/lib.esm/utils/base64-browser.js.map +0 -1
- package/lib.esm/utils/base64.d.ts +0 -40
- package/lib.esm/utils/base64.d.ts.map +0 -1
- package/lib.esm/utils/base64.js +0 -53
- package/lib.esm/utils/base64.js.map +0 -1
- package/lib.esm/utils/data.d.ts +0 -93
- package/lib.esm/utils/data.d.ts.map +0 -1
- package/lib.esm/utils/data.js +0 -170
- package/lib.esm/utils/data.js.map +0 -1
- package/lib.esm/utils/errors.d.ts +0 -512
- package/lib.esm/utils/errors.d.ts.map +0 -1
- package/lib.esm/utils/errors.js +0 -224
- package/lib.esm/utils/errors.js.map +0 -1
- package/lib.esm/utils/events.d.ts +0 -77
- package/lib.esm/utils/events.d.ts.map +0 -1
- package/lib.esm/utils/events.js +0 -42
- package/lib.esm/utils/events.js.map +0 -1
- package/lib.esm/utils/fetch.d.ts +0 -363
- package/lib.esm/utils/fetch.d.ts.map +0 -1
- package/lib.esm/utils/fetch.js +0 -852
- package/lib.esm/utils/fetch.js.map +0 -1
- package/lib.esm/utils/fixednumber.d.ts +0 -252
- package/lib.esm/utils/fixednumber.d.ts.map +0 -1
- package/lib.esm/utils/fixednumber.js +0 -526
- package/lib.esm/utils/fixednumber.js.map +0 -1
- package/lib.esm/utils/geturl-browser.d.ts +0 -4
- package/lib.esm/utils/geturl-browser.d.ts.map +0 -1
- package/lib.esm/utils/geturl-browser.js +0 -62
- package/lib.esm/utils/geturl-browser.js.map +0 -1
- package/lib.esm/utils/geturl.d.ts +0 -10
- package/lib.esm/utils/geturl.d.ts.map +0 -1
- package/lib.esm/utils/geturl.js +0 -114
- package/lib.esm/utils/geturl.js.map +0 -1
- package/lib.esm/utils/index.d.ts +0 -30
- package/lib.esm/utils/index.d.ts.map +0 -1
- package/lib.esm/utils/index.js +0 -22
- package/lib.esm/utils/index.js.map +0 -1
- package/lib.esm/utils/maths.d.ts +0 -66
- package/lib.esm/utils/maths.d.ts.map +0 -1
- package/lib.esm/utils/maths.js +0 -215
- package/lib.esm/utils/maths.js.map +0 -1
- package/lib.esm/utils/properties.d.ts +0 -23
- package/lib.esm/utils/properties.d.ts.map +0 -1
- package/lib.esm/utils/properties.js +0 -54
- package/lib.esm/utils/properties.js.map +0 -1
- package/lib.esm/utils/rlp-decode.d.ts +0 -6
- package/lib.esm/utils/rlp-decode.d.ts.map +0 -1
- package/lib.esm/utils/rlp-decode.js +0 -79
- package/lib.esm/utils/rlp-decode.js.map +0 -1
- package/lib.esm/utils/rlp-encode.d.ts +0 -6
- package/lib.esm/utils/rlp-encode.d.ts.map +0 -1
- package/lib.esm/utils/rlp-encode.js +0 -49
- package/lib.esm/utils/rlp-encode.js.map +0 -1
- package/lib.esm/utils/rlp.d.ts +0 -17
- package/lib.esm/utils/rlp.d.ts.map +0 -1
- package/lib.esm/utils/rlp.js +0 -9
- package/lib.esm/utils/rlp.js.map +0 -1
- package/lib.esm/utils/units.d.ts +0 -24
- package/lib.esm/utils/units.d.ts.map +0 -1
- package/lib.esm/utils/units.js +0 -83
- package/lib.esm/utils/units.js.map +0 -1
- package/lib.esm/utils/utf8.d.ts +0 -96
- package/lib.esm/utils/utf8.d.ts.map +0 -1
- package/lib.esm/utils/utf8.js +0 -221
- package/lib.esm/utils/utf8.js.map +0 -1
- package/lib.esm/utils/uuid.d.ts +0 -8
- package/lib.esm/utils/uuid.d.ts.map +0 -1
- package/lib.esm/utils/uuid.js +0 -30
- package/lib.esm/utils/uuid.js.map +0 -1
- package/lib.esm/wallet/base-wallet.d.ts +0 -57
- package/lib.esm/wallet/base-wallet.d.ts.map +0 -1
- package/lib.esm/wallet/base-wallet.js +0 -123
- package/lib.esm/wallet/base-wallet.js.map +0 -1
- package/lib.esm/wallet/index.d.ts +0 -23
- package/lib.esm/wallet/index.d.ts.map +0 -1
- package/lib.esm/wallet/index.js +0 -22
- package/lib.esm/wallet/index.js.map +0 -1
- package/lib.esm/wallet/json-keystore.d.ts +0 -40
- package/lib.esm/wallet/json-keystore.d.ts.map +0 -1
- package/lib.esm/wallet/json-keystore.js +0 -84
- package/lib.esm/wallet/json-keystore.js.map +0 -1
- package/lib.esm/wallet/utils.d.ts +0 -8
- package/lib.esm/wallet/utils.d.ts.map +0 -1
- package/lib.esm/wallet/utils.js +0 -142
- package/lib.esm/wallet/utils.js.map +0 -1
- package/lib.esm/wallet/wallet.d.ts +0 -62
- package/lib.esm/wallet/wallet.d.ts.map +0 -1
- package/lib.esm/wallet/wallet.js +0 -105
- package/lib.esm/wallet/wallet.js.map +0 -1
- package/lib.esm/wordlists/bit-reader.d.ts +0 -5
- package/lib.esm/wordlists/bit-reader.d.ts.map +0 -1
- package/lib.esm/wordlists/bit-reader.js +0 -32
- package/lib.esm/wordlists/bit-reader.js.map +0 -1
- package/lib.esm/wordlists/decode-owl.d.ts +0 -9
- package/lib.esm/wordlists/decode-owl.d.ts.map +0 -1
- package/lib.esm/wordlists/decode-owl.js +0 -55
- package/lib.esm/wordlists/decode-owl.js.map +0 -1
- package/lib.esm/wordlists/decode-owla.d.ts +0 -5
- package/lib.esm/wordlists/decode-owla.d.ts.map +0 -1
- package/lib.esm/wordlists/decode-owla.js +0 -28
- package/lib.esm/wordlists/decode-owla.js.map +0 -1
- package/lib.esm/wordlists/generation/encode-latin.d.ts +0 -25
- package/lib.esm/wordlists/generation/encode-latin.d.ts.map +0 -1
- package/lib.esm/wordlists/generation/encode-latin.js +0 -344
- package/lib.esm/wordlists/generation/encode-latin.js.map +0 -1
- package/lib.esm/wordlists/index.d.ts +0 -25
- package/lib.esm/wordlists/index.d.ts.map +0 -1
- package/lib.esm/wordlists/index.js +0 -25
- package/lib.esm/wordlists/index.js.map +0 -1
- package/lib.esm/wordlists/lang-cz.d.ts +0 -23
- package/lib.esm/wordlists/lang-cz.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-cz.js +0 -31
- package/lib.esm/wordlists/lang-cz.js.map +0 -1
- package/lib.esm/wordlists/lang-en.d.ts +0 -23
- package/lib.esm/wordlists/lang-en.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-en.js +0 -31
- package/lib.esm/wordlists/lang-en.js.map +0 -1
- package/lib.esm/wordlists/lang-es.d.ts +0 -23
- package/lib.esm/wordlists/lang-es.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-es.js +0 -32
- package/lib.esm/wordlists/lang-es.js.map +0 -1
- package/lib.esm/wordlists/lang-fr.d.ts +0 -23
- package/lib.esm/wordlists/lang-fr.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-fr.js +0 -32
- package/lib.esm/wordlists/lang-fr.js.map +0 -1
- package/lib.esm/wordlists/lang-it.d.ts +0 -23
- package/lib.esm/wordlists/lang-it.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-it.js +0 -31
- package/lib.esm/wordlists/lang-it.js.map +0 -1
- package/lib.esm/wordlists/lang-ja.d.ts +0 -27
- package/lib.esm/wordlists/lang-ja.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-ja.js +0 -154
- package/lib.esm/wordlists/lang-ja.js.map +0 -1
- package/lib.esm/wordlists/lang-ko.d.ts +0 -25
- package/lib.esm/wordlists/lang-ko.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-ko.js +0 -89
- package/lib.esm/wordlists/lang-ko.js.map +0 -1
- package/lib.esm/wordlists/lang-pt.d.ts +0 -23
- package/lib.esm/wordlists/lang-pt.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-pt.js +0 -31
- package/lib.esm/wordlists/lang-pt.js.map +0 -1
- package/lib.esm/wordlists/lang-zh.d.ts +0 -32
- package/lib.esm/wordlists/lang-zh.d.ts.map +0 -1
- package/lib.esm/wordlists/lang-zh.js +0 -92
- package/lib.esm/wordlists/lang-zh.js.map +0 -1
- package/lib.esm/wordlists/wordlist-owl.d.ts +0 -32
- package/lib.esm/wordlists/wordlist-owl.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlist-owl.js +0 -66
- package/lib.esm/wordlists/wordlist-owl.js.map +0 -1
- package/lib.esm/wordlists/wordlist-owla.d.ts +0 -30
- package/lib.esm/wordlists/wordlist-owla.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlist-owla.js +0 -36
- package/lib.esm/wordlists/wordlist-owla.js.map +0 -1
- package/lib.esm/wordlists/wordlist.d.ts +0 -47
- package/lib.esm/wordlists/wordlist.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlist.js +0 -42
- package/lib.esm/wordlists/wordlist.js.map +0 -1
- package/lib.esm/wordlists/wordlists-browser.d.ts +0 -3
- package/lib.esm/wordlists/wordlists-browser.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlists-browser.js +0 -5
- package/lib.esm/wordlists/wordlists-browser.js.map +0 -1
- package/lib.esm/wordlists/wordlists-extra.d.ts +0 -9
- package/lib.esm/wordlists/wordlists-extra.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlists-extra.js +0 -9
- package/lib.esm/wordlists/wordlists-extra.js.map +0 -1
- package/lib.esm/wordlists/wordlists.d.ts +0 -16
- package/lib.esm/wordlists/wordlists.d.ts.map +0 -1
- package/lib.esm/wordlists/wordlists.js +0 -35
- package/lib.esm/wordlists/wordlists.js.map +0 -1
- package/rollup.config.mjs +0 -50
- package/src.ts/_version.ts +0 -6
- package/src.ts/abi/abi-coder.ts +0 -237
- package/src.ts/abi/bytes32.ts +0 -45
- package/src.ts/abi/coders/abstract-coder.ts +0 -541
- package/src.ts/abi/coders/address.ts +0 -36
- package/src.ts/abi/coders/anonymous.ts +0 -29
- package/src.ts/abi/coders/array.ts +0 -199
- package/src.ts/abi/coders/boolean.ts +0 -27
- package/src.ts/abi/coders/bytes.ts +0 -43
- package/src.ts/abi/coders/fixed-bytes.ts +0 -37
- package/src.ts/abi/coders/null.ts +0 -28
- package/src.ts/abi/coders/number.ts +0 -63
- package/src.ts/abi/coders/string.ts +0 -29
- package/src.ts/abi/coders/tuple.ts +0 -69
- package/src.ts/abi/fragments.ts +0 -1617
- package/src.ts/abi/index.ts +0 -41
- package/src.ts/abi/interface.ts +0 -1271
- package/src.ts/abi/typed.ts +0 -796
- package/src.ts/address/address.ts +0 -148
- package/src.ts/address/checks.ts +0 -123
- package/src.ts/address/contract-address.ts +0 -80
- package/src.ts/address/index.ts +0 -57
- package/src.ts/constants/addresses.ts +0 -8
- package/src.ts/constants/hashes.ts +0 -7
- package/src.ts/constants/index.ts +0 -16
- package/src.ts/constants/numbers.ts +0 -35
- package/src.ts/constants/strings.ts +0 -16
- package/src.ts/contract/contract.ts +0 -1120
- package/src.ts/contract/factory.ts +0 -143
- package/src.ts/contract/index.ts +0 -31
- package/src.ts/contract/types.ts +0 -236
- package/src.ts/contract/wrappers.ts +0 -225
- package/src.ts/crypto/crypto-browser.ts +0 -64
- package/src.ts/crypto/crypto.ts +0 -4
- package/src.ts/crypto/hmac.ts +0 -51
- package/src.ts/crypto/index.ts +0 -59
- package/src.ts/crypto/keccak.ts +0 -54
- package/src.ts/crypto/pbkdf2.ts +0 -55
- package/src.ts/crypto/random.ts +0 -36
- package/src.ts/crypto/ripemd160.ts +0 -43
- package/src.ts/crypto/scrypt.ts +0 -114
- package/src.ts/crypto/sha2.ts +0 -78
- package/src.ts/crypto/signature.ts +0 -349
- package/src.ts/crypto/signing-key.ts +0 -123
- package/src.ts/hash/authorization.ts +0 -38
- package/src.ts/hash/id.ts +0 -17
- package/src.ts/hash/index.ts +0 -18
- package/src.ts/hash/message.ts +0 -51
- package/src.ts/hash/namehash.ts +0 -101
- package/src.ts/hash/solidity.ts +0 -117
- package/src.ts/hash/typed-data.ts +0 -658
- package/src.ts/index.ts +0 -12
- package/src.ts/providers/abstract-provider.ts +0 -1761
- package/src.ts/providers/abstract-signer.ts +0 -314
- package/src.ts/providers/community.ts +0 -49
- package/src.ts/providers/contracts.ts +0 -42
- package/src.ts/providers/default-provider.ts +0 -96
- package/src.ts/providers/ens-resolver.ts +0 -606
- package/src.ts/providers/format.ts +0 -320
- package/src.ts/providers/formatting.ts +0 -418
- package/src.ts/providers/index.ts +0 -125
- package/src.ts/providers/network.ts +0 -327
- package/src.ts/providers/pagination.ts +0 -8
- package/src.ts/providers/plugin-fallback.ts +0 -35
- package/src.ts/providers/plugins-network.ts +0 -281
- package/src.ts/providers/provider-browser.ts +0 -334
- package/src.ts/providers/provider-fallback.ts +0 -801
- package/src.ts/providers/provider-ipcsocket-browser.ts +0 -3
- package/src.ts/providers/provider-ipcsocket.ts +0 -81
- package/src.ts/providers/provider-jsonrpc.ts +0 -1335
- package/src.ts/providers/provider-socket.ts +0 -352
- package/src.ts/providers/provider-websocket.ts +0 -103
- package/src.ts/providers/provider.ts +0 -2136
- package/src.ts/providers/signer-noncemanager.ts +0 -98
- package/src.ts/providers/signer.ts +0 -166
- package/src.ts/providers/subscriber-connection.ts +0 -74
- package/src.ts/providers/subscriber-filterid.ts +0 -199
- package/src.ts/providers/subscriber-polling.ts +0 -321
- package/src.ts/providers/ws-browser.ts +0 -11
- package/src.ts/providers/ws.ts +0 -3
- package/src.ts/quantumcoin.ts +0 -219
- package/src.ts/thirdparty.d.ts +0 -16
- package/src.ts/transaction/accesslist.ts +0 -43
- package/src.ts/transaction/address.ts +0 -35
- package/src.ts/transaction/authorization.ts +0 -14
- package/src.ts/transaction/index.ts +0 -51
- package/src.ts/transaction/transaction.ts +0 -1379
- package/src.ts/utils/base58.ts +0 -73
- package/src.ts/utils/base64-browser.ts +0 -25
- package/src.ts/utils/base64.ts +0 -56
- package/src.ts/utils/data.ts +0 -199
- package/src.ts/utils/errors.ts +0 -793
- package/src.ts/utils/events.ts +0 -105
- package/src.ts/utils/fetch.ts +0 -970
- package/src.ts/utils/fixednumber.ts +0 -643
- package/src.ts/utils/geturl-browser.ts +0 -81
- package/src.ts/utils/geturl.ts +0 -134
- package/src.ts/utils/index.ts +0 -95
- package/src.ts/utils/maths.ts +0 -240
- package/src.ts/utils/properties.ts +0 -60
- package/src.ts/utils/rlp-decode.ts +0 -104
- package/src.ts/utils/rlp-encode.ts +0 -64
- package/src.ts/utils/rlp.ts +0 -20
- package/src.ts/utils/test.txt +0 -0
- package/src.ts/utils/units.ts +0 -91
- package/src.ts/utils/utf8.ts +0 -325
- package/src.ts/utils/uuid.ts +0 -36
- package/src.ts/wallet/base-wallet.ts +0 -160
- package/src.ts/wallet/index.ts +0 -32
- package/src.ts/wallet/json-keystore.ts +0 -108
- package/src.ts/wallet/utils.ts +0 -147
- package/src.ts/wallet/wallet.ts +0 -138
- package/src.ts/wordlists/bit-reader.ts +0 -35
- package/src.ts/wordlists/decode-owl.ts +0 -58
- package/src.ts/wordlists/decode-owla.ts +0 -33
- package/src.ts/wordlists/generation/encode-latin.ts +0 -370
- package/src.ts/wordlists/index.ts +0 -26
- package/src.ts/wordlists/lang-cz.ts +0 -33
- package/src.ts/wordlists/lang-en.ts +0 -33
- package/src.ts/wordlists/lang-es.ts +0 -35
- package/src.ts/wordlists/lang-fr.ts +0 -34
- package/src.ts/wordlists/lang-it.ts +0 -33
- package/src.ts/wordlists/lang-ja.ts +0 -181
- package/src.ts/wordlists/lang-ko.ts +0 -104
- package/src.ts/wordlists/lang-pt.ts +0 -34
- package/src.ts/wordlists/lang-zh.ts +0 -112
- package/src.ts/wordlists/wordlist-owl.ts +0 -77
- package/src.ts/wordlists/wordlist-owla.ts +0 -41
- package/src.ts/wordlists/wordlist.ts +0 -59
- package/src.ts/wordlists/wordlists-browser.ts +0 -8
- package/src.ts/wordlists/wordlists-extra.ts +0 -9
- package/src.ts/wordlists/wordlists.ts +0 -38
|
@@ -1,145 +0,0 @@
|
|
|
1
|
-
import type { BigNumberish, BytesLike } from "../utils/index.js";
|
|
2
|
-
/**
|
|
3
|
-
* A SignatureLike
|
|
4
|
-
*
|
|
5
|
-
* @_docloc: api/crypto:Signing
|
|
6
|
-
*/
|
|
7
|
-
export type SignatureLike = Signature | string | {
|
|
8
|
-
r: string;
|
|
9
|
-
s: string;
|
|
10
|
-
v: BigNumberish;
|
|
11
|
-
} | {
|
|
12
|
-
r: string;
|
|
13
|
-
s?: string;
|
|
14
|
-
v?: number;
|
|
15
|
-
} | {
|
|
16
|
-
r: string;
|
|
17
|
-
s: string;
|
|
18
|
-
v?: BigNumberish;
|
|
19
|
-
};
|
|
20
|
-
/**
|
|
21
|
-
* A Signature @TODO
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
* @_docloc: api/crypto:Signing
|
|
25
|
-
*/
|
|
26
|
-
export declare class Signature {
|
|
27
|
-
#private;
|
|
28
|
-
/**
|
|
29
|
-
* The ``r`` value for a signature.
|
|
30
|
-
*
|
|
31
|
-
* This represents the ``x`` coordinate of a "reference" or
|
|
32
|
-
* challenge point, from which the ``y`` can be computed.
|
|
33
|
-
*/
|
|
34
|
-
get r(): string;
|
|
35
|
-
set r(value: BytesLike);
|
|
36
|
-
/**
|
|
37
|
-
* The ``s`` value for a signature.
|
|
38
|
-
*/
|
|
39
|
-
get s(): string;
|
|
40
|
-
set s(_value: BytesLike);
|
|
41
|
-
/**
|
|
42
|
-
* The ``v`` value for a signature.
|
|
43
|
-
*
|
|
44
|
-
* Since a given ``x`` value for ``r`` has two possible values for
|
|
45
|
-
* its correspondin ``y``, the ``v`` indicates which of the two ``y``
|
|
46
|
-
* values to use.
|
|
47
|
-
*
|
|
48
|
-
* It is normalized to the values ``28`` or ``28`` for legacy
|
|
49
|
-
* purposes.
|
|
50
|
-
*/
|
|
51
|
-
get v(): 28 | 28;
|
|
52
|
-
set v(value: BigNumberish);
|
|
53
|
-
/**
|
|
54
|
-
* The EIP-155 ``v`` for legacy transactions. For non-legacy
|
|
55
|
-
* transactions, this value is ``null``.
|
|
56
|
-
*/
|
|
57
|
-
get networkV(): null | bigint;
|
|
58
|
-
/**
|
|
59
|
-
* The chain ID for EIP-155 legacy transactions. For non-legacy
|
|
60
|
-
* transactions, this value is ``null``.
|
|
61
|
-
*/
|
|
62
|
-
get legacyChainId(): null | bigint;
|
|
63
|
-
/**
|
|
64
|
-
* The ``yParity`` for the signature.
|
|
65
|
-
*
|
|
66
|
-
* See ``v`` for more details on how this value is used.
|
|
67
|
-
*/
|
|
68
|
-
get yParity(): 0 | 1;
|
|
69
|
-
/**
|
|
70
|
-
* The [[link-eip-2098]] compact representation of the ``yParity``
|
|
71
|
-
* and ``s`` compacted into a single ``bytes32``.
|
|
72
|
-
*/
|
|
73
|
-
get yParityAndS(): string;
|
|
74
|
-
/**
|
|
75
|
-
* The [[link-eip-2098]] compact representation.
|
|
76
|
-
*/
|
|
77
|
-
get compactSerialized(): string;
|
|
78
|
-
/**
|
|
79
|
-
* The serialized representation.
|
|
80
|
-
*/
|
|
81
|
-
get serialized(): string;
|
|
82
|
-
/**
|
|
83
|
-
* @private
|
|
84
|
-
*/
|
|
85
|
-
constructor(guard: any, r: string, s: string, v: 28);
|
|
86
|
-
/**
|
|
87
|
-
* Returns a new identical [[Signature]].
|
|
88
|
-
*/
|
|
89
|
-
clone(): Signature;
|
|
90
|
-
/**
|
|
91
|
-
* Returns a representation that is compatible with ``JSON.stringify``.
|
|
92
|
-
*/
|
|
93
|
-
toJSON(): any;
|
|
94
|
-
/**
|
|
95
|
-
* Compute the chain ID from the ``v`` in a legacy EIP-155 transactions.
|
|
96
|
-
*
|
|
97
|
-
* @example:
|
|
98
|
-
* Signature.getChainId(45)
|
|
99
|
-
* //_result:
|
|
100
|
-
*
|
|
101
|
-
* Signature.getChainId(46)
|
|
102
|
-
* //_result:
|
|
103
|
-
*/
|
|
104
|
-
static getChainId(v: BigNumberish): bigint;
|
|
105
|
-
/**
|
|
106
|
-
* Compute the ``v`` for a chain ID for a legacy EIP-155 transactions.
|
|
107
|
-
*
|
|
108
|
-
* Legacy transactions which use [[link-eip-155]] hijack the ``v``
|
|
109
|
-
* property to include the chain ID.
|
|
110
|
-
*
|
|
111
|
-
* @example:
|
|
112
|
-
*
|
|
113
|
-
* Signature.getChainIdV(5, 28)
|
|
114
|
-
* //_result:
|
|
115
|
-
*
|
|
116
|
-
*/
|
|
117
|
-
static getChainIdV(chainId: BigNumberish, v: 28): bigint;
|
|
118
|
-
/**
|
|
119
|
-
* Compute the normalized legacy transaction ``v`` from a ``yParirty``,
|
|
120
|
-
* a legacy transaction ``v`` or a legacy [[link-eip-155]] transaction.
|
|
121
|
-
*
|
|
122
|
-
* @example:
|
|
123
|
-
* // The values 0 and 1 imply v is actually yParity
|
|
124
|
-
* Signature.getNormalizedV(0)
|
|
125
|
-
* //_result:
|
|
126
|
-
*
|
|
127
|
-
* // Legacy EIP-155 transaction (i.e. >= 35)
|
|
128
|
-
* Signature.getNormalizedV(46)
|
|
129
|
-
* //_result:
|
|
130
|
-
*
|
|
131
|
-
* // Invalid values throw
|
|
132
|
-
* Signature.getNormalizedV(5)
|
|
133
|
-
* //_error:
|
|
134
|
-
*/
|
|
135
|
-
/**
|
|
136
|
-
* Creates a new [[Signature]].
|
|
137
|
-
*
|
|
138
|
-
* If no %%sig%% is provided, a new [[Signature]] is created
|
|
139
|
-
* with default values.
|
|
140
|
-
*
|
|
141
|
-
* If %%sig%% is a string, it is parsed.
|
|
142
|
-
*/
|
|
143
|
-
static from(sig?: SignatureLike): Signature;
|
|
144
|
-
}
|
|
145
|
-
//# sourceMappingURL=signature.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"signature.d.ts","sourceRoot":"","sources":["../../src.ts/crypto/signature.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAER,YAAY,EAAE,SAAS,EAC1B,MAAM,mBAAmB,CAAC;AAe3B;;;;GAIG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,MAAM,GAAG;IAC7C,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,YAAY,CAAC;CACnB,GAAG;IACA,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,CAAC,CAAC,EAAE,MAAM,CAAC;CACd,GAAG;IACA,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,CAAC,EAAE,YAAY,CAAC;CACpB,CAAC;AAMF;;;;;GAKG;AACH,qBAAa,SAAS;;IAMlB;;;;;OAKG;IACH,IAAI,CAAC,IAAI,MAAM,CAAoB;IACnC,IAAI,CAAC,CAAC,KAAK,EAAE,SAAS,EAErB;IAED;;OAEG;IACH,IAAI,CAAC,IAAI,MAAM,CAAoB;IACnC,IAAI,CAAC,CAAC,MAAM,EAAE,SAAS,EAGtB;IAED;;;;;;;;;OASG;IACH,IAAI,CAAC,IAAI,EAAE,GAAG,EAAE,CAAoB;IACpC,IAAI,CAAC,CAAC,KAAK,EAAE,YAAY,EAIxB;IAED;;;OAGG;IACH,IAAI,QAAQ,IAAI,IAAI,GAAG,MAAM,CAA2B;IAExD;;;OAGG;IACH,IAAI,aAAa,IAAI,IAAI,GAAG,MAAM,CAIjC;IAED;;;;OAIG;IACH,IAAI,OAAO,IAAI,CAAC,GAAG,CAAC,CAEnB;IAED;;;OAGG;IACH,IAAI,WAAW,IAAI,MAAM,CAKxB;IAED;;OAEG;IACH,IAAI,iBAAiB,IAAI,MAAM,CAE9B;IAED;;OAEG;IACH,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED;;OAEG;gBACS,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,EAAE;IAYnD;;OAEG;IACH,KAAK,IAAI,SAAS;IAMlB;;OAEG;IACH,MAAM,IAAI,GAAG;IASb;;;;;;;;;OASG;IACH,MAAM,CAAC,UAAU,CAAC,CAAC,EAAE,YAAY,GAAG,MAAM;IAY1C;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,YAAY,EAAE,CAAC,EAAE,EAAE,GAAG,MAAM;IAIxD;;;;;;;;;;;;;;;;OAgBG;IAYH;;;;;;;OAOG;IACH,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,aAAa,GAAG,SAAS;CAyF9C"}
|
|
@@ -1,302 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Signature = void 0;
|
|
4
|
-
const index_js_1 = require("../constants/index.js");
|
|
5
|
-
const index_js_2 = require("../utils/index.js");
|
|
6
|
-
// Constants
|
|
7
|
-
const BN_0 = BigInt(0);
|
|
8
|
-
//const BN_1 = BigInt(1);
|
|
9
|
-
const BN_2 = BigInt(2);
|
|
10
|
-
const BN_28 = BigInt(28);
|
|
11
|
-
const BN_35 = BigInt(35);
|
|
12
|
-
const _guard = {};
|
|
13
|
-
/*
|
|
14
|
-
function toUint256(value: BigNumberish): string {
|
|
15
|
-
return zeroPadValue(toBeArray(value), 32);
|
|
16
|
-
}*/
|
|
17
|
-
/**
|
|
18
|
-
* A Signature @TODO
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
* @_docloc: api/crypto:Signing
|
|
22
|
-
*/
|
|
23
|
-
class Signature {
|
|
24
|
-
#r;
|
|
25
|
-
#s;
|
|
26
|
-
#v;
|
|
27
|
-
#networkV;
|
|
28
|
-
/**
|
|
29
|
-
* The ``r`` value for a signature.
|
|
30
|
-
*
|
|
31
|
-
* This represents the ``x`` coordinate of a "reference" or
|
|
32
|
-
* challenge point, from which the ``y`` can be computed.
|
|
33
|
-
*/
|
|
34
|
-
get r() { return this.#r; }
|
|
35
|
-
set r(value) {
|
|
36
|
-
this.#r = (0, index_js_2.hexlify)(value);
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* The ``s`` value for a signature.
|
|
40
|
-
*/
|
|
41
|
-
get s() { return this.#s; }
|
|
42
|
-
set s(_value) {
|
|
43
|
-
const value = (0, index_js_2.hexlify)(_value);
|
|
44
|
-
this.#s = value;
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* The ``v`` value for a signature.
|
|
48
|
-
*
|
|
49
|
-
* Since a given ``x`` value for ``r`` has two possible values for
|
|
50
|
-
* its correspondin ``y``, the ``v`` indicates which of the two ``y``
|
|
51
|
-
* values to use.
|
|
52
|
-
*
|
|
53
|
-
* It is normalized to the values ``28`` or ``28`` for legacy
|
|
54
|
-
* purposes.
|
|
55
|
-
*/
|
|
56
|
-
get v() { return this.#v; }
|
|
57
|
-
set v(value) {
|
|
58
|
-
const v = (0, index_js_2.getNumber)(value, "value");
|
|
59
|
-
(0, index_js_2.assertArgument)(v === 28, "invalid v", "v", value);
|
|
60
|
-
this.#v = v;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* The EIP-155 ``v`` for legacy transactions. For non-legacy
|
|
64
|
-
* transactions, this value is ``null``.
|
|
65
|
-
*/
|
|
66
|
-
get networkV() { return this.#networkV; }
|
|
67
|
-
/**
|
|
68
|
-
* The chain ID for EIP-155 legacy transactions. For non-legacy
|
|
69
|
-
* transactions, this value is ``null``.
|
|
70
|
-
*/
|
|
71
|
-
get legacyChainId() {
|
|
72
|
-
const v = this.networkV;
|
|
73
|
-
if (v == null) {
|
|
74
|
-
return null;
|
|
75
|
-
}
|
|
76
|
-
return Signature.getChainId(v);
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* The ``yParity`` for the signature.
|
|
80
|
-
*
|
|
81
|
-
* See ``v`` for more details on how this value is used.
|
|
82
|
-
*/
|
|
83
|
-
get yParity() {
|
|
84
|
-
return (this.v === 28) ? 0 : 1;
|
|
85
|
-
}
|
|
86
|
-
/**
|
|
87
|
-
* The [[link-eip-2098]] compact representation of the ``yParity``
|
|
88
|
-
* and ``s`` compacted into a single ``bytes32``.
|
|
89
|
-
*/
|
|
90
|
-
get yParityAndS() {
|
|
91
|
-
// The EIP-2098 compact representation
|
|
92
|
-
const yParityAndS = (0, index_js_2.getBytes)(this.s);
|
|
93
|
-
if (this.yParity) {
|
|
94
|
-
yParityAndS[0] |= 0x80;
|
|
95
|
-
}
|
|
96
|
-
return (0, index_js_2.hexlify)(yParityAndS);
|
|
97
|
-
}
|
|
98
|
-
/**
|
|
99
|
-
* The [[link-eip-2098]] compact representation.
|
|
100
|
-
*/
|
|
101
|
-
get compactSerialized() {
|
|
102
|
-
return (0, index_js_2.concat)([this.r, this.yParityAndS]);
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* The serialized representation.
|
|
106
|
-
*/
|
|
107
|
-
get serialized() {
|
|
108
|
-
return (0, index_js_2.concat)([this.r, this.s, (this.yParity ? "0x1c" : "0x1b")]);
|
|
109
|
-
}
|
|
110
|
-
/**
|
|
111
|
-
* @private
|
|
112
|
-
*/
|
|
113
|
-
constructor(guard, r, s, v) {
|
|
114
|
-
(0, index_js_2.assertPrivate)(guard, _guard, "Signature");
|
|
115
|
-
this.#r = r;
|
|
116
|
-
this.#s = s;
|
|
117
|
-
this.#v = v;
|
|
118
|
-
this.#networkV = null;
|
|
119
|
-
}
|
|
120
|
-
[Symbol.for('nodejs.util.inspect.custom')]() {
|
|
121
|
-
return `Signature { r: "${this.r}", s: "${this.s}", yParity: ${this.yParity}, networkV: ${this.networkV} }`;
|
|
122
|
-
}
|
|
123
|
-
/**
|
|
124
|
-
* Returns a new identical [[Signature]].
|
|
125
|
-
*/
|
|
126
|
-
clone() {
|
|
127
|
-
const clone = new Signature(_guard, this.r, this.s, this.v);
|
|
128
|
-
if (this.networkV) {
|
|
129
|
-
clone.#networkV = this.networkV;
|
|
130
|
-
}
|
|
131
|
-
return clone;
|
|
132
|
-
}
|
|
133
|
-
/**
|
|
134
|
-
* Returns a representation that is compatible with ``JSON.stringify``.
|
|
135
|
-
*/
|
|
136
|
-
toJSON() {
|
|
137
|
-
const networkV = this.networkV;
|
|
138
|
-
return {
|
|
139
|
-
_type: "signature",
|
|
140
|
-
networkV: ((networkV != null) ? networkV.toString() : null),
|
|
141
|
-
r: this.r, s: this.s, v: this.v,
|
|
142
|
-
};
|
|
143
|
-
}
|
|
144
|
-
/**
|
|
145
|
-
* Compute the chain ID from the ``v`` in a legacy EIP-155 transactions.
|
|
146
|
-
*
|
|
147
|
-
* @example:
|
|
148
|
-
* Signature.getChainId(45)
|
|
149
|
-
* //_result:
|
|
150
|
-
*
|
|
151
|
-
* Signature.getChainId(46)
|
|
152
|
-
* //_result:
|
|
153
|
-
*/
|
|
154
|
-
static getChainId(v) {
|
|
155
|
-
const bv = (0, index_js_2.getBigInt)(v, "v");
|
|
156
|
-
// The v is not an EIP-155 v, so it is the unspecified chain ID
|
|
157
|
-
if ((bv == BN_28) || (bv == BN_28)) {
|
|
158
|
-
return BN_0;
|
|
159
|
-
}
|
|
160
|
-
// Bad value for an EIP-155 v
|
|
161
|
-
(0, index_js_2.assertArgument)(bv >= BN_35, "invalid EIP-155 v", "v", v);
|
|
162
|
-
return (bv - BN_35) / BN_2;
|
|
163
|
-
}
|
|
164
|
-
/**
|
|
165
|
-
* Compute the ``v`` for a chain ID for a legacy EIP-155 transactions.
|
|
166
|
-
*
|
|
167
|
-
* Legacy transactions which use [[link-eip-155]] hijack the ``v``
|
|
168
|
-
* property to include the chain ID.
|
|
169
|
-
*
|
|
170
|
-
* @example:
|
|
171
|
-
*
|
|
172
|
-
* Signature.getChainIdV(5, 28)
|
|
173
|
-
* //_result:
|
|
174
|
-
*
|
|
175
|
-
*/
|
|
176
|
-
static getChainIdV(chainId, v) {
|
|
177
|
-
return ((0, index_js_2.getBigInt)(chainId) * BN_2) + BigInt(35 + v - 28);
|
|
178
|
-
}
|
|
179
|
-
/**
|
|
180
|
-
* Compute the normalized legacy transaction ``v`` from a ``yParirty``,
|
|
181
|
-
* a legacy transaction ``v`` or a legacy [[link-eip-155]] transaction.
|
|
182
|
-
*
|
|
183
|
-
* @example:
|
|
184
|
-
* // The values 0 and 1 imply v is actually yParity
|
|
185
|
-
* Signature.getNormalizedV(0)
|
|
186
|
-
* //_result:
|
|
187
|
-
*
|
|
188
|
-
* // Legacy EIP-155 transaction (i.e. >= 35)
|
|
189
|
-
* Signature.getNormalizedV(46)
|
|
190
|
-
* //_result:
|
|
191
|
-
*
|
|
192
|
-
* // Invalid values throw
|
|
193
|
-
* Signature.getNormalizedV(5)
|
|
194
|
-
* //_error:
|
|
195
|
-
*/
|
|
196
|
-
/*static getNormalizedV(v: BigNumberish): 28 {
|
|
197
|
-
const bv = getBigInt(v);
|
|
198
|
-
|
|
199
|
-
if (bv === BN_1 || bv === BN_28) { return 28; }
|
|
200
|
-
|
|
201
|
-
assertArgument(bv >= BN_35, "invalid v", "v", v);
|
|
202
|
-
|
|
203
|
-
// Otherwise, EIP-155 v means odd is 28 and even is 28
|
|
204
|
-
return (bv & BN_1) ? 28: 28;
|
|
205
|
-
}*/
|
|
206
|
-
/**
|
|
207
|
-
* Creates a new [[Signature]].
|
|
208
|
-
*
|
|
209
|
-
* If no %%sig%% is provided, a new [[Signature]] is created
|
|
210
|
-
* with default values.
|
|
211
|
-
*
|
|
212
|
-
* If %%sig%% is a string, it is parsed.
|
|
213
|
-
*/
|
|
214
|
-
static from(sig) {
|
|
215
|
-
function assertError(check, message) {
|
|
216
|
-
(0, index_js_2.assertArgument)(check, message, "signature", sig);
|
|
217
|
-
}
|
|
218
|
-
;
|
|
219
|
-
if (sig == null) {
|
|
220
|
-
return new Signature(_guard, index_js_1.ZeroHash, index_js_1.ZeroHash, 28);
|
|
221
|
-
}
|
|
222
|
-
if (typeof (sig) === "string") {
|
|
223
|
-
/*const bytes = getBytes(sig, "signature");
|
|
224
|
-
if (bytes.length === 64) {
|
|
225
|
-
const r = hexlify(bytes.slice(0, 32));
|
|
226
|
-
const s = bytes.slice(32, 64);
|
|
227
|
-
const v = (s[0] & 0x80) ? 28: 28;
|
|
228
|
-
s[0] &= 0x7f;
|
|
229
|
-
return new Signature(_guard, r, hexlify(s), v);
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
if (bytes.length === 65) {
|
|
233
|
-
const r = hexlify(bytes.slice(0, 32));
|
|
234
|
-
const s = bytes.slice(32, 64);
|
|
235
|
-
assertError((s[0] & 0x80) === 0, "non-canonical s");
|
|
236
|
-
const v = Signature.getNormalizedV(bytes[64]);
|
|
237
|
-
return new Signature(_guard, r, hexlify(s), v);
|
|
238
|
-
}*/
|
|
239
|
-
assertError(false, "invalid raw signature length");
|
|
240
|
-
}
|
|
241
|
-
if (sig instanceof Signature) {
|
|
242
|
-
return sig.clone();
|
|
243
|
-
}
|
|
244
|
-
return new Signature(_guard, index_js_1.ZeroHash, index_js_1.ZeroHash, 28); //todo
|
|
245
|
-
/*// Get r
|
|
246
|
-
const _r = sig.r;
|
|
247
|
-
assertError(_r != null, "missing r");
|
|
248
|
-
const r = toUint256(_r);
|
|
249
|
-
|
|
250
|
-
// Get s; by any means necessary (we check consistency below)
|
|
251
|
-
const s = (function(s?: string, yParityAndS?: string) {
|
|
252
|
-
if (s != null) { return toUint256(s); }
|
|
253
|
-
|
|
254
|
-
if (yParityAndS != null) {
|
|
255
|
-
assertError(isHexString(yParityAndS, 32), "invalid yParityAndS");
|
|
256
|
-
const bytes = getBytes(yParityAndS);
|
|
257
|
-
bytes[0] &= 0x7f;
|
|
258
|
-
return hexlify(bytes);
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
assertError(false, "missing s");
|
|
262
|
-
})(sig.s, sig.yParityAndS);
|
|
263
|
-
assertError((getBytes(s)[0] & 0x80) == 0, "non-canonical s");
|
|
264
|
-
|
|
265
|
-
// Get v; by any means necessary (we check consistency below)
|
|
266
|
-
const { networkV, v } = (function(_v?: BigNumberish, yParityAndS?: string, yParity?: Numeric): { networkV?: bigint, v: 28 | 28 } {
|
|
267
|
-
if (_v != null) {
|
|
268
|
-
const v = getBigInt(_v);
|
|
269
|
-
return {
|
|
270
|
-
networkV: ((v >= BN_35) ? v: undefined),
|
|
271
|
-
v: Signature.getNormalizedV(v)
|
|
272
|
-
};
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
if (yParityAndS != null) {
|
|
276
|
-
assertError(isHexString(yParityAndS, 32), "invalid yParityAndS");
|
|
277
|
-
return { v: ((getBytes(yParityAndS)[0] & 0x80) ? 28: 28) };
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
if (yParity != null) {
|
|
281
|
-
switch (getNumber(yParity, "sig.yParity")) {
|
|
282
|
-
case 0: return { v: 28 };
|
|
283
|
-
case 1: return { v: 28 };
|
|
284
|
-
}
|
|
285
|
-
assertError(false, "invalid yParity");
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
assertError(false, "missing v");
|
|
289
|
-
})(sig.v, sig.yParityAndS, sig.yParity);
|
|
290
|
-
|
|
291
|
-
const result = new Signature(_guard, r, s, v);
|
|
292
|
-
if (networkV) { result.#networkV = networkV; }
|
|
293
|
-
|
|
294
|
-
// If multiple of v, yParity, yParityAndS we given, check they match
|
|
295
|
-
assertError(sig.yParity == null || getNumber(sig.yParity, "sig.yParity") === result.yParity, "yParity mismatch");
|
|
296
|
-
assertError(sig.yParityAndS == null || sig.yParityAndS === result.yParityAndS, "yParityAndS mismatch");
|
|
297
|
-
|
|
298
|
-
return result;*/
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
exports.Signature = Signature;
|
|
302
|
-
//# sourceMappingURL=signature.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"signature.js","sourceRoot":"","sources":["../../src.ts/crypto/signature.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Add details about signing here.
|
|
3
|
-
*
|
|
4
|
-
* @_subsection: api/crypto:Signing [about-signing]
|
|
5
|
-
*/
|
|
6
|
-
import { Signature } from "./signature.js";
|
|
7
|
-
import type { BytesLike } from "../utils/index.js";
|
|
8
|
-
import type { SignatureLike } from "./index.js";
|
|
9
|
-
/**
|
|
10
|
-
* A **SigningKey** provides high-level access to cryptography operations and key management.
|
|
11
|
-
*/
|
|
12
|
-
export declare class SigningKey {
|
|
13
|
-
#private;
|
|
14
|
-
/**
|
|
15
|
-
* Creates a new **SigningKey** for %%privateKey%%.
|
|
16
|
-
*/
|
|
17
|
-
constructor(privateKey: BytesLike);
|
|
18
|
-
/**
|
|
19
|
-
* The private key.
|
|
20
|
-
*/
|
|
21
|
-
get privateKey(): string;
|
|
22
|
-
/**
|
|
23
|
-
* The public key.
|
|
24
|
-
*
|
|
25
|
-
*/
|
|
26
|
-
get publicKey(): string;
|
|
27
|
-
/**
|
|
28
|
-
* Return the signature of the signed %%digest%%.
|
|
29
|
-
*/
|
|
30
|
-
sign(digest: BytesLike): Signature;
|
|
31
|
-
/**
|
|
32
|
-
* Compute the public key for a private %%key%%. If a publicKey is passed, it is returned as is. for backward compatibility.
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
* @example:
|
|
36
|
-
* sign = new SigningKey(id("some-secret"));
|
|
37
|
-
*
|
|
38
|
-
* // Compute the public key for a private key
|
|
39
|
-
* SigningKey.computePublicKey(sign.privateKey)
|
|
40
|
-
* //_result:
|
|
41
|
-
*/
|
|
42
|
-
static computePublicKey(key: BytesLike): string;
|
|
43
|
-
/**
|
|
44
|
-
* Returns the public key for the private key which produced the
|
|
45
|
-
* %%signature%% for the given %%digest%%.
|
|
46
|
-
*
|
|
47
|
-
* @example:
|
|
48
|
-
* key = new SigningKey(id("some-secret"))
|
|
49
|
-
* digest = id("hello world")
|
|
50
|
-
* sig = key.sign(digest)
|
|
51
|
-
*
|
|
52
|
-
* // Notice the signer public key...
|
|
53
|
-
* key.publicKey
|
|
54
|
-
* //_result:
|
|
55
|
-
*
|
|
56
|
-
* // ...is equal to the recovered public key
|
|
57
|
-
* SigningKey.recoverPublicKey(digest, sig)
|
|
58
|
-
* //_result:
|
|
59
|
-
*
|
|
60
|
-
*/
|
|
61
|
-
static recoverPublicKey(digest: BytesLike, signature: SignatureLike): string;
|
|
62
|
-
}
|
|
63
|
-
//# sourceMappingURL=signing-key.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"signing-key.d.ts","sourceRoot":"","sources":["../../src.ts/crypto/signing-key.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAWH,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAE3C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAMhD;;GAEG;AACH,qBAAa,UAAU;;IAGnB;;OAEG;gBACS,UAAU,EAAE,SAAS;IAKjC;;OAEG;IACH,IAAI,UAAU,IAAI,MAAM,CAA6B;IAErD;;;OAGG;IACH,IAAI,SAAS,IAAI,MAAM,CAA0D;IAEjF;;OAEG;IACH,IAAI,CAAC,MAAM,EAAE,SAAS,GAAG,SAAS;IAclC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,gBAAgB,CAAC,GAAG,EAAE,SAAS,GAAG,MAAM;IAc/C;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,gBAAgB,CAAC,MAAM,EAAE,SAAS,EAAE,SAAS,EAAE,aAAa,GAAG,MAAM;CAW/E"}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Add details about signing here.
|
|
4
|
-
*
|
|
5
|
-
* @_subsection: api/crypto:Signing [about-signing]
|
|
6
|
-
*/
|
|
7
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.SigningKey = void 0;
|
|
9
|
-
const pqc = require("quantum-coin-pqc-js-sdk");
|
|
10
|
-
const quantum_coin_js_sdk_1 = require("quantum-coin-js-sdk");
|
|
11
|
-
const index_js_1 = require("../utils/index.js");
|
|
12
|
-
const signature_js_1 = require("./signature.js");
|
|
13
|
-
const CRYPTO_MESSAGE_LENGTH = 32;
|
|
14
|
-
const CRYPTO_SECRETKEY_BYTES = 64 + 2560 + 1312 + 128;
|
|
15
|
-
const CRYPTO_PUBLICKEY_BYTES = 32 + 1312 + 64;
|
|
16
|
-
/**
|
|
17
|
-
* A **SigningKey** provides high-level access to cryptography operations and key management.
|
|
18
|
-
*/
|
|
19
|
-
class SigningKey {
|
|
20
|
-
#privateKey;
|
|
21
|
-
/**
|
|
22
|
-
* Creates a new **SigningKey** for %%privateKey%%.
|
|
23
|
-
*/
|
|
24
|
-
constructor(privateKey) {
|
|
25
|
-
(0, index_js_1.assertArgument)((0, index_js_1.dataLength)(privateKey) === CRYPTO_SECRETKEY_BYTES, "invalid private key", "privateKey", "[REDACTED]");
|
|
26
|
-
this.#privateKey = (0, index_js_1.hexlify)(privateKey);
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* The private key.
|
|
30
|
-
*/
|
|
31
|
-
get privateKey() { return this.#privateKey; }
|
|
32
|
-
/**
|
|
33
|
-
* The public key.
|
|
34
|
-
*
|
|
35
|
-
*/
|
|
36
|
-
get publicKey() { return SigningKey.computePublicKey(this.#privateKey); }
|
|
37
|
-
/**
|
|
38
|
-
* Return the signature of the signed %%digest%%.
|
|
39
|
-
*/
|
|
40
|
-
sign(digest) {
|
|
41
|
-
(0, index_js_1.assertArgument)((0, index_js_1.dataLength)(digest) === CRYPTO_MESSAGE_LENGTH, "invalid digest length", "digest", digest);
|
|
42
|
-
const sig = pqc.cryptoSign((0, index_js_1.getBytesCopy)(digest), (0, index_js_1.getBytesCopy)(this.#privateKey));
|
|
43
|
-
const pubBytes = (0, index_js_1.getBytes)(this.publicKey);
|
|
44
|
-
const combinedSig = (0, quantum_coin_js_sdk_1.combinePublicKeySignature)(pubBytes, sig);
|
|
45
|
-
return signature_js_1.Signature.from({
|
|
46
|
-
r: this.publicKey,
|
|
47
|
-
s: combinedSig,
|
|
48
|
-
v: 0x1
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
/**
|
|
52
|
-
* Compute the public key for a private %%key%%. If a publicKey is passed, it is returned as is. for backward compatibility.
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
* @example:
|
|
56
|
-
* sign = new SigningKey(id("some-secret"));
|
|
57
|
-
*
|
|
58
|
-
* // Compute the public key for a private key
|
|
59
|
-
* SigningKey.computePublicKey(sign.privateKey)
|
|
60
|
-
* //_result:
|
|
61
|
-
*/
|
|
62
|
-
static computePublicKey(key) {
|
|
63
|
-
let keyBytes = (0, index_js_1.getBytes)(key, "key");
|
|
64
|
-
let pubKey;
|
|
65
|
-
if (keyBytes.length == CRYPTO_SECRETKEY_BYTES) {
|
|
66
|
-
pubKey = (0, quantum_coin_js_sdk_1.publicKeyFromPrivateKey)(keyBytes);
|
|
67
|
-
}
|
|
68
|
-
else if (keyBytes.length == CRYPTO_PUBLICKEY_BYTES) {
|
|
69
|
-
pubKey = keyBytes;
|
|
70
|
-
}
|
|
71
|
-
(0, index_js_1.assertArgument)(pubKey !== null && pubKey !== undefined, "invalid key", "key", "[REDACTED]");
|
|
72
|
-
return pubKey;
|
|
73
|
-
}
|
|
74
|
-
/**
|
|
75
|
-
* Returns the public key for the private key which produced the
|
|
76
|
-
* %%signature%% for the given %%digest%%.
|
|
77
|
-
*
|
|
78
|
-
* @example:
|
|
79
|
-
* key = new SigningKey(id("some-secret"))
|
|
80
|
-
* digest = id("hello world")
|
|
81
|
-
* sig = key.sign(digest)
|
|
82
|
-
*
|
|
83
|
-
* // Notice the signer public key...
|
|
84
|
-
* key.publicKey
|
|
85
|
-
* //_result:
|
|
86
|
-
*
|
|
87
|
-
* // ...is equal to the recovered public key
|
|
88
|
-
* SigningKey.recoverPublicKey(digest, sig)
|
|
89
|
-
* //_result:
|
|
90
|
-
*
|
|
91
|
-
*/
|
|
92
|
-
static recoverPublicKey(digest, signature) {
|
|
93
|
-
(0, index_js_1.assertArgument)((0, index_js_1.dataLength)(digest) === CRYPTO_MESSAGE_LENGTH, "invalid digest length", "digest", digest);
|
|
94
|
-
const sig = signature_js_1.Signature.from(signature);
|
|
95
|
-
let sigBytes = (0, index_js_1.getBytes)(sig.s);
|
|
96
|
-
let digestBytes = digest;
|
|
97
|
-
let publicKey = (0, quantum_coin_js_sdk_1.publicKeyFromSignature)(digestBytes, sigBytes);
|
|
98
|
-
return publicKey;
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
exports.SigningKey = SigningKey;
|
|
102
|
-
//# sourceMappingURL=signing-key.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"signing-key.js","sourceRoot":"","sources":["../../src.ts/crypto/signing-key.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AAEH,+CAAgD;AAChD,6DAA+G;AAE/G,gDAI2B;AAE3B,iDAA2C;AAM3C,MAAM,qBAAqB,GAAG,EAAE,CAAC;AACjC,MAAM,sBAAsB,GAAG,EAAE,GAAG,IAAI,GAAG,IAAI,GAAG,GAAG,CAAC;AACtD,MAAM,sBAAsB,GAAG,EAAE,GAAG,IAAI,GAAG,EAAE,CAAC;AAE9C;;GAEG;AACH,MAAa,UAAU;IACnB,WAAW,CAAS;IAEpB;;OAEG;IACH,YAAY,UAAqB;QAC7B,IAAA,yBAAc,EAAC,IAAA,qBAAU,EAAC,UAAU,CAAC,KAAK,sBAAsB,EAAE,qBAAqB,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;QACrH,IAAI,CAAC,WAAW,GAAG,IAAA,kBAAO,EAAC,UAAU,CAAC,CAAC;IAC3C,CAAC;IAED;;OAEG;IACH,IAAI,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAErD;;;OAGG;IACH,IAAI,SAAS,KAAa,OAAO,UAAU,CAAC,gBAAgB,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;IAEjF;;OAEG;IACH,IAAI,CAAC,MAAiB;QAClB,IAAA,yBAAc,EAAC,IAAA,qBAAU,EAAC,MAAM,CAAC,KAAK,qBAAqB,EAAE,uBAAuB,EAAE,QAAQ,EAAE,MAAM,CAAC,CAAC;QAExG,MAAM,GAAG,GAAQ,GAAG,CAAC,UAAU,CAAC,IAAA,uBAAY,EAAC,MAAM,CAAC,EAAE,IAAA,uBAAY,EAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;QACtF,MAAM,QAAQ,GAAQ,IAAA,mBAAQ,EAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/C,MAAM,WAAW,GAAG,IAAA,+CAAyB,EAAC,QAAQ,EAAE,GAAG,CAAC,CAAC;QAE7D,OAAO,wBAAS,CAAC,IAAI,CAAC;YAClB,CAAC,EAAE,IAAI,CAAC,SAAS;YACjB,CAAC,EAAE,WAAW;YACd,CAAC,EAAE,GAAG;SACT,CAAC,CAAC;IACP,CAAC;IAED;;;;;;;;;;OAUG;IACH,MAAM,CAAC,gBAAgB,CAAC,GAAc;QAClC,IAAI,QAAQ,GAAQ,IAAA,mBAAQ,EAAC,GAAG,EAAE,KAAK,CAAC,CAAC;QACzC,IAAI,MAAW,CAAC;QAEhB,IAAI,QAAQ,CAAC,MAAM,IAAI,sBAAsB,EAAE;YAC3C,MAAM,GAAG,IAAA,6CAAuB,EAAC,QAAQ,CAAC,CAAC;SAC9C;aAAM,IAAG,QAAQ,CAAC,MAAM,IAAI,sBAAsB,EAAE;YACjD,MAAM,GAAG,QAAQ,CAAC;SACrB;QAED,IAAA,yBAAc,EAAC,MAAM,KAAK,IAAI,IAAI,MAAM,KAAK,SAAS,EAAE,aAAa,EAAE,KAAK,EAAE,YAAY,CAAC,CAAC;QAC5F,OAAO,MAAM,CAAC;IAClB,CAAC;IAED;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,gBAAgB,CAAC,MAAiB,EAAE,SAAwB;QAC/D,IAAA,yBAAc,EAAC,IAAA,qBAAU,EAAC,MAAM,CAAC,KAAK,qBAAqB,EAAE,uBAAuB,EAAE,QAAQ,EAAE,MAAM,CAAC,CAAC;QAExG,MAAM,GAAG,GAAG,wBAAS,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QACtC,IAAI,QAAQ,GAAQ,IAAA,mBAAQ,EAAC,GAAG,CAAC,CAAC,CAAC,CAAC;QACpC,IAAI,WAAW,GAAQ,MAAM,CAAC;QAE9B,IAAI,SAAS,GAAG,IAAA,4CAAsB,EAAC,WAAW,EAAE,QAAQ,CAAC,CAAC;QAE9D,OAAO,SAAS,CAAC;IACrB,CAAC;CACJ;AA7FD,gCA6FC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import type { Addressable } from "../address/index.js";
|
|
2
|
-
import type { SignatureLike } from "../crypto/index.js";
|
|
3
|
-
import type { BigNumberish, Numeric } from "../utils/index.js";
|
|
4
|
-
export interface AuthorizationRequest {
|
|
5
|
-
address: string | Addressable;
|
|
6
|
-
nonce?: Numeric;
|
|
7
|
-
chainId?: BigNumberish;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Computes the [[link-eip-7702]] authorization digest to sign.
|
|
11
|
-
*/
|
|
12
|
-
export declare function hashAuthorization(auth: AuthorizationRequest): string;
|
|
13
|
-
/**
|
|
14
|
-
* Return the address of the private key that produced
|
|
15
|
-
* the signature %%sig%% during signing for %%message%%.
|
|
16
|
-
*/
|
|
17
|
-
export declare function verifyAuthorization(auth: AuthorizationRequest, sig: SignatureLike): string;
|
|
18
|
-
//# sourceMappingURL=authorization.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"authorization.d.ts","sourceRoot":"","sources":["../../src.ts/hash/authorization.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACxD,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE/D,MAAM,WAAW,oBAAoB;IACjC,OAAO,EAAE,MAAM,GAAG,WAAW,CAAC;IAC9B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,YAAY,CAAC;CAC1B;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,oBAAoB,GAAG,MAAM,CASpE;AAED;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,oBAAoB,EAAE,GAAG,EAAE,aAAa,GAAG,MAAM,CAE1F"}
|