Inspiration

The possibilities opened up by CCIP to make information seamless across chains coupled with the utility offered by ENS domains.

What it does

Cross-Chain ENS Resolver allows users to retrieve the owner address of an ENS domain across chains. There is a CCERequest contract deployed on Avalanche Fuji, and a CCEResolve contract on Ethereum Sepolia.

The user interacts only with the CCERequest contract on Avalanche Fuji to retrieve the owner address of their queried ENS domain from Ethereum Sepolia, back to Avalanche Fuji. The user inputs the address of the CCEResolve contract, the ENS domain to query as a string, and the chain selector.

The ENS domain is sent to Ethereum Sepolia and used for interacting with the ENS contract on that chain to look up the owner of the domain. The owner address is then sent back to the CCERequest contract along with the ENS domain. These values are stored in state variables and an event is emitted declaring them.

How we built it

The project was built in Foundry and deployed to Avalanche Fuji and Ethereum Sepolia.

Challenges we ran into

Converting the ENS domain string into the appropriate format took a few attempts, but eventually I found a namehash library.

Accomplishments that we're proud of

Sending a bi-directional transaction on CCIP is very exciting.

What we learned

I learned how to interact with ENS contracts directly, which is something I've never done before.

What's next for Cross-Chain ENS Resolver

Added functionality such as looking up balances etc of ENS domains across chains.

Built With

  • avalanche
  • ccip
  • ens
  • foundry
Share this project:

Updates