Open
Conversation
Define a mechanism for mints to restrict endpoint access based on possession of tokens from a specific keyset with a minimum amount requirement. Generalizes NUT-22 from identity-based auth to possession-based authorization without spending proofs.
e8cd658 to
edd0098
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Define a mechanism for mints to restrict endpoint access based on possession of tokens from a specific keyset with a minimum token count requirement. Generalizes NUT-22 from identity-based auth to possession-based authorization without spending proofs.
Context: When I was updating the spec for Conditional Token Framework (#337),
I noticed that I want to grant access to some Mint endpoints only to the user who holds the token.
22.md was not good enough because it was only proof-of-authentication, what I wanted was proof of possession.
24.md was also not good because it requires a payment from the user.
To give more details, I want to introduce a new kind of token in #337, so to speak, "Market Owner token".
Market owner will receive this token when they register a
conditionfor the CTF.A mint can take an additional swap fee for each conditional token transaction, and then later, the Market Owner Token holders can redeem the fee collected in exchange for that market owner token. This incentivizes users to create a more popular market.
If the market is a company, then this token is like a stock.
I want to have an endpoint that only the market owner can access. e.g. "total fee accumulated for this market". This spec is the prerequisite