An Overview Of Ethereum Name Service (ENS)

ENS is a dApp based on Ethereum that offers a new naming system in which crypto users can convert their long alphanumeric wallet address into a human-readable format. ENS was started in early 2017 at the Ethereum Foundation, but in 2018, it spun off as a separate organization. The platform is managed by the Singaporean non-profit, True Names LTD.

For every internet user, it is quite common to hit several different websites every day. Almost every site’s name can be easily read with a simple glance. But does our operating system or the internet understand these simple words? The answer is No. The back-end servers/applications help the users to find the exact website and map it with the correct IP address with the help of your browser and operating system. Ethereum Name Service (ENS) serves the same purpose but has some different functionality. In ENS, domains are mapped to 42-characters-long Ethereum addresses instead of IP addresses. The top-level ENS domain is .eth.

The main job of ENS is to map a human-readable name like ABC.eth to machine-readable identifiers, such as Ethereum/other cryptocurrency addresses, content hashes, and metadata. ENS will be unique to each user pertaining to their Ethereum address. You can set and receive multiple cryptocurrencies using this single address. All you need to do is to add the token address in the ENS record section and that’s it. You can now receive all the cryptocurrencies that you have set using your .ETH address.

ENS Architecture

Below is a high-level diagram of ENS architecture. ENS has two core components: ENS Registry and Resolvers.

Ethereum Name Service

The ENS process flow is as follows:

To resolve an ENS address, if there is a user with a domain name, say ABC.eth, then it first queries the registry smart contracts to find the correct resolvers. The resolver then references and responds with the underlying Ethereum address, something similar to this – oxe754689eb4ddd3987a24…

Core Components

ENS has two main components:

  • Registry
  • Resolvers
Registry

These are the smart contracts that run on the Ethereum blockchain. A registrar owns a domain, so in case you want to set up a domain, you need to interact with a registrar.

Different domains have a different registrar. If a user wants to have a .eth domain, he/she needs to interact with the .eth registrar.

The main functionality of the ENS registry is to map a domain name to the correct resolver. The mapping of ENS with an Ethereum address starts with querying the registry. The registry maintains the list of domains and subdomains, owner records, resolvers, and caching TTL (time-to-live) for each, allowing the owner of a domain to make changes to that data.

The ENS registry stores the following three critical pieces of information:

  • The owner of the domain
  • The resolver for the domain
  • The caching time-to-live for all records under the domain

The domain owner may be either an external account (a user) or a smart contract. Owners of domains in the ENS registry are able to set the following properties:

  • Set the resolver and TTL for the domain
  • Transfer ownership of the domain to another address
  • Change the ownership of subdomains
Resolver

As the name implies, the resolvers resolve the query of converting an ENS domain name into their respective address or hash.

The resolver needs to implement the correct method depending upon the type of the record to get the correct output. The record type can be a cryptocurrency address, IPFS content hash, or any valid data. Any new record type can be defined via the EIP standardization process at any time with no impact on the ENS registry or existing supported resolvers.

Resolving a name in ENS is a two-step process.

The registry first checks for the resolver responsible for the name, and then the resolver provides the answer to the given query.

Namehash

Domain names, through easily readable by human beings, are not interpreted directly by backend applications. The ENS smart contract does not understand the human-readable domain names. Thus, to overcome this issue, ENS introduces a fixed-length 256-bit cryptographic hash that will be generated from the human-readable name using a process called Namehash. Namehash is a recursive process that derives a unique hash from a domain name.

For example, the Namehash of “alice.eth” is 0x787192fc5378cc32aa956ddfdedbf26b24e8d78e40109add0eea2c1a012c3dec. This is the representation of names that is used inside ENS.

Namehash is hierarchical in nature. ENS is able to derive the hash of any subdomain if its parent domain is known.

To get a consistent view of ENS, the domain names are first normalized before finding the hash of a domain name using a process called UTS-46 normalization. This process checks and prohibits any invalid character and treats all upper and lower case names equivalently.

Deployed Registrars

The ENS system consists of a dot-separated hierarchical name called domains.

The following registrars are deployed on the mainnet:

  • .eth: The permanent registrar.
  • .test (testnets only): The test registrar.
  • .addr.reverse: The reverse registrar.
  • .xyz: Via DNS integration.
  • .luxe: Via a custom integration that allows any owner of a .luxe DNS name to use ENS.
  • .kred: Via a custom integration that synchs and changes to a .kred ENS token to DNS automatically.
  • .art: via a custom integration

Out of these three, .eth and .test are top-level domains and are owned by smart contracts called registrars. The registrars are responsible for setting up and maintaining rules for the associated subdomains.

Since ENS follows a hierarchal structure, that means if a user holds a domain, they can configure subdomains if required with full control over all the associated subdomains.

Features

ENS has the following attractive features:

  • Decentralized
  • Immutable
  • Censorship-resistant
  • User-owned/controlled
  • Large ecosystem, supported by numerous wallets, dApps, and browser
  • Supports multiple languages
Domain Renewal

To prevent other users from opting for your domain, users are required to renew it. You can renew your domain any time before it expires by paying the required renewal fee. The renewal fees are paid in ETH.

The minimum renewal period is 28 days. However, there is no limit on the maximum renewal period. ENS offers a grace period of 90 days after your domain expires. Users can renew the domain name during this period to retain their ownership.

The yearly renewals cost is as follows:

  • Names with 5 characters or more – $5/year
  • Names with 4 characters – $160/year
  • Names with 3 characters – $640/year
Social Presence

Website

Medium

Discord

Twitter 

Github

Resources: ENS Docs

Read More: How Stacks 2.0 Builds dApps and Smart Contracts on Bitcoin

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.