@aztec/foundation 0.0.0-test.1 → 0.0.1-commit.b655e406
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/dest/array/array.d.ts +5 -0
- package/dest/array/array.d.ts.map +1 -1
- package/dest/array/array.js +11 -0
- package/dest/async-pool/index.d.ts.map +1 -1
- package/dest/async-pool/index.js +1 -0
- package/dest/bigint/index.d.ts +7 -0
- package/dest/bigint/index.d.ts.map +1 -0
- package/dest/bigint/index.js +15 -0
- package/dest/bigint-buffer/index.d.ts +0 -2
- package/dest/bigint-buffer/index.d.ts.map +1 -1
- package/dest/buffer/buffer16.d.ts +80 -0
- package/dest/buffer/buffer16.d.ts.map +1 -0
- package/dest/buffer/buffer16.js +100 -0
- package/dest/buffer/buffer32.d.ts +3 -7
- package/dest/buffer/buffer32.d.ts.map +1 -1
- package/dest/buffer/buffer32.js +6 -6
- package/dest/buffer/index.d.ts +1 -0
- package/dest/buffer/index.d.ts.map +1 -1
- package/dest/buffer/index.js +1 -0
- package/dest/collection/array.d.ts +16 -3
- package/dest/collection/array.d.ts.map +1 -1
- package/dest/collection/array.js +57 -3
- package/dest/collection/object.d.ts +16 -0
- package/dest/collection/object.d.ts.map +1 -1
- package/dest/collection/object.js +25 -0
- package/dest/config/env_var.d.ts +1 -1
- package/dest/config/env_var.d.ts.map +1 -1
- package/dest/config/index.d.ts +48 -1
- package/dest/config/index.d.ts.map +1 -1
- package/dest/config/index.js +115 -7
- package/dest/config/network_config.d.ts +42 -0
- package/dest/config/network_config.d.ts.map +1 -0
- package/dest/config/network_config.js +9 -0
- package/dest/config/network_name.d.ts +3 -0
- package/dest/config/network_name.d.ts.map +1 -0
- package/dest/config/network_name.js +19 -0
- package/dest/config/secret_value.d.ts +28 -0
- package/dest/config/secret_value.d.ts.map +1 -0
- package/dest/config/secret_value.js +34 -0
- package/dest/crypto/aes128/index.d.ts +2 -4
- package/dest/crypto/aes128/index.d.ts.map +1 -1
- package/dest/crypto/aes128/index.js +23 -6
- package/dest/crypto/bls/bn254_keystore.d.ts +296 -0
- package/dest/crypto/bls/bn254_keystore.d.ts.map +1 -0
- package/dest/crypto/bls/bn254_keystore.js +218 -0
- package/dest/crypto/bls/index.d.ts +13 -0
- package/dest/crypto/bls/index.d.ts.map +1 -0
- package/dest/crypto/bls/index.js +87 -0
- package/dest/crypto/bn254/bn254_utils.d.ts +39 -0
- package/dest/crypto/bn254/bn254_utils.d.ts.map +1 -0
- package/dest/crypto/bn254/bn254_utils.js +56 -0
- package/dest/crypto/bn254/index.d.ts +55 -0
- package/dest/crypto/bn254/index.d.ts.map +1 -0
- package/dest/crypto/bn254/index.js +142 -0
- package/dest/crypto/ecdsa/index.d.ts +2 -2
- package/dest/crypto/ecdsa/index.d.ts.map +1 -1
- package/dest/crypto/ecdsa/index.js +70 -48
- package/dest/crypto/ecdsa/signature.d.ts +1 -3
- package/dest/crypto/ecdsa/signature.d.ts.map +1 -1
- package/dest/crypto/grumpkin/index.d.ts +6 -13
- package/dest/crypto/grumpkin/index.d.ts.map +1 -1
- package/dest/crypto/grumpkin/index.js +69 -54
- package/dest/crypto/index.d.ts +2 -0
- package/dest/crypto/index.d.ts.map +1 -1
- package/dest/crypto/index.js +2 -0
- package/dest/crypto/keccak/index.d.ts +2 -4
- package/dest/crypto/keccak/index.d.ts.map +1 -1
- package/dest/crypto/keys/index.d.ts +0 -2
- package/dest/crypto/keys/index.d.ts.map +1 -1
- package/dest/crypto/keys/index.js +9 -4
- package/dest/crypto/pedersen/pedersen.noble.d.ts +2 -4
- package/dest/crypto/pedersen/pedersen.noble.d.ts.map +1 -1
- package/dest/crypto/pedersen/pedersen.wasm.d.ts +2 -4
- package/dest/crypto/pedersen/pedersen.wasm.d.ts.map +1 -1
- package/dest/crypto/pedersen/pedersen.wasm.js +29 -13
- package/dest/crypto/poseidon/index.d.ts +0 -2
- package/dest/crypto/poseidon/index.d.ts.map +1 -1
- package/dest/crypto/poseidon/index.js +42 -17
- package/dest/crypto/random/index.d.ts +1 -3
- package/dest/crypto/random/index.d.ts.map +1 -1
- package/dest/crypto/random/index.js +2 -34
- package/dest/crypto/random/randomness_singleton.d.ts +0 -2
- package/dest/crypto/random/randomness_singleton.d.ts.map +1 -1
- package/dest/crypto/schnorr/index.d.ts.map +1 -1
- package/dest/crypto/schnorr/index.js +35 -37
- package/dest/crypto/schnorr/signature.d.ts +3 -5
- package/dest/crypto/schnorr/signature.d.ts.map +1 -1
- package/dest/crypto/secp256k1/index.d.ts +4 -6
- package/dest/crypto/secp256k1/index.d.ts.map +1 -1
- package/dest/crypto/secp256k1/index.js +29 -18
- package/dest/crypto/secp256k1-signer/utils.d.ts +55 -4
- package/dest/crypto/secp256k1-signer/utils.d.ts.map +1 -1
- package/dest/crypto/secp256k1-signer/utils.js +92 -6
- package/dest/crypto/serialize.d.ts +4 -6
- package/dest/crypto/serialize.d.ts.map +1 -1
- package/dest/crypto/sha256/index.d.ts +21 -4
- package/dest/crypto/sha256/index.d.ts.map +1 -1
- package/dest/crypto/sha256/index.js +42 -0
- package/dest/crypto/sha512/index.d.ts +1 -3
- package/dest/crypto/sha512/index.d.ts.map +1 -1
- package/dest/crypto/signature/index.d.ts +0 -2
- package/dest/crypto/signature/index.d.ts.map +1 -1
- package/dest/crypto/sync/index.js +3 -1
- package/dest/crypto/sync/pedersen/index.d.ts +2 -4
- package/dest/crypto/sync/pedersen/index.d.ts.map +1 -1
- package/dest/crypto/sync/pedersen/index.js +17 -10
- package/dest/crypto/sync/poseidon/index.d.ts +0 -2
- package/dest/crypto/sync/poseidon/index.d.ts.map +1 -1
- package/dest/crypto/sync/poseidon/index.js +27 -12
- package/dest/decorators/memoize.d.ts.map +1 -1
- package/dest/eth-address/index.d.ts +6 -7
- package/dest/eth-address/index.d.ts.map +1 -1
- package/dest/eth-address/index.js +5 -0
- package/dest/eth-signature/eth_signature.d.ts +16 -14
- package/dest/eth-signature/eth_signature.d.ts.map +1 -1
- package/dest/eth-signature/eth_signature.js +31 -17
- package/dest/fields/bls12_fields.d.ts +148 -0
- package/dest/fields/bls12_fields.d.ts.map +1 -0
- package/dest/fields/bls12_fields.js +359 -0
- package/dest/fields/bls12_point.d.ts +229 -0
- package/dest/fields/bls12_point.d.ts.map +1 -0
- package/dest/fields/bls12_point.js +398 -0
- package/dest/fields/coordinate.d.ts +0 -2
- package/dest/fields/coordinate.d.ts.map +1 -1
- package/dest/fields/fields.d.ts +6 -3
- package/dest/fields/fields.d.ts.map +1 -1
- package/dest/fields/fields.js +43 -15
- package/dest/fields/index.d.ts +2 -0
- package/dest/fields/index.d.ts.map +1 -1
- package/dest/fields/index.js +2 -0
- package/dest/fields/point.d.ts +2 -4
- package/dest/fields/point.d.ts.map +1 -1
- package/dest/fields/point.js +3 -3
- package/dest/fs/index.d.ts +1 -0
- package/dest/fs/index.d.ts.map +1 -1
- package/dest/fs/index.js +1 -0
- package/dest/fs/try_rm_dir.d.ts +3 -0
- package/dest/fs/try_rm_dir.d.ts.map +1 -0
- package/dest/fs/try_rm_dir.js +16 -0
- package/dest/index.d.ts +1 -2
- package/dest/index.d.ts.map +1 -1
- package/dest/index.js +1 -2
- package/dest/iterable/filter.js +1 -1
- package/dest/iterable/map.js +1 -1
- package/dest/jest/env.js +48 -0
- package/dest/jest/setupAfterEnv.js +3 -0
- package/dest/json-rpc/client/fetch.d.ts +2 -2
- package/dest/json-rpc/client/fetch.d.ts.map +1 -1
- package/dest/json-rpc/client/fetch.js +16 -30
- package/dest/json-rpc/client/safe_json_rpc_client.d.ts +9 -3
- package/dest/json-rpc/client/safe_json_rpc_client.d.ts.map +1 -1
- package/dest/json-rpc/client/safe_json_rpc_client.js +173 -13
- package/dest/json-rpc/client/undici.d.ts.map +1 -1
- package/dest/json-rpc/client/undici.js +6 -7
- package/dest/json-rpc/convert.d.ts +2 -9
- package/dest/json-rpc/convert.d.ts.map +1 -1
- package/dest/json-rpc/convert.js +1 -9
- package/dest/json-rpc/errors.d.ts +4 -0
- package/dest/json-rpc/errors.d.ts.map +1 -0
- package/dest/json-rpc/errors.js +6 -0
- package/dest/json-rpc/fixtures/class_a.d.ts +5 -3
- package/dest/json-rpc/fixtures/class_a.d.ts.map +1 -1
- package/dest/json-rpc/fixtures/class_b.d.ts +5 -3
- package/dest/json-rpc/fixtures/class_b.d.ts.map +1 -1
- package/dest/json-rpc/index.d.ts +2 -1
- package/dest/json-rpc/index.d.ts.map +1 -1
- package/dest/json-rpc/index.js +2 -1
- package/dest/json-rpc/js_utils.d.ts.map +1 -1
- package/dest/json-rpc/server/safe_json_rpc_server.d.ts +21 -22
- package/dest/json-rpc/server/safe_json_rpc_server.d.ts.map +1 -1
- package/dest/json-rpc/server/safe_json_rpc_server.js +161 -56
- package/dest/json-rpc/test/integration.d.ts +1 -2
- package/dest/json-rpc/test/integration.d.ts.map +1 -1
- package/dest/log/console.d.ts.map +1 -1
- package/dest/log/gcloud-logger-config.d.ts +0 -1
- package/dest/log/gcloud-logger-config.d.ts.map +1 -1
- package/dest/log/gcloud-logger-config.js +1 -9
- package/dest/log/index.d.ts +4 -4
- package/dest/log/index.d.ts.map +1 -1
- package/dest/log/index.js +4 -4
- package/dest/log/libp2p_logger.js +13 -2
- package/dest/log/log_fn.d.ts +1 -1
- package/dest/log/log_fn.d.ts.map +1 -1
- package/dest/log/noir_debug_log_util.d.ts +14 -0
- package/dest/log/noir_debug_log_util.d.ts.map +1 -0
- package/dest/log/noir_debug_log_util.js +14 -0
- package/dest/log/pino-logger.d.ts +2 -2
- package/dest/log/pino-logger.d.ts.map +1 -1
- package/dest/log/pino-logger.js +28 -2
- package/dest/message/index.d.ts.map +1 -1
- package/dest/mutex/mutex_database.d.ts.map +1 -1
- package/dest/noir/noir_package_config.d.ts +4 -4
- package/dest/number/index.d.ts +3 -0
- package/dest/number/index.d.ts.map +1 -0
- package/dest/number/index.js +12 -0
- package/dest/profiler/index.d.ts +2 -0
- package/dest/profiler/index.d.ts.map +1 -0
- package/dest/profiler/index.js +1 -0
- package/dest/profiler/profiler.d.ts +8 -0
- package/dest/profiler/profiler.d.ts.map +1 -0
- package/dest/profiler/profiler.js +97 -0
- package/dest/promise/running-promise.d.ts +1 -1
- package/dest/promise/running-promise.d.ts.map +1 -1
- package/dest/promise/running-promise.js +2 -2
- package/dest/queue/batch_queue.d.ts +1 -1
- package/dest/queue/batch_queue.js +1 -1
- package/dest/queue/bounded_serial_queue.d.ts.map +1 -1
- package/dest/queue/serial_queue.d.ts +2 -2
- package/dest/queue/serial_queue.d.ts.map +1 -1
- package/dest/queue/serial_queue.js +7 -5
- package/dest/retry/index.d.ts +3 -2
- package/dest/retry/index.d.ts.map +1 -1
- package/dest/retry/index.js +2 -2
- package/dest/schemas/api.d.ts.map +1 -1
- package/dest/schemas/parse.js +1 -1
- package/dest/schemas/schemas.d.ts +9 -6
- package/dest/schemas/schemas.d.ts.map +1 -1
- package/dest/schemas/schemas.js +15 -1
- package/dest/schemas/utils.d.ts +1 -3
- package/dest/schemas/utils.d.ts.map +1 -1
- package/dest/serialize/buffer_reader.d.ts +27 -2
- package/dest/serialize/buffer_reader.d.ts.map +1 -1
- package/dest/serialize/buffer_reader.js +44 -2
- package/dest/serialize/field_reader.d.ts +10 -1
- package/dest/serialize/field_reader.d.ts.map +1 -1
- package/dest/serialize/field_reader.js +18 -1
- package/dest/serialize/free_funcs.d.ts +23 -21
- package/dest/serialize/free_funcs.d.ts.map +1 -1
- package/dest/serialize/free_funcs.js +21 -27
- package/dest/serialize/serialize.d.ts +4 -5
- package/dest/serialize/serialize.d.ts.map +1 -1
- package/dest/string/index.d.ts +7 -2
- package/dest/string/index.d.ts.map +1 -1
- package/dest/string/index.js +27 -1
- package/dest/testing/files/index.d.ts +0 -2
- package/dest/testing/files/index.d.ts.map +1 -1
- package/dest/testing/files/index.js +2 -2
- package/dest/testing/formatting.d.ts +4 -0
- package/dest/testing/formatting.d.ts.map +1 -0
- package/dest/testing/formatting.js +3 -0
- package/dest/testing/index.d.ts +1 -0
- package/dest/testing/index.d.ts.map +1 -1
- package/dest/testing/index.js +1 -0
- package/dest/timer/date.d.ts +2 -1
- package/dest/timer/date.d.ts.map +1 -1
- package/dest/timer/date.js +5 -3
- package/dest/timer/index.d.ts +1 -1
- package/dest/timer/index.d.ts.map +1 -1
- package/dest/timer/index.js +1 -1
- package/dest/timer/timeout.d.ts +18 -5
- package/dest/timer/timeout.d.ts.map +1 -1
- package/dest/timer/timeout.js +43 -22
- package/dest/transport/dispatch/create_dispatch_fn.d.ts.map +1 -1
- package/dest/transport/index.d.ts +0 -1
- package/dest/transport/index.d.ts.map +1 -1
- package/dest/transport/index.js +0 -1
- package/dest/transport/interface/connector.d.ts.map +1 -1
- package/dest/transport/interface/listener.d.ts +0 -1
- package/dest/transport/interface/listener.d.ts.map +1 -1
- package/dest/transport/interface/socket.d.ts.map +1 -1
- package/dest/transport/node/node_connector.d.ts +0 -1
- package/dest/transport/node/node_connector.d.ts.map +1 -1
- package/dest/transport/node/node_connector_socket.d.ts +0 -1
- package/dest/transport/node/node_connector_socket.d.ts.map +1 -1
- package/dest/transport/node/node_listener.d.ts +0 -1
- package/dest/transport/node/node_listener.d.ts.map +1 -1
- package/dest/transport/node/node_listener_socket.d.ts +0 -1
- package/dest/transport/node/node_listener_socket.d.ts.map +1 -1
- package/dest/transport/transport_client.d.ts +0 -1
- package/dest/transport/transport_client.d.ts.map +1 -1
- package/dest/transport/transport_server.d.ts.map +1 -1
- package/dest/trees/hasher.d.ts +4 -6
- package/dest/trees/hasher.d.ts.map +1 -1
- package/dest/trees/index.d.ts +1 -0
- package/dest/trees/index.d.ts.map +1 -1
- package/dest/trees/index.js +1 -0
- package/dest/trees/indexed_merkle_tree.d.ts +0 -2
- package/dest/trees/indexed_merkle_tree.d.ts.map +1 -1
- package/dest/trees/indexed_merkle_tree_calculator.d.ts +1 -3
- package/dest/trees/indexed_merkle_tree_calculator.d.ts.map +1 -1
- package/dest/trees/indexed_tree_leaf.d.ts +0 -2
- package/dest/trees/indexed_tree_leaf.d.ts.map +1 -1
- package/dest/trees/membership_witness.d.ts +19 -3
- package/dest/trees/membership_witness.d.ts.map +1 -1
- package/dest/trees/membership_witness.js +13 -0
- package/dest/trees/merkle_tree.d.ts +0 -2
- package/dest/trees/merkle_tree.d.ts.map +1 -1
- package/dest/trees/merkle_tree_calculator.d.ts +11 -3
- package/dest/trees/merkle_tree_calculator.d.ts.map +1 -1
- package/dest/trees/merkle_tree_calculator.js +31 -1
- package/dest/trees/sibling_path.d.ts +6 -8
- package/dest/trees/sibling_path.d.ts.map +1 -1
- package/dest/trees/unbalanced_merkle_tree.d.ts +19 -8
- package/dest/trees/unbalanced_merkle_tree.d.ts.map +1 -1
- package/dest/trees/unbalanced_merkle_tree.js +49 -50
- package/dest/trees/unbalanced_merkle_tree_calculator.d.ts +48 -0
- package/dest/trees/unbalanced_merkle_tree_calculator.d.ts.map +1 -0
- package/dest/trees/unbalanced_merkle_tree_calculator.js +162 -0
- package/dest/trees/unbalanced_tree_store.d.ts +1 -0
- package/dest/trees/unbalanced_tree_store.d.ts.map +1 -1
- package/dest/trees/unbalanced_tree_store.js +6 -0
- package/dest/types/index.d.ts +25 -2
- package/dest/types/index.d.ts.map +1 -1
- package/dest/url/index.d.ts.map +1 -1
- package/dest/url/index.js +1 -1
- package/package.json +35 -41
- package/src/array/array.ts +13 -0
- package/src/async-pool/index.ts +1 -0
- package/src/bigint/index.ts +20 -0
- package/src/buffer/buffer16.ts +133 -0
- package/src/buffer/buffer32.ts +8 -6
- package/src/buffer/index.ts +1 -0
- package/src/collection/array.ts +66 -4
- package/src/collection/object.ts +37 -0
- package/src/config/env_var.ts +142 -52
- package/src/config/index.ts +191 -8
- package/src/config/network_config.ts +16 -0
- package/src/config/network_name.ts +28 -0
- package/src/config/secret_value.ts +49 -0
- package/src/crypto/aes128/index.ts +19 -10
- package/src/crypto/bls/bn254_keystore.ts +287 -0
- package/src/crypto/bls/index.ts +77 -0
- package/src/crypto/bn254/bn254_utils.ts +64 -0
- package/src/crypto/bn254/index.ts +170 -0
- package/src/crypto/ecdsa/index.ts +41 -23
- package/src/crypto/grumpkin/index.ts +35 -45
- package/src/crypto/index.ts +2 -0
- package/src/crypto/keys/index.ts +5 -5
- package/src/crypto/pedersen/pedersen.wasm.ts +22 -18
- package/src/crypto/poseidon/index.ts +32 -24
- package/src/crypto/random/index.ts +2 -40
- package/src/crypto/schnorr/index.ts +20 -17
- package/src/crypto/secp256k1/index.ts +15 -11
- package/src/crypto/secp256k1-signer/utils.ts +120 -7
- package/src/crypto/sha256/index.ts +47 -0
- package/src/crypto/sync/index.ts +1 -1
- package/src/crypto/sync/pedersen/index.ts +16 -15
- package/src/crypto/sync/poseidon/index.ts +27 -22
- package/src/eth-address/index.ts +9 -2
- package/src/eth-signature/eth_signature.ts +44 -22
- package/src/fields/bls12_fields.ts +463 -0
- package/src/fields/bls12_point.ts +450 -0
- package/src/fields/fields.ts +37 -9
- package/src/fields/index.ts +2 -0
- package/src/fields/point.ts +1 -3
- package/src/fs/index.ts +1 -0
- package/src/fs/try_rm_dir.ts +15 -0
- package/src/index.ts +1 -2
- package/src/iterable/filter.ts +1 -1
- package/src/iterable/map.ts +1 -1
- package/src/jest/env.mjs +52 -0
- package/src/jest/setupAfterEnv.mjs +3 -0
- package/src/json-rpc/client/fetch.ts +14 -33
- package/src/json-rpc/client/safe_json_rpc_client.ts +226 -13
- package/src/json-rpc/client/undici.ts +8 -15
- package/src/json-rpc/convert.ts +3 -12
- package/src/json-rpc/errors.ts +6 -0
- package/src/json-rpc/fixtures/class_a.ts +4 -1
- package/src/json-rpc/fixtures/class_b.ts +4 -1
- package/src/json-rpc/index.ts +2 -1
- package/src/json-rpc/server/safe_json_rpc_server.ts +141 -48
- package/src/json-rpc/test/integration.ts +1 -1
- package/src/log/console.ts +4 -1
- package/src/log/gcloud-logger-config.ts +3 -7
- package/src/log/index.ts +4 -4
- package/src/log/libp2p_logger.ts +21 -2
- package/src/log/log_fn.ts +1 -1
- package/src/log/noir_debug_log_util.ts +21 -0
- package/src/log/pino-logger.ts +33 -2
- package/src/message/index.ts +5 -1
- package/src/mutex/mutex_database.ts +2 -3
- package/src/number/index.ts +14 -0
- package/src/profiler/index.ts +1 -0
- package/src/profiler/profiler.ts +125 -0
- package/src/promise/running-promise.ts +2 -2
- package/src/queue/batch_queue.ts +1 -1
- package/src/queue/bounded_serial_queue.ts +4 -1
- package/src/queue/serial_queue.ts +5 -5
- package/src/retry/index.ts +10 -5
- package/src/schemas/api.ts +4 -4
- package/src/schemas/parse.ts +1 -1
- package/src/schemas/schemas.ts +19 -1
- package/src/serialize/buffer_reader.ts +60 -3
- package/src/serialize/field_reader.ts +27 -3
- package/src/serialize/free_funcs.ts +25 -31
- package/src/serialize/serialize.ts +2 -0
- package/src/string/index.ts +36 -1
- package/src/testing/files/index.ts +6 -2
- package/src/testing/formatting.ts +3 -0
- package/src/testing/index.ts +1 -0
- package/src/timer/date.ts +9 -3
- package/src/timer/index.ts +1 -1
- package/src/timer/timeout.ts +54 -19
- package/src/transport/index.ts +0 -1
- package/src/transport/interface/connector.ts +0 -1
- package/src/transport/interface/listener.ts +2 -3
- package/src/transport/interface/socket.ts +2 -3
- package/src/transport/transport_client.ts +3 -4
- package/src/transport/transport_server.ts +4 -1
- package/src/trees/hasher.ts +4 -4
- package/src/trees/index.ts +1 -0
- package/src/trees/indexed_merkle_tree.ts +5 -1
- package/src/trees/indexed_merkle_tree_calculator.ts +2 -2
- package/src/trees/membership_witness.ts +13 -0
- package/src/trees/merkle_tree.ts +4 -1
- package/src/trees/merkle_tree_calculator.ts +43 -5
- package/src/trees/unbalanced_merkle_tree.ts +50 -42
- package/src/trees/unbalanced_merkle_tree_calculator.ts +194 -0
- package/src/trees/unbalanced_tree_store.ts +5 -1
- package/src/types/index.ts +25 -4
- package/src/url/index.ts +0 -1
- package/dest/crypto/pedersen/pedersen.elliptic.d.ts +0 -13
- package/dest/crypto/pedersen/pedersen.elliptic.d.ts.map +0 -1
- package/dest/crypto/pedersen/pedersen.elliptic.js +0 -582
- package/dest/log/debug.d.ts +0 -56
- package/dest/log/debug.d.ts.map +0 -1
- package/dest/log/debug.js +0 -75
- package/dest/log/log_history.d.ts +0 -31
- package/dest/log/log_history.d.ts.map +0 -1
- package/dest/log/log_history.js +0 -38
- package/dest/transport/browser/index.d.ts +0 -5
- package/dest/transport/browser/index.d.ts.map +0 -1
- package/dest/transport/browser/index.js +0 -4
- package/dest/transport/browser/message_port_socket.d.ts +0 -37
- package/dest/transport/browser/message_port_socket.d.ts.map +0 -1
- package/dest/transport/browser/message_port_socket.js +0 -42
- package/dest/transport/browser/shared_worker_connector.d.ts +0 -19
- package/dest/transport/browser/shared_worker_connector.d.ts.map +0 -1
- package/dest/transport/browser/shared_worker_connector.js +0 -19
- package/dest/transport/browser/shared_worker_listener.d.ts +0 -38
- package/dest/transport/browser/shared_worker_listener.d.ts.map +0 -1
- package/dest/transport/browser/shared_worker_listener.js +0 -33
- package/dest/transport/browser/worker_connector.d.ts +0 -26
- package/dest/transport/browser/worker_connector.d.ts.map +0 -1
- package/dest/transport/browser/worker_connector.js +0 -30
- package/dest/transport/browser/worker_listener.d.ts +0 -39
- package/dest/transport/browser/worker_listener.d.ts.map +0 -1
- package/dest/transport/browser/worker_listener.js +0 -35
- package/dest/wasm/empty_wasi_sdk.d.ts +0 -130
- package/dest/wasm/empty_wasi_sdk.d.ts.map +0 -1
- package/dest/wasm/empty_wasi_sdk.js +0 -148
- package/dest/wasm/index.d.ts +0 -2
- package/dest/wasm/index.d.ts.map +0 -1
- package/dest/wasm/index.js +0 -1
- package/dest/wasm/wasm_module.d.ts +0 -136
- package/dest/wasm/wasm_module.d.ts.map +0 -1
- package/dest/wasm/wasm_module.js +0 -196
- package/dest/worker/browser/index.d.ts +0 -3
- package/dest/worker/browser/index.d.ts.map +0 -1
- package/dest/worker/browser/index.js +0 -2
- package/dest/worker/browser/start_web_module.d.ts +0 -7
- package/dest/worker/browser/start_web_module.d.ts.map +0 -1
- package/dest/worker/browser/start_web_module.js +0 -27
- package/dest/worker/browser/web_data_store.d.ts +0 -24
- package/dest/worker/browser/web_data_store.d.ts.map +0 -1
- package/dest/worker/browser/web_data_store.js +0 -29
- package/dest/worker/browser/web_worker.d.ts +0 -10
- package/dest/worker/browser/web_worker.d.ts.map +0 -1
- package/dest/worker/browser/web_worker.js +0 -25
- package/dest/worker/data_store.d.ts +0 -21
- package/dest/worker/data_store.d.ts.map +0 -1
- package/dest/worker/data_store.js +0 -3
- package/dest/worker/index.d.ts +0 -3
- package/dest/worker/index.d.ts.map +0 -1
- package/dest/worker/index.js +0 -1
- package/dest/worker/node/index.d.ts +0 -3
- package/dest/worker/node/index.d.ts.map +0 -1
- package/dest/worker/node/index.js +0 -2
- package/dest/worker/node/node_data_store.d.ts +0 -13
- package/dest/worker/node/node_data_store.d.ts.map +0 -1
- package/dest/worker/node/node_data_store.js +0 -20
- package/dest/worker/node/node_worker.d.ts +0 -6
- package/dest/worker/node/node_worker.d.ts.map +0 -1
- package/dest/worker/node/node_worker.js +0 -22
- package/dest/worker/node/start_node_module.d.ts +0 -7
- package/dest/worker/node/start_node_module.d.ts.map +0 -1
- package/dest/worker/node/start_node_module.js +0 -31
- package/dest/worker/wasm_worker.d.ts +0 -9
- package/dest/worker/wasm_worker.d.ts.map +0 -1
- package/dest/worker/wasm_worker.js +0 -3
- package/dest/worker/worker_pool.d.ts +0 -40
- package/dest/worker/worker_pool.d.ts.map +0 -1
- package/dest/worker/worker_pool.js +0 -51
- package/src/crypto/pedersen/pedersen.elliptic.ts +0 -584
- package/src/log/debug.ts +0 -104
- package/src/log/log_history.ts +0 -44
- package/src/transport/browser/index.ts +0 -4
- package/src/transport/browser/message_port_socket.ts +0 -48
- package/src/transport/browser/shared_worker_connector.ts +0 -21
- package/src/transport/browser/shared_worker_listener.ts +0 -53
- package/src/transport/browser/worker_connector.ts +0 -30
- package/src/transport/browser/worker_listener.ts +0 -54
- package/src/wasm/README.md +0 -6
- package/src/wasm/empty_wasi_sdk.ts +0 -166
- package/src/wasm/fixtures/gcd.wasm +0 -0
- package/src/wasm/fixtures/gcd.wat +0 -27
- package/src/wasm/index.ts +0 -1
- package/src/wasm/wasm_module.ts +0 -260
- package/src/worker/browser/index.ts +0 -2
- package/src/worker/browser/start_web_module.ts +0 -24
- package/src/worker/browser/web_data_store.ts +0 -38
- package/src/worker/browser/web_worker.ts +0 -25
- package/src/worker/data_store.ts +0 -19
- package/src/worker/index.ts +0 -2
- package/src/worker/node/index.ts +0 -2
- package/src/worker/node/node_data_store.ts +0 -27
- package/src/worker/node/node_worker.ts +0 -23
- package/src/worker/node/start_node_module.ts +0 -30
- package/src/worker/wasm_worker.ts +0 -7
- package/src/worker/worker_pool.ts +0 -73
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
3
1
|
import { Fr } from '../../../fields/fields.js';
|
|
4
2
|
import { type Fieldable } from '../../../serialize/serialize.js';
|
|
5
3
|
/**
|
|
6
4
|
* Create a pedersen commitment (point) from an array of input fields.
|
|
7
5
|
* Left pads any inputs less than 32 bytes.
|
|
8
6
|
*/
|
|
9
|
-
export declare function pedersenCommit(input: Buffer[], offset?: number): Buffer[];
|
|
7
|
+
export declare function pedersenCommit(input: Buffer[], offset?: number): Buffer<ArrayBuffer>[];
|
|
10
8
|
/**
|
|
11
9
|
* Create a pedersen hash (field) from an array of input fields.
|
|
12
10
|
* @param input - The input fieldables to hash.
|
|
@@ -17,5 +15,5 @@ export declare function pedersenHash(input: Fieldable[], index?: number): Fr;
|
|
|
17
15
|
/**
|
|
18
16
|
* Create a pedersen hash from an arbitrary length buffer.
|
|
19
17
|
*/
|
|
20
|
-
export declare function pedersenHashBuffer(input: Buffer, index?: number): Buffer
|
|
18
|
+
export declare function pedersenHashBuffer(input: Buffer, index?: number): Buffer<ArrayBuffer>;
|
|
21
19
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/crypto/sync/pedersen/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/crypto/sync/pedersen/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,EAAE,EAAE,MAAM,2BAA2B,CAAC;AAC/C,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,iCAAiC,CAAC;AAEpF;;;GAGG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,MAAM,SAAI,yBAUzD;AAED;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,KAAK,SAAI,GAAG,EAAE,CAO9D;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,SAAI,uBAM1D"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BarretenbergSync
|
|
1
|
+
import { BarretenbergSync } from '@aztec/bb.js';
|
|
2
2
|
import { Fr } from '../../../fields/fields.js';
|
|
3
3
|
import { serializeToFields } from '../../../serialize/serialize.js';
|
|
4
4
|
/**
|
|
@@ -12,12 +12,13 @@ import { serializeToFields } from '../../../serialize/serialize.js';
|
|
|
12
12
|
Buffer.alloc(32 - i.length, 0),
|
|
13
13
|
i
|
|
14
14
|
]) : i);
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
const response = BarretenbergSync.getSingleton().pedersenCommit({
|
|
16
|
+
inputs: input,
|
|
17
|
+
hashIndex: offset
|
|
18
|
+
});
|
|
18
19
|
return [
|
|
19
|
-
Buffer.from(point.x
|
|
20
|
-
Buffer.from(point.y
|
|
20
|
+
Buffer.from(response.point.x),
|
|
21
|
+
Buffer.from(response.point.y)
|
|
21
22
|
];
|
|
22
23
|
}
|
|
23
24
|
/**
|
|
@@ -27,12 +28,18 @@ import { serializeToFields } from '../../../serialize/serialize.js';
|
|
|
27
28
|
* @returns The pedersen hash.
|
|
28
29
|
*/ export function pedersenHash(input, index = 0) {
|
|
29
30
|
const inputFields = serializeToFields(input);
|
|
30
|
-
const
|
|
31
|
-
|
|
31
|
+
const response = BarretenbergSync.getSingleton().pedersenHash({
|
|
32
|
+
inputs: inputFields.map((i)=>i.toBuffer()),
|
|
33
|
+
hashIndex: index
|
|
34
|
+
});
|
|
35
|
+
return Fr.fromBuffer(Buffer.from(response.hash));
|
|
32
36
|
}
|
|
33
37
|
/**
|
|
34
38
|
* Create a pedersen hash from an arbitrary length buffer.
|
|
35
39
|
*/ export function pedersenHashBuffer(input, index = 0) {
|
|
36
|
-
const
|
|
37
|
-
|
|
40
|
+
const response = BarretenbergSync.getSingleton().pedersenHashBuffer({
|
|
41
|
+
input,
|
|
42
|
+
hashIndex: index
|
|
43
|
+
});
|
|
44
|
+
return Buffer.from(response.hash);
|
|
38
45
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/crypto/sync/poseidon/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/crypto/sync/poseidon/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,EAAE,EAAE,MAAM,2BAA2B,CAAC;AAC/C,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,iCAAiC,CAAC;AAEpF;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,SAAS,EAAE,GAAG,EAAE,CAOpD;AAED;;;;;GAKG;AACH,wBAAgB,0BAA0B,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,SAAS,EAAE,MAAM,GAAG,EAAE,CASpF;AAED,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,SAAS,EAAE,GAAG,EAAE,CAO9D;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,SAAS,EAAE,GAAG,EAAE,EAAE,CAW7D;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,EAAE,CAiBpD"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BarretenbergSync
|
|
1
|
+
import { BarretenbergSync } from '@aztec/bb.js';
|
|
2
2
|
import { Fr } from '../../../fields/fields.js';
|
|
3
3
|
import { serializeToFields } from '../../../serialize/serialize.js';
|
|
4
4
|
/**
|
|
@@ -7,8 +7,11 @@ import { serializeToFields } from '../../../serialize/serialize.js';
|
|
|
7
7
|
* @returns The poseidon hash.
|
|
8
8
|
*/ export function poseidon2Hash(input) {
|
|
9
9
|
const inputFields = serializeToFields(input);
|
|
10
|
-
const
|
|
11
|
-
|
|
10
|
+
const api = BarretenbergSync.getSingleton();
|
|
11
|
+
const response = api.poseidon2Hash({
|
|
12
|
+
inputs: inputFields.map((i)=>i.toBuffer())
|
|
13
|
+
});
|
|
14
|
+
return Fr.fromBuffer(Buffer.from(response.hash));
|
|
12
15
|
}
|
|
13
16
|
/**
|
|
14
17
|
* Create a poseidon hash (field) from an array of input fields and a domain separator.
|
|
@@ -18,13 +21,19 @@ import { serializeToFields } from '../../../serialize/serialize.js';
|
|
|
18
21
|
*/ export function poseidon2HashWithSeparator(input, separator) {
|
|
19
22
|
const inputFields = serializeToFields(input);
|
|
20
23
|
inputFields.unshift(new Fr(separator));
|
|
21
|
-
const
|
|
22
|
-
|
|
24
|
+
const api = BarretenbergSync.getSingleton();
|
|
25
|
+
const response = api.poseidon2Hash({
|
|
26
|
+
inputs: inputFields.map((i)=>i.toBuffer())
|
|
27
|
+
});
|
|
28
|
+
return Fr.fromBuffer(Buffer.from(response.hash));
|
|
23
29
|
}
|
|
24
30
|
export function poseidon2HashAccumulate(input) {
|
|
25
31
|
const inputFields = serializeToFields(input);
|
|
26
|
-
const
|
|
27
|
-
|
|
32
|
+
const api = BarretenbergSync.getSingleton();
|
|
33
|
+
const response = api.poseidon2HashAccumulate({
|
|
34
|
+
inputs: inputFields.map((i)=>i.toBuffer())
|
|
35
|
+
});
|
|
36
|
+
return Fr.fromBuffer(Buffer.from(response.hash));
|
|
28
37
|
}
|
|
29
38
|
/**
|
|
30
39
|
* Runs a Poseidon2 permutation.
|
|
@@ -34,10 +43,13 @@ export function poseidon2HashAccumulate(input) {
|
|
|
34
43
|
const inputFields = serializeToFields(input);
|
|
35
44
|
// We'd like this assertion but it's not possible to use it in the browser.
|
|
36
45
|
// assert(input.length === 4, 'Input state must be of size 4');
|
|
37
|
-
const
|
|
46
|
+
const api = BarretenbergSync.getSingleton();
|
|
47
|
+
const response = api.poseidon2Permutation({
|
|
48
|
+
inputs: inputFields.map((i)=>i.toBuffer())
|
|
49
|
+
});
|
|
38
50
|
// We'd like this assertion but it's not possible to use it in the browser.
|
|
39
|
-
// assert(
|
|
40
|
-
return
|
|
51
|
+
// assert(response.outputs.length === 4, 'Output state must be of size 4');
|
|
52
|
+
return response.outputs.map((o)=>Fr.fromBuffer(Buffer.from(o)));
|
|
41
53
|
}
|
|
42
54
|
export function poseidon2HashBytes(input) {
|
|
43
55
|
const inputFields = [];
|
|
@@ -48,6 +60,9 @@ export function poseidon2HashBytes(input) {
|
|
|
48
60
|
fieldBytes.reverse();
|
|
49
61
|
inputFields.push(Fr.fromBuffer(fieldBytes));
|
|
50
62
|
}
|
|
51
|
-
const
|
|
52
|
-
|
|
63
|
+
const api = BarretenbergSync.getSingleton();
|
|
64
|
+
const response = api.poseidon2Hash({
|
|
65
|
+
inputs: inputFields.map((i)=>i.toBuffer())
|
|
66
|
+
});
|
|
67
|
+
return Fr.fromBuffer(Buffer.from(response.hash));
|
|
53
68
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"memoize.d.ts","sourceRoot":"","sources":["../../src/decorators/memoize.ts"],"names":[],"mappings":"AAAA,wBAAgB,OAAO,CAAC,IAAI,SAAS,MAAM,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,MAAM,EAAE,OAAO,EAAE,2BAA2B,
|
|
1
|
+
{"version":3,"file":"memoize.d.ts","sourceRoot":"","sources":["../../src/decorators/memoize.ts"],"names":[],"mappings":"AAAA,wBAAgB,OAAO,CAAC,IAAI,SAAS,MAAM,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,MAAM,EAAE,OAAO,EAAE,2BAA2B,IACxF,MAAM,IAAI,YAS5B"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
3
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
4
1
|
import { inspect } from 'util';
|
|
5
2
|
import { Fr } from '../fields/index.js';
|
|
6
3
|
import { BufferReader, FieldReader } from '../serialize/index.js';
|
|
@@ -70,7 +67,7 @@ export declare class EthAddress {
|
|
|
70
67
|
* @param address - The Ethereum address as a hex-encoded string.
|
|
71
68
|
* @returns The Ethereum address in its checksum format.
|
|
72
69
|
*/
|
|
73
|
-
static toChecksumAddress(address: string): string
|
|
70
|
+
static toChecksumAddress(address: string): `0x${string}`;
|
|
74
71
|
/**
|
|
75
72
|
* Checks whether the given EthAddress instance is equal to the current instance.
|
|
76
73
|
* Equality is determined by comparing the underlying byte buffers of both instances.
|
|
@@ -95,12 +92,12 @@ export declare class EthAddress {
|
|
|
95
92
|
*
|
|
96
93
|
* @returns A checksummed Ethereum address string.
|
|
97
94
|
*/
|
|
98
|
-
toChecksumString(): string
|
|
95
|
+
toChecksumString(): `0x${string}`;
|
|
99
96
|
/**
|
|
100
97
|
* Returns a 20-byte buffer representation of the Ethereum address.
|
|
101
98
|
* @returns A 20-byte Buffer containing the Ethereum address.
|
|
102
99
|
*/
|
|
103
|
-
toBuffer(): Buffer
|
|
100
|
+
toBuffer(): Buffer<ArrayBufferLike>;
|
|
104
101
|
/**
|
|
105
102
|
* Returns a 32-byte buffer representation of the Ethereum address, with the original 20-byte address
|
|
106
103
|
* occupying the last 20 bytes and the first 12 bytes being zero-filled.
|
|
@@ -108,7 +105,7 @@ export declare class EthAddress {
|
|
|
108
105
|
*
|
|
109
106
|
* @returns A 32-byte Buffer containing the padded Ethereum address.
|
|
110
107
|
*/
|
|
111
|
-
toBuffer32(): Buffer
|
|
108
|
+
toBuffer32(): Buffer<ArrayBuffer>;
|
|
112
109
|
/**
|
|
113
110
|
* Returns a new field with the same contents as this EthAddress.
|
|
114
111
|
*
|
|
@@ -128,6 +125,8 @@ export declare class EthAddress {
|
|
|
128
125
|
* @returns The EthAddress.
|
|
129
126
|
*/
|
|
130
127
|
static fromBuffer(buffer: Buffer | BufferReader): EthAddress;
|
|
128
|
+
/** Converts a number into an address. Useful for testing. */
|
|
129
|
+
static fromNumber(num: bigint | number): EthAddress;
|
|
131
130
|
toJSON(): `0x${string}`;
|
|
132
131
|
static get schema(): import("zod").ZodType<EthAddress, any, string>;
|
|
133
132
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/eth-address/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/eth-address/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAI/B,OAAO,EAAE,EAAE,EAAE,MAAM,oBAAoB,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAIlE;;;;;GAKG;AACH,qBAAa,UAAU;IAMT,OAAO,CAAC,MAAM;IAL1B,gDAAgD;IAChD,OAAc,aAAa,SAAM;IACjC,0EAA0E;IAC1E,OAAc,IAAI,aAA0D;gBAExD,MAAM,EAAE,MAAM;IAMlC;;;;;;;OAOG;WACW,UAAU,CAAC,OAAO,EAAE,MAAM;IAOxC;;;;;;OAMG;WACW,MAAM;IAIpB;;;;;;;;OAQG;WACW,SAAS,CAAC,OAAO,EAAE,MAAM;IAYvC;;;;;OAKG;IACI,MAAM;IAIb;;;;;;;OAOG;WACW,oBAAoB,CAAC,OAAO,EAAE,MAAM;IAgBlD;;;;;;;;;OASG;WACW,iBAAiB,CAAC,OAAO,EAAE,MAAM,GAAG,KAAK,MAAM,EAAE;IAoB/D;;;;;;OAMG;IACI,MAAM,CAAC,GAAG,EAAE,UAAU;IAI7B;;;;;;OAMG;IACI,QAAQ;IAIf,CAAC,OAAO,CAAC,MAAM,CAAC;IAIhB;;;;;;OAMG;IACI,gBAAgB;IAIvB;;;OAGG;IACI,QAAQ;IAIf;;;;;;OAMG;IACI,UAAU;IAMjB;;;;OAIG;IACI,OAAO;IAId;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,EAAE,EAAE,EAAE,GAAG,UAAU;IAIpC,MAAM,CAAC,UAAU,CAAC,MAAM,EAAE,EAAE,EAAE,GAAG,WAAW;IAK5C;;;;OAIG;IACH,MAAM,CAAC,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,YAAY,GAAG,UAAU;IAK5D,6DAA6D;IAC7D,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,UAAU;IAMnD,MAAM;IAIN,MAAM,KAAK,MAAM,mDAEhB;CACF"}
|
|
@@ -187,6 +187,11 @@ import { bufferToHex } from '../string/index.js';
|
|
|
187
187
|
const reader = BufferReader.asReader(buffer);
|
|
188
188
|
return new EthAddress(reader.readBytes(EthAddress.SIZE_IN_BYTES));
|
|
189
189
|
}
|
|
190
|
+
/** Converts a number into an address. Useful for testing. */ static fromNumber(num) {
|
|
191
|
+
const buffer = Buffer.alloc(EthAddress.SIZE_IN_BYTES);
|
|
192
|
+
buffer.writeBigUInt64BE(BigInt(num), 0);
|
|
193
|
+
return new EthAddress(buffer);
|
|
194
|
+
}
|
|
190
195
|
toJSON() {
|
|
191
196
|
return this.toString();
|
|
192
197
|
}
|
|
@@ -1,22 +1,20 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
3
1
|
import { Buffer32 } from '@aztec/foundation/buffer';
|
|
4
2
|
import { BufferReader } from '@aztec/foundation/serialize';
|
|
5
3
|
import { z } from 'zod';
|
|
6
|
-
/**
|
|
7
|
-
*
|
|
8
|
-
* A version of the Signature class that uses `0x${string}` values for r and s rather than
|
|
9
|
-
* Buffer32s
|
|
4
|
+
/**
|
|
5
|
+
* A version of the Signature class that uses `0x${string}` values for r and s rather than Buffer32s
|
|
10
6
|
*/
|
|
11
7
|
export type ViemSignature = {
|
|
12
8
|
r: `0x${string}`;
|
|
13
9
|
s: `0x${string}`;
|
|
14
10
|
v: number;
|
|
15
|
-
|
|
11
|
+
};
|
|
12
|
+
export type ViemTransactionSignature = {
|
|
13
|
+
r: `0x${string}`;
|
|
14
|
+
s: `0x${string}`;
|
|
15
|
+
yParity: 0 | 1;
|
|
16
16
|
};
|
|
17
17
|
/**
|
|
18
|
-
* Signature
|
|
19
|
-
*
|
|
20
18
|
* Contains a signature split into it's primary components (r,s,v)
|
|
21
19
|
*/
|
|
22
20
|
export declare class Signature {
|
|
@@ -26,18 +24,15 @@ export declare class Signature {
|
|
|
26
24
|
readonly s: Buffer32;
|
|
27
25
|
/** The v value of the signature */
|
|
28
26
|
readonly v: number;
|
|
29
|
-
/** Does this struct store an empty signature */
|
|
30
|
-
readonly isEmpty: boolean;
|
|
31
27
|
private size;
|
|
28
|
+
readonly empty: boolean;
|
|
32
29
|
constructor(
|
|
33
30
|
/** The r value of the signature */
|
|
34
31
|
r: Buffer32,
|
|
35
32
|
/** The s value of the signature */
|
|
36
33
|
s: Buffer32,
|
|
37
34
|
/** The v value of the signature */
|
|
38
|
-
v: number
|
|
39
|
-
/** Does this struct store an empty signature */
|
|
40
|
-
isEmpty?: boolean);
|
|
35
|
+
v: number);
|
|
41
36
|
static fromBuffer(buf: Buffer | BufferReader): Signature;
|
|
42
37
|
static isValidString(sig: `0x${string}`): boolean;
|
|
43
38
|
/**
|
|
@@ -46,8 +41,11 @@ export declare class Signature {
|
|
|
46
41
|
* default serialization of u32
|
|
47
42
|
*/
|
|
48
43
|
static fromString(sig: `0x${string}`): Signature;
|
|
44
|
+
static fromViemSignature(sig: ViemSignature): Signature;
|
|
45
|
+
static fromViemTransactionSignature(sig: ViemTransactionSignature): Signature;
|
|
49
46
|
static random(): Signature;
|
|
50
47
|
static empty(): Signature;
|
|
48
|
+
isEmpty(): boolean;
|
|
51
49
|
equals(other: Signature): boolean;
|
|
52
50
|
toBuffer(): Buffer;
|
|
53
51
|
getSize(): number;
|
|
@@ -56,6 +54,10 @@ export declare class Signature {
|
|
|
56
54
|
* Return the signature with `0x${string}` encodings for r and s
|
|
57
55
|
*/
|
|
58
56
|
toViemSignature(): ViemSignature;
|
|
57
|
+
/**
|
|
58
|
+
* Return the signature with `0x${string}` encodings for r and s. Verifies v is valid
|
|
59
|
+
*/
|
|
60
|
+
toViemTransactionSignature(): ViemTransactionSignature;
|
|
59
61
|
toJSON(): `0x${string}`;
|
|
60
62
|
static get schema(): z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, `0x${string}`, string>, `0x${string}`, string>, Signature, string>;
|
|
61
63
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eth_signature.d.ts","sourceRoot":"","sources":["../../src/eth-signature/eth_signature.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"eth_signature.d.ts","sourceRoot":"","sources":["../../src/eth-signature/eth_signature.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACpD,OAAO,EAAE,YAAY,EAAqB,MAAM,6BAA6B,CAAC;AAE9E,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG;IAC1B,CAAC,EAAE,KAAK,MAAM,EAAE,CAAC;IACjB,CAAC,EAAE,KAAK,MAAM,EAAE,CAAC;IACjB,CAAC,EAAE,MAAM,CAAC;CACX,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KAAK,MAAM,2HAMhB;CACF"}
|
|
@@ -3,29 +3,26 @@ import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
import { hasHexPrefix, hexToBuffer } from '../string/index.js';
|
|
5
5
|
/**
|
|
6
|
-
* Signature
|
|
7
|
-
*
|
|
8
6
|
* Contains a signature split into it's primary components (r,s,v)
|
|
9
7
|
*/ export class Signature {
|
|
10
8
|
r;
|
|
11
9
|
s;
|
|
12
10
|
v;
|
|
13
|
-
isEmpty;
|
|
14
11
|
// Cached values
|
|
15
12
|
size;
|
|
16
|
-
|
|
13
|
+
empty;
|
|
14
|
+
constructor(/** The r value of the signature */ r, /** The s value of the signature */ s, /** The v value of the signature */ v){
|
|
17
15
|
this.r = r;
|
|
18
16
|
this.s = s;
|
|
19
17
|
this.v = v;
|
|
20
|
-
this.
|
|
18
|
+
this.empty = r.isZero() && s.isZero() && v === 0;
|
|
21
19
|
}
|
|
22
20
|
static fromBuffer(buf) {
|
|
23
21
|
const reader = BufferReader.asReader(buf);
|
|
24
22
|
const r = reader.readObject(Buffer32);
|
|
25
23
|
const s = reader.readObject(Buffer32);
|
|
26
24
|
const v = reader.readNumber();
|
|
27
|
-
|
|
28
|
-
return new Signature(r, s, v, isEmpty);
|
|
25
|
+
return new Signature(r, s, v);
|
|
29
26
|
}
|
|
30
27
|
static isValidString(sig) {
|
|
31
28
|
return /^0x[0-9a-f]{129,}$/i.test(sig);
|
|
@@ -40,26 +37,32 @@ import { hasHexPrefix, hexToBuffer } from '../string/index.js';
|
|
|
40
37
|
const r = reader.readObject(Buffer32);
|
|
41
38
|
const s = reader.readObject(Buffer32);
|
|
42
39
|
const v = parseInt(sig.slice(2 + 64 * 2), 16);
|
|
43
|
-
|
|
44
|
-
|
|
40
|
+
return new Signature(r, s, v);
|
|
41
|
+
}
|
|
42
|
+
static fromViemSignature(sig) {
|
|
43
|
+
return new Signature(Buffer32.fromBuffer(hexToBuffer(sig.r)), Buffer32.fromBuffer(hexToBuffer(sig.s)), sig.v);
|
|
44
|
+
}
|
|
45
|
+
static fromViemTransactionSignature(sig) {
|
|
46
|
+
return new Signature(Buffer32.fromBuffer(hexToBuffer(sig.r)), Buffer32.fromBuffer(hexToBuffer(sig.s)), sig.yParity);
|
|
45
47
|
}
|
|
46
48
|
static random() {
|
|
47
|
-
return new Signature(Buffer32.random(), Buffer32.random(),
|
|
49
|
+
return new Signature(Buffer32.random(), Buffer32.random(), 1);
|
|
48
50
|
}
|
|
49
51
|
static empty() {
|
|
50
|
-
return new Signature(Buffer32.ZERO, Buffer32.ZERO, 0
|
|
52
|
+
return new Signature(Buffer32.ZERO, Buffer32.ZERO, 0);
|
|
53
|
+
}
|
|
54
|
+
isEmpty() {
|
|
55
|
+
return this.empty;
|
|
51
56
|
}
|
|
52
57
|
equals(other) {
|
|
53
|
-
return this.r.equals(other.r) && this.s.equals(other.s) && this.v === other.v && this.
|
|
58
|
+
return this.r.equals(other.r) && this.s.equals(other.s) && this.v === other.v && this.empty === other.empty;
|
|
54
59
|
}
|
|
55
60
|
toBuffer() {
|
|
56
|
-
|
|
61
|
+
return serializeToBuffer([
|
|
57
62
|
this.r,
|
|
58
63
|
this.s,
|
|
59
64
|
this.v
|
|
60
65
|
]);
|
|
61
|
-
this.size = buffer.length;
|
|
62
|
-
return buffer;
|
|
63
66
|
}
|
|
64
67
|
getSize() {
|
|
65
68
|
// We cache size to avoid recalculating it
|
|
@@ -78,8 +81,19 @@ import { hasHexPrefix, hexToBuffer } from '../string/index.js';
|
|
|
78
81
|
return {
|
|
79
82
|
r: this.r.toString(),
|
|
80
83
|
s: this.s.toString(),
|
|
81
|
-
v: this.v
|
|
82
|
-
|
|
84
|
+
v: this.v
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Return the signature with `0x${string}` encodings for r and s. Verifies v is valid
|
|
89
|
+
*/ toViemTransactionSignature() {
|
|
90
|
+
if (this.v !== 0 && this.v !== 1) {
|
|
91
|
+
throw new Error('Invalid transaction signature');
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
r: this.r.toString(),
|
|
95
|
+
s: this.s.toString(),
|
|
96
|
+
yParity: this.v
|
|
83
97
|
};
|
|
84
98
|
}
|
|
85
99
|
toJSON() {
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
import { inspect } from 'util';
|
|
2
|
+
import { BufferReader } from '../serialize/buffer_reader.js';
|
|
3
|
+
import { Fr } from './fields.js';
|
|
4
|
+
/**
|
|
5
|
+
* Base BLS12field class.
|
|
6
|
+
*/
|
|
7
|
+
export declare abstract class BLS12Field {
|
|
8
|
+
private asBuffer?;
|
|
9
|
+
private asBigInt?;
|
|
10
|
+
protected constructor(value: number | bigint | Buffer);
|
|
11
|
+
protected abstract modulus(): bigint;
|
|
12
|
+
protected abstract size(): number;
|
|
13
|
+
/**
|
|
14
|
+
* We return a copy of the Buffer to ensure this remains immutable.
|
|
15
|
+
*/
|
|
16
|
+
toBuffer(): Buffer;
|
|
17
|
+
toString(): `0x${string}`;
|
|
18
|
+
toBigInt(): bigint;
|
|
19
|
+
toNoirBigNum(): {
|
|
20
|
+
limbs: string[];
|
|
21
|
+
};
|
|
22
|
+
equals(rhs: BLS12Field): boolean;
|
|
23
|
+
lt(rhs: BLS12Field): boolean;
|
|
24
|
+
isZero(): boolean;
|
|
25
|
+
isEmpty(): boolean;
|
|
26
|
+
isNegative(): boolean;
|
|
27
|
+
toFriendlyJSON(): string;
|
|
28
|
+
toField(): this;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Fr field class.
|
|
32
|
+
* @dev This class is used to represent elements of BLS12-381 scalar field.
|
|
33
|
+
*/
|
|
34
|
+
export declare class BLS12Fr extends BLS12Field {
|
|
35
|
+
static SIZE_IN_BYTES: number;
|
|
36
|
+
static MODULUS: bigint;
|
|
37
|
+
static ZERO: BLS12Fr;
|
|
38
|
+
static ONE: BLS12Fr;
|
|
39
|
+
static MAX_FIELD_VALUE: BLS12Fr;
|
|
40
|
+
constructor(value: number | bigint | Buffer);
|
|
41
|
+
[inspect.custom](): string;
|
|
42
|
+
protected modulus(): bigint;
|
|
43
|
+
protected size(): number;
|
|
44
|
+
static random(): BLS12Fr;
|
|
45
|
+
static zero(): BLS12Fr;
|
|
46
|
+
static isZero(value: BLS12Fr): boolean;
|
|
47
|
+
static fromBuffer(buffer: Buffer | BufferReader): BLS12Fr;
|
|
48
|
+
/**
|
|
49
|
+
* Creates a BLS12Fr instance from a string.
|
|
50
|
+
* @param buf - the string to create a BLS12Fr from.
|
|
51
|
+
* @returns the BLS12Fr instance
|
|
52
|
+
* @remarks if the string only consists of numbers, we assume we are parsing a bigint,
|
|
53
|
+
* otherwise we require the hex string to be prepended with "0x", to ensure there is no misunderstanding
|
|
54
|
+
* as to what is being parsed.
|
|
55
|
+
*/
|
|
56
|
+
static fromString(buf: string): BLS12Fr;
|
|
57
|
+
/**
|
|
58
|
+
* Creates a BLS12Fr instance from a hex string.
|
|
59
|
+
* @param buf - a hex encoded string.
|
|
60
|
+
* @returns the BLS12Fr instance
|
|
61
|
+
*/
|
|
62
|
+
static fromHexString(buf: string): BLS12Fr;
|
|
63
|
+
/**
|
|
64
|
+
* Constructs a field from noir BigNum type.
|
|
65
|
+
*/
|
|
66
|
+
static fromNoirBigNum(bignum: {
|
|
67
|
+
limbs: string[];
|
|
68
|
+
}): BLS12Fr;
|
|
69
|
+
/**
|
|
70
|
+
* Creates a BLS12Fr instance from a BN254 Fr instance.
|
|
71
|
+
* @dev The BN254 field size < BLS12_381, so we cannot overflow here.
|
|
72
|
+
* Useful for blob related calculations.
|
|
73
|
+
* @param field - a BN254 Fr instance.
|
|
74
|
+
* @returns the BLS12Fr instance
|
|
75
|
+
*/
|
|
76
|
+
static fromBN254Fr(field: Fr): BLS12Fr;
|
|
77
|
+
/**
|
|
78
|
+
* Creates a BN254 Fr instance from a BLS12Fr instance.
|
|
79
|
+
* @dev The BN254 field size < BLS12_381, so we must check the size here
|
|
80
|
+
* Useful for blob related calculations.
|
|
81
|
+
* @param field - a BLS12Fr instance.
|
|
82
|
+
* @returns the BN254 Fr instance
|
|
83
|
+
*/
|
|
84
|
+
toBN254Fr(): Fr;
|
|
85
|
+
/** Arithmetic - wrapper around noble curves */
|
|
86
|
+
add(rhs: BLS12Fr): BLS12Fr;
|
|
87
|
+
square(): BLS12Fr;
|
|
88
|
+
negate(): BLS12Fr;
|
|
89
|
+
sub(rhs: BLS12Fr): BLS12Fr;
|
|
90
|
+
mul(rhs: BLS12Fr): BLS12Fr;
|
|
91
|
+
div(rhs: BLS12Fr): BLS12Fr;
|
|
92
|
+
sqrt(): BLS12Fr | null;
|
|
93
|
+
pow(rhs: bigint): BLS12Fr;
|
|
94
|
+
toJSON(): `0x${string}`;
|
|
95
|
+
static get schema(): import("zod").ZodType<BLS12Fr, any, string>;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Fq field class.
|
|
99
|
+
* @dev This class is used to represent elements of BLS12-381 base field.
|
|
100
|
+
*/
|
|
101
|
+
export declare class BLS12Fq extends BLS12Field {
|
|
102
|
+
static SIZE_IN_BYTES: number;
|
|
103
|
+
static MODULUS: bigint;
|
|
104
|
+
static ZERO: BLS12Fq;
|
|
105
|
+
static ONE: BLS12Fq;
|
|
106
|
+
static MAX_FIELD_VALUE: BLS12Fq;
|
|
107
|
+
constructor(value: number | bigint | Buffer);
|
|
108
|
+
[inspect.custom](): string;
|
|
109
|
+
protected modulus(): bigint;
|
|
110
|
+
protected size(): number;
|
|
111
|
+
static random(): BLS12Fq;
|
|
112
|
+
static zero(): BLS12Fq;
|
|
113
|
+
static isZero(value: BLS12Fq): boolean;
|
|
114
|
+
static fromBuffer(buffer: Buffer | BufferReader): BLS12Fq;
|
|
115
|
+
/**
|
|
116
|
+
* Creates a BLS12Fq instance from a string.
|
|
117
|
+
* @param buf - the string to create a BLS12Fq from.
|
|
118
|
+
* @returns the BLS12Fq instance
|
|
119
|
+
* @remarks if the string only consists of numbers, we assume we are parsing a bigint,
|
|
120
|
+
* otherwise we require the hex string to be prepended with "0x", to ensure there is no misunderstanding
|
|
121
|
+
* as to what is being parsed.
|
|
122
|
+
*/
|
|
123
|
+
static fromString(buf: string): BLS12Fq;
|
|
124
|
+
/**
|
|
125
|
+
* Creates a BLS12Fq instance from a hex string.
|
|
126
|
+
* @param buf - a hex encoded string.
|
|
127
|
+
* @returns the BLS12Fq instance
|
|
128
|
+
*/
|
|
129
|
+
static fromHexString(buf: string): BLS12Fq;
|
|
130
|
+
/**
|
|
131
|
+
* Constructs a field from noir BigNum type.
|
|
132
|
+
*/
|
|
133
|
+
static fromNoirBigNum(bignum: {
|
|
134
|
+
limbs: string[];
|
|
135
|
+
}): BLS12Fq;
|
|
136
|
+
/** Arithmetic - wrapper around noble curves */
|
|
137
|
+
add(rhs: BLS12Fq): BLS12Fq;
|
|
138
|
+
square(): BLS12Fq;
|
|
139
|
+
negate(): BLS12Fq;
|
|
140
|
+
sub(rhs: BLS12Fq): BLS12Fq;
|
|
141
|
+
mul(rhs: BLS12Fq): BLS12Fq;
|
|
142
|
+
div(rhs: BLS12Fq): BLS12Fq;
|
|
143
|
+
sqrt(): BLS12Fq | null;
|
|
144
|
+
pow(rhs: bigint): BLS12Fq;
|
|
145
|
+
toJSON(): `0x${string}`;
|
|
146
|
+
static get schema(): import("zod").ZodType<BLS12Fq, any, string>;
|
|
147
|
+
}
|
|
148
|
+
//# sourceMappingURL=bls12_fields.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bls12_fields.d.ts","sourceRoot":"","sources":["../../src/fields/bls12_fields.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAK/B,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAE7D,OAAO,EAAE,EAAE,EAAE,MAAM,aAAa,CAAC;AAcjC;;GAEG;AACH,8BAAsB,UAAU;IA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