Skip to content

Commit

Permalink
WIP: impl notes
Browse files Browse the repository at this point in the history
  • Loading branch information
ross-spencer committed Nov 20, 2024
1 parent f2d7541 commit 5d7e288
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions src/simple_sign/sign.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,20 +58,40 @@ def retrieve_aliased(pkey: str) -> str:
is consistent parsing of metadata that allows this function to be
broadly applicable across functions.
"""

"""
given all unspent, we need all aliases:
http://0.0.0.0:1442/matches?unspent
from the list of aliases, return the stake key for the pkey (alias)
"""


raise NotImplementedError("reading staked values is not yet implemented")


def signature_in_staked_pool(pkey: str, token_policy_id: str, min_stake: int) -> bool:
"""Validate whether the signing key belongs to a someone who has
enough stake in a given token.
"""

"""
calculate all tokens for a given stake address:
http://0.0.0.0:1442/matches/stake1ux9erxtj7d4u4avfznkawu0ew7qttvv530shqm8dg09sh4g9ma27v?unspent
"""

raise NotImplementedError("reading staked values is not yet implemented")


def signature_in_license_pool(pkey: str, policy_id: str) -> bool:
"""Validate whether signing key matches one of those in a pool of
licenses associated with the project and return True if so.
"""

"""
find license for a given stake address:
http://0.0.0.0:1442/matches/stake1ux9erxtj7d4u4avfznkawu0ew7qttvv530shqm8dg09sh4g9ma27v?unspent
"""

raise NotImplementedError("reading from license pool is not yet implemented")


Expand Down

0 comments on commit 5d7e288

Please sign in to comment.