[Music] I'm Greg Derell at ENS Labs and excited to talk about ENS or identity in your apps. Um, so first of all, let's talk about what is ENS. The Ethereum name service is a decentralized permissionless naming protocol that lives on Ethereum and scales to the entire internet. At a high level, we turn complex hex addresses into human readable names. So at the top, nobody's going to remember that.
Nobody knows what that means. But gregirleth, very easy. And that's me. I'm Gregirl. You can think of it similar to DNS, right?
Back in the day, servers had IP addresses instead of domain names. And domain names are significantly better. For crypto, ENS does the same thing. we go from hex addresses to human readable names. And the way you should think about it is anywhere you can put an IP address in a browser, uh, you can use a DNS name.
Similarly, anywhere you read or write a hex address, you should be able to use an ENS name. We want to get rid of hex addresses in crypto. And this is powered by two processes. Right? On the left, you're reading something.
This transaction already happened. And instead of seeing in the bottom two examples ox179A doing something on the contract ox121 that doesn't mean anything right you have no idea what's happening here but in the top two examples you could see that I am sending something to the smart contract named zk.ns.gregirl.eth Very easy.
It's some ZK application under my name or real Cameron sending something to Greg Squirrel. Very easy to understand. On the right side, you see the opposite. So, I'm not reading a past transaction or seeing a name. I'm typing in a name.
I'm sending assets to Gregscril.eth. So, those two examples are examples of forward resolution and reverse resolution. It's the idea of a name going to an address. you can have a different address on each chain.
And reverse resolution is exactly the opposite. It's an address going into a name. And as of recently, this is also available on multiple chains. They're kind of grayed out because it's only on test nets for now, but both of these things work across multiple chains in the EVM. And these two things come together.
So forward resolution and reverse resolution form this idea of a primary name. And a primary name is when you sign into an application and see yourself kind of recognized as your ENS name. It's really this idea of going from just a username where you would type in a name and get an address to a profile. So here you can see is my ENS profile, right? I have my avatar image, a description saying that I like baking and a bunch of addresses on different chains of mine.
This is a full ENS profile and we want to make sure people are thinking about ENS as a profile instead of just you know a name to address map and so you understand the basics of ENS. It's like why does this exist? Why is it important? And the end goal is that users of cryptoowered experiences should never interact with hex addresses. This is Ethereum as you all know the logo.
And a fun fact is that the Ethereum logo or that the ENS logo is actually a perfect wrapper around the Ethereum logo because ENS exists to make Ethereum and all of crypto easier to use. So I feel like showing it this way um is a fun way to remind people why ENS exists. So now you know what it is and why it's important. So let's dive into how it works from the smart contract side of things. So today at the core of ENS is a registry.
But the registry is a smart contract and a simplified version of it stores a name and a resolver. A resolver is what's responsible for storing all of the data associated with a name. So all of those addresses and all of those other social records that you saw in the screenshot before. Now many names can use the same resolver or you can have different names that use a custom resolver. Resolver is a very customizable entry point into a name and I will show you how resolvers work.
So this is an example of what the public resolver which is kind of the default resolver that most people use in EMS works for my name Gregirl.eth right at a high level you have a few different data types. You store addresses, you store text records and you can store something called a content hash. Addresses and text records might be kind of straightforward. You know, I can store an ETH address, a base address, a Bitcoin address, really anything.
We support any EVM chain and basically any non EVM chain as well. So, for example, if you're in PayPal, you know, a popular payments app, and I have a Bitcoin address set for my name, I can actually send Bitcoin from my PayPal account to an ENS name. Um, which is really cool. Most people think it is only Ethereum, but we actually resolve addresses on any chain. Um, text records are arbitrary key value stores.
It's just a string to a string. Some of the common ones are storing an avatar or a description. And this is what makes ENS more of a profile than just a username. Like I explained before, the content hash is basically a way to connect some decentralized content to your name and make a decentralized website. So for example, Vitalik famously shares his blog as vital.
And what's that what that's doing under the hood is looking at the content hash record for Vitalic, seeing that he's posted the content on IPFS and surfacing that content through a kind of gateway. And so the content hash is basically a way to store decentralized content alongside your ENS name. And this is the public default resolver. Now, if we want to get a little fancy, um, many of you might know that Bass issues subdomains under base.eth.
So for example, I have a name greg.base.eth and the way that works is very similar. Uh they have a resolver on mainet ethereum because that's the entry point again to all ENS data. But the thing that's I guess fancy about bass is that instead of storing the records directly like we did previously, they revert with this off-chain lookup.
And this revert is called CCIP read or ER3668 3668. This is a spec um created by ENS that basically makes it easy to fetch offchain data from a smart contract. It was written by you by ENS and mainly used by us, but it's an open Ethereum spec or an open EVM spec that anybody can use. And what happens here is that once the smart contract, which is the resolver in this diagram, reverts with a off-chain lookup, the client or like the wallet for example that you're trying to resolve a name from will reach out to some off-chain gateway like an HTTP server and ask for some other data. So CCIP read basically defers the resolution of a name to some other data source and that can be a database it can be a layer 2 like the base chain in this case and so on.
So this is how you have flexible L2 subnames with ENS. And so these are kind of building blocks right we went over what ENS is why it's important um and how it works. So, what are some things that you can build with ENS? And I just want to reiterate again at a high level when you're working on something this weekend, you should be thinking anywhere your app shows a hex address, it should instead show an ENS name. So, what does that look like?
If you're building some AI agent that you're talking to, uh, that agent probably has a wallet and therefore that agent should have a name. Uh, if you are looking for creative use cases of how to use a name in AI, maybe you can store a system prompt in a text record for a name as an example. If you're building a wallet app, you should provide your users with a way to get a username and so they can send assets to each other more easily. If you want to have a better user interface, you would probably have an avatar and so on. Primary names are also an interesting way to basically surface any content.
So if you have maybe a DeFi app where you might not think how can ENS be used, think if you have some leaderboard and you want to show the addresses that have the best the best returns or the MEV bot that extracted the most value. It's easier to see that a name, you know, had the best trades verse an address. So again, anywhere there is an address, there should be names. This is maybe more clear in social and then obviously for content side, you could have decentralized websites as well. So, these are just some examples as you're thinking about things over the weekend, the different features of ENS that you might want to use um in your project.
Two resources that will become useful for you this weekend, especially when building primary names and L2 user experiences, is Duran, and then I'll go to the next in a second if you guys want to scan this QR code. Um, Duran is basically a framework to easily create L2 subnames on ENS. And so if you're building an application that's deployed to base or arbitum or any of these things um or even EVM compatible L1's, you'd be able to use DUR to easily issue subnames for your users and still have an opportunity to customize really how that smart contract works. So it kind of walks you through step by step um what you would need to do to create L2 subdomains for an ENS name and issue usernames to all of your users. The next thing that plays really nicely with Duran is the new L2 primary name feature I was explaining earlier.
Um, this is the idea of going from an address to a name, which you would need to show, you know, usernames on a leaderboard or on a block explorer or in a wallet or anything like that. Primary names are really what turns ENS from a name into an identity. And yeah, I'll leave this up for a second if anybody wants to scan. Cool. Um, using these resources or your own imagination, we have three prizes this weekend.
First, the most creative use case of ENS. This might be an a an sorry, an AI agent that stores the system prompt in a text record like I said before, or some privacy solution that rotates the addresses uh and gets creative with the way you use resolvers. The next is the best use of L2 primary names, that new feature that I was describing. Um, this is where we're weakest on examples and kind of code snippets. So, if you run into trouble, come to our booth and we will help you out.
Um, but just giving you a little heads up. And then best use of ENS is basically anything that you can think of. So, it might be an AI agent, it might be a use of LT primary names, but just the best teams will get this prize. Um, yeah. So, these are our docs for everything.
And this is my personal telegram. We will be here all weekend, but if you have issues and are not in the building, feel free to reach out. Uh we have five minutes, I believe, for questions. Um so I would love to take those now. And if not, I'll scroll through some of the other resources.
No questions. Okay, then I'll take a moment to scroll through Duran just because I think that's useful to highlight. Um, and I already had it. okay. Dur is what I was talking about before is a step-by-step process to create L2 subnames.
And basically at first you deploy a contract to or you have to set the resolver. So it assumes that you already have an ENS name on L1 because all resolution for ENS starts on L1 Ethereum. This is like Gregirl.eth in my case or your project name. You would choose this name and a chain that you want to deploy the subnames on.
So it would be like username.name. Um and then it walks you through basically connecting those dots using CCIP read that I explained before. Um later it walks you through the process of customizing a registar and this is basically the business logic that allows users to register a username. So you might customize this such that it requires a self proof or a world ID proof to register a username proving that only verifiable humans can mint a subdomain and use your application.
Uh this is kind of the customization that we'd be looking for in this sort of example. And then ultimately it walks you through actually registering a name on Etherscan and kind of settling the process. So we support a number of chains out of the box with this. And if you're trying to build on some EVM chain that is not listed here, come by the booth and we can help you get set up. Uh everything is obviously open source and we are here all weekend to support.
So that's what I wanted to walk through. Um but yeah, come by the booth and good luck with your hacks. [Music]
Automatic transcript — names and jargon may be misspelled.