The Official ENS Name Wrapper is Audited, Published on Testnet, and the Live Contract is “Right Around the Corner”!
The Ethereum Name Service (ENS) is a distributed and open naming system built on the Ethereum blockchain. ENS domains, such as john.eth or 123.eth, can replace long alphanumeric wallet addresses, host websites, be your primary Web3 username, and have other practical features.
On top of existing ENS features, the ENS core team “True Names, Limited” will roll out a major improvement – The official “Name Wrapper” contract, for ENS Subdomains.
What is the ENS Name Wrapper?
Name Wrapper is a smart contract that will allow to issue subdomains (such as sub.domain.eth) as a separate Non Fungible Tokens (NFTs). It is already possible to make and use subdomains, but they are not created as separate NFTs and cannot be transferred between wallets, rented or sold. On top of that, it will be possible to customize subdomains by revoking sets of permissions (burning fuses) to change the degree of ownership.
The ability for anyone to own and trade a subdomain opens up many possibilities:
- Platforms can use subdomain infrastructure for ownable usernames.
- Businesses can use subdomains for payments and accounting.
- Artists can issue subdomains as artwork, and tokens for fans & contributors.
- Merchants can issue subdomains as tickets, access tokens, proof of authenticity (Internet of Things) and more.
- Brands & individuals can rent & sell their subdomains.
Multiple projects such as Decentraland are already using ENS subdomains as tradable in-platform usernames (john.dcl.eth for example). Decentraland had to create its own custom contract to accomplish this, but with the Name Wrapper, it will be easy for anyone to do the same. By supporting ENS, platforms are taking advantage of an already fully built and tested blockchain naming service.
Name Wrapper & Fuses
Before diving into subdomain customization, it is worth explaining the terminology of ENS infrastructure:
- Registrant: owner of main domain (such as domain.eth) that can set the controller address and transfer it to someone else which technically means changing the Registrant.
- This is the ultimate owner.
- Controller: address that can do anything except transfer the domain.
- Can not change the Registrant.
- Expiration Date: the date on which the registration expires and the domain needs to be renewed.
- Anyone can renew ENS domain.
- Records: information such as multiple crypto wallet addresses, hosted content, avatar, email, description, socials, etc. tied to the ENS domain.
- Records can be set by the Controller.
- Resolver: stores and handles all the records for the domain (ENS provides a functional public resolver).
- With a custom resolver, it is possible to manage data, limit or add functions, request off-chain data (EIP-3668/ CCIP Read) and resolve subdomains that technically do not even exist (Coinbase is currently using both of these features).
- Time-To-Live (TTL): custom setting that allows the client to specify how long to cache records.
- In principle, there is no need to change this setting and cache records on the blockchain.
Name Wrapper will make 2 crucial things possible:
- Allow issuance of subdomains as individual NFTs.
- Allow customization of subdomain permissions.
Technically creating a subdomain means setting the Name Wrapper contract address as the controller of the subdomain. In return, a wrapped NFT representing the subdomain is created. Unwrapping means sending the subdomain NFT to a burn address that is not owned by anyone. You are not really destroying the subdomain itself (associated data is stored in the ENS core registry), but just the NFT representing the ownership and rights.
The customization of subdomains is achieved by burning fuses or revoking sets of permissions. Fuses can be burned when issuing the subdomain and later by the new owner. Once a fuse is burned the permission that the fuse represents is revoked for a specified time.
In total there are 7 different fuses:
CANNOT_UNWRAP = 1
- If this fuse is burned, the name cannot be unwrapped. By disabling the unwrap function, it will not be possible to unwrap the domain. This prevents the domain of being unwrapped to reset the fuses.
CANNOT_BURN_FUSES = 2
- If this fuse is burned, no further fuses can be burned. This allows to permanently lock a set of permissions on the domain. Any further tries to burn fuses will fail.
CANNOT_TRANSFER = 4
- If this fuse is burned, the name cannot be transferred. This allows the use of ENS domains as Soul Bound Tokens (SBTs) which cannot be transferred or sold, but still exist as separate NFTs.
CANNOT_SET_RESOLVER = 8
- If this fuse is burned, the resolver cannot be changed.
CANNOT_SET_TTL = 16
- If this fuse is burned, the TTL cannot be changed.
CANNOT_CREATE_SUBDOMAIN = 32
- If this fuse is burned, new subdomains cannot be created. By burning this fuse, it will not be possible to issue more subdomains under the domain.
PARENT_CANNOT_CONTROL = 64
- If this fuse is burned, existing subdomains cannot be replaced by the parent name and the parent can no longer burn other fuses on this child. Without this restriction, the parent domain (domain.eth) could take full ownership of the child domain (sub.domain.eth) at any time. This fuse can only be burned only by the parent domain.
It is also possible to skip burning any of the fuses and fully use the child domain (transfer, sell, set records, host content etc). In that case, the parent domain would still be the ultimate owner and could regain ownership even if another address owns the child domain. Only the parent can burn Fuse 64 which revokes this permission. No other fuse can be burned prior to Fuse 64 and also Fuse 1 which guarantees that the child domain can not be unwrapped.
Worth mentioning that child domains can also be parent domains to other subdomains. That means it is possible to issue multi-level subdomains and individually tailor these restrictions for any domain.
ENS Name Wrapper Fuse Expiry
Each domain has an expiry for the fuses (one for all fuses). Only the owner of the parent domain can set the expiry and it can only be increased. In the case of expiry the fuses are cleared (set to their most permissive state). When burning fuses, it is mandatory to set an expiry that can not be greater than the parent domain’s expiry. After domain.eth is renewed, the owner of domain.eth can extend sub.domain.eth fuse expiry. For example:
- If domain.eth is registered for a year, the fuses can be burned only for a year or less. After domain.eth is renewed for longer the owner of domain.eth can extend fuses on sub.domain.eth
- If sub.domain.eth fuses expire in a year, the fuses can be burned only for a year or less. After the owner of domain.eth extend fuses on sub.domain.eth, the owner of sub.domain.eth can extend fuses on sub2.sub.domain.eth
To maintain trustless ownership for sub.domain.eth for a long or infinite period of time:
- Pay for the domain.eth registration years ahead before issuing sub.domain.eth. This allows long expiry on fuses.
- Build a custom registrar such that anyone can extend fuses.
There are no renewal fees for subdomains on the protocol level, but the main parent domain must be renewed as fuse expiry can not be longer than the parent domain expiry. If the registration of the main domain is not extended, it expires and gets unwrapped. Worth to mention that it is technically possible to charge subdomain registration fees with the custom registrar.
After the domain expires existing subdomains are not burned and are still functioning. If someone re-registers the main domain, the new owner could take back the ownership, burn fuses or just do nothing with the existing subdomains.
ENS Name Wrapper Use-Cases
Name Wrapper opens up many new possibilities and a chance to build a network and brand around the ENS domain. The customization of domain restrictions opens up more use cases than a standard NFT.
- Gift subdomains to promote your domain/brand.
- Rent and sell subdomains with full ownership.
- Issue a subdomain with full ownership, but limit further subdomain creation.
- Issue transferable or non-transferable subdomains as attendance tokens (john.event.eth), personal identifiers (john.sales.google.eth), tickets (ticket.2022.festival.eth), in-platform usernames (john.twitter.eth).
- Issue a subdomain with short expiry for day tickets (day1.festival.eth), coupons (discount.store.eth), access tokens (trial.course.eth).
- Use subdomains as Proof of Authenticity (88.116500ln.daytona.rolex.eth).
- Use a custom registar to allow specified NFT holders to mint a subdomain (4269.bayc.eth).
- Use custom resolver to allow fuses to be extended by anyone (with or without a fee), manage and retrieve off-chain data, and add or limit functionalities for subdomains. For example, limit record customization so the subdomain can be used only for intended purposes (crypto sent to john.exchange.eth goes to exchange wallet).
There has always been a market for usernames on popular platforms such as Twitter and Instagram. Most platforms are against username trading, but that only makes the market unsafe and attracts a lot of scammers. Platforms could embrace ENS and encourage safe username trading or technically limit the ability for the subdomains to be transferable.
There is a large list of individuals and companies including Puma, Budweiser, Nike & Coca-Cola who already own their ENS domains. Hopefully, they already have plans for when the Name Wrapper releases.
I’m 448.eth and this is my fourth article. Follow me on Twitter (@448_eth) to learn more about ENS 🙂