CCIP-Read-DNS-Gateway is a specialized server providing DNS resolution services for ENS domains with a focus on gasless DNSSEC support. It leverages the CCIP-Read protocol to offer efficient, off-chain DNS resolution and DNSSEC validation.
-
index.ts
: Express server for handling incoming requests. Mostly suitable for self-hosting or cloud development. -
worker.ts
: Cloudflare worker script for handling incoming requests in a (Cloudflare Worker) serverless environment. -
app.ts
: Configures server routes and handlers. Utilizes the@ensdomains/dnsprovejs
library for DNS queries and proof generation.
git clone https://github.com/your-repo/ccip-read-dns-gateway.git
cd ccip-read-dns-gateway
npm install
Set the DOH_GATEWAY_URL
environment variable to specify your DNS-over-HTTPS gateway:
export DOH_GATEWAY_URL=https://your-doh-gateway.com/dns-query
To run the server locally:
npm start
The server will start on http://localhost:8080
by default.
-
Install Wrangler CLI:
npm install -g @cloudflare/wrangler
-
Authenticate with your Cloudflare account:
wrangler login
-
Update
wrangler.toml
with your DoH gateway URL:[vars] DOH_GATEWAY_URL = "https://your-doh-gateway.com/dns-query"
-
Deploy the worker:
wrangler publish
GET /
: Health check endpointPOST /
: Main endpoint for DNS resolution and proof generation
@ensdomains/dnsprovejs
: Library for DNS proof generation and validation@chainlink/ccip-read-server
: Framework for implementing CCIP-Read servers
MIT
For support, please open an issue in the GitHub repository or contact our support team at [email protected].