Identity in Your Apps with ENS - ETHGlobal San Francisco 2024
ETHGlobal·Thu, Oct 9, 2025, 12:00 AM
Join us for a workshop with Luc van Kampen from ENS titled, "Identity in Your Apps with ENS." Learn all about ENS (Ethereum Name Service), the decentralised naming protocol used by Coinbase, Uniswap, Venmo, and thousands more. We'll cover: - What is ENS - How does ENS work under the hood - Some ideas for what you can build on ENS - Latest resources to help you during the hackathon This workshop took place at ETHGlobal San Francisco, a 3-day hackathon held from October 18 to 20, 2024, which brought together web3 developers, designers and product builders from all around the globe for a weekend-long adventure to advance the Ethereum ecosystem! ----------------- Follow us: https://x.com/ethglobal Check us out: https://ethglobal.com/ Email us at: hello@ethglobal.com
Transcript
[Music] all right um good morning afternoon or evening whenever and wherever you are whether you're here in the room with us today or whether you're watching this recording an hour from now while you're hacking or three months from now or a year from now um my name is Luke Luke D eth um I'm developer relations at the ethereum name service and today I have a bit of a cold but I'll be running you through um how to set up identity in your apps and all of the other cool stuff you can do with enss or some of the cool stuff there is much more um and if you're interested doca domains will have everything you need so quick agenda for today we'll be talking about what what ens why ens subnames and all of the other cool stuff how and stuff you can build cool so for starters what is ens ens is super simple ens is a decentralized permissionless naming protocol that lives on ethereum and that skills to the entire internet and so what that means is that ens allows us to turn hex addresses like 0 x225 f13 714 Y c35 into human readable names like luke. e in the same way that DNS allows us to turn IP addresses into usernames or into domain names in this case and ens allows us to take heximal addresses and Bitcoin addresses and any form of formattable address into a regular name so anywhere you can put an IP address like in a browser or an address or anything of the sorts you can put a DNS domain name and for the same right anywhere you can read or write an address you should be able to put an ens name now what that looks like is round about here on the left you can see transactions normally this would be a bunch of addresses money coming in from here going to there left and right into a contract and back and forth um but instead you can just see that they're names because it's easier for people to do and on the right where you can enter an address instead of making a crucial typo and screwing up a major transaction to your friend or copying something wrong or having selected too few or too many um you just have a name and a profile picture and some other information to double check and you know give you that peace of mind when your users are going through certain flows so ens is a two-step process um there's forwards resolution which is from name to address for whichever coin type that is um and there's reverse resolution which is from an address to a name and so this allows us to let people sign into applications and then immediately show their username and their profile picture and their Twitter in the top right um or whatever information you want to show my mouse is in the way um so ens is not just a username it's a whole set profile um we aim to extend DNS and add additional functionality and so it we can store all sorts of cool stuff inside of a profile an avatar a banner a Twitter record like I mentioned before an X record um Bitcoin addresses Litecoin addresses ethereum addresses you name it down here you'll see an array of sites that are all with Greg in it um of different websites that are gateways if you will where you can view profiles and anything of the sorts so here's a really cool one my absolute favorite except for the other ones I made myself um the ens manager app which allows you to view information about a profile you can find it at .a whatever name you're looking for um and so in this case this is my profile I have some salana records set I have a bunch of social records set I've got the description I've got a location I've got a website luke. Compu which is also an enss name um and I've got a whole bunch of other records that the manager app might not support but other apps can and so you can leverage records if you wanted to in user profiles to do dark mode prefer preferencing or anything of the sorts whatever here's some more examples of that top right experience on every website you can imagine with one line of code it's built into WME no additional dependencies um or just one RPC call you can showcase somebody's username it's that easy so why um users of crypto powered experiences should never in my opinion at least um have to interact with a hex address actually users of any application should never have to interact with a hex address yes it's cool to interact with hex addresses and to move them around from A to B and to be able to actually view what's happening under the hood but my mom doesn't want to look through her transaction history and see a million transactions to all of these weird random places that are completely unknown if she can also just just see that it's an invoice from coinbase and it was this and this and this and that it was money sent to Luke and it was this and this and this etc etc so it's about improving the user experience um to that extent our logo is wrapping the ethereum logo to improve the user experience we are padding the ethereum user experience making a bit more soft around the edges so there's different types of VNS names you might want to know about there's the native ens TLD um which we created ourselves is maintained on mainnet and it's the eth TLD and there's every other DNS TLD in existence doxyz do.org computer which I have one of luke.
computer umash finance and you name it these are all usable within UNS because they're just regular domain names and we're just a protocol that allows for a bit fancier resolution than regular DNS we're just extending how it work how it works so to that extent ethames live on mainnet they are decentralized once you own a name you have the nft there is not a chance that anyone can do anything about it um and it is controlled by the Dow so we have a decentralized autonomous organization there's a whole Spiel behind it I encourage you to look into it it's super interesting but long story short once you have your name you're safe um and you pay an annual protocol fee to prevent squatting so for a regular felter name or above that's $5 a year we're not going to talk about three letter names um with regards to DNS they're free well I mean you're already paying for a DNS name there should be no reason you should be paying us we're just a protocol and so as long as you have a DNS name you set a text record and then your name will now magically work anytime someone does a look up to the smart contracts the smart contracts will do an offchain call it'll read from your name it'll verify all the information in there do a signature check and then be like awesome this is valid information it leverages DNS SEC it's cool it's complicated there's docs about it not enough time in this talk but the owner ship is controlled by the registar which means that if you're getting a verisign still owns your doom you just lease it from verisign if you have a.org same story and so you're still reg with the regular DNS ownership rules whereas with eth once you have a name it's a fight between you and the smart contract and I rest assured the smart contract's winning um so there's also offchain names and L2 subnames um those don't have a protocol fee at all and they give developer give Dev velers more flexibility so the way that works is once you own a name you can deploy a contract a resolver um and you can basically tell that resolver to load information from another location whether that's a contract on an L2 that does State Route verification on the way back or whether that's from an API offchain um this is EIP 3668 there's docs pages about this don't worry about it I've spent way too much time on it you'll find out all about it um these are used by coinbase Linea Unis Swap and many more in production got to make sure I don't accidentally do more name drops um and we've got some crazy astonishing numbers um as of recently so more about how those work how does enss work as a whole um super simple we have a contract on mainnet I will be oversimplifying a little bit um but essentially we keep track of the name and the resolver and the owner um for luke. eth my resolver is 0x 49 y da this one will be familiar because a lot of us have this one I'll get back to it in a minute um cbid has its own resolver it's just a contract they wrote that then says please load from this offchain location um and Linea has their own same thing both of these contracts are 30 lines Max so I encourage you to have a look at them um you'll be able to look these up as well awesome so the one I'm using 0x 49 is the public resolver the public resolver is a contract we ens Labs have written and it's the default for all of you who register in name through the NS manager app the public resolver is just key value storage in a smart contract um and so I've uploaded my address my text records and my content hash and anytime someone does a look up for my name it'll go to the resolver it'll query the information and it will just Depot its like dump its storage slots and so the public resolver has basic authentication built in and the owner of a name has the ability to update its own text records pretty self-explanatory it's a sensible def fault for most people but if you wanted to build your own stuff you can build your own stuff and so in coinbase's case with cb. there's the offchain resolver so anytime somebody does a lookup to the contract um it'll revert with offchain lookup again 30 lines or less contract um and then it will hit some sort of API or some sort of Gateway that then queries information from an L2 or that queries information from a database and then resubmit it to the contract on the way back to do a verification this can be any arbitrary verification logic you get to implement this in your contract in your resolver and so this could be a state rot verification this could be a signature check it could be anything of the sorts so those are ccip read again EIP 3668 there's a whole docs page about this doc study domainweb subdomains everything you need to know I'll link to it at the end of the slides so this leverages wild card resolution the idea that you can do a lookup for a name and that it exists somewhere in the space um and so it will do name lookup from back to the front from eth to Luke to hello so hello. luke.
eth all of that fun stuff so super simple look for the resolver in the registry if it's not set look for its parent and then continue until a resolver it's found basically it's just how we do name resolution under the hood um and then we resolve the original name via the closest we can find and so if my subdomain subdomain hello. luke. eth exists then it'll use that Direct directly but if it doesn't it'll use eth or it'll use e. Luke or whatever the hell depending on the order cool so all of this cool stuff um EIP 3668 you'll find on the docs as well um and this is kind of what that flow looks like and so you revert with offchain lookup it hits some sort of like the the client re hits some sort of Gateway the Gateway fetches the information and then there's a call back function that does verification sweet so Linea does this similarly it uses the evm Gateway resolver which is a template contract we've written that leverages 3668 so it's to make it easier but it is also another name on the list of things you need to remember um don't worry about this it's in the docs if you're interested you'll find it um the evm Gateway resolver is basically just a contract that lets you verify storage slots on an L2 so if you wanted to issue subnames on an L2 you could just drop this in and it will magically load the storage slots from your template contract cool so there's the offchain resolver and the evm Gateway resolver they both use pcip read and they both read offchain data but one of them reads arbitrary offchain data and the other one reads from any L2 and so it's kind of a subset of offchain resolvers as a whole um and same story arbitrary verification and L2 State Route verification awesome so take a breath that is the deepest we'll go okay it's not that crazy um there's many different ways you can Implement ens you can can press buttons in the manager app and have a super user-friendly experience leveraging the name wrapper a pre- deepy smart contract that allows you to issue subnames on L1 um or you can take it all the way crazy and write a contract from scratch and so there's a bunch of options in between I encourage you to check out the docs doc studs domain web subdomains um and it'll have everything for you so if you're issuing subdomains this is where you've got to be I'll keep it on the screen for a few seconds if you want to scan a QR code um this might be a Rick Roll so be careful uh but it might also go to the right docs page it it depends you never know with my slides um so if you're issuing subdomains and you're building something really cool and during this hackathon you're like yay I want to give out free usernames to all of my users this is where to be and it will explain to you all the different fun options so building on ens um we've got a couple hackathon resources as well another QR code or a Rick Roll you'll never know unless you scan it so please scan it um and it contains the key Concepts some code Snippets random on liners you can copy paste and do cool stuff with as well as contact info um so should I not be hacking at the ens Booth or like harassing people for the next 72 hours um You can call me while I'm asleep in my hotel room CU our contact info is on there as well as well as we have a ton of other wonderful ens members around that you can harass to with all of your technical or non-technical questions cool if you want any more project ideas um honestly integrating enss is one line I wish I could give a bounty to all of you um but we cannot because they won't let us and so uh we're giving out prizes to anybody who builds anything cool with enss and so I encourage you to build whatever your dreams desire and just give out subnames um and we'll be happy to to help you out along the way cool so we've got 2 and a2k for the most creative use case we've got 2 and 1 12K for the best L2 experience so if you're issuing subnames on base or you're issuing subnames on arbitrum or wherever your mind um or heart's desires are you can do so and then we've also got three follow-up prizes two and a half one and a half and 1K for honorable mentions and so if you build anything cool in the ecosystem or like name renewal tooling or a Registration site then be my guest thank you there's another QR code I don't know what this one does but that's fine um I hope you all have a wonderful day thank you for attending this talk and if you're hacking happy hacking um and I look forward to seeing what you guys build awesome [Applause] cool am I still being recorded yeah awesome if there's any more questions um I'll happily take them we have a microphone over there but you can also just yell them at me and I'll repeat them back for the room go for it are you guys um I I'm not sure but I can look into that for you and so um doc study n domain deployments um you'll find it don't worry about it um we've got a deployment on mainten a deployment on seoa and a deployment on uh heski um those three are all linked to the deployments that they equate to so mainnet is linked to base but sapoia is linked to base sepolia and then etc etc and so if you're using a seoa somewhere I recommend staying in the sapoia line of things and keeping all of the chain IDs correct um but resolution always starts at either main net sapoia or heski or whichever test nets come in the future and then trickle down to whatever chains correspond and so if you're working on a test net make sure all of them are test net chain IDs cool go for it yeah so the question was if you want to issue names on an L2 um whether you could sure yeah so um the name will uh is this this a second layer name we're talking about so in this example you have your name. b.
eth I'll take myself for the example loan. b. eth um and then you want to issue subnames for that so the difficult part here is that you're under the jurisdiction of base. eth and that is under the jurisdiction ofe now eth is a very free jurisdiction and everyone can set their own subdomain um with base. eth everything is controlled by a contract on base itself and so I would recommend looking into the particulars and whether they you set a custom resolver because they might not they might only let you set records and then the rest of the logic is just in the contract um but if you have a regular.
eth or if you have a DNS name a second level name so a luke. eth or a loan. eth or a Luke docash or luke. computer.com or whatever those have full permission and freedom for you to issue as many subnames as you'd like um however if you are on a sub subname basis you're obviously dependent on the one layer of implementer right and so if I was issuing subnames under luke.
e then somebody would only be able to do their own subnames if my contract let them do such a thing [Music]
Automatic transcript — names and jargon may be misspelled.