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

Support CIDs as proofs #32

Open
matheus23 opened this issue Dec 13, 2021 · 0 comments
Open

Support CIDs as proofs #32

matheus23 opened this issue Dec 13, 2021 · 0 comments

Comments

@matheus23
Copy link
Member

The spec allows to use CIDs as proofs:

You can substitute [encoded proofs] for CIDs of the proofs as long as the proof is reachable over IPFS.

I'd like to support this without having to pull in a js-ipfs dependency. Esp. because ipfs node setup is highly dependent on the use case. Plus, we don't want to force everyone using ts-ucan to run js-ipfs in their frontends.

So, instead I'd pull in multiformats to be able to parse CIDs (we already have multibase in our dependencies anyway). On top of that, we can just require a function load: (cid: CID) => Promise<string> and we should be fine.

As a second step we can think of providing ways to construct CID-backed UCAN chains.

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

No branches or pull requests

1 participant