CCTP Express Architecture
CCTP Express adopts a Hub-and-Spoke architecture, it can be broken down into a 3-layered system: a request for quote mechanism to obtain users' bridging intent, enabling a filler network to claim and fill those orders, and lastly a settlement layer periodically repay fillers through CCTP and utilizing attestation service from Iris.
CCTP Express aligns with the industry standards, the CrossChainOrder
struct follows ERC-7683 standard.
Below is a diagram of the architecture of CCTP Express:
Order initiation
User signs an off-chain message defining the parameters of an order.
The order is disseminated to Fillers. The Filler calls
initiate
on the source chain SpokePool. ACrossChainOrder
will be created and the user's funds are transferred to theSpokePool
for escrow.The
SpokePool
on source chain submits aDeposit
message to Circle's off-chain attestation service, Iris, for attestation and subsequently aDepositAttestation
will be generated.
Filler Network Fills Order
Fillers calls
fillOrder
on the destinationSpokePool
with their own assets which are then transferred to the user from theSpokePool
.The
SpokePool
on destination chain submits aFill
message to Iris and aFillAttestation
will be generated.
Settlement
A permissionless Datadaemon retrieves the
DepositAttestation
andFillAttestation
from Iris and relay to theHub Pool
on the Settlement Chain.Periodically, a permissionless Datadaemon calls
repayFunds
andrebalanceFunds
at theHub Pool
, which would collect all the attestations and perform the following steps:Iterate through a list of attestations, a valid filled order is supported by both Deposit and Fill attestation.
Determine the aggregate settlement sum from all valid fills for each filler.
If there is sufficient fund on
SpokePool
to repay filler, arepayFunds
message in the form of merkle root hash is sent to Iris.For the remaining outstanding payment, the
Hub Pool
will send arebalanceFunds
message in the form of merkle root hash to Iris, which indicates how much a SpokePool with surplus funds would send to another pool in deficit to fulfill the need for repayment.
Once the
repayFunds
andrebalanceFunds
messages got attested by Iris, they are sent to respective SpokePools. Datamaemon will callrepayFunds
andrebalanceFunds
on SpokePools with merkle root hash and their respective transaction details. Accordingly, funds would be repaid to fillers and sent to other SpokePools to ensure sufficient funds for handling repayments.Repay funds to fillers from the SpokePool on destination chain, and rebalance funds across
SpokePools
on difference chains via CCTP.
Cctp Fill Settlement
In case of order initiated by Fillers not being filled, the Datadaemon can call
cctpFill
and mark the order status on destination chainSpokePool
toRequestCctpFill
and block any filler from filling it. At the same time, theSpokePool
will emit aCctpFill
message to Iris for attestation.The
CctpFillAttestation
will be used to replace theFillAttestation
mentioned in 5. and allow the user fund to be transferred via the CCTP route.
Last updated