@aztec/stdlib 0.0.1-commit.9b94fc1 → 0.0.1-commit.9badcec54
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 +740 -5
- package/dest/abi/abi.d.ts.map +1 -1
- package/dest/abi/abi.js +17 -9
- package/dest/abi/authorization_selector.d.ts +4 -7
- package/dest/abi/authorization_selector.d.ts.map +1 -1
- package/dest/abi/authorization_selector.js +2 -1
- package/dest/abi/buffer.d.ts +15 -5
- package/dest/abi/buffer.d.ts.map +1 -1
- package/dest/abi/buffer.js +26 -5
- package/dest/abi/contract_artifact.d.ts +2 -2
- package/dest/abi/contract_artifact.d.ts.map +1 -1
- package/dest/abi/contract_artifact.js +1 -1
- package/dest/abi/decoder.d.ts +7 -46
- package/dest/abi/decoder.d.ts.map +1 -1
- package/dest/abi/decoder.js +17 -70
- package/dest/abi/encoder.d.ts +2 -2
- package/dest/abi/encoder.d.ts.map +1 -1
- package/dest/abi/encoder.js +65 -8
- package/dest/abi/event_metadata_definition.d.ts +3 -1
- package/dest/abi/event_metadata_definition.d.ts.map +1 -1
- package/dest/abi/event_metadata_definition.js +1 -1
- package/dest/abi/event_selector.d.ts +4 -7
- package/dest/abi/event_selector.d.ts.map +1 -1
- package/dest/abi/event_selector.js +2 -1
- package/dest/abi/function_call.d.ts +48 -10
- package/dest/abi/function_call.d.ts.map +1 -1
- package/dest/abi/function_call.js +20 -3
- package/dest/abi/function_selector.d.ts +5 -7
- package/dest/abi/function_selector.d.ts.map +1 -1
- package/dest/abi/function_selector.js +11 -5
- package/dest/abi/function_signature_decoder.d.ts +43 -0
- package/dest/abi/function_signature_decoder.d.ts.map +1 -0
- package/dest/abi/function_signature_decoder.js +66 -0
- package/dest/abi/index.d.ts +2 -1
- package/dest/abi/index.d.ts.map +1 -1
- package/dest/abi/index.js +1 -0
- package/dest/abi/note_selector.d.ts +4 -7
- package/dest/abi/note_selector.d.ts.map +1 -1
- package/dest/abi/note_selector.js +3 -5
- package/dest/abi/selector.d.ts +3 -3
- package/dest/abi/selector.d.ts.map +1 -1
- package/dest/abi/selector.js +5 -3
- package/dest/abi/utils.d.ts +20 -1
- package/dest/abi/utils.d.ts.map +1 -1
- package/dest/abi/utils.js +22 -0
- package/dest/auth_witness/auth_witness.d.ts +3 -2
- package/dest/auth_witness/auth_witness.d.ts.map +1 -1
- package/dest/auth_witness/auth_witness.js +5 -5
- package/dest/avm/avm.d.ts +298 -86
- package/dest/avm/avm.d.ts.map +1 -1
- package/dest/avm/avm.js +238 -22
- package/dest/avm/avm_accumulated_data.d.ts +31 -4
- package/dest/avm/avm_accumulated_data.d.ts.map +1 -1
- package/dest/avm/avm_accumulated_data.js +6 -3
- package/dest/avm/avm_circuit_public_inputs.d.ts +14 -12
- package/dest/avm/avm_circuit_public_inputs.d.ts.map +1 -1
- package/dest/avm/avm_circuit_public_inputs.js +4 -2
- package/dest/avm/avm_proving_request.d.ts +472 -468
- package/dest/avm/avm_proving_request.d.ts.map +1 -1
- package/dest/avm/contract_storage_read.d.ts +14 -2
- package/dest/avm/contract_storage_read.d.ts.map +1 -1
- package/dest/avm/contract_storage_read.js +1 -1
- package/dest/avm/contract_storage_update_request.d.ts +14 -2
- package/dest/avm/contract_storage_update_request.d.ts.map +1 -1
- package/dest/avm/contract_storage_update_request.js +1 -1
- package/dest/avm/message_pack.d.ts +1 -1
- package/dest/avm/message_pack.d.ts.map +1 -1
- package/dest/avm/message_pack.js +2 -1
- package/dest/avm/public_call_stack_item_compressed.d.ts +4 -2
- package/dest/avm/public_call_stack_item_compressed.d.ts.map +1 -1
- package/dest/avm/public_call_stack_item_compressed.js +1 -1
- package/dest/avm/public_data_read.d.ts +11 -2
- package/dest/avm/public_data_read.d.ts.map +1 -1
- package/dest/avm/public_data_read.js +1 -1
- package/dest/avm/public_data_update_request.d.ts +11 -2
- package/dest/avm/public_data_update_request.d.ts.map +1 -1
- package/dest/avm/public_data_update_request.js +4 -2
- package/dest/avm/public_data_write.d.ts +8 -2
- package/dest/avm/public_data_write.d.ts.map +1 -1
- package/dest/avm/public_data_write.js +1 -1
- package/dest/avm/public_inner_call_request.d.ts +5 -2
- package/dest/avm/public_inner_call_request.d.ts.map +1 -1
- package/dest/avm/public_inner_call_request.js +3 -1
- package/dest/avm/revert_code.d.ts +13 -8
- package/dest/avm/revert_code.d.ts.map +1 -1
- package/dest/avm/revert_code.js +20 -23
- package/dest/aztec-address/index.d.ts +5 -7
- package/dest/aztec-address/index.d.ts.map +1 -1
- package/dest/aztec-address/index.js +6 -5
- package/dest/block/attestation_info.d.ts +5 -5
- package/dest/block/attestation_info.d.ts.map +1 -1
- package/dest/block/attestation_info.js +5 -5
- package/dest/block/block_data.d.ts +52 -0
- package/dest/block/block_data.d.ts.map +1 -0
- package/dest/block/block_data.js +12 -0
- package/dest/block/block_hash.d.ts +20 -15
- package/dest/block/block_hash.d.ts.map +1 -1
- package/dest/block/block_hash.js +23 -20
- package/dest/block/block_parameter.d.ts +6 -0
- package/dest/block/block_parameter.d.ts.map +1 -0
- package/dest/block/block_parameter.js +8 -0
- package/dest/block/body.d.ts +1 -1
- package/dest/block/body.d.ts.map +1 -1
- package/dest/block/body.js +5 -2
- package/dest/block/checkpointed_l2_block.d.ts +150 -0
- package/dest/block/checkpointed_l2_block.d.ts.map +1 -0
- package/dest/block/checkpointed_l2_block.js +46 -0
- package/dest/block/in_block.d.ts +34 -15
- package/dest/block/in_block.d.ts.map +1 -1
- package/dest/block/in_block.js +21 -12
- package/dest/block/index.d.ts +4 -5
- package/dest/block/index.d.ts.map +1 -1
- package/dest/block/index.js +3 -4
- package/dest/block/l2_block.d.ts +67 -59
- package/dest/block/l2_block.d.ts.map +1 -1
- package/dest/block/l2_block.js +78 -109
- package/dest/block/l2_block_info.d.ts +21 -15
- package/dest/block/l2_block_info.d.ts.map +1 -1
- package/dest/block/l2_block_info.js +14 -12
- package/dest/block/l2_block_source.d.ts +477 -153
- package/dest/block/l2_block_source.d.ts.map +1 -1
- package/dest/block/l2_block_source.js +30 -16
- 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 +20 -7
- package/dest/block/l2_block_stream/interfaces.d.ts.map +1 -1
- package/dest/block/l2_block_stream/l2_block_stream.d.ts +13 -3
- package/dest/block/l2_block_stream/l2_block_stream.d.ts.map +1 -1
- package/dest/block/l2_block_stream/l2_block_stream.js +126 -32
- package/dest/block/l2_block_stream/l2_tips_memory_store.d.ts +24 -15
- 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 +55 -59
- package/dest/block/l2_block_stream/l2_tips_store_base.d.ts +49 -0
- package/dest/block/l2_block_stream/l2_tips_store_base.d.ts.map +1 -0
- package/dest/block/l2_block_stream/l2_tips_store_base.js +192 -0
- package/dest/block/proposal/attestations_and_signers.d.ts +2 -2
- package/dest/block/proposal/attestations_and_signers.d.ts.map +1 -1
- package/dest/block/proposal/committee_attestation.d.ts +2 -2
- package/dest/block/proposal/committee_attestation.d.ts.map +1 -1
- 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 +483 -43
- package/dest/block/validate_block_result.d.ts +24 -24
- package/dest/block/validate_block_result.d.ts.map +1 -1
- package/dest/block/validate_block_result.js +18 -17
- package/dest/checkpoint/checkpoint.d.ts +81 -18
- package/dest/checkpoint/checkpoint.d.ts.map +1 -1
- package/dest/checkpoint/checkpoint.js +92 -17
- package/dest/checkpoint/checkpoint_data.d.ts +186 -0
- package/dest/checkpoint/checkpoint_data.d.ts.map +1 -0
- package/dest/checkpoint/checkpoint_data.js +36 -0
- package/dest/checkpoint/checkpoint_info.d.ts +38 -0
- package/dest/checkpoint/checkpoint_info.d.ts.map +1 -0
- package/dest/checkpoint/checkpoint_info.js +34 -0
- package/dest/checkpoint/index.d.ts +4 -1
- package/dest/checkpoint/index.d.ts.map +1 -1
- package/dest/checkpoint/index.js +3 -0
- package/dest/checkpoint/published_checkpoint.d.ts +58 -15
- package/dest/checkpoint/published_checkpoint.d.ts.map +1 -1
- package/dest/checkpoint/published_checkpoint.js +16 -6
- package/dest/checkpoint/validate.d.ts +36 -0
- package/dest/checkpoint/validate.d.ts.map +1 -0
- package/dest/checkpoint/validate.js +120 -0
- package/dest/config/chain-config.d.ts +1 -1
- package/dest/config/chain-config.d.ts.map +1 -1
- package/dest/config/chain-config.js +7 -1
- package/dest/config/index.d.ts +3 -1
- package/dest/config/index.d.ts.map +1 -1
- package/dest/config/index.js +2 -0
- package/dest/config/node-rpc-config.js +1 -1
- package/dest/config/pipelining-config.d.ts +19 -0
- package/dest/config/pipelining-config.d.ts.map +1 -0
- package/dest/config/pipelining-config.js +18 -0
- package/dest/config/sequencer-config.d.ts +12 -0
- package/dest/config/sequencer-config.d.ts.map +1 -0
- package/dest/config/sequencer-config.js +31 -0
- 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 +2 -2
- package/dest/contract/complete_address.d.ts +5 -2
- package/dest/contract/complete_address.d.ts.map +1 -1
- package/dest/contract/complete_address.js +1 -1
- package/dest/contract/contract_address.d.ts +5 -5
- package/dest/contract/contract_address.d.ts.map +1 -1
- package/dest/contract/contract_address.js +9 -9
- package/dest/contract/contract_class.d.ts +3 -4
- package/dest/contract/contract_class.d.ts.map +1 -1
- package/dest/contract/contract_class.js +1 -1
- package/dest/contract/contract_class_id.d.ts +4 -4
- package/dest/contract/contract_class_id.d.ts.map +1 -1
- package/dest/contract/contract_class_id.js +9 -8
- package/dest/contract/contract_deployment_data.d.ts +5 -5
- package/dest/contract/contract_instance.d.ts +2 -2
- package/dest/contract/contract_instance.d.ts.map +1 -1
- package/dest/contract/contract_instance.js +1 -1
- package/dest/contract/contract_instance_update.d.ts +2 -2
- package/dest/contract/contract_instance_update.d.ts.map +1 -1
- package/dest/contract/contract_instance_update.js +1 -1
- package/dest/contract/deployment_info.d.ts +2 -2
- package/dest/contract/deployment_info.d.ts.map +1 -1
- package/dest/contract/index.d.ts +1 -5
- package/dest/contract/index.d.ts.map +1 -1
- package/dest/contract/index.js +0 -4
- package/dest/contract/interfaces/contract_class.d.ts +17 -165
- package/dest/contract/interfaces/contract_class.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_class.js +24 -34
- package/dest/contract/interfaces/contract_data_source.d.ts +4 -3
- package/dest/contract/interfaces/contract_data_source.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_instance.d.ts +40 -31
- package/dest/contract/interfaces/contract_instance.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_instance.js +30 -5
- package/dest/contract/interfaces/contract_instance_update.d.ts +7 -8
- package/dest/contract/interfaces/contract_instance_update.d.ts.map +1 -1
- package/dest/contract/interfaces/contract_instance_update.js +5 -5
- package/dest/contract/interfaces/node-info.d.ts +3 -1
- package/dest/contract/interfaces/node-info.d.ts.map +1 -1
- package/dest/contract/interfaces/node-info.js +2 -1
- package/dest/contract/partial_address.d.ts +2 -2
- package/dest/contract/partial_address.d.ts.map +1 -1
- package/dest/contract/private_function.d.ts +2 -2
- package/dest/contract/private_function.d.ts.map +1 -1
- package/dest/contract/private_function.js +7 -9
- package/dest/database-version/database_version.d.ts +58 -0
- package/dest/database-version/database_version.d.ts.map +1 -0
- package/dest/database-version/database_version.js +69 -0
- package/dest/database-version/version_manager.d.ts +3 -49
- package/dest/database-version/version_manager.d.ts.map +1 -1
- package/dest/database-version/version_manager.js +1 -64
- package/dest/delayed_public_mutable/delayed_public_mutable_values.d.ts +3 -3
- package/dest/delayed_public_mutable/delayed_public_mutable_values.d.ts.map +1 -1
- package/dest/delayed_public_mutable/delayed_public_mutable_values.js +9 -12
- package/dest/delayed_public_mutable/delayed_public_mutable_values_with_hash.d.ts +2 -2
- package/dest/delayed_public_mutable/delayed_public_mutable_values_with_hash.d.ts.map +1 -1
- package/dest/delayed_public_mutable/delayed_public_mutable_values_with_hash.js +1 -1
- package/dest/delayed_public_mutable/scheduled_value_change.d.ts +2 -2
- package/dest/delayed_public_mutable/scheduled_value_change.d.ts.map +1 -1
- package/dest/delayed_public_mutable/scheduled_value_change.js +1 -1
- package/dest/deserialization/index.d.ts +11 -0
- package/dest/deserialization/index.d.ts.map +1 -0
- package/dest/deserialization/index.js +10 -0
- package/dest/epoch-helpers/index.d.ts +17 -1
- package/dest/epoch-helpers/index.d.ts.map +1 -1
- package/dest/epoch-helpers/index.js +26 -6
- package/dest/errors/proving_error.d.ts +2 -2
- package/dest/errors/proving_error.d.ts.map +1 -1
- package/dest/errors/simulation_error.d.ts +2 -2
- package/dest/errors/simulation_error.d.ts.map +1 -1
- package/dest/fees/transaction_fee.d.ts +2 -2
- package/dest/fees/transaction_fee.d.ts.map +1 -1
- package/dest/file-store/factory.d.ts +4 -3
- package/dest/file-store/factory.d.ts.map +1 -1
- package/dest/file-store/factory.js +2 -2
- package/dest/file-store/http.d.ts +9 -2
- package/dest/file-store/http.d.ts.map +1 -1
- package/dest/file-store/http.js +20 -9
- package/dest/file-store/index.d.ts +2 -1
- package/dest/file-store/index.d.ts.map +1 -1
- package/dest/file-store/local.d.ts +3 -3
- package/dest/file-store/local.d.ts.map +1 -1
- package/dest/file-store/local.js +13 -4
- package/dest/file-store/s3.d.ts +1 -1
- package/dest/file-store/s3.d.ts.map +1 -1
- package/dest/file-store/s3.js +11 -3
- package/dest/gas/fee_math.d.ts +49 -0
- package/dest/gas/fee_math.d.ts.map +1 -0
- package/dest/gas/fee_math.js +80 -0
- package/dest/gas/gas.d.ts +2 -2
- package/dest/gas/gas.d.ts.map +1 -1
- package/dest/gas/gas.js +4 -2
- package/dest/gas/gas_fees.d.ts +2 -2
- package/dest/gas/gas_fees.d.ts.map +1 -1
- package/dest/gas/gas_fees.js +16 -2
- package/dest/gas/gas_settings.d.ts +41 -4
- package/dest/gas/gas_settings.d.ts.map +1 -1
- package/dest/gas/gas_settings.js +51 -7
- 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/ha-signing/config.d.ts +136 -0
- package/dest/ha-signing/config.d.ts.map +1 -0
- package/dest/ha-signing/config.js +97 -0
- package/dest/ha-signing/index.d.ts +4 -0
- package/dest/ha-signing/index.d.ts.map +1 -0
- package/dest/ha-signing/index.js +3 -0
- package/dest/ha-signing/local_config.d.ts +63 -0
- package/dest/ha-signing/local_config.d.ts.map +1 -0
- package/dest/ha-signing/local_config.js +24 -0
- package/dest/ha-signing/types.d.ts +90 -0
- package/dest/ha-signing/types.d.ts.map +1 -0
- package/dest/ha-signing/types.js +39 -0
- package/dest/hash/hash.d.ts +34 -8
- package/dest/hash/hash.d.ts.map +1 -1
- package/dest/hash/hash.js +77 -21
- package/dest/hash/map_slot.d.ts +2 -2
- package/dest/hash/map_slot.d.ts.map +1 -1
- package/dest/hash/map_slot.js +4 -3
- package/dest/interfaces/allowed_element.d.ts +31 -26
- package/dest/interfaces/allowed_element.d.ts.map +1 -1
- package/dest/interfaces/allowed_element.js +11 -11
- package/dest/interfaces/api_limit.d.ts +3 -1
- package/dest/interfaces/api_limit.d.ts.map +1 -1
- package/dest/interfaces/api_limit.js +2 -0
- package/dest/interfaces/archiver.d.ts +12 -7
- package/dest/interfaces/archiver.d.ts.map +1 -1
- package/dest/interfaces/archiver.js +45 -23
- package/dest/interfaces/aztec-node-admin.d.ts +212 -78
- package/dest/interfaces/aztec-node-admin.d.ts.map +1 -1
- package/dest/interfaces/aztec-node-admin.js +18 -10
- package/dest/interfaces/aztec-node-debug.d.ts +21 -0
- package/dest/interfaces/aztec-node-debug.d.ts.map +1 -0
- package/dest/interfaces/aztec-node-debug.js +18 -0
- package/dest/interfaces/aztec-node.d.ts +107 -97
- package/dest/interfaces/aztec-node.d.ts.map +1 -1
- package/dest/interfaces/aztec-node.js +37 -33
- package/dest/interfaces/block-builder.d.ts +55 -18
- package/dest/interfaces/block-builder.d.ts.map +1 -1
- package/dest/interfaces/block-builder.js +23 -1
- package/dest/interfaces/client.d.ts +2 -1
- package/dest/interfaces/client.d.ts.map +1 -1
- package/dest/interfaces/client.js +1 -0
- package/dest/interfaces/configs.d.ts +127 -53
- package/dest/interfaces/configs.d.ts.map +1 -1
- package/dest/interfaces/configs.js +21 -8
- package/dest/interfaces/epoch-prover.d.ts +5 -5
- package/dest/interfaces/epoch-prover.d.ts.map +1 -1
- package/dest/interfaces/get_logs_response.d.ts +30 -6
- package/dest/interfaces/get_logs_response.d.ts.map +1 -1
- package/dest/interfaces/get_logs_response.js +5 -4
- package/dest/interfaces/l2_logs_source.d.ts +23 -15
- package/dest/interfaces/l2_logs_source.d.ts.map +1 -1
- package/dest/interfaces/merkle_tree_operations.d.ts +16 -24
- package/dest/interfaces/merkle_tree_operations.d.ts.map +1 -1
- package/dest/interfaces/p2p.d.ts +9 -16
- package/dest/interfaces/p2p.d.ts.map +1 -1
- package/dest/interfaces/p2p.js +3 -4
- package/dest/interfaces/prover-broker.d.ts +16 -1
- package/dest/interfaces/prover-broker.d.ts.map +1 -1
- package/dest/interfaces/prover-broker.js +4 -1
- package/dest/interfaces/prover-client.d.ts +24 -3
- package/dest/interfaces/prover-client.d.ts.map +1 -1
- package/dest/interfaces/prover-client.js +22 -7
- package/dest/interfaces/proving-job.d.ts +226 -222
- package/dest/interfaces/proving-job.d.ts.map +1 -1
- package/dest/interfaces/proving-job.js +1 -7
- package/dest/interfaces/public_state_source.d.ts +2 -2
- package/dest/interfaces/public_state_source.d.ts.map +1 -1
- package/dest/interfaces/server_circuit_prover.d.ts +4 -3
- package/dest/interfaces/server_circuit_prover.d.ts.map +1 -1
- package/dest/interfaces/slasher.d.ts +9 -10
- package/dest/interfaces/slasher.d.ts.map +1 -1
- package/dest/interfaces/slasher.js +5 -5
- package/dest/interfaces/validator.d.ts +243 -57
- package/dest/interfaces/validator.d.ts.map +1 -1
- package/dest/interfaces/validator.js +17 -9
- package/dest/interfaces/world_state.d.ts +26 -33
- package/dest/interfaces/world_state.d.ts.map +1 -1
- package/dest/interfaces/world_state.js +4 -3
- package/dest/kernel/claimed_length_array.d.ts +2 -2
- package/dest/kernel/claimed_length_array.d.ts.map +1 -1
- package/dest/kernel/claimed_length_array.js +3 -1
- package/dest/kernel/hints/build_note_hash_read_request_hints.d.ts +7 -6
- package/dest/kernel/hints/build_note_hash_read_request_hints.d.ts.map +1 -1
- package/dest/kernel/hints/build_note_hash_read_request_hints.js +31 -19
- package/dest/kernel/hints/build_nullifier_read_request_hints.d.ts +5 -5
- package/dest/kernel/hints/build_nullifier_read_request_hints.d.ts.map +1 -1
- package/dest/kernel/hints/build_nullifier_read_request_hints.js +28 -17
- package/dest/kernel/hints/build_transient_data_hints.d.ts +5 -2
- package/dest/kernel/hints/build_transient_data_hints.d.ts.map +1 -1
- package/dest/kernel/hints/build_transient_data_hints.js +9 -3
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.d.ts +1 -1
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.d.ts.map +1 -1
- package/dest/kernel/hints/find_private_kernel_reset_dimensions.js +1 -3
- package/dest/kernel/hints/index.d.ts +2 -2
- package/dest/kernel/hints/index.js +2 -2
- package/dest/kernel/hints/key_validation_hint.d.ts +3 -2
- package/dest/kernel/hints/key_validation_hint.d.ts.map +1 -1
- package/dest/kernel/hints/key_validation_hint.js +1 -1
- package/dest/kernel/hints/key_validation_request.d.ts +5 -3
- package/dest/kernel/hints/key_validation_request.d.ts.map +1 -1
- package/dest/kernel/hints/key_validation_request.js +2 -1
- package/dest/kernel/hints/key_validation_request_and_separator.d.ts +24 -0
- package/dest/kernel/hints/key_validation_request_and_separator.d.ts.map +1 -0
- package/dest/kernel/hints/{key_validation_request_and_generator.js → key_validation_request_and_separator.js} +13 -16
- package/dest/kernel/hints/note_hash_read_request_hints.d.ts +2 -2
- package/dest/kernel/hints/note_hash_read_request_hints.d.ts.map +1 -1
- package/dest/kernel/hints/note_hash_read_request_hints.js +1 -1
- package/dest/kernel/hints/private_kernel_reset_hints.d.ts +13 -1
- package/dest/kernel/hints/private_kernel_reset_hints.d.ts.map +1 -1
- package/dest/kernel/hints/read_request.d.ts +8 -2
- package/dest/kernel/hints/read_request.d.ts.map +1 -1
- package/dest/kernel/hints/read_request.js +1 -1
- package/dest/kernel/hints/read_request_hints.d.ts +7 -1
- package/dest/kernel/hints/read_request_hints.d.ts.map +1 -1
- package/dest/kernel/hints/{scoped_key_validation_request_and_generator.d.ts → scoped_key_validation_request_and_separator.d.ts} +9 -9
- package/dest/kernel/hints/{scoped_key_validation_request_and_generator.d.ts.map → scoped_key_validation_request_and_separator.d.ts.map} +1 -1
- package/dest/kernel/hints/{scoped_key_validation_request_and_generator.js → scoped_key_validation_request_and_separator.js} +6 -6
- package/dest/kernel/hints/scoped_value_cache.d.ts +2 -2
- package/dest/kernel/hints/scoped_value_cache.d.ts.map +1 -1
- package/dest/kernel/hints/transient_data_squashing_hint.d.ts +2 -2
- package/dest/kernel/hints/transient_data_squashing_hint.d.ts.map +1 -1
- package/dest/kernel/hints/transient_data_squashing_hint.js +4 -2
- package/dest/kernel/hints/tree_leaf_read_request.d.ts +2 -2
- package/dest/kernel/hints/tree_leaf_read_request.d.ts.map +1 -1
- package/dest/kernel/hints/tree_leaf_read_request.js +1 -1
- package/dest/kernel/log_hash.d.ts +2 -2
- package/dest/kernel/log_hash.d.ts.map +1 -1
- package/dest/kernel/log_hash.js +4 -2
- package/dest/kernel/note_hash.d.ts +2 -2
- package/dest/kernel/note_hash.d.ts.map +1 -1
- package/dest/kernel/note_hash.js +1 -1
- package/dest/kernel/nullifier.d.ts +2 -2
- package/dest/kernel/nullifier.d.ts.map +1 -1
- package/dest/kernel/nullifier.js +1 -1
- package/dest/kernel/padded_side_effects.d.ts +2 -2
- package/dest/kernel/padded_side_effects.d.ts.map +1 -1
- package/dest/kernel/padded_side_effects.js +1 -1
- package/dest/kernel/private_accumulated_data.d.ts +23 -1
- package/dest/kernel/private_accumulated_data.d.ts.map +1 -1
- package/dest/kernel/private_call_data.d.ts +26 -2
- package/dest/kernel/private_call_data.d.ts.map +1 -1
- package/dest/kernel/private_call_data.js +1 -1
- package/dest/kernel/private_call_request.d.ts +17 -2
- package/dest/kernel/private_call_request.d.ts.map +1 -1
- package/dest/kernel/private_call_request.js +1 -1
- package/dest/kernel/private_circuit_public_inputs.d.ts +127 -54
- package/dest/kernel/private_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_circuit_public_inputs.js +72 -72
- package/dest/kernel/private_context_inputs.d.ts +2 -2
- package/dest/kernel/private_context_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_circuit_public_inputs.d.ts +34 -4
- package/dest/kernel/private_kernel_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_circuit_public_inputs.js +5 -5
- package/dest/kernel/private_kernel_data.d.ts +7 -1
- package/dest/kernel/private_kernel_data.d.ts.map +1 -1
- package/dest/kernel/private_kernel_init_circuit_private_inputs.d.ts +23 -2
- package/dest/kernel/private_kernel_init_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_init_circuit_private_inputs.js +1 -1
- package/dest/kernel/private_kernel_inner_circuit_private_inputs.d.ts +7 -1
- package/dest/kernel/private_kernel_inner_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_reset_circuit_private_inputs.d.ts +4 -1
- package/dest/kernel/private_kernel_reset_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.d.ts +12 -3
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_tail_circuit_private_inputs.js +4 -4
- package/dest/kernel/private_kernel_tail_circuit_public_inputs.d.ts +27 -4
- package/dest/kernel/private_kernel_tail_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_kernel_tail_circuit_public_inputs.js +12 -8
- package/dest/kernel/private_log_data.d.ts +2 -2
- package/dest/kernel/private_log_data.d.ts.map +1 -1
- package/dest/kernel/private_log_data.js +5 -2
- package/dest/kernel/private_to_avm_accumulated_data.d.ts +4 -4
- package/dest/kernel/private_to_avm_accumulated_data.d.ts.map +1 -1
- package/dest/kernel/private_to_avm_accumulated_data.js +6 -3
- package/dest/kernel/private_to_public_accumulated_data.d.ts +2 -2
- package/dest/kernel/private_to_public_accumulated_data.d.ts.map +1 -1
- package/dest/kernel/private_to_public_accumulated_data.js +4 -2
- package/dest/kernel/private_to_public_accumulated_data_builder.d.ts +2 -2
- package/dest/kernel/private_to_public_accumulated_data_builder.d.ts.map +1 -1
- package/dest/kernel/private_to_public_accumulated_data_builder.js +1 -1
- package/dest/kernel/private_to_public_kernel_circuit_public_inputs.d.ts +4 -4
- package/dest/kernel/private_to_public_kernel_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_to_public_kernel_circuit_public_inputs.js +8 -8
- package/dest/kernel/private_to_rollup_accumulated_data.d.ts +18 -2
- package/dest/kernel/private_to_rollup_accumulated_data.d.ts.map +1 -1
- package/dest/kernel/private_to_rollup_accumulated_data.js +4 -2
- package/dest/kernel/private_to_rollup_kernel_circuit_public_inputs.d.ts +19 -4
- package/dest/kernel/private_to_rollup_kernel_circuit_public_inputs.d.ts.map +1 -1
- package/dest/kernel/private_to_rollup_kernel_circuit_public_inputs.js +8 -8
- package/dest/kernel/private_validation_requests.d.ts +13 -4
- package/dest/kernel/private_validation_requests.d.ts.map +1 -1
- package/dest/kernel/private_validation_requests.js +12 -10
- package/dest/kernel/public_call_request.d.ts +23 -2
- package/dest/kernel/public_call_request.d.ts.map +1 -1
- package/dest/kernel/public_call_request.js +6 -3
- package/dest/kernel/utils/optional_number.d.ts +8 -2
- package/dest/kernel/utils/optional_number.d.ts.map +1 -1
- package/dest/keys/derivation.d.ts +7 -6
- package/dest/keys/derivation.d.ts.map +1 -1
- package/dest/keys/derivation.js +20 -17
- package/dest/keys/key_types.d.ts +3 -3
- package/dest/keys/key_types.d.ts.map +1 -1
- package/dest/keys/public_key.d.ts +2 -2
- package/dest/keys/public_key.d.ts.map +1 -1
- package/dest/keys/public_keys.d.ts +7 -2
- package/dest/keys/public_keys.d.ts.map +1 -1
- package/dest/keys/public_keys.js +5 -4
- package/dest/keys/utils.d.ts +1 -1
- package/dest/keys/utils.d.ts.map +1 -1
- package/dest/keys/utils.js +8 -4
- package/dest/kv-store/config.d.ts +17 -0
- package/dest/kv-store/config.d.ts.map +1 -0
- package/dest/kv-store/config.js +26 -0
- package/dest/kv-store/index.d.ts +2 -0
- package/dest/kv-store/index.d.ts.map +1 -0
- package/dest/kv-store/index.js +1 -0
- package/dest/l1-contracts/index.d.ts +2 -2
- package/dest/l1-contracts/index.d.ts.map +1 -1
- package/dest/l1-contracts/index.js +1 -1
- package/dest/logs/contract_class_log.d.ts +2 -2
- package/dest/logs/contract_class_log.d.ts.map +1 -1
- package/dest/logs/contract_class_log.js +5 -3
- package/dest/logs/debug_log.d.ts +2 -2
- package/dest/logs/debug_log.d.ts.map +1 -1
- package/dest/logs/debug_log.js +1 -1
- package/dest/logs/debug_log_store.d.ts +30 -0
- package/dest/logs/debug_log_store.d.ts.map +1 -0
- package/dest/logs/debug_log_store.js +30 -0
- package/dest/logs/extended_contract_class_log.d.ts +3 -1
- package/dest/logs/extended_contract_class_log.d.ts.map +1 -1
- package/dest/logs/extended_directional_app_tagging_secret.d.ts +47 -0
- package/dest/logs/extended_directional_app_tagging_secret.d.ts.map +1 -0
- package/dest/logs/{directional_app_tagging_secret.js → extended_directional_app_tagging_secret.js} +38 -22
- package/dest/logs/extended_public_log.d.ts +20 -4
- package/dest/logs/extended_public_log.d.ts.map +1 -1
- package/dest/logs/index.d.ts +6 -3
- package/dest/logs/index.d.ts.map +1 -1
- package/dest/logs/index.js +5 -2
- package/dest/logs/log_filter.d.ts +4 -1
- package/dest/logs/log_filter.d.ts.map +1 -1
- package/dest/logs/log_filter.js +2 -1
- package/dest/logs/log_id.d.ts +29 -11
- package/dest/logs/log_id.d.ts.map +1 -1
- package/dest/logs/log_id.js +26 -16
- package/dest/logs/message_context.d.ts +5 -8
- package/dest/logs/message_context.d.ts.map +1 -1
- package/dest/logs/message_context.js +24 -10
- package/dest/logs/pending_tagged_log.d.ts +3 -4
- package/dest/logs/pending_tagged_log.d.ts.map +1 -1
- package/dest/logs/pending_tagged_log.js +3 -3
- package/dest/logs/pre_tag.d.ts +16 -11
- package/dest/logs/pre_tag.d.ts.map +1 -1
- package/dest/logs/pre_tag.js +2 -2
- package/dest/logs/private_log.d.ts +3 -3
- package/dest/logs/private_log.d.ts.map +1 -1
- package/dest/logs/private_log.js +6 -3
- package/dest/logs/public_log.d.ts +6 -4
- package/dest/logs/public_log.d.ts.map +1 -1
- package/dest/logs/public_log.js +9 -3
- package/dest/logs/shared_secret_derivation.d.ts +11 -10
- package/dest/logs/shared_secret_derivation.d.ts.map +1 -1
- package/dest/logs/shared_secret_derivation.js +16 -10
- package/dest/logs/siloed_tag.d.ts +26 -0
- package/dest/logs/siloed_tag.d.ts.map +1 -0
- package/dest/logs/siloed_tag.js +40 -0
- package/dest/logs/tag.d.ts +20 -0
- package/dest/logs/tag.d.ts.map +1 -0
- package/dest/logs/tag.js +34 -0
- package/dest/logs/tagging_index_range.d.ts +40 -0
- package/dest/logs/tagging_index_range.d.ts.map +1 -0
- package/dest/logs/tagging_index_range.js +8 -0
- package/dest/logs/tx_scoped_l2_log.d.ts +34 -38
- package/dest/logs/tx_scoped_l2_log.d.ts.map +1 -1
- package/dest/logs/tx_scoped_l2_log.js +46 -44
- package/dest/messaging/in_hash.d.ts +5 -3
- package/dest/messaging/in_hash.d.ts.map +1 -1
- package/dest/messaging/in_hash.js +4 -2
- package/dest/messaging/inbox_leaf.d.ts +10 -7
- package/dest/messaging/inbox_leaf.d.ts.map +1 -1
- package/dest/messaging/inbox_leaf.js +10 -9
- package/dest/messaging/l1_actor.d.ts +8 -2
- package/dest/messaging/l1_actor.d.ts.map +1 -1
- package/dest/messaging/l1_actor.js +2 -2
- package/dest/messaging/l1_to_l2_message.d.ts +9 -3
- package/dest/messaging/l1_to_l2_message.d.ts.map +1 -1
- package/dest/messaging/l1_to_l2_message.js +13 -15
- package/dest/messaging/l1_to_l2_message_source.d.ts +9 -11
- package/dest/messaging/l1_to_l2_message_source.d.ts.map +1 -1
- package/dest/messaging/l2_actor.d.ts +8 -2
- package/dest/messaging/l2_actor.d.ts.map +1 -1
- package/dest/messaging/l2_actor.js +2 -2
- package/dest/messaging/l2_to_l1_membership.d.ts +117 -8
- package/dest/messaging/l2_to_l1_membership.d.ts.map +1 -1
- package/dest/messaging/l2_to_l1_membership.js +210 -49
- package/dest/messaging/l2_to_l1_message.d.ts +3 -2
- package/dest/messaging/l2_to_l1_message.d.ts.map +1 -1
- package/dest/messaging/l2_to_l1_message.js +4 -1
- package/dest/messaging/out_hash.d.ts +42 -4
- package/dest/messaging/out_hash.d.ts.map +1 -1
- package/dest/messaging/out_hash.js +55 -20
- package/dest/noir/index.d.ts +3 -3
- package/dest/noir/index.d.ts.map +1 -1
- package/dest/note/index.d.ts +1 -2
- package/dest/note/index.d.ts.map +1 -1
- package/dest/note/index.js +0 -1
- package/dest/note/note.d.ts +2 -2
- package/dest/note/note.d.ts.map +1 -1
- package/dest/note/note.js +5 -2
- package/dest/note/note_dao.d.ts +48 -9
- package/dest/note/note_dao.d.ts.map +1 -1
- package/dest/note/note_dao.js +27 -16
- package/dest/p2p/attestation_utils.d.ts +13 -3
- package/dest/p2p/attestation_utils.d.ts.map +1 -1
- package/dest/p2p/attestation_utils.js +46 -1
- package/dest/p2p/block_proposal.d.ts +106 -29
- package/dest/p2p/block_proposal.d.ts.map +1 -1
- package/dest/p2p/block_proposal.js +142 -47
- package/dest/p2p/checkpoint_attestation.d.ts +80 -0
- package/dest/p2p/checkpoint_attestation.d.ts.map +1 -0
- package/dest/p2p/{block_attestation.js → checkpoint_attestation.js} +24 -25
- package/dest/p2p/checkpoint_proposal.d.ts +172 -0
- package/dest/p2p/checkpoint_proposal.d.ts.map +1 -0
- package/dest/p2p/checkpoint_proposal.js +214 -0
- package/dest/p2p/client_type.d.ts +2 -5
- package/dest/p2p/client_type.d.ts.map +1 -1
- package/dest/p2p/client_type.js +0 -7
- package/dest/p2p/consensus_payload.d.ts +21 -12
- package/dest/p2p/consensus_payload.d.ts.map +1 -1
- package/dest/p2p/consensus_payload.js +25 -20
- package/dest/p2p/constants.d.ts +5 -0
- package/dest/p2p/constants.d.ts.map +1 -0
- package/dest/p2p/constants.js +3 -0
- package/dest/p2p/gossipable.d.ts +7 -6
- package/dest/p2p/gossipable.d.ts.map +1 -1
- package/dest/p2p/gossipable.js +16 -5
- package/dest/p2p/index.d.ts +5 -3
- package/dest/p2p/index.d.ts.map +1 -1
- package/dest/p2p/index.js +4 -2
- package/dest/p2p/message_validator.d.ts +18 -3
- package/dest/p2p/message_validator.d.ts.map +1 -1
- package/dest/p2p/message_validator.js +2 -1
- package/dest/p2p/peer_error.d.ts +3 -1
- package/dest/p2p/peer_error.d.ts.map +1 -1
- package/dest/p2p/peer_error.js +5 -0
- package/dest/p2p/signature_utils.d.ts +5 -3
- package/dest/p2p/signature_utils.d.ts.map +1 -1
- package/dest/p2p/signature_utils.js +5 -2
- package/dest/p2p/signed_txs.d.ts +42 -0
- package/dest/p2p/signed_txs.d.ts.map +1 -0
- package/dest/p2p/signed_txs.js +75 -0
- package/dest/p2p/topic_type.d.ts +5 -5
- package/dest/p2p/topic_type.d.ts.map +1 -1
- package/dest/p2p/topic_type.js +9 -19
- package/dest/parity/parity_base_private_inputs.d.ts +4 -2
- package/dest/parity/parity_base_private_inputs.d.ts.map +1 -1
- package/dest/parity/parity_base_private_inputs.js +1 -1
- package/dest/parity/parity_public_inputs.d.ts +5 -2
- package/dest/parity/parity_public_inputs.d.ts.map +1 -1
- package/dest/parity/parity_public_inputs.js +1 -1
- package/dest/parity/parity_root_private_inputs.d.ts +2 -1
- package/dest/parity/parity_root_private_inputs.d.ts.map +1 -1
- package/dest/proofs/chonk_proof.d.ts +47 -3
- package/dest/proofs/chonk_proof.d.ts.map +1 -1
- package/dest/proofs/chonk_proof.js +96 -16
- package/dest/proofs/proof.d.ts +5 -2
- package/dest/proofs/proof.d.ts.map +1 -1
- package/dest/proofs/proof.js +1 -1
- package/dest/proofs/proof_data.d.ts +13 -1
- package/dest/proofs/proof_data.d.ts.map +1 -1
- package/dest/proofs/proof_data.js +17 -0
- package/dest/proofs/recursive_proof.d.ts +11 -2
- package/dest/proofs/recursive_proof.d.ts.map +1 -1
- package/dest/proofs/recursive_proof.js +1 -1
- package/dest/rollup/avm_proof_data.d.ts +3 -5
- package/dest/rollup/avm_proof_data.d.ts.map +1 -1
- package/dest/rollup/avm_proof_data.js +1 -9
- package/dest/rollup/base_rollup_hints.d.ts +35 -2
- package/dest/rollup/base_rollup_hints.d.ts.map +1 -1
- package/dest/rollup/base_rollup_hints.js +1 -1
- package/dest/rollup/block_constant_data.d.ts +13 -2
- package/dest/rollup/block_constant_data.d.ts.map +1 -1
- package/dest/rollup/block_constant_data.js +1 -1
- package/dest/rollup/block_headers_hash.d.ts +2 -2
- package/dest/rollup/block_headers_hash.d.ts.map +1 -1
- package/dest/rollup/block_headers_hash.js +10 -4
- package/dest/rollup/block_merge_rollup_private_inputs.d.ts +4 -1
- package/dest/rollup/block_merge_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/block_rollup_public_inputs.d.ts +48 -12
- package/dest/rollup/block_rollup_public_inputs.d.ts.map +1 -1
- package/dest/rollup/block_rollup_public_inputs.js +9 -13
- package/dest/rollup/block_root_rollup_private_inputs.d.ts +65 -2
- package/dest/rollup/block_root_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/block_root_rollup_private_inputs.js +1 -1
- package/dest/rollup/checkpoint_constant_data.d.ts +12 -2
- package/dest/rollup/checkpoint_constant_data.d.ts.map +1 -1
- package/dest/rollup/checkpoint_constant_data.js +5 -2
- package/dest/rollup/checkpoint_header.d.ts +47 -13
- package/dest/rollup/checkpoint_header.d.ts.map +1 -1
- package/dest/rollup/checkpoint_header.js +55 -22
- package/dest/rollup/checkpoint_merge_rollup_private_inputs.d.ts +4 -1
- package/dest/rollup/checkpoint_merge_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/checkpoint_rollup_public_inputs.d.ts +47 -7
- package/dest/rollup/checkpoint_rollup_public_inputs.d.ts.map +1 -1
- package/dest/rollup/checkpoint_rollup_public_inputs.js +12 -4
- package/dest/rollup/checkpoint_root_rollup_private_inputs.d.ts +46 -4
- package/dest/rollup/checkpoint_root_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/checkpoint_root_rollup_private_inputs.js +15 -3
- package/dest/rollup/epoch_constant_data.d.ts +17 -2
- package/dest/rollup/epoch_constant_data.d.ts.map +1 -1
- package/dest/rollup/epoch_constant_data.js +1 -1
- package/dest/rollup/public_chonk_verifier_private_inputs.d.ts +2 -2
- package/dest/rollup/public_chonk_verifier_private_inputs.d.ts.map +1 -1
- package/dest/rollup/public_chonk_verifier_private_inputs.js +1 -1
- package/dest/rollup/public_chonk_verifier_public_inputs.d.ts +2 -2
- package/dest/rollup/public_chonk_verifier_public_inputs.d.ts.map +1 -1
- package/dest/rollup/public_chonk_verifier_public_inputs.js +1 -1
- package/dest/rollup/public_tx_base_rollup_private_inputs.d.ts +1 -1
- package/dest/rollup/public_tx_base_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/public_tx_base_rollup_private_inputs.js +2 -2
- package/dest/rollup/root_rollup_private_inputs.d.ts +6 -1
- package/dest/rollup/root_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/root_rollup_public_inputs.d.ts +22 -7
- package/dest/rollup/root_rollup_public_inputs.d.ts.map +1 -1
- package/dest/rollup/root_rollup_public_inputs.js +11 -5
- package/dest/rollup/tree_snapshot_diff_hints.d.ts +25 -2
- package/dest/rollup/tree_snapshot_diff_hints.d.ts.map +1 -1
- package/dest/rollup/tree_snapshot_diff_hints.js +1 -1
- package/dest/rollup/tx_merge_rollup_private_inputs.d.ts +4 -1
- package/dest/rollup/tx_merge_rollup_private_inputs.d.ts.map +1 -1
- package/dest/rollup/tx_rollup_public_inputs.d.ts +30 -2
- package/dest/rollup/tx_rollup_public_inputs.d.ts.map +1 -1
- package/dest/rollup/tx_rollup_public_inputs.js +1 -1
- package/dest/schemas/schemas.d.ts +7 -4
- package/dest/schemas/schemas.d.ts.map +1 -1
- package/dest/schemas/schemas.js +2 -1
- package/dest/slashing/helpers.d.ts +2 -2
- package/dest/slashing/helpers.d.ts.map +1 -1
- package/dest/slashing/helpers.js +6 -0
- package/dest/slashing/index.d.ts +2 -3
- package/dest/slashing/index.d.ts.map +1 -1
- package/dest/slashing/index.js +1 -2
- package/dest/slashing/serialization.d.ts +2 -6
- package/dest/slashing/serialization.d.ts.map +1 -1
- package/dest/slashing/serialization.js +0 -60
- package/dest/slashing/types.d.ts +11 -94
- package/dest/slashing/types.d.ts.map +1 -1
- package/dest/slashing/types.js +16 -18
- package/dest/slashing/{tally.d.ts → votes.d.ts} +8 -2
- package/dest/slashing/votes.d.ts.map +1 -0
- package/dest/slashing/{tally.js → votes.js} +35 -3
- package/dest/snapshots/types.d.ts +1 -1
- package/dest/snapshots/types.d.ts.map +1 -1
- package/dest/snapshots/types.js +5 -5
- package/dest/stats/stats.d.ts +10 -8
- package/dest/stats/stats.d.ts.map +1 -1
- package/dest/tests/factories.d.ts +46 -21
- package/dest/tests/factories.d.ts.map +1 -1
- package/dest/tests/factories.js +130 -78
- package/dest/tests/jest.js +1 -1
- package/dest/tests/mocks.d.ts +92 -19
- package/dest/tests/mocks.d.ts.map +1 -1
- package/dest/tests/mocks.js +197 -67
- package/dest/timetable/index.d.ts +87 -0
- package/dest/timetable/index.d.ts.map +1 -0
- package/dest/timetable/index.js +229 -0
- package/dest/trees/append_only_tree_snapshot.d.ts +14 -2
- package/dest/trees/append_only_tree_snapshot.d.ts.map +1 -1
- package/dest/trees/append_only_tree_snapshot.js +4 -2
- package/dest/trees/database_public_state_source.d.ts +2 -2
- package/dest/trees/database_public_state_source.d.ts.map +1 -1
- package/dest/trees/database_public_state_source.js +1 -1
- package/dest/trees/nullifier_leaf.d.ts +15 -2
- package/dest/trees/nullifier_leaf.d.ts.map +1 -1
- package/dest/trees/nullifier_leaf.js +4 -1
- package/dest/trees/nullifier_membership_witness.d.ts +11 -2
- package/dest/trees/nullifier_membership_witness.d.ts.map +1 -1
- package/dest/trees/nullifier_membership_witness.js +1 -1
- package/dest/trees/public_data_leaf.d.ts +18 -2
- package/dest/trees/public_data_leaf.d.ts.map +1 -1
- package/dest/trees/public_data_leaf.js +8 -7
- package/dest/trees/public_data_witness.d.ts +12 -2
- package/dest/trees/public_data_witness.d.ts.map +1 -1
- package/dest/trees/public_data_witness.js +1 -1
- package/dest/tx/block_header.d.ts +27 -12
- package/dest/tx/block_header.d.ts.map +1 -1
- package/dest/tx/block_header.js +20 -5
- package/dest/tx/call_context.d.ts +14 -2
- package/dest/tx/call_context.d.ts.map +1 -1
- package/dest/tx/call_context.js +3 -1
- package/dest/tx/capsule.d.ts +10 -3
- package/dest/tx/capsule.d.ts.map +1 -1
- package/dest/tx/capsule.js +10 -4
- package/dest/tx/execution_payload.d.ts +9 -1
- package/dest/tx/execution_payload.d.ts.map +1 -1
- package/dest/tx/fee_provider.d.ts +10 -0
- package/dest/tx/fee_provider.d.ts.map +1 -0
- package/dest/tx/fee_provider.js +1 -0
- package/dest/tx/function_data.d.ts +5 -3
- package/dest/tx/function_data.d.ts.map +1 -1
- package/dest/tx/function_data.js +1 -1
- package/dest/tx/global_variable_builder.d.ts +5 -4
- package/dest/tx/global_variable_builder.d.ts.map +1 -1
- package/dest/tx/global_variables.d.ts +27 -12
- package/dest/tx/global_variables.d.ts.map +1 -1
- package/dest/tx/global_variables.js +11 -9
- package/dest/tx/hashed_values.d.ts +8 -2
- package/dest/tx/hashed_values.d.ts.map +1 -1
- package/dest/tx/hashed_values.js +1 -1
- package/dest/tx/in_tx.d.ts +26 -0
- package/dest/tx/in_tx.d.ts.map +1 -0
- package/dest/tx/in_tx.js +14 -0
- package/dest/tx/index.d.ts +3 -2
- package/dest/tx/index.d.ts.map +1 -1
- package/dest/tx/index.js +2 -1
- package/dest/tx/indexed_tx_effect.d.ts +14 -10
- package/dest/tx/indexed_tx_effect.d.ts.map +1 -1
- package/dest/tx/indexed_tx_effect.js +7 -6
- package/dest/tx/offchain_effect.d.ts +2 -2
- package/dest/tx/offchain_effect.d.ts.map +1 -1
- package/dest/tx/offchain_effect.js +1 -1
- package/dest/tx/partial_state_reference.d.ts +5 -2
- package/dest/tx/partial_state_reference.d.ts.map +1 -1
- package/dest/tx/private_execution_result.d.ts +30 -13
- package/dest/tx/private_execution_result.d.ts.map +1 -1
- package/dest/tx/private_execution_result.js +10 -27
- package/dest/tx/private_tx_constant_data.d.ts +17 -2
- package/dest/tx/private_tx_constant_data.d.ts.map +1 -1
- package/dest/tx/private_tx_constant_data.js +1 -1
- package/dest/tx/processed_tx.d.ts +5 -4
- package/dest/tx/processed_tx.d.ts.map +1 -1
- package/dest/tx/processed_tx.js +8 -7
- package/dest/tx/profiling.d.ts +166 -31
- package/dest/tx/profiling.d.ts.map +1 -1
- package/dest/tx/profiling.js +60 -13
- package/dest/tx/protocol_contracts.d.ts +3 -3
- package/dest/tx/protocol_contracts.d.ts.map +1 -1
- package/dest/tx/protocol_contracts.js +3 -3
- package/dest/tx/public_call_request_with_calldata.d.ts +8 -2
- package/dest/tx/public_call_request_with_calldata.d.ts.map +1 -1
- package/dest/tx/public_call_request_with_calldata.js +4 -2
- package/dest/tx/public_simulation_output.d.ts +5 -3
- package/dest/tx/public_simulation_output.d.ts.map +1 -1
- package/dest/tx/public_simulation_output.js +8 -4
- package/dest/tx/simulated_tx.d.ts +1146 -11
- package/dest/tx/simulated_tx.d.ts.map +1 -1
- package/dest/tx/simulated_tx.js +7 -4
- package/dest/tx/state_reference.d.ts +4 -2
- package/dest/tx/state_reference.d.ts.map +1 -1
- package/dest/tx/state_reference.js +3 -1
- package/dest/tx/tree_snapshots.d.ts +2 -2
- package/dest/tx/tree_snapshots.d.ts.map +1 -1
- package/dest/tx/tree_snapshots.js +3 -1
- package/dest/tx/tx.d.ts +42 -11
- package/dest/tx/tx.d.ts.map +1 -1
- package/dest/tx/tx.js +37 -12
- package/dest/tx/tx_constant_data.d.ts +2 -2
- package/dest/tx/tx_constant_data.d.ts.map +1 -1
- package/dest/tx/tx_constant_data.js +1 -1
- package/dest/tx/tx_context.d.ts +3 -2
- package/dest/tx/tx_context.d.ts.map +1 -1
- package/dest/tx/tx_context.js +1 -1
- package/dest/tx/tx_effect.d.ts +33 -7
- package/dest/tx/tx_effect.d.ts.map +1 -1
- package/dest/tx/tx_effect.js +8 -11
- package/dest/tx/tx_execution_request.d.ts +31 -2
- package/dest/tx/tx_execution_request.d.ts.map +1 -1
- package/dest/tx/tx_execution_request.js +7 -3
- package/dest/tx/tx_hash.d.ts +3 -2
- package/dest/tx/tx_hash.d.ts.map +1 -1
- package/dest/tx/tx_hash.js +1 -1
- package/dest/tx/tx_receipt.d.ts +76 -18
- package/dest/tx/tx_receipt.d.ts.map +1 -1
- package/dest/tx/tx_receipt.js +65 -29
- package/dest/tx/tx_request.d.ts +7 -2
- package/dest/tx/tx_request.d.ts.map +1 -1
- package/dest/tx/tx_request.js +4 -4
- package/dest/tx/validator/empty_validator.d.ts +2 -2
- package/dest/tx/validator/empty_validator.d.ts.map +1 -1
- package/dest/tx/validator/error_texts.d.ts +11 -2
- package/dest/tx/validator/error_texts.d.ts.map +1 -1
- package/dest/tx/validator/error_texts.js +13 -1
- package/dest/tx/validator/tx_validator.d.ts +2 -5
- package/dest/tx/validator/tx_validator.d.ts.map +1 -1
- package/dest/tx/validator/tx_validator.js +4 -4
- package/dest/types/shared.d.ts +4 -10
- package/dest/types/shared.d.ts.map +1 -1
- package/dest/types/shared.js +0 -9
- package/dest/update-checker/index.d.ts +3 -2
- package/dest/update-checker/index.d.ts.map +1 -1
- package/dest/update-checker/index.js +2 -1
- package/dest/update-checker/package_version.d.ts +3 -0
- package/dest/update-checker/package_version.d.ts.map +1 -0
- package/dest/update-checker/package_version.js +24 -0
- package/dest/update-checker/version_checker.d.ts +25 -0
- package/dest/update-checker/version_checker.d.ts.map +1 -0
- package/dest/update-checker/version_checker.js +50 -0
- package/dest/validators/errors.d.ts +7 -2
- package/dest/validators/errors.d.ts.map +1 -1
- package/dest/validators/errors.js +7 -0
- package/dest/validators/schemas.d.ts +38 -38
- package/dest/validators/schemas.d.ts.map +1 -1
- package/dest/validators/schemas.js +17 -16
- package/dest/validators/types.d.ts +3 -3
- package/dest/validators/types.d.ts.map +1 -1
- package/dest/versioning/versioning.d.ts +5 -3
- package/dest/versioning/versioning.d.ts.map +1 -1
- package/dest/versioning/versioning.js +4 -1
- package/dest/vks/verification_key.d.ts +2 -116
- package/dest/vks/verification_key.d.ts.map +1 -1
- package/dest/vks/verification_key.js +5 -126
- package/dest/vks/vk_data.d.ts +8 -2
- package/dest/vks/vk_data.d.ts.map +1 -1
- package/dest/vks/vk_data.js +1 -1
- package/dest/world-state/genesis_data.d.ts +11 -0
- package/dest/world-state/genesis_data.d.ts.map +1 -0
- package/dest/world-state/genesis_data.js +4 -0
- package/dest/world-state/index.d.ts +2 -1
- package/dest/world-state/index.d.ts.map +1 -1
- package/dest/world-state/index.js +1 -0
- package/dest/zkpassport/index.d.ts +4 -5
- package/dest/zkpassport/index.d.ts.map +1 -1
- package/dest/zkpassport/index.js +11 -11
- package/package.json +35 -15
- package/src/abi/abi.ts +64 -35
- package/src/abi/authorization_selector.ts +5 -10
- package/src/abi/buffer.ts +26 -5
- package/src/abi/contract_artifact.ts +10 -10
- package/src/abi/decoder.ts +37 -83
- package/src/abi/encoder.ts +86 -7
- package/src/abi/event_metadata_definition.ts +2 -0
- package/src/abi/event_selector.ts +5 -10
- package/src/abi/function_call.ts +26 -4
- package/src/abi/function_selector.ts +15 -15
- package/src/abi/function_signature_decoder.ts +77 -0
- package/src/abi/index.ts +1 -0
- package/src/abi/note_selector.ts +5 -14
- package/src/abi/selector.ts +2 -2
- package/src/abi/utils.ts +42 -0
- package/src/auth_witness/auth_witness.ts +5 -5
- package/src/avm/avm.ts +338 -20
- package/src/avm/avm_accumulated_data.ts +1 -1
- package/src/avm/avm_circuit_public_inputs.ts +1 -1
- package/src/avm/contract_storage_read.ts +1 -1
- package/src/avm/contract_storage_update_request.ts +1 -1
- package/src/avm/message_pack.ts +2 -1
- package/src/avm/public_call_stack_item_compressed.ts +1 -1
- package/src/avm/public_data_read.ts +1 -1
- package/src/avm/public_data_update_request.ts +1 -1
- package/src/avm/public_data_write.ts +1 -1
- package/src/avm/public_inner_call_request.ts +1 -1
- package/src/avm/revert_code.ts +27 -26
- package/src/aztec-address/index.ts +6 -11
- package/src/block/attestation_info.ts +10 -7
- package/src/block/block_data.ts +25 -0
- package/src/block/block_hash.ts +32 -24
- package/src/block/block_parameter.ts +10 -0
- package/src/block/body.ts +2 -1
- package/src/block/checkpointed_l2_block.ts +70 -0
- package/src/block/in_block.ts +28 -15
- package/src/block/index.ts +3 -4
- package/src/block/l2_block.ts +117 -139
- package/src/block/l2_block_info.ts +19 -16
- package/src/block/l2_block_source.ts +239 -75
- package/src/block/l2_block_stream/index.ts +1 -0
- package/src/block/l2_block_stream/interfaces.ts +21 -6
- package/src/block/l2_block_stream/l2_block_stream.ts +163 -37
- package/src/block/l2_block_stream/l2_tips_memory_store.ts +63 -54
- package/src/block/l2_block_stream/l2_tips_store_base.ts +238 -0
- package/src/block/proposal/attestations_and_signers.ts +1 -1
- package/src/block/proposal/committee_attestation.ts +1 -1
- package/src/block/test/l2_tips_store_test_suite.ts +493 -36
- package/src/block/validate_block_result.ts +40 -35
- package/src/checkpoint/checkpoint.ts +135 -28
- package/src/checkpoint/checkpoint_data.ts +87 -0
- package/src/checkpoint/checkpoint_info.ts +52 -0
- package/src/checkpoint/index.ts +3 -0
- package/src/checkpoint/published_checkpoint.ts +26 -9
- package/src/checkpoint/validate.ts +230 -0
- package/src/config/chain-config.ts +7 -1
- package/src/config/index.ts +2 -0
- package/src/config/node-rpc-config.ts +1 -1
- package/src/config/pipelining-config.ts +31 -0
- package/src/config/sequencer-config.ts +47 -0
- package/src/contract/artifact_hash.ts +2 -2
- package/src/contract/complete_address.ts +1 -1
- package/src/contract/contract_address.ts +9 -9
- package/src/contract/contract_class.ts +5 -5
- package/src/contract/contract_class_id.ts +9 -8
- package/src/contract/contract_instance.ts +1 -1
- package/src/contract/contract_instance_update.ts +1 -1
- package/src/contract/deployment_info.ts +1 -1
- package/src/contract/index.ts +0 -4
- package/src/contract/interfaces/contract_class.ts +48 -97
- package/src/contract/interfaces/contract_data_source.ts +3 -2
- package/src/contract/interfaces/contract_instance.ts +48 -16
- package/src/contract/interfaces/contract_instance_update.ts +12 -10
- package/src/contract/interfaces/node-info.ts +3 -0
- package/src/contract/partial_address.ts +1 -1
- package/src/contract/private_function.ts +8 -6
- package/src/database-version/database_version.ts +87 -0
- package/src/database-version/version_manager.ts +1 -77
- package/src/delayed_public_mutable/delayed_public_mutable_values.ts +11 -12
- package/src/delayed_public_mutable/delayed_public_mutable_values_with_hash.ts +1 -1
- package/src/delayed_public_mutable/scheduled_value_change.ts +1 -1
- package/src/deserialization/index.ts +21 -0
- package/src/epoch-helpers/index.ts +51 -10
- package/src/errors/simulation_error.ts +1 -1
- package/src/fees/transaction_fee.ts +1 -1
- package/src/file-store/factory.ts +13 -4
- package/src/file-store/http.ts +29 -10
- package/src/file-store/index.ts +1 -0
- package/src/file-store/local.ts +15 -5
- package/src/file-store/s3.ts +12 -3
- package/src/gas/README.md +154 -0
- package/src/gas/fee_math.ts +120 -0
- package/src/gas/gas.ts +1 -1
- package/src/gas/gas_fees.ts +16 -2
- package/src/gas/gas_settings.ts +66 -13
- package/src/gas/index.ts +1 -0
- package/src/ha-signing/config.ts +156 -0
- package/src/ha-signing/index.ts +29 -0
- package/src/ha-signing/local_config.ts +46 -0
- package/src/ha-signing/types.ts +126 -0
- package/src/hash/hash.ts +74 -19
- package/src/hash/map_slot.ts +4 -3
- package/src/interfaces/allowed_element.ts +35 -13
- package/src/interfaces/api_limit.ts +2 -0
- package/src/interfaces/archiver.ts +59 -31
- package/src/interfaces/aztec-node-admin.ts +38 -13
- package/src/interfaces/aztec-node-debug.ts +40 -0
- package/src/interfaces/aztec-node.ts +195 -176
- package/src/interfaces/block-builder.ts +102 -27
- package/src/interfaces/client.ts +1 -0
- package/src/interfaces/configs.ts +99 -37
- package/src/interfaces/epoch-prover.ts +4 -4
- package/src/interfaces/get_logs_response.ts +13 -9
- package/src/interfaces/l2_logs_source.ts +27 -14
- package/src/interfaces/merkle_tree_operations.ts +18 -23
- package/src/interfaces/p2p.ts +10 -25
- package/src/interfaces/prover-broker.ts +22 -0
- package/src/interfaces/prover-client.ts +45 -15
- package/src/interfaces/proving-job.ts +2 -11
- package/src/interfaces/public_state_source.ts +1 -1
- package/src/interfaces/server_circuit_prover.ts +3 -3
- package/src/interfaces/slasher.ts +26 -26
- package/src/interfaces/validator.ts +135 -48
- package/src/interfaces/world_state.ts +29 -20
- package/src/kernel/claimed_length_array.ts +1 -1
- package/src/kernel/hints/build_note_hash_read_request_hints.ts +34 -30
- package/src/kernel/hints/build_nullifier_read_request_hints.ts +33 -33
- package/src/kernel/hints/build_transient_data_hints.ts +17 -2
- package/src/kernel/hints/find_private_kernel_reset_dimensions.ts +2 -4
- package/src/kernel/hints/index.ts +2 -2
- package/src/kernel/hints/key_validation_hint.ts +1 -1
- package/src/kernel/hints/key_validation_request.ts +2 -1
- package/src/kernel/hints/key_validation_request_and_separator.ts +49 -0
- package/src/kernel/hints/note_hash_read_request_hints.ts +1 -1
- package/src/kernel/hints/read_request.ts +1 -1
- package/src/kernel/hints/{scoped_key_validation_request_and_generator.ts → scoped_key_validation_request_and_separator.ts} +11 -11
- package/src/kernel/hints/scoped_value_cache.ts +1 -1
- package/src/kernel/hints/transient_data_squashing_hint.ts +1 -1
- package/src/kernel/hints/tree_leaf_read_request.ts +1 -1
- package/src/kernel/log_hash.ts +1 -1
- package/src/kernel/note_hash.ts +1 -1
- package/src/kernel/nullifier.ts +1 -1
- package/src/kernel/padded_side_effects.ts +1 -1
- package/src/kernel/private_call_data.ts +1 -1
- package/src/kernel/private_call_request.ts +1 -1
- package/src/kernel/private_circuit_public_inputs.ts +100 -100
- package/src/kernel/private_context_inputs.ts +1 -1
- package/src/kernel/private_kernel_circuit_public_inputs.ts +3 -3
- package/src/kernel/private_kernel_init_circuit_private_inputs.ts +1 -1
- package/src/kernel/private_kernel_tail_circuit_private_inputs.ts +2 -2
- package/src/kernel/private_kernel_tail_circuit_public_inputs.ts +15 -6
- package/src/kernel/private_log_data.ts +1 -1
- package/src/kernel/private_to_avm_accumulated_data.ts +1 -1
- package/src/kernel/private_to_public_accumulated_data.ts +1 -1
- package/src/kernel/private_to_public_accumulated_data_builder.ts +1 -1
- package/src/kernel/private_to_public_kernel_circuit_public_inputs.ts +7 -7
- package/src/kernel/private_to_rollup_accumulated_data.ts +1 -1
- package/src/kernel/private_to_rollup_kernel_circuit_public_inputs.ts +7 -7
- package/src/kernel/private_validation_requests.ts +8 -8
- package/src/kernel/public_call_request.ts +1 -1
- package/src/kernel/utils/optional_number.ts +1 -1
- package/src/keys/derivation.ts +20 -17
- package/src/keys/key_types.ts +6 -2
- package/src/keys/public_key.ts +1 -1
- package/src/keys/public_keys.ts +5 -4
- package/src/keys/utils.ts +8 -4
- package/src/kv-store/config.ts +36 -0
- package/src/kv-store/index.ts +1 -0
- package/src/l1-contracts/index.ts +1 -1
- package/src/logs/contract_class_log.ts +2 -2
- package/src/logs/debug_log.ts +1 -1
- package/src/logs/debug_log_store.ts +54 -0
- package/src/logs/{directional_app_tagging_secret.ts → extended_directional_app_tagging_secret.ts} +45 -24
- package/src/logs/index.ts +5 -2
- package/src/logs/log_filter.ts +5 -0
- package/src/logs/log_id.ts +31 -17
- package/src/logs/message_context.ts +18 -8
- package/src/logs/pending_tagged_log.ts +2 -4
- package/src/logs/pre_tag.ts +5 -5
- package/src/logs/private_log.ts +3 -2
- package/src/logs/public_log.ts +12 -3
- package/src/logs/shared_secret_derivation.ts +22 -11
- package/src/logs/siloed_tag.ts +54 -0
- package/src/logs/tag.ts +42 -0
- package/src/logs/tagging_index_range.ts +24 -0
- package/src/logs/tx_scoped_l2_log.ts +62 -43
- package/src/messaging/in_hash.ts +4 -2
- package/src/messaging/inbox_leaf.ts +11 -10
- package/src/messaging/l1_actor.ts +2 -2
- package/src/messaging/l1_to_l2_message.ts +14 -10
- package/src/messaging/l1_to_l2_message_source.ts +8 -11
- package/src/messaging/l2_actor.ts +2 -2
- package/src/messaging/l2_to_l1_membership.ts +253 -61
- package/src/messaging/l2_to_l1_message.ts +5 -1
- package/src/messaging/out_hash.ts +63 -22
- package/src/noir/index.ts +2 -2
- package/src/note/index.ts +0 -1
- package/src/note/note.ts +5 -2
- package/src/note/note_dao.ts +49 -16
- package/src/p2p/attestation_utils.ts +59 -3
- package/src/p2p/block_proposal.ts +226 -56
- package/src/p2p/{block_attestation.ts → checkpoint_attestation.ts} +41 -33
- package/src/p2p/checkpoint_proposal.ts +358 -0
- package/src/p2p/client_type.ts +0 -6
- package/src/p2p/consensus_payload.ts +30 -19
- package/src/p2p/constants.ts +6 -0
- package/src/p2p/gossipable.ts +18 -8
- package/src/p2p/index.ts +4 -2
- package/src/p2p/message_validator.ts +14 -2
- package/src/p2p/peer_error.ts +7 -0
- package/src/p2p/signature_utils.ts +5 -2
- package/src/p2p/signed_txs.ts +88 -0
- package/src/p2p/topic_type.ts +10 -16
- package/src/parity/parity_base_private_inputs.ts +1 -1
- package/src/parity/parity_public_inputs.ts +1 -1
- package/src/proofs/chonk_proof.ts +102 -12
- package/src/proofs/proof.ts +1 -1
- package/src/proofs/proof_data.ts +24 -0
- package/src/proofs/recursive_proof.ts +1 -1
- package/src/rollup/avm_proof_data.ts +2 -9
- package/src/rollup/base_rollup_hints.ts +1 -1
- package/src/rollup/block_constant_data.ts +1 -1
- package/src/rollup/block_headers_hash.ts +13 -4
- package/src/rollup/block_rollup_public_inputs.ts +6 -12
- package/src/rollup/block_root_rollup_private_inputs.ts +1 -1
- package/src/rollup/checkpoint_constant_data.ts +2 -1
- package/src/rollup/checkpoint_header.ts +69 -20
- package/src/rollup/checkpoint_rollup_public_inputs.ts +18 -6
- package/src/rollup/checkpoint_root_rollup_private_inputs.ts +16 -2
- package/src/rollup/epoch_constant_data.ts +1 -1
- package/src/rollup/public_chonk_verifier_private_inputs.ts +1 -1
- package/src/rollup/public_chonk_verifier_public_inputs.ts +1 -1
- package/src/rollup/public_tx_base_rollup_private_inputs.ts +2 -2
- package/src/rollup/root_rollup_public_inputs.ts +17 -8
- package/src/rollup/tree_snapshot_diff_hints.ts +1 -1
- package/src/rollup/tx_rollup_public_inputs.ts +1 -1
- package/src/schemas/schemas.ts +6 -1
- package/src/slashing/helpers.ts +8 -0
- package/src/slashing/index.ts +1 -2
- package/src/slashing/serialization.ts +1 -81
- package/src/slashing/types.ts +26 -40
- package/src/slashing/{tally.ts → votes.ts} +41 -2
- package/src/snapshots/types.ts +33 -29
- package/src/stats/stats.ts +10 -7
- package/src/tests/factories.ts +158 -104
- package/src/tests/jest.ts +1 -1
- package/src/tests/mocks.ts +318 -90
- package/src/timetable/index.ts +346 -0
- package/src/trees/append_only_tree_snapshot.ts +1 -1
- package/src/trees/database_public_state_source.ts +1 -1
- package/src/trees/nullifier_leaf.ts +5 -1
- package/src/trees/nullifier_membership_witness.ts +1 -1
- package/src/trees/public_data_leaf.ts +12 -6
- package/src/trees/public_data_witness.ts +1 -1
- package/src/tx/block_header.ts +33 -13
- package/src/tx/call_context.ts +1 -1
- package/src/tx/capsule.ts +11 -3
- package/src/tx/fee_provider.ts +10 -0
- package/src/tx/function_data.ts +1 -1
- package/src/tx/global_variable_builder.ts +10 -4
- package/src/tx/global_variables.ts +16 -10
- package/src/tx/hashed_values.ts +1 -1
- package/src/tx/in_tx.ts +24 -0
- package/src/tx/index.ts +2 -1
- package/src/tx/indexed_tx_effect.ts +8 -7
- package/src/tx/offchain_effect.ts +1 -1
- package/src/tx/partial_state_reference.ts +1 -1
- package/src/tx/private_execution_result.ts +10 -25
- package/src/tx/private_tx_constant_data.ts +1 -1
- package/src/tx/processed_tx.ts +19 -16
- package/src/tx/profiling.ts +61 -10
- package/src/tx/protocol_contracts.ts +4 -4
- package/src/tx/public_call_request_with_calldata.ts +1 -1
- package/src/tx/public_simulation_output.ts +5 -1
- package/src/tx/simulated_tx.ts +14 -3
- package/src/tx/state_reference.ts +1 -1
- package/src/tx/tree_snapshots.ts +1 -1
- package/src/tx/tx.ts +44 -26
- package/src/tx/tx_constant_data.ts +1 -1
- package/src/tx/tx_context.ts +1 -1
- package/src/tx/tx_effect.ts +5 -12
- package/src/tx/tx_execution_request.ts +3 -1
- package/src/tx/tx_hash.ts +1 -1
- package/src/tx/tx_receipt.ts +100 -30
- package/src/tx/tx_request.ts +4 -4
- package/src/tx/validator/empty_validator.ts +1 -1
- package/src/tx/validator/error_texts.ts +16 -1
- package/src/tx/validator/tx_validator.ts +9 -7
- package/src/types/shared.ts +0 -10
- package/src/update-checker/index.ts +2 -1
- package/src/update-checker/package_version.ts +30 -0
- package/src/update-checker/version_checker.ts +65 -0
- package/src/validators/errors.ts +10 -1
- package/src/validators/schemas.ts +61 -48
- package/src/validators/types.ts +5 -4
- package/src/versioning/versioning.ts +5 -2
- package/src/vks/verification_key.ts +5 -184
- package/src/vks/vk_data.ts +1 -1
- package/src/world-state/genesis_data.ts +15 -0
- package/src/world-state/index.ts +1 -0
- package/src/zkpassport/index.ts +13 -14
- package/dest/abi/mocked_keys.d.ts +0 -2
- package/dest/abi/mocked_keys.d.ts.map +0 -1
- package/dest/abi/mocked_keys.js +0 -1
- package/dest/block/l2_block_code_to_purge.d.ts +0 -12
- package/dest/block/l2_block_code_to_purge.d.ts.map +0 -1
- package/dest/block/l2_block_code_to_purge.js +0 -61
- package/dest/block/l2_block_header.d.ts +0 -98
- package/dest/block/l2_block_header.d.ts.map +0 -1
- package/dest/block/l2_block_header.js +0 -153
- package/dest/block/l2_block_new.d.ts +0 -108
- package/dest/block/l2_block_new.d.ts.map +0 -1
- package/dest/block/l2_block_new.js +0 -135
- package/dest/block/l2_block_number.d.ts +0 -5
- package/dest/block/l2_block_number.d.ts.map +0 -1
- package/dest/block/l2_block_number.js +0 -6
- package/dest/block/published_l2_block.d.ts +0 -130
- package/dest/block/published_l2_block.d.ts.map +0 -1
- package/dest/block/published_l2_block.js +0 -48
- package/dest/contract/contract_class_metadata.d.ts +0 -8
- package/dest/contract/contract_class_metadata.d.ts.map +0 -1
- package/dest/contract/contract_class_metadata.js +0 -1
- package/dest/contract/contract_metadata.d.ts +0 -7
- package/dest/contract/contract_metadata.d.ts.map +0 -1
- package/dest/contract/contract_metadata.js +0 -1
- package/dest/contract/private_function_membership_proof.d.ts +0 -32
- package/dest/contract/private_function_membership_proof.d.ts.map +0 -1
- package/dest/contract/private_function_membership_proof.js +0 -124
- package/dest/contract/utility_function_membership_proof.d.ts +0 -27
- package/dest/contract/utility_function_membership_proof.d.ts.map +0 -1
- package/dest/contract/utility_function_membership_proof.js +0 -87
- package/dest/database-version/index.d.ts +0 -2
- package/dest/database-version/index.d.ts.map +0 -1
- package/dest/database-version/index.js +0 -1
- package/dest/kernel/hints/key_validation_request_and_generator.d.ts +0 -25
- package/dest/kernel/hints/key_validation_request_and_generator.d.ts.map +0 -1
- package/dest/l1-contracts/slash_factory.d.ts +0 -44
- package/dest/l1-contracts/slash_factory.d.ts.map +0 -1
- package/dest/l1-contracts/slash_factory.js +0 -157
- package/dest/logs/directional_app_tagging_secret.d.ts +0 -40
- package/dest/logs/directional_app_tagging_secret.d.ts.map +0 -1
- package/dest/logs/log_with_tx_data.d.ts +0 -19
- package/dest/logs/log_with_tx_data.d.ts.map +0 -1
- package/dest/logs/log_with_tx_data.js +0 -49
- package/dest/note/notes_filter.d.ts +0 -25
- package/dest/note/notes_filter.d.ts.map +0 -1
- package/dest/note/notes_filter.js +0 -10
- package/dest/p2p/block_attestation.d.ts +0 -80
- package/dest/p2p/block_attestation.d.ts.map +0 -1
- package/dest/slashing/empire.d.ts +0 -31
- package/dest/slashing/empire.d.ts.map +0 -1
- package/dest/slashing/empire.js +0 -85
- package/dest/slashing/tally.d.ts.map +0 -1
- package/dest/tx/content_commitment.d.ts +0 -48
- package/dest/tx/content_commitment.d.ts.map +0 -1
- package/dest/tx/content_commitment.js +0 -82
- package/dest/update-checker/update-checker.d.ts +0 -49
- package/dest/update-checker/update-checker.d.ts.map +0 -1
- package/dest/update-checker/update-checker.js +0 -130
- package/src/abi/mocked_keys.ts +0 -2
- package/src/block/l2_block_code_to_purge.ts +0 -88
- package/src/block/l2_block_header.ts +0 -246
- package/src/block/l2_block_new.ts +0 -171
- package/src/block/l2_block_number.ts +0 -8
- package/src/block/published_l2_block.ts +0 -65
- package/src/contract/contract_class_metadata.ts +0 -8
- package/src/contract/contract_metadata.ts +0 -7
- package/src/contract/private_function_membership_proof.ts +0 -167
- package/src/contract/utility_function_membership_proof.ts +0 -118
- package/src/database-version/index.ts +0 -1
- package/src/kernel/hints/key_validation_request_and_generator.ts +0 -52
- package/src/l1-contracts/slash_factory.ts +0 -177
- package/src/logs/log_with_tx_data.ts +0 -46
- package/src/note/notes_filter.ts +0 -35
- package/src/slashing/empire.ts +0 -102
- package/src/tx/content_commitment.ts +0 -104
- package/src/update-checker/update-checker.ts +0 -165
package/src/p2p/gossipable.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { BaseBuffer32 } from '@aztec/foundation/buffer';
|
|
2
2
|
import { BufferReader, bigintToUInt64BE, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
3
3
|
|
|
4
4
|
import type { TopicType } from './topic_type.js';
|
|
@@ -7,23 +7,33 @@ export class P2PMessage {
|
|
|
7
7
|
constructor(
|
|
8
8
|
public readonly payload: Buffer,
|
|
9
9
|
public readonly timestamp?: Date,
|
|
10
|
+
public readonly traceContext?: string,
|
|
10
11
|
) {}
|
|
11
12
|
|
|
12
|
-
static fromGossipable(message: Gossipable, instrumentMessages = false): P2PMessage {
|
|
13
|
-
|
|
13
|
+
static fromGossipable(message: Gossipable, instrumentMessages = false, traceContext?: string): P2PMessage {
|
|
14
|
+
if (!instrumentMessages) {
|
|
15
|
+
return new P2PMessage(message.toBuffer());
|
|
16
|
+
}
|
|
17
|
+
return new P2PMessage(message.toBuffer(), new Date(), traceContext);
|
|
14
18
|
}
|
|
15
19
|
|
|
16
20
|
static fromMessageData(messageData: Buffer, instrumentMessages = false): P2PMessage {
|
|
17
21
|
const reader = new BufferReader(messageData);
|
|
18
|
-
|
|
22
|
+
let timestamp: Date | undefined;
|
|
23
|
+
let traceContext: string | undefined;
|
|
24
|
+
if (instrumentMessages) {
|
|
25
|
+
timestamp = new Date(Number(reader.readUInt64()));
|
|
26
|
+
traceContext = reader.readString();
|
|
27
|
+
}
|
|
19
28
|
const payload = reader.readBuffer();
|
|
20
|
-
return new P2PMessage(payload, timestamp);
|
|
29
|
+
return new P2PMessage(payload, timestamp, traceContext);
|
|
21
30
|
}
|
|
22
31
|
|
|
23
32
|
toMessageData(): Buffer {
|
|
24
33
|
const arr: Buffer[] = [];
|
|
25
34
|
if (this.timestamp) {
|
|
26
35
|
arr.push(bigintToUInt64BE(BigInt(this.timestamp.getTime())));
|
|
36
|
+
arr.push(serializeToBuffer(this.traceContext ?? ''));
|
|
27
37
|
}
|
|
28
38
|
arr.push(serializeToBuffer(this.payload.length, this.payload));
|
|
29
39
|
return serializeToBuffer(arr);
|
|
@@ -36,7 +46,7 @@ export class P2PMessage {
|
|
|
36
46
|
* Any class which extends gossipable will be able to be Gossiped over the p2p network
|
|
37
47
|
*/
|
|
38
48
|
export abstract class Gossipable {
|
|
39
|
-
private cachedId:
|
|
49
|
+
private cachedId: BaseBuffer32 | undefined;
|
|
40
50
|
/** The p2p topic identifier, this determines how the message is handled */
|
|
41
51
|
static p2pTopic: TopicType;
|
|
42
52
|
|
|
@@ -44,7 +54,7 @@ export abstract class Gossipable {
|
|
|
44
54
|
* A digest of the message information **used for logging only**.
|
|
45
55
|
* The identifier used for deduplication is `getMsgIdFn` as defined in `encoding.ts` which is a hash over topic and data.
|
|
46
56
|
*/
|
|
47
|
-
async p2pMessageLoggingIdentifier(): Promise<
|
|
57
|
+
async p2pMessageLoggingIdentifier(): Promise<BaseBuffer32> {
|
|
48
58
|
if (this.cachedId) {
|
|
49
59
|
return this.cachedId;
|
|
50
60
|
}
|
|
@@ -52,7 +62,7 @@ export abstract class Gossipable {
|
|
|
52
62
|
return this.cachedId;
|
|
53
63
|
}
|
|
54
64
|
|
|
55
|
-
abstract generateP2PMessageIdentifier(): Promise<
|
|
65
|
+
abstract generateP2PMessageIdentifier(): Promise<BaseBuffer32>;
|
|
56
66
|
|
|
57
67
|
abstract toBuffer(): Buffer;
|
|
58
68
|
|
package/src/p2p/index.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
export * from './attestation_utils.js';
|
|
2
|
-
export * from './block_attestation.js';
|
|
3
2
|
export * from './block_proposal.js';
|
|
3
|
+
export * from './checkpoint_attestation.js';
|
|
4
|
+
export * from './checkpoint_proposal.js';
|
|
4
5
|
export * from './consensus_payload.js';
|
|
5
6
|
export * from './gossipable.js';
|
|
6
7
|
export * from './interface.js';
|
|
7
8
|
export * from './signature_utils.js';
|
|
9
|
+
export * from './signed_txs.js';
|
|
8
10
|
export * from './topic_type.js';
|
|
9
|
-
export * from './client_type.js';
|
|
10
11
|
export * from './message_validator.js';
|
|
11
12
|
export * from './peer_error.js';
|
|
13
|
+
export * from './constants.js';
|
|
@@ -1,10 +1,22 @@
|
|
|
1
1
|
import type { PeerErrorSeverity } from './peer_error.js';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* Result of validating a P2P message.
|
|
5
|
+
* - 'accept': Message is valid and should be accepted and processed
|
|
6
|
+
* - 'ignore': Message should be ignored (not propagated or processed, but sender not penalized)
|
|
7
|
+
* - 'reject': Message is invalid (rejected and sender penalized)
|
|
8
|
+
*/
|
|
9
|
+
export type ValidationResult =
|
|
10
|
+
| { result: 'accept' }
|
|
11
|
+
| { result: 'ignore' }
|
|
12
|
+
| { result: 'reject'; severity: PeerErrorSeverity };
|
|
13
|
+
|
|
3
14
|
/**
|
|
4
15
|
* P2PValidator
|
|
5
16
|
*
|
|
6
|
-
* A validator for P2P messages, which returns a
|
|
17
|
+
* A validator for P2P messages, which returns a ValidationResult indicating
|
|
18
|
+
* whether to accept, ignore, or reject the message
|
|
7
19
|
*/
|
|
8
20
|
export interface P2PValidator<T> {
|
|
9
|
-
validate(message: T): Promise<
|
|
21
|
+
validate(message: T): Promise<ValidationResult>;
|
|
10
22
|
}
|
package/src/p2p/peer_error.ts
CHANGED
|
@@ -15,3 +15,10 @@ export enum PeerErrorSeverity {
|
|
|
15
15
|
*/
|
|
16
16
|
HighToleranceError = 'HighToleranceError',
|
|
17
17
|
}
|
|
18
|
+
|
|
19
|
+
/** Severities ordered from mildest to harshest. */
|
|
20
|
+
export const PeerErrorSeverityByHarshness = [
|
|
21
|
+
PeerErrorSeverity.HighToleranceError,
|
|
22
|
+
PeerErrorSeverity.MidToleranceError,
|
|
23
|
+
PeerErrorSeverity.LowToleranceError,
|
|
24
|
+
] as const;
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { Buffer32 } from '@aztec/foundation/buffer';
|
|
2
|
-
import { keccak256
|
|
2
|
+
import { keccak256 } from '@aztec/foundation/crypto/keccak';
|
|
3
|
+
import { makeEthSignDigest } from '@aztec/foundation/crypto/secp256k1-signer';
|
|
3
4
|
|
|
4
5
|
export enum SignatureDomainSeparator {
|
|
5
6
|
blockProposal = 0,
|
|
6
|
-
|
|
7
|
+
checkpointAttestation = 1,
|
|
7
8
|
attestationsAndSigners = 2,
|
|
9
|
+
checkpointProposal = 3,
|
|
10
|
+
signedTxs = 4,
|
|
8
11
|
}
|
|
9
12
|
|
|
10
13
|
export interface Signable {
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { Buffer32 } from '@aztec/foundation/buffer';
|
|
2
|
+
import { tryRecoverAddress } from '@aztec/foundation/crypto/secp256k1-signer';
|
|
3
|
+
import type { EthAddress } from '@aztec/foundation/eth-address';
|
|
4
|
+
import { Signature } from '@aztec/foundation/eth-signature';
|
|
5
|
+
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
6
|
+
|
|
7
|
+
import { MAX_TXS_PER_BLOCK } from '../deserialization/index.js';
|
|
8
|
+
import { Tx } from '../tx/tx.js';
|
|
9
|
+
import {
|
|
10
|
+
SignatureDomainSeparator,
|
|
11
|
+
getHashedSignaturePayload,
|
|
12
|
+
getHashedSignaturePayloadEthSignedMessage,
|
|
13
|
+
} from './signature_utils.js';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* A signed collection of transactions.
|
|
17
|
+
* The signature is over the transaction objects themselves, providing
|
|
18
|
+
* data availability guarantees beyond just the transaction hashes.
|
|
19
|
+
*/
|
|
20
|
+
export class SignedTxs {
|
|
21
|
+
private sender: EthAddress | undefined;
|
|
22
|
+
|
|
23
|
+
constructor(
|
|
24
|
+
/** The transactions */
|
|
25
|
+
public readonly txs: Tx[],
|
|
26
|
+
/** The proposer's signature over the transactions */
|
|
27
|
+
public readonly signature: Signature,
|
|
28
|
+
) {}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Get the payload to sign for this signed txs.
|
|
32
|
+
*/
|
|
33
|
+
getPayloadToSign(domainSeparator: SignatureDomainSeparator): Buffer {
|
|
34
|
+
return serializeToBuffer([domainSeparator, this.txs.length, this.txs]);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Lazily evaluate the sender of the signed txs; result is cached
|
|
39
|
+
* @returns The sender address, or undefined if signature recovery fails
|
|
40
|
+
*/
|
|
41
|
+
getSender(): EthAddress | undefined {
|
|
42
|
+
if (!this.sender) {
|
|
43
|
+
const hashed = getHashedSignaturePayloadEthSignedMessage(this, SignatureDomainSeparator.signedTxs);
|
|
44
|
+
this.sender = tryRecoverAddress(hashed, this.signature);
|
|
45
|
+
}
|
|
46
|
+
return this.sender;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Create SignedTxs from a signer function
|
|
51
|
+
*/
|
|
52
|
+
static async createFromSigner(
|
|
53
|
+
txs: Tx[],
|
|
54
|
+
payloadSigner: (payload: Buffer32) => Promise<Signature>,
|
|
55
|
+
): Promise<SignedTxs> {
|
|
56
|
+
const tempSignedTxs = new SignedTxs(txs, Signature.empty());
|
|
57
|
+
const hashed = getHashedSignaturePayload(tempSignedTxs, SignatureDomainSeparator.signedTxs);
|
|
58
|
+
const signature = await payloadSigner(hashed);
|
|
59
|
+
return new SignedTxs(txs, signature);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
toBuffer(): Buffer {
|
|
63
|
+
return serializeToBuffer([this.txs.length, this.txs, this.signature]);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
static fromBuffer(buf: Buffer | BufferReader): SignedTxs {
|
|
67
|
+
const reader = BufferReader.asReader(buf);
|
|
68
|
+
const txCount = reader.readNumber();
|
|
69
|
+
if (txCount > MAX_TXS_PER_BLOCK) {
|
|
70
|
+
throw new Error(`txs count ${txCount} exceeds maximum ${MAX_TXS_PER_BLOCK}`);
|
|
71
|
+
}
|
|
72
|
+
const txs = reader.readArray(txCount, Tx);
|
|
73
|
+
const signature = reader.readObject(Signature);
|
|
74
|
+
return new SignedTxs(txs, signature);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
getSize(): number {
|
|
78
|
+
return 4 /* txs.length */ + this.txs.reduce((acc, tx) => acc + tx.getSize(), 0) + this.signature.getSize();
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
static empty(): SignedTxs {
|
|
82
|
+
return new SignedTxs([], Signature.empty());
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
static random(): SignedTxs {
|
|
86
|
+
return new SignedTxs([Tx.random(), Tx.random()], Signature.random());
|
|
87
|
+
}
|
|
88
|
+
}
|
package/src/p2p/topic_type.ts
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { P2PClientType } from './client_type.js';
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
2
|
* Creates the topic channel identifier string from a given topic type
|
|
5
3
|
*/
|
|
@@ -23,22 +21,18 @@ export function getTopicFromString(topicStr: string): TopicType | undefined {
|
|
|
23
21
|
export enum TopicType {
|
|
24
22
|
tx = 'tx',
|
|
25
23
|
block_proposal = 'block_proposal',
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
export function getTopicTypeForClientType(clientType: P2PClientType) {
|
|
30
|
-
if (clientType === P2PClientType.Full) {
|
|
31
|
-
return Object.values(TopicType);
|
|
32
|
-
} else if (clientType === P2PClientType.Prover) {
|
|
33
|
-
return [TopicType.tx, TopicType.block_proposal];
|
|
34
|
-
} else {
|
|
35
|
-
const _: never = clientType;
|
|
36
|
-
return [TopicType.tx];
|
|
37
|
-
}
|
|
24
|
+
checkpoint_proposal = 'checkpoint_proposal',
|
|
25
|
+
checkpoint_attestation = 'checkpoint_attestation',
|
|
38
26
|
}
|
|
39
27
|
|
|
40
|
-
|
|
41
|
-
|
|
28
|
+
/** Returns all gossip topics, optionally filtering out transactions. */
|
|
29
|
+
export function getTopicsForConfig(disableTransactions: boolean) {
|
|
30
|
+
const topics = [
|
|
31
|
+
TopicType.tx,
|
|
32
|
+
TopicType.block_proposal,
|
|
33
|
+
TopicType.checkpoint_proposal,
|
|
34
|
+
TopicType.checkpoint_attestation,
|
|
35
|
+
];
|
|
42
36
|
if (disableTransactions) {
|
|
43
37
|
return topics.filter(topic => topic !== TopicType.tx);
|
|
44
38
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { NUMBER_OF_L1_L2_MESSAGES_PER_ROLLUP, NUM_MSGS_PER_BASE_PARITY } from '@aztec/constants';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { bufferSchemaFor } from '@aztec/foundation/schemas';
|
|
4
4
|
import { BufferReader, type Tuple, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
5
5
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Fr } from '@aztec/foundation/
|
|
1
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
2
2
|
import { bufferSchemaFor } from '@aztec/foundation/schemas';
|
|
3
3
|
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
4
4
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
@@ -1,20 +1,41 @@
|
|
|
1
|
+
import { BarretenbergSync, flattenChonkProofFields } from '@aztec/bb.js';
|
|
1
2
|
import { CHONK_PROOF_LENGTH } from '@aztec/constants';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
3
|
+
import { times } from '@aztec/foundation/collection';
|
|
4
|
+
import { randomBytes } from '@aztec/foundation/crypto/random';
|
|
5
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
6
|
import { bufferSchemaFor } from '@aztec/foundation/schemas';
|
|
5
|
-
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
7
|
+
import { BufferReader, numToUInt32BE, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Serialization format detection for ChonkProof is size-based:
|
|
11
|
+
* - UNCOMPRESSED (legacy): [field_count=1632: uint32] [fields...] → total ≈ 52KB (>= 40KB)
|
|
12
|
+
* - COMPRESSED: [byte_count: uint32] [compressed_bytes] → total ≈ 35KB (< 40KB)
|
|
13
|
+
*
|
|
14
|
+
* Detection: if the first uint32 equals CHONK_PROOF_LENGTH (1632), it's legacy format
|
|
15
|
+
* (field count). Otherwise, it's compressed format (byte count). The old uncompressed
|
|
16
|
+
* format is never smaller than 40KB; compressed proofs are always smaller than 40KB.
|
|
17
|
+
*/
|
|
6
18
|
|
|
7
19
|
// CHONK: "Client Honk" - An UltraHonk variant with incremental folding and delayed non-native arithmetic.
|
|
8
20
|
export class ChonkProof {
|
|
21
|
+
/**
|
|
22
|
+
* Optional compressed proof bytes from chonk compression (point compression + u256 encoding).
|
|
23
|
+
* When set, toBuffer() will serialize in compressed format (~1.7x smaller).
|
|
24
|
+
* When reading from compressed format, this is populated and fields are decompressed on demand.
|
|
25
|
+
*/
|
|
26
|
+
public compressedProof?: Buffer;
|
|
27
|
+
|
|
9
28
|
constructor(
|
|
10
29
|
// The proof fields.
|
|
11
30
|
// For native verification, attach public inputs via `attachPublicInputs(publicInputs)`.
|
|
12
31
|
// Not using Tuple here due to the length being too high.
|
|
13
32
|
public fields: Fr[],
|
|
33
|
+
compressedProof?: Buffer,
|
|
14
34
|
) {
|
|
15
35
|
if (fields.length !== CHONK_PROOF_LENGTH) {
|
|
16
36
|
throw new Error(`Invalid ChonkProof length: ${fields.length}`);
|
|
17
37
|
}
|
|
38
|
+
this.compressedProof = compressedProof;
|
|
18
39
|
}
|
|
19
40
|
|
|
20
41
|
public attachPublicInputs(publicInputs: Fr[]) {
|
|
@@ -31,12 +52,15 @@ export class ChonkProof {
|
|
|
31
52
|
|
|
32
53
|
static random() {
|
|
33
54
|
// NB: Not using Fr.random here because it slows down some tests that require a large number of txs significantly.
|
|
55
|
+
// NB2: generate one fewer random bytes to not have to deal with buffers representing numbers greater than the field modulus
|
|
56
|
+
// NB3: a chonk proof can be compressed. Simulate this by filling 1/4 of the proof with zero data
|
|
34
57
|
const reducedFrSize = Fr.SIZE_IN_BYTES - 1;
|
|
35
|
-
const
|
|
36
|
-
const
|
|
37
|
-
|
|
38
|
-
(
|
|
39
|
-
|
|
58
|
+
const nonZeroFields = Math.floor((3 * CHONK_PROOF_LENGTH) / 4);
|
|
59
|
+
const randomFields = randomBytes(nonZeroFields * Fr.SIZE_IN_BYTES);
|
|
60
|
+
const proof = [
|
|
61
|
+
...times(nonZeroFields, i => new Fr(randomFields.subarray(i * reducedFrSize, (i + 1) * reducedFrSize))),
|
|
62
|
+
...times(CHONK_PROOF_LENGTH - nonZeroFields, () => Fr.ZERO),
|
|
63
|
+
];
|
|
40
64
|
return new ChonkProof(proof);
|
|
41
65
|
}
|
|
42
66
|
|
|
@@ -49,19 +73,84 @@ export class ChonkProof {
|
|
|
49
73
|
return this.toBuffer();
|
|
50
74
|
}
|
|
51
75
|
|
|
76
|
+
/**
|
|
77
|
+
* Deserialize a ChonkProof from a buffer.
|
|
78
|
+
* Supports both legacy (field elements) and compressed (chonk compression) formats.
|
|
79
|
+
*
|
|
80
|
+
* Size-based format detection:
|
|
81
|
+
* - First uint32 == CHONK_PROOF_LENGTH (1632): legacy format, read field elements
|
|
82
|
+
* Total proof data ≈ 52KB (always >= 40KB)
|
|
83
|
+
* - Otherwise: compressed format, first uint32 is byte count of compressed data
|
|
84
|
+
* Total proof data ≈ 35KB (always < 40KB)
|
|
85
|
+
*/
|
|
52
86
|
static fromBuffer(buffer: Buffer | BufferReader): ChonkProof {
|
|
53
87
|
const reader = BufferReader.asReader(buffer);
|
|
54
|
-
const
|
|
55
|
-
|
|
56
|
-
|
|
88
|
+
const firstUint32 = reader.readNumber();
|
|
89
|
+
|
|
90
|
+
if (firstUint32 === CHONK_PROOF_LENGTH) {
|
|
91
|
+
// Legacy format: firstUint32 is the field count (1632)
|
|
92
|
+
// Widen to `number` to prevent TS from narrowing to literal 1632,
|
|
93
|
+
// which would cause Tuple<Fr, 1632> to exceed the recursion limit.
|
|
94
|
+
const fieldCount: number = firstUint32;
|
|
95
|
+
const proof = reader.readArray(fieldCount, Fr);
|
|
96
|
+
return new ChonkProof(proof);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
// Compressed format: firstUint32 is the compressed byte count
|
|
100
|
+
const compressedBytes = reader.readBytes(firstUint32);
|
|
101
|
+
return ChonkProof.fromCompressedBytes(Buffer.from(compressedBytes));
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* Create a ChonkProof from compressed bytes by decompressing via the BarretenbergSync API.
|
|
106
|
+
* The compressed format uses point compression and u256 encoding (from PR #20645).
|
|
107
|
+
*
|
|
108
|
+
* @param compressed - Compressed proof bytes from chonk compression
|
|
109
|
+
* @returns ChonkProof with both fields and compressed bytes populated
|
|
110
|
+
*/
|
|
111
|
+
static fromCompressedBytes(compressed: Buffer): ChonkProof {
|
|
112
|
+
const api = BarretenbergSync.getSingleton();
|
|
113
|
+
const result = api.chonkDecompressProof({ compressedProof: new Uint8Array(compressed) });
|
|
114
|
+
|
|
115
|
+
// Flatten the structured bb.js ChonkProof into flat Fr[] field elements
|
|
116
|
+
const flatFields = flattenChonkProofFields(result.proof);
|
|
117
|
+
const fields = flatFields.map(f => Fr.fromBuffer(Buffer.from(f)));
|
|
118
|
+
|
|
119
|
+
// The decompressed proof includes public inputs in hidingOinkProof.
|
|
120
|
+
// Since ChonkProof stores fields WITHOUT public inputs, strip them.
|
|
121
|
+
// The number of public inputs = total fields - CHONK_PROOF_LENGTH
|
|
122
|
+
if (fields.length > CHONK_PROOF_LENGTH) {
|
|
123
|
+
const numPubInputs = fields.length - CHONK_PROOF_LENGTH;
|
|
124
|
+
const proofFields = fields.slice(numPubInputs);
|
|
125
|
+
return new ChonkProof(proofFields, compressed);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
return new ChonkProof(fields, compressed);
|
|
57
129
|
}
|
|
58
130
|
|
|
131
|
+
/**
|
|
132
|
+
* Serialize the proof to a buffer.
|
|
133
|
+
* If compressed bytes are available, uses the compressed format (~1.7x smaller).
|
|
134
|
+
* Otherwise falls back to legacy field element format.
|
|
135
|
+
*/
|
|
59
136
|
public toBuffer() {
|
|
137
|
+
if (this.compressedProof) {
|
|
138
|
+
// Compressed format: [compressed_byte_count: uint32] [compressed_bytes]
|
|
139
|
+
return Buffer.concat([numToUInt32BE(this.compressedProof.length), this.compressedProof]);
|
|
140
|
+
}
|
|
141
|
+
// Legacy format: [field_count=1632: uint32] [fields...]
|
|
60
142
|
return serializeToBuffer(this.fields.length, this.fields);
|
|
61
143
|
}
|
|
62
144
|
}
|
|
63
145
|
|
|
64
146
|
export class ChonkProofWithPublicInputs {
|
|
147
|
+
/**
|
|
148
|
+
* Optional compressed proof bytes (covers the full proof WITH public inputs).
|
|
149
|
+
* Set by the prover when using chonk compression. Flows through to ChonkProof
|
|
150
|
+
* via removePublicInputs() so the Tx can serialize in compressed format.
|
|
151
|
+
*/
|
|
152
|
+
public compressedProof?: Buffer;
|
|
153
|
+
|
|
65
154
|
constructor(
|
|
66
155
|
// The proof fields with public inputs.
|
|
67
156
|
// For recursive verification, use without public inputs via `removePublicInputs()`.
|
|
@@ -79,7 +168,8 @@ export class ChonkProofWithPublicInputs {
|
|
|
79
168
|
|
|
80
169
|
public removePublicInputs() {
|
|
81
170
|
const numPublicInputs = this.fieldsWithPublicInputs.length - CHONK_PROOF_LENGTH;
|
|
82
|
-
|
|
171
|
+
// Flow compressed proof bytes through so the ChonkProof can serialize efficiently
|
|
172
|
+
return new ChonkProof(this.fieldsWithPublicInputs.slice(numPublicInputs), this.compressedProof);
|
|
83
173
|
}
|
|
84
174
|
|
|
85
175
|
public isEmpty() {
|
package/src/proofs/proof.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PAIRING_POINTS_SIZE } from '@aztec/constants';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
4
4
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
5
5
|
|
package/src/proofs/proof_data.ts
CHANGED
|
@@ -29,6 +29,30 @@ export class ProofData<T extends Bufferable, PROOF_LENGTH extends number> {
|
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
+
/**
|
|
33
|
+
* Represents the data of a recursive proof for a circuit with a fixed verification key.
|
|
34
|
+
*/
|
|
35
|
+
export class ProofDataForFixedVk<T extends Bufferable, PROOF_LENGTH extends number> {
|
|
36
|
+
constructor(
|
|
37
|
+
public publicInputs: T,
|
|
38
|
+
public proof: RecursiveProof<PROOF_LENGTH>,
|
|
39
|
+
) {}
|
|
40
|
+
|
|
41
|
+
public toBuffer(): Buffer {
|
|
42
|
+
return serializeToBuffer(this.publicInputs, this.proof);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
public static fromBuffer<T extends Bufferable, PROOF_LENGTH extends number>(
|
|
46
|
+
buffer: Buffer | BufferReader,
|
|
47
|
+
publicInputs: {
|
|
48
|
+
fromBuffer: (reader: BufferReader) => T;
|
|
49
|
+
},
|
|
50
|
+
): ProofDataForFixedVk<T, PROOF_LENGTH> {
|
|
51
|
+
const reader = BufferReader.asReader(buffer);
|
|
52
|
+
return new ProofDataForFixedVk(reader.readObject(publicInputs), RecursiveProof.fromBuffer(reader));
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
32
56
|
export type ChonkProofData<T extends Bufferable> = ProofData<T, typeof CHONK_PROOF_LENGTH>;
|
|
33
57
|
|
|
34
58
|
export type UltraHonkProofData<T extends Bufferable> = ProofData<T, typeof RECURSIVE_PROOF_LENGTH>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { makeTuple } from '@aztec/foundation/array';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { schemas } from '@aztec/foundation/schemas';
|
|
4
4
|
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
5
5
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
@@ -1,13 +1,6 @@
|
|
|
1
1
|
import { AVM_V2_PROOF_LENGTH_IN_FIELDS_PADDED } from '@aztec/constants';
|
|
2
|
-
import { Fr } from '@aztec/foundation/fields';
|
|
3
2
|
|
|
4
3
|
import { AvmCircuitPublicInputs } from '../avm/avm_circuit_public_inputs.js';
|
|
5
|
-
import type {
|
|
4
|
+
import type { ProofDataForFixedVk } from '../proofs/proof_data.js';
|
|
6
5
|
|
|
7
|
-
export type AvmProofData =
|
|
8
|
-
|
|
9
|
-
// TODO(#14234)[Unconditional PIs validation]: remove this function.
|
|
10
|
-
export function enhanceProofWithPiValidationFlag(proof: Fr[], skipPublicInputsValidation: boolean): Fr[] {
|
|
11
|
-
const skipPublicInputsField = skipPublicInputsValidation ? new Fr(1) : new Fr(0);
|
|
12
|
-
return [skipPublicInputsField].concat(proof).slice(0, AVM_V2_PROOF_LENGTH_IN_FIELDS_PADDED);
|
|
13
|
-
}
|
|
6
|
+
export type AvmProofData = ProofDataForFixedVk<AvmCircuitPublicInputs, typeof AVM_V2_PROOF_LENGTH_IN_FIELDS_PADDED>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { SpongeBlob } from '@aztec/blob-lib/types';
|
|
2
2
|
import { ARCHIVE_HEIGHT, MAX_CONTRACT_CLASS_LOGS_PER_TX } from '@aztec/constants';
|
|
3
3
|
import { makeTuple } from '@aztec/foundation/array';
|
|
4
|
-
import { Fr } from '@aztec/foundation/
|
|
4
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
5
5
|
import { BufferReader, type Tuple, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
6
6
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
7
7
|
import type { FieldsOf } from '@aztec/foundation/types';
|
|
@@ -1,12 +1,21 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { DomainSeparator } from '@aztec/constants';
|
|
2
|
+
import { poseidon2HashWithSeparator } from '@aztec/foundation/crypto/poseidon';
|
|
3
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
4
|
+
import { computeUnbalancedMerkleTreeRootAsync } from '@aztec/foundation/trees';
|
|
3
5
|
|
|
4
6
|
import type { BlockHeader } from '../tx/block_header.js';
|
|
5
7
|
|
|
6
8
|
export async function computeBlockHeadersHash(blockHeaders: BlockHeader[]): Promise<Fr> {
|
|
7
9
|
const blockHeaderHashes = await Promise.all(blockHeaders.map(header => header.hash()));
|
|
8
|
-
// Must match the implementation in merge_block_rollups.nr, with the **
|
|
10
|
+
// Must match the implementation in merge_block_rollups.nr, with the **unbalanced** rollup structure
|
|
9
11
|
// (see validate_consecutive_block_rollups.nr > assert_rollups_filled_greedily.nr).
|
|
10
|
-
const
|
|
12
|
+
const blockHeadersHasher = async (left: Uint8Array, right: Uint8Array) =>
|
|
13
|
+
(
|
|
14
|
+
await poseidon2HashWithSeparator([Buffer.from(left), Buffer.from(right)], DomainSeparator.BLOCK_HEADERS_HASH)
|
|
15
|
+
).toBuffer() as Buffer<ArrayBuffer>;
|
|
16
|
+
const blockHeadersHash = await computeUnbalancedMerkleTreeRootAsync(
|
|
17
|
+
blockHeaderHashes.map(hash => hash.toBuffer()),
|
|
18
|
+
blockHeadersHasher,
|
|
19
|
+
);
|
|
11
20
|
return Fr.fromBuffer(blockHeadersHash);
|
|
12
21
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { SpongeBlob } from '@aztec/blob-lib/types';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { bufferSchemaFor } from '@aztec/foundation/schemas';
|
|
4
4
|
import { BufferReader, bigintToUInt64BE, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
5
5
|
import { bufferToHex, hexToBuffer } from '@aztec/foundation/string';
|
|
@@ -43,17 +43,13 @@ export class BlockRollupPublicInputs {
|
|
|
43
43
|
*/
|
|
44
44
|
public endSpongeBlob: SpongeBlob,
|
|
45
45
|
/**
|
|
46
|
-
* Timestamp of the
|
|
46
|
+
* Timestamp of the blocks in this block range.
|
|
47
47
|
*/
|
|
48
|
-
public
|
|
49
|
-
/**
|
|
50
|
-
* Timestamp of the last block in this block range.
|
|
51
|
-
*/
|
|
52
|
-
public endTimestamp: UInt64,
|
|
48
|
+
public timestamp: UInt64,
|
|
53
49
|
/**
|
|
54
50
|
* Hash of the headers of all blocks in this block range. It will be combined with the `blockHeadersHash` from
|
|
55
|
-
* other blocks in the same checkpoint to form
|
|
56
|
-
* the checkpoint header, enabling validation of the blocks included in a checkpoint given their headers.
|
|
51
|
+
* other blocks in the same checkpoint to form an unbalanced tree. The root of that tree becomes the final hash
|
|
52
|
+
* stored in the checkpoint header, enabling validation of the blocks included in a checkpoint given their headers.
|
|
57
53
|
*/
|
|
58
54
|
public blockHeadersHash: Fr,
|
|
59
55
|
/**
|
|
@@ -85,7 +81,6 @@ export class BlockRollupPublicInputs {
|
|
|
85
81
|
reader.readObject(SpongeBlob),
|
|
86
82
|
reader.readObject(SpongeBlob),
|
|
87
83
|
reader.readUInt64(),
|
|
88
|
-
reader.readUInt64(),
|
|
89
84
|
Fr.fromBuffer(reader),
|
|
90
85
|
Fr.fromBuffer(reader),
|
|
91
86
|
Fr.fromBuffer(reader),
|
|
@@ -103,8 +98,7 @@ export class BlockRollupPublicInputs {
|
|
|
103
98
|
this.endState,
|
|
104
99
|
this.startSpongeBlob,
|
|
105
100
|
this.endSpongeBlob,
|
|
106
|
-
bigintToUInt64BE(this.
|
|
107
|
-
bigintToUInt64BE(this.endTimestamp),
|
|
101
|
+
bigintToUInt64BE(this.timestamp),
|
|
108
102
|
this.blockHeadersHash,
|
|
109
103
|
this.inHash,
|
|
110
104
|
this.outHash,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ARCHIVE_HEIGHT, L1_TO_L2_MSG_SUBTREE_ROOT_SIBLING_PATH_LENGTH } from '@aztec/constants';
|
|
2
|
-
import { Fr } from '@aztec/foundation/
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
3
3
|
import { bufferSchemaFor } from '@aztec/foundation/schemas';
|
|
4
4
|
import { BufferReader, type Tuple, bigintToUInt64BE, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
5
5
|
import type { FieldsOf } from '@aztec/foundation/types';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SlotNumber } from '@aztec/foundation/branded-types';
|
|
2
|
+
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
2
3
|
import { EthAddress } from '@aztec/foundation/eth-address';
|
|
3
|
-
import { Fr } from '@aztec/foundation/fields';
|
|
4
4
|
import { BufferReader, serializeToBuffer } from '@aztec/foundation/serialize';
|
|
5
5
|
import type { FieldsOf } from '@aztec/foundation/types';
|
|
6
6
|
|
|
@@ -11,6 +11,7 @@ import { GasFees } from '../gas/gas_fees.js';
|
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* Constants that are the same for the entire checkpoint.
|
|
14
|
+
* Used in circuits during rollup proving.
|
|
14
15
|
*/
|
|
15
16
|
export class CheckpointConstantData {
|
|
16
17
|
constructor(
|