@aztec/stdlib 0.0.1-commit.993d240 → 0.0.1-commit.9a89641
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/abi/abi.d.ts +32 -7
- package/dest/abi/abi.d.ts.map +1 -1
- package/dest/abi/abi.js +11 -2
- package/dest/abi/buffer.d.ts +6 -2
- package/dest/abi/buffer.d.ts.map +1 -1
- package/dest/abi/buffer.js +13 -1
- package/dest/abi/contract_artifact.d.ts +1 -1
- package/dest/abi/contract_artifact.d.ts.map +1 -1
- package/dest/abi/contract_artifact.js +35 -19
- package/dest/abi/decoder.d.ts +12 -5
- package/dest/abi/decoder.d.ts.map +1 -1
- package/dest/abi/decoder.js +18 -21
- package/dest/abi/function_call.d.ts +17 -8
- package/dest/abi/function_call.d.ts.map +1 -1
- package/dest/abi/function_call.js +28 -9
- package/dest/avm/avm.d.ts +212 -211
- package/dest/avm/avm.d.ts.map +1 -1
- package/dest/avm/avm.js +4 -2
- package/dest/avm/index.d.ts +1 -6
- package/dest/avm/index.d.ts.map +1 -1
- package/dest/avm/index.js +0 -5
- package/dest/aztec-address/index.d.ts +35 -5
- package/dest/aztec-address/index.d.ts.map +1 -1
- package/dest/aztec-address/index.js +32 -8
- package/dest/block/attestation_info.d.ts +1 -1
- package/dest/block/attestation_info.d.ts.map +1 -1
- package/dest/block/attestation_info.js +7 -4
- package/dest/block/l2_block_source.d.ts +57 -28
- package/dest/block/l2_block_source.d.ts.map +1 -1
- package/dest/block/l2_block_source.js +20 -2
- package/dest/block/l2_block_stream/event_driven_l2_block_stream.d.ts +39 -0
- package/dest/block/l2_block_stream/event_driven_l2_block_stream.d.ts.map +1 -0
- package/dest/block/l2_block_stream/event_driven_l2_block_stream.js +165 -0
- package/dest/block/l2_block_stream/index.d.ts +2 -1
- package/dest/block/l2_block_stream/index.d.ts.map +1 -1
- package/dest/block/l2_block_stream/index.js +1 -0
- package/dest/block/l2_block_stream/interfaces.d.ts +83 -11
- package/dest/block/l2_block_stream/interfaces.d.ts.map +1 -1
- package/dest/block/l2_block_stream/interfaces.js +25 -1
- package/dest/block/l2_block_stream/l2_block_stream.d.ts +24 -15
- package/dest/block/l2_block_stream/l2_block_stream.d.ts.map +1 -1
- package/dest/block/l2_block_stream/l2_block_stream.js +175 -151
- package/dest/block/l2_block_stream/l2_tips_memory_store.d.ts +6 -12
- package/dest/block/l2_block_stream/l2_tips_memory_store.d.ts.map +1 -1
- package/dest/block/l2_block_stream/l2_tips_memory_store.js +8 -32
- package/dest/block/l2_block_stream/l2_tips_store_base.d.ts +17 -18
- package/dest/block/l2_block_stream/l2_tips_store_base.d.ts.map +1 -1
- package/dest/block/l2_block_stream/l2_tips_store_base.js +70 -58
- package/dest/block/proposal/attestations_and_signers.d.ts +19 -1
- package/dest/block/proposal/attestations_and_signers.d.ts.map +1 -1
- package/dest/block/proposal/attestations_and_signers.js +47 -7
- package/dest/block/test/l2_tips_store_test_suite.d.ts +1 -1
- package/dest/block/test/l2_tips_store_test_suite.d.ts.map +1 -1
- package/dest/block/test/l2_tips_store_test_suite.js +301 -37
- package/dest/block/validate_block_result.d.ts +16 -1
- package/dest/block/validate_block_result.d.ts.map +1 -1
- package/dest/block/validate_block_result.js +18 -3
- package/dest/checkpoint/checkpoint.js +2 -2
- package/dest/checkpoint/index.d.ts +2 -1
- package/dest/checkpoint/index.d.ts.map +1 -1
- package/dest/checkpoint/index.js +1 -0
- package/dest/checkpoint/simulation_overrides.d.ts +61 -0
- package/dest/checkpoint/simulation_overrides.d.ts.map +1 -0
- package/dest/checkpoint/simulation_overrides.js +98 -0
- package/dest/checkpoint/validate.d.ts +11 -3
- package/dest/checkpoint/validate.d.ts.map +1 -1
- package/dest/checkpoint/validate.js +9 -6
- package/dest/config/index.d.ts +2 -2
- package/dest/config/index.d.ts.map +1 -1
- package/dest/config/index.js +1 -1
- package/dest/config/network-consensus-config.d.ts +72 -0
- package/dest/config/network-consensus-config.d.ts.map +1 -0
- package/dest/config/network-consensus-config.js +223 -0
- package/dest/config/node-rpc-config.d.ts +1 -1
- package/dest/config/node-rpc-config.d.ts.map +1 -1
- package/dest/config/node-rpc-config.js +1 -1
- package/dest/config/sequencer-config.d.ts +4 -2
- package/dest/config/sequencer-config.d.ts.map +1 -1
- package/dest/config/sequencer-config.js +22 -3
- package/dest/contract/artifact_hash.d.ts +2 -2
- package/dest/contract/artifact_hash.d.ts.map +1 -1
- package/dest/contract/artifact_hash.js +10 -2
- package/dest/contract/contract_address.d.ts +5 -4
- package/dest/contract/contract_address.d.ts.map +1 -1
- package/dest/contract/contract_class.d.ts +1 -1
- package/dest/contract/contract_class.d.ts.map +1 -1
- package/dest/contract/contract_class.js +3 -2
- package/dest/contract/contract_instance.d.ts +16 -2
- package/dest/contract/contract_instance.d.ts.map +1 -1
- package/dest/contract/contract_instance.js +45 -0
- package/dest/contract/index.d.ts +1 -2
- package/dest/contract/index.d.ts.map +1 -1
- package/dest/contract/index.js +0 -1
- package/dest/contract/interfaces/contract_data_source.d.ts +3 -5
- package/dest/contract/interfaces/contract_data_source.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_instance.d.ts +71 -10
- package/dest/contract/interfaces/contract_instance.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_instance.js +7 -2
- package/dest/contract/interfaces/node-info.d.ts +11 -1
- package/dest/contract/interfaces/node-info.d.ts.map +1 -1
- package/dest/contract/interfaces/node-info.js +7 -1
- package/dest/contract/partial_address.d.ts +9 -3
- package/dest/contract/partial_address.d.ts.map +1 -1
- package/dest/contract/partial_address.js +8 -2
- package/dest/database-version/version_manager.d.ts +18 -4
- package/dest/database-version/version_manager.d.ts.map +1 -1
- package/dest/database-version/version_manager.js +76 -6
- package/dest/deserialization/index.d.ts +35 -3
- package/dest/deserialization/index.d.ts.map +1 -1
- package/dest/deserialization/index.js +32 -1
- package/dest/file-store/factory.d.ts +1 -1
- package/dest/file-store/factory.d.ts.map +1 -1
- package/dest/file-store/factory.js +7 -0
- package/dest/file-store/index.d.ts +2 -1
- package/dest/file-store/index.d.ts.map +1 -1
- package/dest/file-store/index.js +1 -0
- package/dest/file-store/memory.d.ts +24 -0
- package/dest/file-store/memory.d.ts.map +1 -0
- package/dest/file-store/memory.js +80 -0
- package/dest/gas/gas_settings.d.ts +7 -13
- package/dest/gas/gas_settings.d.ts.map +1 -1
- package/dest/gas/gas_settings.js +9 -16
- package/dest/gas/index.d.ts +2 -1
- package/dest/gas/index.d.ts.map +1 -1
- package/dest/gas/index.js +1 -0
- package/dest/gas/tx_gas_limits.d.ts +72 -0
- package/dest/gas/tx_gas_limits.d.ts.map +1 -0
- package/dest/gas/tx_gas_limits.js +85 -0
- package/dest/ha-signing/config.d.ts +19 -5
- package/dest/ha-signing/config.d.ts.map +1 -1
- package/dest/ha-signing/config.js +9 -3
- package/dest/ha-signing/local_config.d.ts +10 -2
- package/dest/ha-signing/local_config.d.ts.map +1 -1
- package/dest/ha-signing/local_config.js +8 -2
- package/dest/hash/hash.d.ts +1 -2
- package/dest/hash/hash.d.ts.map +1 -1
- package/dest/hash/hash.js +0 -7
- package/dest/interfaces/api_limit.d.ts +6 -1
- package/dest/interfaces/api_limit.d.ts.map +1 -1
- package/dest/interfaces/api_limit.js +3 -0
- package/dest/interfaces/archiver.d.ts +12 -7
- package/dest/interfaces/archiver.d.ts.map +1 -1
- package/dest/interfaces/archiver.js +13 -6
- package/dest/interfaces/aztec-node-admin.d.ts +25 -17
- package/dest/interfaces/aztec-node-admin.d.ts.map +1 -1
- package/dest/interfaces/aztec-node-admin.js +1 -1
- package/dest/interfaces/aztec-node-debug.d.ts +40 -2
- package/dest/interfaces/aztec-node-debug.d.ts.map +1 -1
- package/dest/interfaces/aztec-node-debug.js +29 -1
- package/dest/interfaces/aztec-node.d.ts +100 -33
- package/dest/interfaces/aztec-node.d.ts.map +1 -1
- package/dest/interfaces/aztec-node.js +72 -23
- package/dest/interfaces/block-builder.d.ts +9 -2
- package/dest/interfaces/block-builder.d.ts.map +1 -1
- package/dest/interfaces/block_response.d.ts +5 -5
- package/dest/interfaces/block_response.d.ts.map +1 -1
- package/dest/interfaces/chain_tips.d.ts +8 -47
- package/dest/interfaces/chain_tips.d.ts.map +1 -1
- package/dest/interfaces/chain_tips.js +1 -6
- package/dest/interfaces/checkpoint_parameter.d.ts +3 -3
- package/dest/interfaces/checkpoint_parameter.d.ts.map +1 -1
- package/dest/interfaces/checkpoint_parameter.js +3 -3
- package/dest/interfaces/checkpoint_response.d.ts +5 -5
- package/dest/interfaces/checkpoint_response.d.ts.map +1 -1
- package/dest/interfaces/client.d.ts +2 -1
- package/dest/interfaces/client.d.ts.map +1 -1
- package/dest/interfaces/configs.d.ts +33 -6
- package/dest/interfaces/configs.d.ts.map +1 -1
- package/dest/interfaces/configs.js +6 -1
- package/dest/interfaces/get_tx_by_hash_options.d.ts +9 -0
- package/dest/interfaces/get_tx_by_hash_options.d.ts.map +1 -0
- package/dest/interfaces/get_tx_by_hash_options.js +4 -0
- package/dest/interfaces/merkle_tree_operations.d.ts +8 -3
- package/dest/interfaces/merkle_tree_operations.d.ts.map +1 -1
- package/dest/interfaces/p2p.d.ts +38 -9
- package/dest/interfaces/p2p.d.ts.map +1 -1
- package/dest/interfaces/p2p.js +14 -2
- package/dest/interfaces/private_kernel_prover.d.ts +71 -12
- package/dest/interfaces/private_kernel_prover.d.ts.map +1 -1
- package/dest/interfaces/prover-client.d.ts +2 -3
- package/dest/interfaces/prover-client.d.ts.map +1 -1
- package/dest/interfaces/prover-node.d.ts +12 -8
- package/dest/interfaces/prover-node.d.ts.map +1 -1
- package/dest/interfaces/prover-node.js +24 -17
- package/dest/interfaces/proving-job.d.ts +17 -4
- package/dest/interfaces/proving-job.d.ts.map +1 -1
- package/dest/interfaces/proving-job.js +13 -4
- package/dest/interfaces/server.d.ts +1 -3
- package/dest/interfaces/server.d.ts.map +1 -1
- package/dest/interfaces/server.js +0 -2
- package/dest/interfaces/server_circuit_prover.d.ts +3 -3
- package/dest/interfaces/server_circuit_prover.d.ts.map +1 -1
- package/dest/interfaces/tx_provider.d.ts +5 -1
- package/dest/interfaces/tx_provider.d.ts.map +1 -1
- package/dest/interfaces/validator.d.ts +15 -4
- package/dest/interfaces/validator.d.ts.map +1 -1
- package/dest/interfaces/validator.js +3 -1
- package/dest/interfaces/world_state.d.ts +14 -1
- package/dest/interfaces/world_state.d.ts.map +1 -1
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.d.ts +8 -2
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.d.ts.map +1 -1
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.js +12 -74
- package/dest/kernel/hints/index.d.ts +1 -2
- package/dest/kernel/hints/index.d.ts.map +1 -1
- package/dest/kernel/hints/index.js +0 -1
- package/dest/kernel/hints/read_request.js +1 -1
- package/dest/kernel/index.d.ts +6 -2
- package/dest/kernel/index.d.ts.map +1 -1
- package/dest/kernel/index.js +5 -1
- package/dest/kernel/log_hash.d.ts +1 -1
- package/dest/kernel/log_hash.d.ts.map +1 -1
- package/dest/kernel/log_hash.js +2 -2
- package/dest/kernel/note_hash.js +1 -1
- package/dest/kernel/nullifier.js +1 -1
- package/dest/kernel/private_circuit_public_inputs.d.ts +13 -3
- package/dest/kernel/private_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_circuit_public_inputs.js +14 -7
- package/dest/kernel/private_context_inputs.d.ts +4 -3
- package/dest/kernel/private_context_inputs.d.ts.map +1 -1
- package/dest/kernel/private_context_inputs.js +7 -3
- package/dest/kernel/private_kernel_circuit_public_inputs.d.ts +7 -9
- package/dest/kernel/private_kernel_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_circuit_public_inputs.js +10 -7
- package/dest/kernel/private_kernel_init_2_circuit_private_inputs.d.ts +2 -3
- package/dest/kernel/private_kernel_init_2_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_init_2_circuit_private_inputs.js +3 -5
- package/dest/kernel/private_kernel_init_3_circuit_private_inputs.d.ts +2 -3
- package/dest/kernel/private_kernel_init_3_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_init_3_circuit_private_inputs.js +3 -5
- package/dest/kernel/private_kernel_init_4_circuit_private_inputs.d.ts +24 -0
- package/dest/kernel/private_kernel_init_4_circuit_private_inputs.d.ts.map +1 -0
- package/dest/kernel/private_kernel_init_4_circuit_private_inputs.js +37 -0
- package/dest/kernel/private_kernel_init_5_circuit_private_inputs.d.ts +25 -0
- package/dest/kernel/private_kernel_init_5_circuit_private_inputs.d.ts.map +1 -0
- package/dest/kernel/private_kernel_init_5_circuit_private_inputs.js +39 -0
- package/dest/kernel/private_kernel_init_circuit_private_inputs.d.ts +1 -9
- package/dest/kernel/private_kernel_init_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_init_circuit_private_inputs.js +2 -6
- package/dest/kernel/private_kernel_inner_4_circuit_private_inputs.d.ts +18 -0
- package/dest/kernel/private_kernel_inner_4_circuit_private_inputs.d.ts.map +1 -0
- package/dest/kernel/private_kernel_inner_4_circuit_private_inputs.js +27 -0
- package/dest/kernel/private_kernel_inner_5_circuit_private_inputs.d.ts +19 -0
- package/dest/kernel/private_kernel_inner_5_circuit_private_inputs.d.ts.map +1 -0
- package/dest/kernel/private_kernel_inner_5_circuit_private_inputs.js +29 -0
- package/dest/kernel/private_kernel_prover_output.d.ts +4 -1
- package/dest/kernel/private_kernel_prover_output.d.ts.map +1 -1
- package/dest/kernel/private_kernel_prover_output.js +4 -1
- package/dest/kernel/private_kernel_reset_dimensions.d.ts +7 -8
- package/dest/kernel/private_kernel_reset_dimensions.d.ts.map +1 -1
- package/dest/kernel/private_kernel_reset_tail_circuit_private_inputs.d.ts +29 -0
- package/dest/kernel/private_kernel_reset_tail_circuit_private_inputs.d.ts.map +1 -0
- package/dest/kernel/private_kernel_reset_tail_circuit_private_inputs.js +36 -0
- package/dest/kernel/private_kernel_simulated_output.d.ts +1 -7
- package/dest/kernel/private_kernel_simulated_output.d.ts.map +1 -1
- package/dest/kernel/private_kernel_simulated_output.js +2 -1
- package/dest/kernel/private_log_data.d.ts +1 -1
- package/dest/kernel/private_log_data.d.ts.map +1 -1
- package/dest/kernel/private_log_data.js +1 -1
- package/dest/kernel/utils/index.d.ts +1 -2
- package/dest/kernel/utils/index.d.ts.map +1 -1
- package/dest/kernel/utils/index.js +0 -1
- package/dest/keys/derivation.d.ts +41 -6
- package/dest/keys/derivation.d.ts.map +1 -1
- package/dest/keys/derivation.js +49 -26
- package/dest/logs/app_tagging_secret.d.ts +30 -7
- package/dest/logs/app_tagging_secret.d.ts.map +1 -1
- package/dest/logs/app_tagging_secret.js +46 -39
- package/dest/logs/app_tagging_secret_kind.d.ts +2 -1
- package/dest/logs/app_tagging_secret_kind.d.ts.map +1 -1
- package/dest/logs/app_tagging_secret_kind.js +13 -0
- package/dest/logs/contract_class_log.d.ts +1 -2
- package/dest/logs/contract_class_log.d.ts.map +1 -1
- package/dest/logs/contract_class_log.js +0 -4
- package/dest/logs/log_result.d.ts +3 -3
- package/dest/logs/log_result.d.ts.map +1 -1
- package/dest/logs/logs_query.d.ts +2 -2
- package/dest/logs/message_context.d.ts +4 -13
- package/dest/logs/message_context.d.ts.map +1 -1
- package/dest/logs/message_context.js +1 -62
- package/dest/logs/pending_tagged_log.d.ts +6 -8
- package/dest/logs/pending_tagged_log.d.ts.map +1 -1
- package/dest/logs/pending_tagged_log.js +1 -31
- package/dest/logs/shared_secret_derivation.d.ts +29 -6
- package/dest/logs/shared_secret_derivation.d.ts.map +1 -1
- package/dest/logs/shared_secret_derivation.js +44 -11
- package/dest/messaging/l1_to_l2_message.d.ts +23 -2
- package/dest/messaging/l1_to_l2_message.d.ts.map +1 -1
- package/dest/messaging/l1_to_l2_message.js +36 -11
- package/dest/messaging/l2_to_l1_membership.d.ts +11 -4
- package/dest/messaging/l2_to_l1_membership.d.ts.map +1 -1
- package/dest/messaging/l2_to_l1_membership.js +22 -7
- package/dest/noir/index.d.ts +3 -3
- package/dest/noir/index.d.ts.map +1 -1
- package/dest/p2p/attestation_utils.d.ts +1 -1
- package/dest/p2p/attestation_utils.d.ts.map +1 -1
- package/dest/p2p/attestation_utils.js +8 -1
- package/dest/p2p/checkpoint_attestation.d.ts +10 -1
- package/dest/p2p/checkpoint_attestation.d.ts.map +1 -1
- package/dest/p2p/checkpoint_attestation.js +10 -0
- package/dest/p2p/checkpoint_proposal.d.ts +2 -1
- package/dest/p2p/checkpoint_proposal.d.ts.map +1 -1
- package/dest/p2p/consensus_payload.d.ts +2 -1
- package/dest/p2p/consensus_payload.d.ts.map +1 -1
- package/dest/p2p/index.d.ts +1 -2
- package/dest/p2p/index.d.ts.map +1 -1
- package/dest/p2p/index.js +0 -1
- package/dest/p2p/signature_utils.d.ts +10 -1
- package/dest/p2p/signature_utils.d.ts.map +1 -1
- package/dest/p2p/signature_utils.js +9 -1
- package/dest/rollup/avm_proof_data.d.ts +3 -3
- package/dest/rollup/avm_proof_data.d.ts.map +1 -1
- package/dest/rollup/checkpoint_header.d.ts +8 -3
- package/dest/rollup/checkpoint_header.d.ts.map +1 -1
- package/dest/rollup/checkpoint_header.js +20 -10
- package/dest/stats/stats.d.ts +2 -2
- package/dest/stats/stats.d.ts.map +1 -1
- package/dest/tests/factories.d.ts +1 -27
- package/dest/tests/factories.d.ts.map +1 -1
- package/dest/tests/factories.js +10 -45
- package/dest/tests/mocks.d.ts +1 -1
- package/dest/tests/mocks.d.ts.map +1 -1
- package/dest/tests/mocks.js +3 -2
- package/dest/timetable/budgets.d.ts +57 -0
- package/dest/timetable/budgets.d.ts.map +1 -0
- package/dest/timetable/budgets.js +56 -0
- package/dest/timetable/build_proposer_timetable.d.ts +21 -0
- package/dest/timetable/build_proposer_timetable.d.ts.map +1 -0
- package/dest/timetable/build_proposer_timetable.js +17 -0
- package/dest/timetable/consensus_timetable.d.ts +70 -0
- package/dest/timetable/consensus_timetable.d.ts.map +1 -0
- package/dest/timetable/consensus_timetable.js +89 -0
- package/dest/timetable/index.d.ts +5 -87
- package/dest/timetable/index.d.ts.map +1 -1
- package/dest/timetable/index.js +4 -243
- package/dest/timetable/proposer_timetable.d.ts +106 -0
- package/dest/timetable/proposer_timetable.d.ts.map +1 -0
- package/dest/timetable/proposer_timetable.js +132 -0
- package/dest/trees/nullifier_membership_witness.d.ts +5 -8
- package/dest/trees/nullifier_membership_witness.d.ts.map +1 -1
- package/dest/trees/nullifier_membership_witness.js +0 -9
- package/dest/trees/public_data_witness.d.ts +7 -17
- package/dest/trees/public_data_witness.d.ts.map +1 -1
- package/dest/trees/public_data_witness.js +0 -27
- package/dest/tx/execution_payload.d.ts +1 -1
- package/dest/tx/execution_payload.d.ts.map +1 -1
- package/dest/tx/execution_payload.js +1 -1
- package/dest/tx/fee_provider.d.ts +2 -2
- package/dest/tx/fee_provider.d.ts.map +1 -1
- package/dest/tx/global_variable_builder.d.ts +2 -12
- package/dest/tx/global_variable_builder.d.ts.map +1 -1
- package/dest/tx/global_variables.js +2 -2
- package/dest/tx/hashed_values.d.ts +7 -1
- package/dest/tx/hashed_values.d.ts.map +1 -1
- package/dest/tx/hashed_values.js +9 -1
- package/dest/tx/index.d.ts +1 -2
- package/dest/tx/index.d.ts.map +1 -1
- package/dest/tx/index.js +0 -1
- package/dest/tx/indexed_tx_effect.d.ts +5 -2
- package/dest/tx/indexed_tx_effect.d.ts.map +1 -1
- package/dest/tx/indexed_tx_effect.js +8 -4
- package/dest/tx/offchain_effect.js +1 -1
- package/dest/tx/private_tx_constant_data.d.ts +18 -2
- package/dest/tx/private_tx_constant_data.d.ts.map +1 -1
- package/dest/tx/private_tx_constant_data.js +13 -4
- package/dest/tx/profiling.d.ts +1 -1
- package/dest/tx/profiling.d.ts.map +1 -1
- package/dest/tx/profiling.js +2 -0
- package/dest/tx/simulated_tx.d.ts +10 -6
- package/dest/tx/simulated_tx.d.ts.map +1 -1
- package/dest/tx/simulated_tx.js +7 -2
- package/dest/tx/tx.d.ts +23 -1
- package/dest/tx/tx.d.ts.map +1 -1
- package/dest/tx/tx.js +32 -3
- package/dest/tx/tx_receipt.d.ts +143 -60
- package/dest/tx/tx_receipt.d.ts.map +1 -1
- package/dest/tx/tx_receipt.js +141 -45
- package/dest/tx/validator/error_texts.d.ts +2 -2
- package/dest/tx/validator/error_texts.d.ts.map +1 -1
- package/dest/tx/validator/error_texts.js +1 -1
- package/dest/validators/errors.d.ts +16 -1
- package/dest/validators/errors.d.ts.map +1 -1
- package/dest/validators/errors.js +12 -0
- package/dest/world-state/genesis_data.d.ts +9 -1
- package/dest/world-state/genesis_data.d.ts.map +1 -1
- package/dest/world-state/genesis_data.js +1 -0
- package/dest/world-state/world_state_revision.d.ts +1 -18
- package/dest/world-state/world_state_revision.d.ts.map +1 -1
- package/dest/world-state/world_state_revision.js +0 -20
- package/package.json +8 -8
- package/src/abi/abi.ts +32 -4
- package/src/abi/buffer.ts +13 -1
- package/src/abi/contract_artifact.ts +40 -16
- package/src/abi/decoder.ts +20 -24
- package/src/abi/function_call.ts +19 -7
- package/src/avm/avm.ts +5 -2
- package/src/avm/index.ts +0 -5
- package/src/aztec-address/index.ts +36 -6
- package/src/block/attestation_info.ts +7 -2
- package/src/block/l2_block_source.ts +95 -19
- package/src/block/l2_block_stream/event_driven_l2_block_stream.ts +207 -0
- package/src/block/l2_block_stream/index.ts +1 -0
- package/src/block/l2_block_stream/interfaces.ts +98 -10
- package/src/block/l2_block_stream/l2_block_stream.ts +255 -177
- package/src/block/l2_block_stream/l2_tips_memory_store.ts +12 -41
- package/src/block/l2_block_stream/l2_tips_store_base.ts +84 -93
- package/src/block/proposal/attestations_and_signers.ts +53 -7
- package/src/block/test/l2_tips_store_test_suite.ts +275 -28
- package/src/block/validate_block_result.ts +48 -2
- package/src/checkpoint/checkpoint.ts +2 -2
- package/src/checkpoint/index.ts +1 -0
- package/src/checkpoint/simulation_overrides.ts +171 -0
- package/src/checkpoint/validate.ts +16 -6
- package/src/config/index.ts +1 -1
- package/src/config/network-consensus-config.ts +291 -0
- package/src/config/node-rpc-config.ts +2 -1
- package/src/config/sequencer-config.ts +36 -5
- package/src/contract/artifact_hash.ts +15 -3
- package/src/contract/contract_address.ts +4 -3
- package/src/contract/contract_class.ts +3 -2
- package/src/contract/contract_instance.ts +62 -1
- package/src/contract/index.ts +0 -1
- package/src/contract/interfaces/contract_data_source.ts +2 -4
- package/src/contract/interfaces/contract_instance.ts +26 -8
- package/src/contract/interfaces/node-info.ts +11 -0
- package/src/contract/partial_address.ts +8 -2
- package/src/database-version/version_manager.ts +96 -6
- package/src/deserialization/index.ts +35 -2
- package/src/file-store/factory.ts +7 -0
- package/src/file-store/index.ts +1 -0
- package/src/file-store/memory.ts +94 -0
- package/src/gas/README.md +199 -35
- package/src/gas/gas_settings.ts +11 -21
- package/src/gas/index.ts +1 -0
- package/src/gas/tx_gas_limits.ts +123 -0
- package/src/ha-signing/config.ts +23 -5
- package/src/ha-signing/local_config.ts +20 -1
- package/src/hash/hash.ts +0 -8
- package/src/interfaces/api_limit.ts +5 -0
- package/src/interfaces/archiver.ts +22 -9
- package/src/interfaces/aztec-node-admin.ts +1 -1
- package/src/interfaces/aztec-node-debug.ts +54 -2
- package/src/interfaces/aztec-node.ts +175 -49
- package/src/interfaces/block-builder.ts +8 -1
- package/src/interfaces/block_response.ts +4 -4
- package/src/interfaces/chain_tips.ts +8 -16
- package/src/interfaces/checkpoint_parameter.ts +3 -3
- package/src/interfaces/checkpoint_response.ts +4 -4
- package/src/interfaces/client.ts +1 -0
- package/src/interfaces/configs.ts +33 -6
- package/src/interfaces/get_tx_by_hash_options.ts +14 -0
- package/src/interfaces/merkle_tree_operations.ts +8 -2
- package/src/interfaces/p2p.ts +29 -9
- package/src/interfaces/private_kernel_prover.ts +104 -13
- package/src/interfaces/prover-client.ts +1 -3
- package/src/interfaces/prover-node.ts +32 -17
- package/src/interfaces/proving-job.ts +15 -3
- package/src/interfaces/server.ts +0 -2
- package/src/interfaces/server_circuit_prover.ts +2 -2
- package/src/interfaces/tx_provider.ts +4 -0
- package/src/interfaces/validator.ts +11 -0
- package/src/interfaces/world_state.ts +14 -0
- package/src/kernel/hints/find_private_kernel_reset_dimensions.ts +22 -112
- package/src/kernel/hints/index.ts +0 -1
- package/src/kernel/hints/read_request.ts +1 -1
- package/src/kernel/index.ts +5 -1
- package/src/kernel/log_hash.ts +5 -2
- package/src/kernel/note_hash.ts +1 -1
- package/src/kernel/nullifier.ts +1 -1
- package/src/kernel/private_circuit_public_inputs.ts +12 -1
- package/src/kernel/private_context_inputs.ts +10 -3
- package/src/kernel/private_kernel_circuit_public_inputs.ts +9 -7
- package/src/kernel/private_kernel_init_2_circuit_private_inputs.ts +0 -3
- package/src/kernel/private_kernel_init_3_circuit_private_inputs.ts +0 -3
- package/src/kernel/private_kernel_init_4_circuit_private_inputs.ts +52 -0
- package/src/kernel/private_kernel_init_5_circuit_private_inputs.ts +55 -0
- package/src/kernel/private_kernel_init_circuit_private_inputs.ts +0 -6
- package/src/kernel/private_kernel_inner_4_circuit_private_inputs.ts +39 -0
- package/src/kernel/private_kernel_inner_5_circuit_private_inputs.ts +42 -0
- package/src/kernel/private_kernel_prover_output.ts +4 -0
- package/src/kernel/private_kernel_reset_dimensions.ts +16 -6
- package/src/kernel/private_kernel_reset_tail_circuit_private_inputs.ts +69 -0
- package/src/kernel/private_kernel_simulated_output.ts +0 -7
- package/src/kernel/private_log_data.ts +4 -1
- package/src/kernel/utils/index.ts +0 -1
- package/src/keys/derivation.ts +69 -24
- package/src/logs/app_tagging_secret.ts +62 -39
- package/src/logs/app_tagging_secret_kind.ts +15 -0
- package/src/logs/contract_class_log.ts +0 -9
- package/src/logs/log_result.ts +2 -2
- package/src/logs/logs_query.ts +2 -2
- package/src/logs/message_context.ts +6 -60
- package/src/logs/pending_tagged_log.ts +6 -33
- package/src/logs/shared_secret_derivation.ts +47 -14
- package/src/messaging/l1_to_l2_message.ts +51 -13
- package/src/messaging/l2_to_l1_membership.ts +28 -11
- package/src/noir/index.ts +2 -1
- package/src/p2p/attestation_utils.ts +8 -1
- package/src/p2p/checkpoint_attestation.ts +12 -0
- package/src/p2p/index.ts +0 -1
- package/src/p2p/signature_utils.ts +9 -0
- package/src/rollup/avm_proof_data.ts +2 -2
- package/src/rollup/checkpoint_header.ts +16 -2
- package/src/stats/stats.ts +6 -2
- package/src/tests/factories.ts +13 -51
- package/src/tests/mocks.ts +7 -2
- package/src/timetable/README.md +609 -0
- package/src/timetable/budgets.ts +87 -0
- package/src/timetable/build_proposer_timetable.ts +42 -0
- package/src/timetable/consensus_timetable.ts +126 -0
- package/src/timetable/index.ts +4 -361
- package/src/timetable/proposer_timetable.ts +190 -0
- package/src/timetable/timetable-example.svg +108 -0
- package/src/trees/nullifier_membership_witness.ts +0 -11
- package/src/trees/public_data_witness.ts +0 -31
- package/src/tx/execution_payload.ts +2 -1
- package/src/tx/fee_provider.ts +1 -1
- package/src/tx/global_variable_builder.ts +1 -17
- package/src/tx/global_variables.ts +2 -2
- package/src/tx/hashed_values.ts +11 -6
- package/src/tx/index.ts +0 -1
- package/src/tx/indexed_tx_effect.ts +17 -4
- package/src/tx/offchain_effect.ts +1 -1
- package/src/tx/private_tx_constant_data.ts +25 -2
- package/src/tx/profiling.ts +2 -0
- package/src/tx/simulated_tx.ts +13 -2
- package/src/tx/tx.ts +46 -3
- package/src/tx/tx_receipt.ts +263 -71
- package/src/tx/validator/error_texts.ts +2 -1
- package/src/validators/errors.ts +17 -0
- package/src/world-state/genesis_data.ts +10 -0
- package/src/world-state/world_state_revision.ts +0 -33
- package/dest/avm/contract_storage_read.d.ts +0 -58
- package/dest/avm/contract_storage_read.d.ts.map +0 -1
- package/dest/avm/contract_storage_read.js +0 -65
- package/dest/avm/contract_storage_update_request.d.ts +0 -65
- package/dest/avm/contract_storage_update_request.d.ts.map +0 -1
- package/dest/avm/contract_storage_update_request.js +0 -80
- package/dest/avm/public_call_stack_item_compressed.d.ts +0 -43
- package/dest/avm/public_call_stack_item_compressed.d.ts.map +0 -1
- package/dest/avm/public_call_stack_item_compressed.js +0 -70
- package/dest/avm/public_data_update_request.d.ts +0 -62
- package/dest/avm/public_data_update_request.d.ts.map +0 -1
- package/dest/avm/public_data_update_request.js +0 -67
- package/dest/avm/public_inner_call_request.d.ts +0 -50
- package/dest/avm/public_inner_call_request.d.ts.map +0 -1
- package/dest/avm/public_inner_call_request.js +0 -74
- package/dest/config/pipelining-config.d.ts +0 -15
- package/dest/config/pipelining-config.d.ts.map +0 -1
- package/dest/config/pipelining-config.js +0 -18
- package/dest/contract/deployment_info.d.ts +0 -24
- package/dest/contract/deployment_info.d.ts.map +0 -1
- package/dest/contract/deployment_info.js +0 -3
- package/dest/interfaces/epoch-prover.d.ts +0 -57
- package/dest/interfaces/epoch-prover.d.ts.map +0 -1
- package/dest/interfaces/epoch-prover.js +0 -1
- package/dest/interfaces/prover-coordination.d.ts +0 -15
- package/dest/interfaces/prover-coordination.d.ts.map +0 -1
- package/dest/interfaces/prover-coordination.js +0 -1
- package/dest/kernel/hints/tree_leaf_read_request.d.ts +0 -14
- package/dest/kernel/hints/tree_leaf_read_request.d.ts.map +0 -1
- package/dest/kernel/hints/tree_leaf_read_request.js +0 -33
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.d.ts +0 -47
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.d.ts.map +0 -1
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.js +0 -38
- package/dest/kernel/utils/optional_number.d.ts +0 -31
- package/dest/kernel/utils/optional_number.d.ts.map +0 -1
- package/dest/kernel/utils/optional_number.js +0 -42
- package/dest/p2p/interface.d.ts +0 -5
- package/dest/p2p/interface.d.ts.map +0 -1
- package/dest/p2p/interface.js +0 -1
- package/dest/tx/validator/empty_validator.d.ts +0 -5
- package/dest/tx/validator/empty_validator.d.ts.map +0 -1
- package/dest/tx/validator/empty_validator.js +0 -7
- package/src/avm/contract_storage_read.ts +0 -77
- package/src/avm/contract_storage_update_request.ts +0 -93
- package/src/avm/public_call_stack_item_compressed.ts +0 -113
- package/src/avm/public_data_update_request.ts +0 -106
- package/src/avm/public_inner_call_request.ts +0 -85
- package/src/config/pipelining-config.ts +0 -31
- package/src/contract/deployment_info.ts +0 -25
- package/src/interfaces/epoch-prover.ts +0 -72
- package/src/interfaces/prover-coordination.ts +0 -17
- package/src/kernel/hints/tree_leaf_read_request.ts +0 -35
- package/src/kernel/private_kernel_tail_circuit_private_inputs.ts +0 -58
- package/src/kernel/utils/optional_number.ts +0 -50
- package/src/p2p/interface.ts +0 -4
- package/src/tx/validator/empty_validator.ts +0 -7
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { range } from '@aztec/foundation/array';
|
|
3
|
-
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
1
|
+
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
2
|
|
|
5
3
|
import type { TxHash } from '../tx/tx_hash.js';
|
|
6
4
|
|
|
@@ -13,60 +11,8 @@ import type { TxHash } from '../tx/tx_hash.js';
|
|
|
13
11
|
*
|
|
14
12
|
* A TS version of `message_context.nr`.
|
|
15
13
|
*/
|
|
16
|
-
export
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
) {}
|
|
22
|
-
|
|
23
|
-
toFields(): Fr[] {
|
|
24
|
-
return [
|
|
25
|
-
this.txHash.hash,
|
|
26
|
-
...serializeBoundedVec(this.uniqueNoteHashesInTx, MAX_NOTE_HASHES_PER_TX),
|
|
27
|
-
this.firstNullifierInTx,
|
|
28
|
-
];
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
toNoirStruct() {
|
|
32
|
-
/* eslint-disable camelcase */
|
|
33
|
-
return {
|
|
34
|
-
tx_hash: this.txHash.hash,
|
|
35
|
-
unique_note_hashes_in_tx: this.uniqueNoteHashesInTx,
|
|
36
|
-
first_nullifier_in_tx: this.firstNullifierInTx,
|
|
37
|
-
};
|
|
38
|
-
/* eslint-enable camelcase */
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
static toEmptyFields(): Fr[] {
|
|
42
|
-
const serializationLen =
|
|
43
|
-
1 /* txHash */ + MAX_NOTE_HASHES_PER_TX + 1 /* uniqueNoteHashesInTx BVec */ + 1; /* firstNullifierInTx */
|
|
44
|
-
return range(serializationLen).map(_ => Fr.zero());
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
static toSerializedOption(response: MessageContext | null): Fr[] {
|
|
48
|
-
if (response) {
|
|
49
|
-
return [new Fr(1), ...response.toFields()];
|
|
50
|
-
} else {
|
|
51
|
-
return [new Fr(0), ...MessageContext.toEmptyFields()];
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* Helper function to serialize a bounded vector according to Noir's BoundedVec format
|
|
58
|
-
* @param values - The values to serialize
|
|
59
|
-
* @param maxLength - The maximum length of the bounded vector
|
|
60
|
-
* @returns The serialized bounded vector as Fr[]
|
|
61
|
-
* @dev Copied over from pending_tagged_log.ts.
|
|
62
|
-
*/
|
|
63
|
-
function serializeBoundedVec(values: Fr[], maxLength: number): Fr[] {
|
|
64
|
-
if (values.length > maxLength) {
|
|
65
|
-
throw new Error(`Attempted to serialize ${values} values into a BoundedVec with max length ${maxLength}`);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
const lengthDiff = maxLength - values.length;
|
|
69
|
-
const zeroPaddingArray = Array(lengthDiff).fill(Fr.ZERO);
|
|
70
|
-
const storage = values.concat(zeroPaddingArray);
|
|
71
|
-
return [...storage, new Fr(values.length)];
|
|
72
|
-
}
|
|
14
|
+
export type MessageContext = {
|
|
15
|
+
txHash: TxHash;
|
|
16
|
+
uniqueNoteHashesInTx: Fr[];
|
|
17
|
+
firstNullifierInTx: Fr;
|
|
18
|
+
};
|
|
@@ -1,39 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
1
|
+
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
2
|
|
|
4
|
-
import type {
|
|
5
|
-
import { MessageContext } from './message_context.js';
|
|
3
|
+
import type { MessageContext } from './message_context.js';
|
|
6
4
|
|
|
7
5
|
/**
|
|
8
6
|
* Represents a pending tagged log as it is stored in the pending tagged log array to which the fetchTaggedLogs oracle
|
|
9
7
|
* inserts found private logs. A TS version of `pending_tagged_log.nr`.
|
|
10
8
|
*/
|
|
11
|
-
export
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
public log: Fr[],
|
|
16
|
-
txHash: TxHash,
|
|
17
|
-
uniqueNoteHashesInTx: Fr[],
|
|
18
|
-
firstNullifierInTx: Fr,
|
|
19
|
-
) {
|
|
20
|
-
this.context = new MessageContext(txHash, uniqueNoteHashesInTx, firstNullifierInTx);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
toFields(): Fr[] {
|
|
24
|
-
return [...serializeBoundedVec(this.log, PRIVATE_LOG_SIZE_IN_FIELDS), ...this.context.toFields()];
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Helper function to serialize a bounded vector according to Noir's BoundedVec format
|
|
30
|
-
* @param values - The values to serialize
|
|
31
|
-
* @param maxLength - The maximum length of the bounded vector
|
|
32
|
-
* @returns The serialized bounded vector as Fr[]
|
|
33
|
-
*/
|
|
34
|
-
function serializeBoundedVec(values: Fr[], maxLength: number): Fr[] {
|
|
35
|
-
const lengthDiff = maxLength - values.length;
|
|
36
|
-
const zeroPaddingArray = Array(lengthDiff).fill(Fr.ZERO);
|
|
37
|
-
const storage = values.concat(zeroPaddingArray);
|
|
38
|
-
return [...storage, new Fr(values.length)];
|
|
39
|
-
}
|
|
9
|
+
export type PendingTaggedLog = {
|
|
10
|
+
log: Fr[];
|
|
11
|
+
context: MessageContext;
|
|
12
|
+
};
|
|
@@ -2,16 +2,28 @@ import { DomainSeparator } from '@aztec/constants';
|
|
|
2
2
|
import { Grumpkin } from '@aztec/foundation/crypto/grumpkin';
|
|
3
3
|
import { poseidon2HashWithSeparator } from '@aztec/foundation/crypto/poseidon';
|
|
4
4
|
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
5
|
-
import
|
|
5
|
+
import { GrumpkinScalar, type Point } from '@aztec/foundation/curves/grumpkin';
|
|
6
6
|
|
|
7
7
|
import type { AztecAddress } from '../aztec-address/index.js';
|
|
8
8
|
import type { PublicKey } from '../keys/public_key.js';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
|
-
* Derives
|
|
11
|
+
* Derives the raw ECDH shared secret point `S = secretKey * publicKey`.
|
|
12
12
|
*
|
|
13
|
-
*
|
|
14
|
-
|
|
13
|
+
* @throws If the publicKey is zero.
|
|
14
|
+
*/
|
|
15
|
+
export function deriveEcdhSharedSecretPoint(secretKey: GrumpkinScalar, publicKey: PublicKey): Promise<Point> {
|
|
16
|
+
if (publicKey.isZero()) {
|
|
17
|
+
throw new Error(
|
|
18
|
+
`Attempting to derive a shared secret with a zero public key. You have probably passed a zero public key in your Noir code somewhere thinking that the note won't be broadcast... but it was.`,
|
|
19
|
+
);
|
|
20
|
+
}
|
|
21
|
+
return Grumpkin.mul(publicKey, secretKey);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Derives an app-siloed ECDH shared secret from keys: ECDHs `S = secretKey * publicKey` via
|
|
26
|
+
* {@link deriveEcdhSharedSecretPoint}, then app-silos it via {@link appSiloEcdhSharedSecretPoint}.
|
|
15
27
|
*
|
|
16
28
|
* @param secretKey - The secret key used to derive shared secret.
|
|
17
29
|
* @param publicKey - The public key used to derive shared secret.
|
|
@@ -19,19 +31,40 @@ import type { PublicKey } from '../keys/public_key.js';
|
|
|
19
31
|
* @returns The app-siloed shared secret as a Field.
|
|
20
32
|
* @throws If the publicKey is zero.
|
|
21
33
|
*/
|
|
22
|
-
export async function
|
|
34
|
+
export async function appSiloEcdhSharedSecret(
|
|
23
35
|
secretKey: GrumpkinScalar,
|
|
24
36
|
publicKey: PublicKey,
|
|
25
37
|
contractAddress: AztecAddress,
|
|
26
38
|
): Promise<Fr> {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
39
|
+
const rawSharedSecret = await deriveEcdhSharedSecretPoint(secretKey, publicKey);
|
|
40
|
+
return appSiloEcdhSharedSecretPoint(rawSharedSecret, contractAddress);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* App-silos a shared secret point: `s_app = h(DOM_SEP__APP_SILOED_ECDH_SHARED_SECRET, S.x, S.y, app)`.
|
|
45
|
+
*
|
|
46
|
+
* Mirrors `compute_app_siloed_shared_secret` in aztec-nr.
|
|
47
|
+
*
|
|
48
|
+
* @param point - The raw shared secret point `S`.
|
|
49
|
+
* @param app - The contract address to silo to.
|
|
50
|
+
*/
|
|
51
|
+
export function appSiloEcdhSharedSecretPoint(point: Point, app: AztecAddress): Promise<Fr> {
|
|
52
|
+
return poseidon2HashWithSeparator([point.x, point.y, app], DomainSeparator.APP_SILOED_ECDH_SHARED_SECRET);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Protects a handshake's shared secret from being forged by the recipient: `S' = hash(ephPk, recipientPoint) * S`.
|
|
57
|
+
*
|
|
58
|
+
* Mirrors aztec-nr's `protect_from_forgery` and must stay byte-compatible with it.
|
|
59
|
+
*
|
|
60
|
+
* @param secret - The raw shared secret `S` to protect.
|
|
61
|
+
* @param ephPk - The handshake's ephemeral public key.
|
|
62
|
+
* @param recipientPoint - The recipient's address point.
|
|
63
|
+
*/
|
|
64
|
+
export async function protectFromForgery(secret: Point, ephPk: Point, recipientPoint: Point): Promise<Point> {
|
|
65
|
+
const scalar = await poseidon2HashWithSeparator(
|
|
66
|
+
[ephPk.x, ephPk.y, recipientPoint.x, recipientPoint.y],
|
|
67
|
+
DomainSeparator.HANDSHAKE_FORGERY_PROTECTION,
|
|
36
68
|
);
|
|
69
|
+
return Grumpkin.mul(secret, new GrumpkinScalar(scalar.toBigInt()));
|
|
37
70
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { DomainSeparator, type L1_TO_L2_MSG_TREE_HEIGHT } from '@aztec/constants';
|
|
2
|
+
import { poseidon2HashWithSeparator } from '@aztec/foundation/crypto/poseidon';
|
|
2
3
|
import { sha256ToField } from '@aztec/foundation/crypto/sha256';
|
|
3
4
|
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
5
|
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
@@ -7,7 +8,7 @@ import { SiblingPath } from '@aztec/foundation/trees';
|
|
|
7
8
|
|
|
8
9
|
import type { AztecAddress } from '../aztec-address/index.js';
|
|
9
10
|
import type { BlockParameter } from '../block/block_parameter.js';
|
|
10
|
-
import {
|
|
11
|
+
import { siloNullifier } from '../hash/hash.js';
|
|
11
12
|
import type { AztecNode } from '../interfaces/aztec-node.js';
|
|
12
13
|
import { MerkleTreeId } from '../trees/merkle_tree_id.js';
|
|
13
14
|
import { L1Actor } from './l1_actor.js';
|
|
@@ -74,28 +75,65 @@ export class L1ToL2Message {
|
|
|
74
75
|
}
|
|
75
76
|
}
|
|
76
77
|
|
|
77
|
-
|
|
78
|
-
|
|
78
|
+
/**
|
|
79
|
+
* The unsiloed nullifier a message consumer derives, together with the contract address needed to silo it.
|
|
80
|
+
*/
|
|
81
|
+
export interface UnsiloedMessageNullifier {
|
|
82
|
+
contractAddress: AztecAddress;
|
|
83
|
+
nullifier: Fr;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Computes the unsiloed nullifier that the fee juice contract (and any consumer following the same scheme) derives when
|
|
88
|
+
* consuming an L1 to L2 message.
|
|
89
|
+
*
|
|
90
|
+
* This is not a general-purpose utility: other contracts may derive the secret hash and hence the nullifier
|
|
91
|
+
* differently. The result is unsiloed — callers silo it (with the consuming contract's address) before looking it up
|
|
92
|
+
* in the nullifier tree.
|
|
93
|
+
*/
|
|
94
|
+
export function computeFeeJuiceMessageNullifier(messageHash: Fr, secret: Fr): Promise<Fr> {
|
|
95
|
+
return poseidon2HashWithSeparator([messageHash, secret], DomainSeparator.MESSAGE_NULLIFIER);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* Fetches the membership witness of an L1 to L2 message. When `unsiloedNullifier` is provided, the message is
|
|
100
|
+
* additionally required to be un-nullified.
|
|
101
|
+
*/
|
|
102
|
+
export async function getL1ToL2MessageWitness(
|
|
79
103
|
node: AztecNode,
|
|
80
|
-
contractAddress: AztecAddress,
|
|
81
104
|
messageHash: Fr,
|
|
82
|
-
|
|
105
|
+
unsiloedNullifier?: UnsiloedMessageNullifier,
|
|
83
106
|
referenceBlock: BlockParameter = 'latest',
|
|
84
107
|
): Promise<[bigint, SiblingPath<typeof L1_TO_L2_MSG_TREE_HEIGHT>]> {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
const
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
108
|
+
// Both requests are dispatched before awaiting so they run concurrently.
|
|
109
|
+
const l1ToL2ResponsePromise = node.getL1ToL2MessageMembershipWitness(referenceBlock, messageHash);
|
|
110
|
+
const nullifierResponsePromise = unsiloedNullifier
|
|
111
|
+
? siloNullifier(unsiloedNullifier.contractAddress, unsiloedNullifier.nullifier).then(siloed =>
|
|
112
|
+
node.findLeavesIndexes(referenceBlock, MerkleTreeId.NULLIFIER_TREE, [siloed]),
|
|
113
|
+
)
|
|
114
|
+
: undefined;
|
|
91
115
|
|
|
116
|
+
const l1ToL2Response = await l1ToL2ResponsePromise;
|
|
92
117
|
if (!l1ToL2Response) {
|
|
93
118
|
throw new Error(`No L1 to L2 message found for message hash ${messageHash.toString()}`);
|
|
94
119
|
}
|
|
95
120
|
|
|
96
|
-
|
|
121
|
+
const nullifierResponse = await nullifierResponsePromise;
|
|
122
|
+
if (nullifierResponse?.[0] !== undefined) {
|
|
97
123
|
throw new Error(`No non-nullified L1 to L2 message found for message hash ${messageHash.toString()}`);
|
|
98
124
|
}
|
|
99
125
|
|
|
100
126
|
return l1ToL2Response;
|
|
101
127
|
}
|
|
128
|
+
|
|
129
|
+
// This functionality is not on the node because we do not want to pass the node the secret, and give the node the ability to derive a valid nullifer for an L1 to L2 message.
|
|
130
|
+
export async function getNonNullifiedL1ToL2MessageWitness(
|
|
131
|
+
node: AztecNode,
|
|
132
|
+
contractAddress: AztecAddress,
|
|
133
|
+
messageHash: Fr,
|
|
134
|
+
secret: Fr,
|
|
135
|
+
referenceBlock: BlockParameter = 'latest',
|
|
136
|
+
): Promise<[bigint, SiblingPath<typeof L1_TO_L2_MSG_TREE_HEIGHT>]> {
|
|
137
|
+
const nullifier = await computeFeeJuiceMessageNullifier(messageHash, secret);
|
|
138
|
+
return getL1ToL2MessageWitness(node, messageHash, { contractAddress, nullifier }, referenceBlock);
|
|
139
|
+
}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import { MAX_CHECKPOINTS_PER_EPOCH, OUT_HASH_TREE_LEAF_COUNT } from '@aztec/constants';
|
|
2
|
-
import type
|
|
2
|
+
import { type EpochNumber, EpochNumberSchema } from '@aztec/foundation/branded-types';
|
|
3
3
|
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
4
|
import { SiblingPath, UnbalancedMerkleTreeCalculator, computeUnbalancedShaRoot } from '@aztec/foundation/trees';
|
|
5
5
|
|
|
6
|
+
import { z } from 'zod';
|
|
7
|
+
|
|
6
8
|
import type { AztecNode } from '../interfaces/aztec-node.js';
|
|
9
|
+
import { schemas } from '../schemas/schemas.js';
|
|
7
10
|
import { TxHash } from '../tx/tx_hash.js';
|
|
8
|
-
import { TxReceipt } from '../tx/tx_receipt.js';
|
|
11
|
+
import type { TxReceipt } from '../tx/tx_receipt.js';
|
|
9
12
|
|
|
10
13
|
/**
|
|
11
14
|
* Provides access to the L1 Outbox's per-epoch roots so the witness helper can pick the smallest
|
|
@@ -123,6 +126,19 @@ export type L2ToL1MembershipWitness = {
|
|
|
123
126
|
siblingPath: SiblingPath<number>;
|
|
124
127
|
};
|
|
125
128
|
|
|
129
|
+
/**
|
|
130
|
+
* Zod schema for {@link L2ToL1MembershipWitness}. The sibling-path length varies with the shape of
|
|
131
|
+
* the per-epoch tree, so we use the unsized `SiblingPath.schema` here rather than a fixed-height
|
|
132
|
+
* `schemaFor`.
|
|
133
|
+
*/
|
|
134
|
+
export const L2ToL1MembershipWitnessSchema = z.object({
|
|
135
|
+
epochNumber: EpochNumberSchema,
|
|
136
|
+
numCheckpointsInEpoch: schemas.Integer,
|
|
137
|
+
root: schemas.Fr,
|
|
138
|
+
leafIndex: schemas.BigInt,
|
|
139
|
+
siblingPath: SiblingPath.schema,
|
|
140
|
+
}) as unknown as z.ZodType<L2ToL1MembershipWitness>;
|
|
141
|
+
|
|
126
142
|
/**
|
|
127
143
|
* Computes the L2 to L1 membership witness for a given message in a transaction.
|
|
128
144
|
*
|
|
@@ -144,26 +160,27 @@ export type L2ToL1MembershipWitness = {
|
|
|
144
160
|
* If not provided, the message is found by scanning the tx's messages (throws if duplicates exist).
|
|
145
161
|
*/
|
|
146
162
|
export async function computeL2ToL1MembershipWitness(
|
|
147
|
-
node: Pick<AztecNode, 'getL2ToL1Messages' | 'getTxReceipt' | '
|
|
163
|
+
node: Pick<AztecNode, 'getL2ToL1Messages' | 'getTxReceipt' | 'getBlock' | 'getCheckpointsData'>,
|
|
148
164
|
outboxOrRoots: OutboxRootsReader | Fr[],
|
|
149
165
|
message: Fr,
|
|
150
|
-
txHashOrReceipt: TxHash | Pick<TxReceipt, 'txHash' | 'epochNumber' | 'blockNumber'>,
|
|
166
|
+
txHashOrReceipt: TxHash | Pick<TxReceipt, 'txHash' | 'epochNumber' | 'blockNumber' | 'txIndexInBlock'>,
|
|
151
167
|
messageIndexInTx?: number,
|
|
152
168
|
): Promise<L2ToL1MembershipWitness | undefined> {
|
|
153
|
-
const receipt =
|
|
154
|
-
|
|
155
|
-
|
|
169
|
+
const receipt =
|
|
170
|
+
'txHash' in txHashOrReceipt ? txHashOrReceipt : await node.getTxReceipt(txHashOrReceipt, { includeTxEffect: true });
|
|
171
|
+
|
|
172
|
+
const { epochNumber, blockNumber, txIndexInBlock } = receipt;
|
|
173
|
+
if (epochNumber === undefined || blockNumber === undefined || txIndexInBlock === undefined) {
|
|
156
174
|
return undefined;
|
|
157
175
|
}
|
|
158
176
|
|
|
159
|
-
const [messagesInEpoch, block,
|
|
177
|
+
const [messagesInEpoch, block, checkpointsData] = await Promise.all([
|
|
160
178
|
node.getL2ToL1Messages(epochNumber),
|
|
161
179
|
node.getBlock(blockNumber),
|
|
162
|
-
node.getTxEffect(txHash),
|
|
163
180
|
node.getCheckpointsData({ epoch: epochNumber }),
|
|
164
181
|
]);
|
|
165
182
|
|
|
166
|
-
if (messagesInEpoch.length === 0 || !block
|
|
183
|
+
if (messagesInEpoch.length === 0 || !block) {
|
|
167
184
|
return undefined;
|
|
168
185
|
}
|
|
169
186
|
|
|
@@ -173,7 +190,7 @@ export async function computeL2ToL1MembershipWitness(
|
|
|
173
190
|
}
|
|
174
191
|
|
|
175
192
|
const blockIndex = block.indexWithinCheckpoint;
|
|
176
|
-
const txIndex =
|
|
193
|
+
const txIndex = txIndexInBlock;
|
|
177
194
|
|
|
178
195
|
// Pick the smallest partial-proof root on the Outbox that covers checkpointIndex. The Outbox
|
|
179
196
|
// stores roots keyed by `numCheckpointsInEpoch - 1`, so to cover a tx in checkpoint at index
|
package/src/noir/index.ts
CHANGED
|
@@ -2,6 +2,7 @@ import type {
|
|
|
2
2
|
ABIParameter,
|
|
3
3
|
ABIParameterVisibility,
|
|
4
4
|
AbiErrorType,
|
|
5
|
+
AbiNamedValue,
|
|
5
6
|
AbiType,
|
|
6
7
|
AbiValue,
|
|
7
8
|
DebugFileMap,
|
|
@@ -73,7 +74,7 @@ export interface NoirCompiledContract {
|
|
|
73
74
|
/** The events of the contract */
|
|
74
75
|
outputs: {
|
|
75
76
|
structs: Record<string, AbiType[]>;
|
|
76
|
-
globals: Record<string, AbiValue[]>;
|
|
77
|
+
globals: Record<string, (AbiNamedValue | AbiValue)[]>;
|
|
77
78
|
};
|
|
78
79
|
/** The map of file ID to the source code and path of the file. */
|
|
79
80
|
file_map: DebugFileMap;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { normalizeSignature } from '@aztec/foundation/crypto/secp256k1-signer';
|
|
1
2
|
import type { EthAddress } from '@aztec/foundation/eth-address';
|
|
2
3
|
|
|
3
4
|
import { CommitteeAttestation } from '../block/index.js';
|
|
@@ -18,9 +19,15 @@ export function orderAttestations(
|
|
|
18
19
|
for (const attestation of attestations) {
|
|
19
20
|
const sender = attestation.getSender();
|
|
20
21
|
if (sender) {
|
|
22
|
+
// Canonicalize the recovery byte to v ∈ {27, 28} before it reaches the L1 bundle. A committee
|
|
23
|
+
// member (or a peer mutating the byte in flight) can emit an equivalent signature in yParity form
|
|
24
|
+
// (v = 0/1); left as-is it makes `packAttestations` (empty iff v === 0) and `getSigners` (empty iff
|
|
25
|
+
// r,s,v all zero) disagree, reverting `propose()` with SignersSizeMismatch, and a v = 1 byte would
|
|
26
|
+
// later revert epoch proving in ECDSA.recover. `sender` recovered, so the signature is non-empty
|
|
27
|
+
// and low-s, and normalizeSignature preserves the recovered address.
|
|
21
28
|
attestationMap.set(
|
|
22
29
|
sender.toString(),
|
|
23
|
-
CommitteeAttestation.fromAddressAndSignature(sender, attestation.signature),
|
|
30
|
+
CommitteeAttestation.fromAddressAndSignature(sender, normalizeSignature(attestation.signature)),
|
|
24
31
|
);
|
|
25
32
|
}
|
|
26
33
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CheckpointProposalHash, type SlotNumber } from '@aztec/foundation/branded-types';
|
|
2
2
|
import { type BaseBuffer32, Buffer32 } from '@aztec/foundation/buffer';
|
|
3
|
+
import { normalizeSignature } from '@aztec/foundation/crypto/secp256k1-signer';
|
|
3
4
|
import type { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
5
|
import type { EthAddress } from '@aztec/foundation/eth-address';
|
|
5
6
|
import { Signature } from '@aztec/foundation/eth-signature';
|
|
@@ -97,6 +98,17 @@ export class CheckpointAttestation extends Gossipable {
|
|
|
97
98
|
return this.cachedProposer ?? undefined;
|
|
98
99
|
}
|
|
99
100
|
|
|
101
|
+
/**
|
|
102
|
+
* Returns a copy with the attester signature canonicalized to v ∈ {27, 28}. Callers store attestations
|
|
103
|
+
* received from gossip verbatim; normalizing on ingress keeps a signature emitted in yParity form
|
|
104
|
+
* (v = 0/1) — whether by a malicious committee member or a peer mutating the byte in flight — from
|
|
105
|
+
* reaching the L1 bundle in a non-canonical form. Must only be called once the signature has recovered
|
|
106
|
+
* a sender (so it is non-empty and low-s); `normalizeSignature` throws on an all-zero signature.
|
|
107
|
+
*/
|
|
108
|
+
withNormalizedSignature(): CheckpointAttestation {
|
|
109
|
+
return new CheckpointAttestation(this.payload, normalizeSignature(this.signature), this.proposerSignature);
|
|
110
|
+
}
|
|
111
|
+
|
|
100
112
|
getPayload(): Buffer {
|
|
101
113
|
return this.payload.getPayloadToSign();
|
|
102
114
|
}
|
package/src/p2p/index.ts
CHANGED
|
@@ -4,7 +4,6 @@ export * from './checkpoint_attestation.js';
|
|
|
4
4
|
export * from './checkpoint_proposal.js';
|
|
5
5
|
export * from './consensus_payload.js';
|
|
6
6
|
export * from './gossipable.js';
|
|
7
|
-
export * from './interface.js';
|
|
8
7
|
export * from './signature_utils.js';
|
|
9
8
|
export * from './signed_txs.js';
|
|
10
9
|
export * from './topic_type.js';
|
|
@@ -112,6 +112,15 @@ export function getHashedSignaturePayloadTypedData(signable: Signable): Buffer32
|
|
|
112
112
|
return Buffer32.fromString(hashTypedData(getCoordinationSignatureTypedData(signable)));
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
+
/**
|
|
116
|
+
* Recovers the sender of a gossiped coordination message. Deliberately lenient (allowYParityAsV): a
|
|
117
|
+
* signature whose recovery byte is in yParity form (v ∈ {0, 1}) still resolves to its sender, so the P2P
|
|
118
|
+
* layer can attribute and accept it and then canonicalize on ingress (CheckpointAttestation.
|
|
119
|
+
* withNormalizedSignature, A-1351) before it reaches the L1 bundle. This is intentionally looser than
|
|
120
|
+
* on-chain checkpoint validation (getAttestationInfoFromPayload), which recovers strictly to mirror L1's
|
|
121
|
+
* ECDSA.recover — do not unify the two. These proposal/attestation signatures are P2P-only and never reach
|
|
122
|
+
* L1 verbatim, so leniency here cannot leak a non-canonical byte onto L1.
|
|
123
|
+
*/
|
|
115
124
|
export function recoverCoordinationSigner(signable: Signable, signature: Signature): EthAddress | undefined {
|
|
116
125
|
const digest = getHashedSignaturePayloadTypedData(signable);
|
|
117
126
|
return tryRecoverAddress(digest, signature, { allowYParityAsV: true });
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AVM_V2_PROOF_LENGTH_IN_FIELDS } from '@aztec/constants';
|
|
2
2
|
|
|
3
3
|
import { AvmCircuitPublicInputs } from '../avm/avm_circuit_public_inputs.js';
|
|
4
4
|
import type { ProofDataForFixedVk } from '../proofs/proof_data.js';
|
|
5
5
|
|
|
6
|
-
export type AvmProofData = ProofDataForFixedVk<AvmCircuitPublicInputs, typeof
|
|
6
|
+
export type AvmProofData = ProofDataForFixedVk<AvmCircuitPublicInputs, typeof AVM_V2_PROOF_LENGTH_IN_FIELDS>;
|
|
@@ -52,6 +52,8 @@ export class CheckpointHeader {
|
|
|
52
52
|
public gasFees: GasFees,
|
|
53
53
|
/** Total mana used in the block, computed by the root rollup circuit */
|
|
54
54
|
public totalManaUsed: Fr,
|
|
55
|
+
/** Total fees accrued across the checkpoint. */
|
|
56
|
+
public accumulatedFees: Fr,
|
|
55
57
|
) {}
|
|
56
58
|
|
|
57
59
|
static get schema(): ZodFor<CheckpointHeader> {
|
|
@@ -68,6 +70,7 @@ export class CheckpointHeader {
|
|
|
68
70
|
feeRecipient: schemas.AztecAddress,
|
|
69
71
|
gasFees: GasFees.schema,
|
|
70
72
|
totalManaUsed: schemas.Fr,
|
|
73
|
+
accumulatedFees: schemas.Fr,
|
|
71
74
|
})
|
|
72
75
|
.transform(CheckpointHeader.from);
|
|
73
76
|
}
|
|
@@ -85,6 +88,7 @@ export class CheckpointHeader {
|
|
|
85
88
|
fields.feeRecipient,
|
|
86
89
|
fields.gasFees,
|
|
87
90
|
fields.totalManaUsed,
|
|
91
|
+
fields.accumulatedFees,
|
|
88
92
|
] as const;
|
|
89
93
|
}
|
|
90
94
|
|
|
@@ -107,6 +111,7 @@ export class CheckpointHeader {
|
|
|
107
111
|
reader.readObject(AztecAddress),
|
|
108
112
|
reader.readObject(GasFees),
|
|
109
113
|
reader.readObject(Fr),
|
|
114
|
+
reader.readObject(Fr),
|
|
110
115
|
);
|
|
111
116
|
}
|
|
112
117
|
|
|
@@ -122,7 +127,8 @@ export class CheckpointHeader {
|
|
|
122
127
|
this.coinbase.equals(other.coinbase) &&
|
|
123
128
|
this.feeRecipient.equals(other.feeRecipient) &&
|
|
124
129
|
this.gasFees.equals(other.gasFees) &&
|
|
125
|
-
this.totalManaUsed.equals(other.totalManaUsed)
|
|
130
|
+
this.totalManaUsed.equals(other.totalManaUsed) &&
|
|
131
|
+
this.accumulatedFees.equals(other.accumulatedFees)
|
|
126
132
|
);
|
|
127
133
|
}
|
|
128
134
|
|
|
@@ -151,6 +157,7 @@ export class CheckpointHeader {
|
|
|
151
157
|
this.feeRecipient,
|
|
152
158
|
this.gasFees,
|
|
153
159
|
this.totalManaUsed,
|
|
160
|
+
this.accumulatedFees,
|
|
154
161
|
]);
|
|
155
162
|
}
|
|
156
163
|
|
|
@@ -171,6 +178,7 @@ export class CheckpointHeader {
|
|
|
171
178
|
feeRecipient: AztecAddress.ZERO,
|
|
172
179
|
gasFees: GasFees.empty(),
|
|
173
180
|
totalManaUsed: Fr.ZERO,
|
|
181
|
+
accumulatedFees: Fr.ZERO,
|
|
174
182
|
...fields,
|
|
175
183
|
});
|
|
176
184
|
}
|
|
@@ -188,6 +196,7 @@ export class CheckpointHeader {
|
|
|
188
196
|
feeRecipient: new AztecAddress(Fr.random()),
|
|
189
197
|
gasFees: GasFees.random(),
|
|
190
198
|
totalManaUsed: new Fr(BigInt(Math.floor(Math.random() * 1000000))),
|
|
199
|
+
accumulatedFees: new Fr(BigInt(Math.floor(Math.random() * 1000000))),
|
|
191
200
|
...overrides,
|
|
192
201
|
});
|
|
193
202
|
}
|
|
@@ -204,7 +213,8 @@ export class CheckpointHeader {
|
|
|
204
213
|
this.coinbase.isZero() &&
|
|
205
214
|
this.feeRecipient.isZero() &&
|
|
206
215
|
this.gasFees.isEmpty() &&
|
|
207
|
-
this.totalManaUsed.isZero()
|
|
216
|
+
this.totalManaUsed.isZero() &&
|
|
217
|
+
this.accumulatedFees.isZero()
|
|
208
218
|
);
|
|
209
219
|
}
|
|
210
220
|
|
|
@@ -233,6 +243,7 @@ export class CheckpointHeader {
|
|
|
233
243
|
new AztecAddress(hexToBuffer(header.feeRecipient)),
|
|
234
244
|
new GasFees(header.gasFees.feePerDaGas, header.gasFees.feePerL2Gas),
|
|
235
245
|
new Fr(header.totalManaUsed),
|
|
246
|
+
new Fr(header.accumulatedFees),
|
|
236
247
|
);
|
|
237
248
|
}
|
|
238
249
|
|
|
@@ -260,6 +271,7 @@ export class CheckpointHeader {
|
|
|
260
271
|
feePerL2Gas: this.gasFees.feePerL2Gas,
|
|
261
272
|
},
|
|
262
273
|
totalManaUsed: this.totalManaUsed.toBigInt(),
|
|
274
|
+
accumulatedFees: this.accumulatedFees.toBigInt(),
|
|
263
275
|
};
|
|
264
276
|
}
|
|
265
277
|
|
|
@@ -276,6 +288,7 @@ export class CheckpointHeader {
|
|
|
276
288
|
feeRecipient: this.feeRecipient.toString(),
|
|
277
289
|
gasFees: this.gasFees.toInspect(),
|
|
278
290
|
totalManaUsed: this.totalManaUsed.toBigInt(),
|
|
291
|
+
accumulatedFees: this.accumulatedFees.toBigInt(),
|
|
279
292
|
};
|
|
280
293
|
}
|
|
281
294
|
|
|
@@ -292,6 +305,7 @@ export class CheckpointHeader {
|
|
|
292
305
|
feeRecipient: ${this.feeRecipient.toString()},
|
|
293
306
|
gasFees: { da:${this.gasFees.feePerDaGas}, l2:${this.gasFees.feePerL2Gas} },
|
|
294
307
|
totalManaUsed: ${this.totalManaUsed.toBigInt()},
|
|
308
|
+
accumulatedFees: ${this.accumulatedFees.toBigInt()},
|
|
295
309
|
}`;
|
|
296
310
|
}
|
|
297
311
|
}
|
package/src/stats/stats.ts
CHANGED
|
@@ -86,12 +86,16 @@ export type ClientCircuitName =
|
|
|
86
86
|
| 'private-kernel-init'
|
|
87
87
|
| 'private-kernel-init-2'
|
|
88
88
|
| 'private-kernel-init-3'
|
|
89
|
+
| 'private-kernel-init-4'
|
|
90
|
+
| 'private-kernel-init-5'
|
|
89
91
|
| 'private-kernel-inner'
|
|
90
92
|
| 'private-kernel-inner-2'
|
|
91
93
|
| 'private-kernel-inner-3'
|
|
94
|
+
| 'private-kernel-inner-4'
|
|
95
|
+
| 'private-kernel-inner-5'
|
|
92
96
|
| 'private-kernel-reset'
|
|
93
|
-
| 'private-kernel-tail'
|
|
94
|
-
| 'private-kernel-tail-to-public'
|
|
97
|
+
| 'private-kernel-reset-tail'
|
|
98
|
+
| 'private-kernel-reset-tail-to-public'
|
|
95
99
|
| 'hiding-kernel-to-rollup'
|
|
96
100
|
| 'hiding-kernel-to-public'
|
|
97
101
|
| 'app-circuit';
|