WormholeARImplementation
Last updated
Was this helpful?
Last updated
Was this helpful?
This contract is used to allow Superform to send messages via .
WormholeARImplementation
builds upon AMBImplementation
to formalize certain methods specific to Wormhole sent via .
The implemented interface can be found in Wormhole Receivers .
This function handles the reception of messages broadcast via Wormhole.
payload
bytes payload of the message
sourceAddress
address of the source contract
sourceChain
bytes32 Wormhole source chain id
deliveryHash
bytes unique delivery hash of contents
There are multiple bridge related configurations to be made on the contract. These configuration functions can only be set by the PROTOCOL_ADMIN
This function sets the automatic relayer address for the appropriate chain.
relayer_
address of the automatic relayer on the current chain
This function allows the ProtocolAdmin
to map a Wormhole chain id to Superform's chain id, the EVM id.
superChainId_
internal chain id used by superform protocol. block.chainid
casted to uint64
ambChainId_
uint16 chain id allocated to each chain by Wormhole
This function allows the ProtocolAdmin
to set receiver implementations on a new chain id.
chainId_
uint16 Wormhole chain id
authorizedImpl_
address of the Wormhole message bridge on the respective chain
As mentioned in the section, messages can be retried by calling retryPayload
with a bytes hash of relevant data. In the case of Wormhole, the data is the following: