Skip to content

debuggingfuture/ens-offchain-registrar

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ENS Offchain Registrar Cookies

This is a fork to

  • experiment CCIP with cookies and token authentication
  • New ENSjs react hooks
  • Custom on/off chain resolver

Motivation

Part of experiment during ETHGlobal SG

  • whitelist mechanisms
    • onchain
      • ENS TXT
    • offchain
      • cloudflare D1
  • decrypt IPFS cid hash
  • on/off chain resolver
  • returns contenthash, TXT as in PublicResolver
  • CCIP gateway for other records
  • cross-domain cookies

Trust assumption is gateway properly decrypt and return valid content. Consider use of TEE/ decentralization / chainlink functions for trustless execution.

Major modifications are highlighted in bold


This repo builds on top of ensdomains/offchain-resolver to demonstrate what is effectively an offchain subname registrar for ENS names.

Note: This repo does not include a resolver contract. You can find that here, or use ccip.tools to easily deploy it.

Cloudflare Worker is used as the CCIP Read gateway.

A worker version is hosted at https://ens-gateway.debuggingfuturecors.workers.dev/

Cloudflare D1 is used to store whitelist

These choices allow for a scalable namespace with low cost (store up to 1M names for free), low latency, and high availability.

A bare bones Next.js app that allows users to access websites only if included whitelist. There is a button to add yourself into the whitelist.

About

Offchain registrar for ENS subnames using CloudFlare Workers and D1

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • TypeScript 59.3%
  • Solidity 40.2%
  • JavaScript 0.5%