Closed oed closed 4 years ago
Well, the encoding of any given CID will depend on the version, so the decoding algorithm would have to be:
It would also be nice to add some motivation around why we're using multicodecs. Specifically, it makes CIDs fully self describing and unambiguous in all contexts where multiformats can be used.
Made a small update to the algorithm which I think should be sufficient.
Not sure how to best go about updating the Decoding algorithm:
Should it just try to match the first bytes with the CID version. I guess we need to account for the possiblity that future CID versions might be larger?
Fixes https://github.com/multiformats/cid/issues/25