Skip to content

Set interchain account address on controller chain during init: tracking issue #378

Closed
@seantking

Description

@seantking

Summary

In the ics27 specification, the following function is defined:

// This helper function is required for the controller chain to get the address of a newly registered interchain account on a host chain.
// Because the registration of an interchain account happens during the channel creation handshake, there is no way for the controller chain to know what the address of the interchain account is on the host chain in advance. 
// This function sends an IBC packet to the host chain, on the owner port + active channel with the sole intention of eventually parsing the interchain account address from the Acknowledgement packet on the controller chain side.
// The OnAcknowledgePacket function on the controller chain will handle the parsing + setting the interchain account address in state.
// The controller chain builds the messages (before sending via IBC in the TrySendTx fn) that the host side will eventually execute. Therefore, the interchain account address must be known by the controller chain.
function GetInterchainAccountAddressFromAck(connectionId: string, counterPartyConnectionId: string, ownerAddress: string) returns (nil){
    // Sends a generic IBC packet to the host chain with the intention of parsing the interchain account address associated with this port/connection/channel from the Acknowledgement packet.
}

This step is required for the controller chain to know the address of the interchain account on the host side.

The problem with this approach is twofold:

  1. Poor UX: This is an unnecessary extra step
  2. Cost: As this is an additional IBC transaction it will cost extra tokens

As suggested here: cosmos/ibc#597 we can use the version string during the channel creation handshake to pass the address of the interchain account back to the host chain.

In order for this to be possible, a relayer will need to query the host chain for an updated version string prior to calling the OnChanOpenAck endpoint. At present this query does not exist. There is an issue here describing the work that needs to be done on ibc-go: #136

Work that needs to be done to achieve this:


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged/assigned

Metadata

Metadata

Assignees

Type

No type

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions