Skip to content

apollo_transaction_converter: version-gate deploy-account address derivation#14545

Closed
ron-starkware wants to merge 1 commit into
ron/address-derivation/os-flag-from-vcfrom
ron/address-derivation/converter-version-gate
Closed

apollo_transaction_converter: version-gate deploy-account address derivation#14545
ron-starkware wants to merge 1 commit into
ron/address-derivation/os-flag-from-vcfrom
ron/address-derivation/converter-version-gate

Conversation

@ron-starkware

Copy link
Copy Markdown
Contributor

Deploy-account contract addresses are derived inside the shared private
helper convert_rpc_tx_to_internal, reached from two public converter
methods: convert_rpc_tx_to_internal_rpc_tx (gateway tx ingestion) and
convert_consensus_tx_to_internal_consensus_tx (consensus proposal
validation). Both now take an AddressDerivationHash parameter, resolved at
the call site from the expected (latest) versioned constants
(address_derivation_hash()). Both call sites - apollo_gateway and
apollo_consensus_orchestrator - already depend on blockifier, so the hash
is resolved where it's used rather than where the converter is built;
TransactionConverter::new is unchanged, so the batcher/consensus-manager/
mempool-p2p construction sites are untouched and no inert default is
threaded through them.

InternalRpcDeployAccountTransaction's tx hash now reuses the contract
address stored during conversion instead of recomputing it, so the
version-gated address flows into the hash. Dormant on its own: the hash is
Pedersen for all versions until the activation flag is enabled.

Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com

…ivation

Deploy-account contract addresses are derived inside the shared private
helper convert_rpc_tx_to_internal, reached from two public converter
methods: convert_rpc_tx_to_internal_rpc_tx (gateway tx ingestion) and
convert_consensus_tx_to_internal_consensus_tx (consensus proposal
validation). Both now take an AddressDerivationHash parameter, resolved at
the call site from the expected (latest) versioned constants
(address_derivation_hash()). Both call sites - apollo_gateway and
apollo_consensus_orchestrator - already depend on blockifier, so the hash
is resolved where it's used rather than where the converter is built;
TransactionConverter::new is unchanged, so the batcher/consensus-manager/
mempool-p2p construction sites are untouched and no inert default is
threaded through them.

InternalRpcDeployAccountTransaction's tx hash now reuses the contract
address stored during conversion instead of recomputing it, so the
version-gated address flows into the hash. Dormant on its own: the hash is
Pedersen for all versions until the activation flag is enabled.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@reviewable-StarkWare

Copy link
Copy Markdown

This change is Reviewable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants