Skip to content

Commit

Permalink
Multisig script and submitGrant method for handling submission of gra…
Browse files Browse the repository at this point in the history
…nts from mutlisig. (#103)

* submitGrant method for handling submission of grants from mutlisig.

multisig issuer/holder script with credential issuance and GRANT/ADMIT workflow.

Signed-off-by: pfeairheller <pfeairheller@gmail.com>

* Unit test for `submitGrant`

Signed-off-by: pfeairheller <pfeairheller@gmail.com>

---------

Signed-off-by: pfeairheller <pfeairheller@gmail.com>
  • Loading branch information
pfeairheller authored Jan 16, 2024
1 parent cbe57d4 commit e151291
Show file tree
Hide file tree
Showing 5 changed files with 553 additions and 11 deletions.
13 changes: 9 additions & 4 deletions scripts/list_person_credentials.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@

def list_credentials():
url = "http://localhost:3901"
bran = b'0123456789abcdefghijk'
# bran = b'0123456789abcdefghijk'
# bran = b'PoLT1X6fDQliXyCuzCVuv'
bran = b'Pwt6yLXRSs7IjZ23tRHIV'
tier = Tiers.low

client = SignifyClient(passcode=bran, tier=tier, url=url)
Expand All @@ -23,13 +25,16 @@ def list_credentials():

aids = res['aids']

assert len(aids) == 1
aid = aids[0]['prefix']
assert len(aids) == 2

res = identifiers.get("holder")

aid = res['prefix']
print(aid)
credentials = client.credentials()

creds = credentials.list(filtr={'-a-i': aid})
print(creds)
# print(creds)
assert len(creds) == 1

creder = serdering.SerderACDC(sad=creds[0]['sad'])
Expand Down
2 changes: 1 addition & 1 deletion scripts/multisig-holder.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ def create_admit(client, participant, group, said, recp):
payload=dict(gid=ghab["prefix"]),
embeds=embeds, recipients=recp)

ipex.submitAdmit(ghab['name'], exn=admit, sigs=sigs, atc=end, recp=grant.ked['i'])
ipex.submitAdmit(ghab['name'], exn=admit, sigs=sigs, atc=end, recp=[grant.ked['i']])


def get_aid(client, name):
Expand Down
Loading

0 comments on commit e151291

Please sign in to comment.