Going Cross-Chain with CCIP
A primer on Chainlink's Cross-Chain Interoperability Protocol (CCIP)
Cross-chain interoperability solutions have proven to be critical infrastructure for blockchains and their respective ecosystems. And yet, recent events like the Multichain bridge hack have continued to remind us that this infrastructure is still immature and prone to security vulnerabilities, with bridges responsible for $2.66 TVH (total value hacked) to date. Developers, institutions, and retail users alike need to be able to bridge assets and transfer data across chains in a secure, cost-efficient, and easy-to-use manner. Today we explore one particular solution which aims to address all of these factors - Chainlink’s Cross-Chain Interoperability Protocol.
Contents
A Quick Refresher on Chainlink
What is CCIP?
How does CCIP work?
Why is CCIP important?
Closing Thoughts
Alpha
A Quick Refresher on Chainlink
For those unfamiliar with Chainlink, it is a decentralized oracle network which facilitates the transfer of smart contract data between blockchains and off-chain sources.
Blockchain oracles are entities which connect blockchains to external data sources, and enable smart contracts to execute onchain using inputs provided off-chain.
Many existing oracles rely on a centralized entity to deliver data to a smart contract, introducing a critical single point of failure. This has lead to numerous attacks in DeFi, including the Mango Markets exploit , which has even caught the ire of regulators.
Chainlink is essentially a network of independent entities, or oracles, working together to retrieve, aggregate, and deliver validated data to smart contracts which are then executed. If you’d like to learn more I suggest reading this .
CCIP
Cross-chain protocols emerged to meet the needs of the rapidly growing multi-chain environment, where heterogenous chains were not able to natively communicate with chains in other ecosystems and networks. Unfortunately, many of these protocols proved to be vulnerable to security risks, and were consequently attacked. According to DeFi Llama, bridges have incurred up to $2.66b TVH (total value hacked). Without going into the how and the why, this is evidently a huge problem for crypto. Secure cross-chain infrastructure is crucial for the evolution of the Web3 ecosystem as a whole.
So what’s Chainlink cooking?
The Cross-Chain Interoperability Protocol, or CCIP, is Chainlink’s solution to the the many intricacies of blockchain interoperability. It is ultimately intended to be a “global, open-source standard” for cross-chain communication. An easy way to think of it is a TCP/IP for blockchains.
“CCIP is really about creating a global, open-source standard that allows blockchains to communicate with each other, smart contracts to communicate with each other, and enable the movement of tokens between chains “ - Sergei Nazarov
At its core, CCIP enables a sender on a source chain to send a message to a receiver on a destination chain. Its core capabilities are arbitrary messaging, token transfers, and programmable token transfers.
Let’s take a look at how it all works.
How CCIP Works
Evidently, there are many moving parts involved in a CCIP transaction lifecycle. The core principle is that a sender on a source chain can successfully send a message/token to a receiver on the destination chain.
Some important terms to know
DONs 👥
Decentralized Oracle Networks are exactly what they sound like - a network of multiple oracles working together in a decentralized manner. In the CCIP, there is a a Committing DON and an Executing DON - they each have individual responsibilities in facilitating the transfer between the source and destination chain - mostly they are in place to ensure the finality and authenticity of the transaction.
Routers 🖥️
Users interact with the CCIP via Routers. Routers are smart contracts which provide an interface for users to interact with - it is simply our ‘front-end’ in this case. Similar to Endpoints on LayerZero, every chain has one unique Router. Anyone who wishes to use a Router simply needs to know how to navigate the Router UI.
Onramp/Offramp 🛫 🛬
These are smart contracts in the CCIP architecture which validate the transaction instructions prior to sending/receiving the message. The onramp is responsible for validating things like the account address syntax, message size and gas limit, preserving the transaction sequence numbers. The offramp is responsible for ensuring the message is authentic, ensure the message is only delivered ONCE, and delivering the final message to the destination chain’s Router.
Token Pools 🏊
A token pool is an ‘abstraction layer’ which facilitates the specific instruction included in the transaction. This means the token pool will lock
or burn
the token on the source chain, and consequently unlock
or mint
on the destination chain. The mechanism varies on the specific asset being transferred.
The neat thing about TPs is that they provide rate limiting; a security feature which allows token issuers to set a max. rate at which their token can be transferred. This can be used to prevent malicious actors from flooding the network with transactions, or to prevent users from transferring their tokens too quickly.
ARM 💪 🔐
The crème de la crème of the CCIP , the Active Risk Management is a network of independent nodes responsible for monitoring the system for any malicious activity. The ARM consists of offchain and onchain components, of which you can read a detailed overview here. It is ultimately acting as a “secondary validation service” for the CCIP.
Here’s a (simplified) step by step breakdown of a cross-chain transaction on CCIP:
Sender initiates a cross-chain transaction by interacting with the CCIP Router.
Router routes the transaction instruction to the Onramp.
Onramp contract validates the transaction details and forwards the information to the Token Pool.
The token pool locks/burns the assets on the source chain and forwards the information to the Committing and Executing DONs.
In short, the DONs verify and validate the transaction information, with the ‘blessing’ of the ARM network, and forward it along to the destination chain’s Offramp.
The Offramp contract interacts with the TokenPool based on the specific instructions (either
unlock
ormint
) , and then forwards the transaction along to the destination chain’s Router.The receiver receives the token by interacting with the Router on the destination chain.
Fees & Billing 💲💲
CCIP uses a gas-locked fee payment mechanism (“Smart Execution”) to ensure the reliable execution of cross-chain transactions regardless of unexpected spikes in the destination chain gas. This means developers/users will be able to simply pay for gas on the source chain and not have to worry about execution on the destination chain. This model for CCIP was intended to reduce friction for users and allow for scalability; therefore CCIP will support gas payments in LINK and in alternative assets, such as native blockchain gas coins and their ERC20 wrapped versions. CCIP ensures gas prices are accurate by maintaining a cache of destination chain gas prices, denominated in each feeToken
.
Security
It’s not a secret that security is by far the most important feature in cross-chain protocols. CCIP is quite security-centric (potential cause for concern in the performance and speed of transaction processing) : first off the CCIP utilizes the security of Chainlink’s DONs in validating information between the source and dest. chains. In addition, CCIP utilizes Chainlink’s Off-Chain-Reporting (OCR) protocol - a P2P network of nodes which allows nodes to aggregate their observations about price feeds into one place.
And lastly, CCIP introduces the ARM system, an additional layer of security in which a network of independent nodes oversee and monitor the entire transaction processing lifecycle for malicious activity.
Why is CCIP important?
Cross-chain interoperability continues to be a crucial yet painful part of the evolving Web3 landscape. It is not going away any time soon, but the need for secure solutions is greater than ever.
The vision for CCIP, as with most cross-chain protocols these days, is to enable a suite of cross-chain applications and functions which were not previously possible given the limitations of existing solutions. This includes things like
cross chain lending
cross chain governance
cross chain yield farming
CCIP is also expected to benefit Chainlink and LINK holders, as gas will be paid in $ LINK and not $ETH . Additional utility for LINK will certainly be welcomed, though I wouldn’t anticipate any major price action from the launch of CCIP.
Closing Thoughts 💭
Time for some opinions!
Here’s the TLDR; I believe CCIP presents a unique, multi-layer security approach to cross-chain interoperability - I don’t think it will be the end-all solution, however, nor do I think that should be the goal.
Look, most people involved in crypto have heard of Chainlink at some point. It is considered the industry oracle service by many, and is widely used and adopted among blockchains and dApps. Purists and fundamentalists may scream “Don’t trust, verify!” , but in my opinion there is no pure “trustlessness” in crypto and anyone who tries to tell you otherwise is shilling something. There is an inherent level of trust in any protocol or app you use. The more users a protocol has, the more trusted it becomes.
Chainlink currently boasts $8,010,052,517,053 in total value enabled (!!) , home to over 1,800 projects in its ecosystem, and has partnered with the SWIFT bank messaging system, among others. I’d say it’s a pretty trusted and reputable protocol at this moment in time.
My point is that when it comes to something which has historically been proven to be risky like cross-chain communication, people tend to trust bigger networks and protocols.
This may give Chainlink an advantage for the adoption of the CCIP, particularly among institutions and larger players who value security first and foremost, even if at the cost of slower performance. Which brings me to another point.
CCIP may be slow.
Though it is quite impressive to consider the layers of security involved in the transaction lifecycle on CCIP, I believe all the steps may create some (or a lot) friction and affect the speed and performance of the protocol overall. And the reality is, if you if you can do the same thing you do with CCIP but in seconds using a solution like a bridge built on top of LayerZero, it will be tough to compete.
Nonetheless, I believe CCIP will be critical infrastructure for developers and users who wish to prioritize security for cross-chain interaction. It may not be the flashiest protocol, but given Chainlink’s history and adoption, many developers, institutions, and retail users alike will feel inclined to use CCIP as a ‘safer’ cross-chain solution.
Latest Alpha 💎
CCIP is (kinda) already here! As of monday July 17th, early mainnet access is already available on Avalanche, Ethereum, Optimism, and Polygon. On July 20, CCIP will become available to all developers across five testnets: Arbitrum Goerli, Avalanche Fuji, Ethereum Sepolia, Optimism Goerli, and Polygon Mumbai.
The CCIP explorer is already live: https://ccip.chain.link/
DeFi bluechips like Synthetix and Aave also have early access and have begun shaping what adoption of CCIP will look like :
Cross-chain Liquidity
Synthetix is Decentralized Exchange (DEX) which allows users to mint a variety of synthetic assets against their SNX 0.00%↑ collateral. One of the recent additions to its V3 upgrade is the Synth Teleporter, which employs CCIP to provide users with a streamlined route to transfer Synth liquidity across different chains via a burn-and-mint mechanism.
This model enables Synthetix liquidity to flow toward areas with the highest demand without the need for liquidity pools.
Besides the 30 minute wait time(!!) , UI looks quite clean! Now I just need to load up some snxUSD …
Cross-chain Governance
Aave is the OG borrow/lending protocol in DeFi, and the Aave DAO has facilitated multi-chain governance mechanism, using Ethereum as the voting network. This incurs significant gas costs to voters over time. Therefore, Aave Governance V3 is integrating Chainlink CCIP to create a more secure and cost-efficient mechanism for its cross-chain governance.
And on that note… the Uniswap Foundation recently published its Bridge Assessment Report , as they search out the best available options for building their cross-chain governance mechanism on top of. As my buddy DAdvisoor hinted at, would Uniswap consider Chainlink’s CCIP if Aave and other bluechip protocols continue to adopt it?
Cross-Chain Functionality in Capital Markets
Something which I’m particulalry excited about is the implementation of CCIP in global capital markets. Chainlink has already partnered with SWIFT, a global messaging standard for banks - now with CCIP, enterprises will be able to connect with and interoperate across any public or private blockchain environment directly from their existing backend systems.
Talk about some real world utility….
And that’s a wrap! This paper is meant to be a primer on CCIP , not an all-out guide. If you are interested in exploring CCIP, check out the latest blog post .
None of this is financial advice! I am not sponsored by Chainlink or any of the other projects named in this paper. Ape responsibly friends 🍻