Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delegatable resolver registrar #295

Conversation

makoto
Copy link
Member

@makoto makoto commented Dec 6, 2023

A minimum registrar that allows the contract to approve user to update subnames.

@jefflau
Copy link
Member

jefflau commented Dec 6, 2023

Just had a thought as well. If this is being deployed per user, it could also just be the same contract as the DelegatableResolver. Then you wouldn't have to approve the registrar on the resolver and save a transaction and UX.

Copy link
Member

@Arachnid Arachnid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intended to be used in prod, or just as an example registrar?

contracts/resolvers/DelegatableResolverRegistrar.sol Outdated Show resolved Hide resolved
contracts/resolvers/DelegatableResolverRegistrar.sol Outdated Show resolved Hide resolved
@makoto
Copy link
Member Author

makoto commented Dec 7, 2023

Is this intended to be used in prod, or just as an example registrar? more as an example. I initially just had it as a gist, but had problem compiling via remix, hence decided to put into our contract. I don't mind taking this out completely from ens-contracts repo and put that in evmgateway repo instead

0,
operator
);
if (authorized == false) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this does what you want. It won't prevent duplicate subdomains, because it only prevents the same person being issued the same name twice. I think instead you need to keep a mapping of issued names, or modify the DelegatableResolver to keep track of issued names.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's my intention. I only added it to avoiding existing operator to waste the gas. Not sure restricting multiple subname operators at registrar level makes sense because the owner of the resolver contract can always approve multiple operators. If we want to change the delegatable resolver to only have single owner per subname, I think I need to add registrar feature directly in the resolver as @jefflau initially suggested.

@makoto
Copy link
Member Author

makoto commented Dec 12, 2023

Going to close this as I added the contract into evmgateway at https://github.com/ensdomains/evmgateway/pull/23/files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants