Skip to content
This repository has been archived by the owner on Nov 22, 2024. It is now read-only.

Commit

Permalink
TODO around submit claim
Browse files Browse the repository at this point in the history
Signed-off-by: John Andersen <[email protected]>
  • Loading branch information
pdxjohnny committed Oct 18, 2023
1 parent 9ba8bca commit 0219237
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions scitt_emulator/federation_activitypub_bovine.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,15 +276,26 @@ async def handle(
cose_path.write_bytes(claim)
service_parameters_path = Path(tempdir, "service_parameters")
service_parameters_path.write_bytes(service_parameters)
print(service_parameters)

clazz = TREE_ALGS[treeAlgorithm]
service = clazz(service_parameters_path=service_parameters_path)
service.verify_receipt(cose_path, receipt_path)

logger.info("Receipt verified")

# TODO Submit to own SCITT
return
# TODO Announce that this entry ID was created via
# federation to avoid an infinate loop
scitt_emulator.client.submit_claim(
home_scitt_url,
claim,
str(Path(tempdir, "home_receipt").resolve()),
str(Path(tempdir, "home_entry_id").resolve()),
scitt_emulator.client.HttpClient(
home_scitt_token,
home_scitt_cacert,
),
)
except Exception as ex:
logger.error(ex)
logger.exception(ex)
Expand Down

0 comments on commit 0219237

Please sign in to comment.