w3c / vc-data-integrity

W3C Data Integrity Specification
https://w3c.github.io/vc-data-integrity/
Other
39 stars 17 forks source link

Fix algorithm misalignments using new cryptosuite interface. #244

Closed msporny closed 4 months ago

msporny commented 5 months ago

This PR updates the "Cryptographic Suite Selection Algorithm" interface that was defined by @jyasskin that MUST be defined by all DI cryptographic suite specifications. PR https://github.com/w3c/vc-di-ecdsa/pull/57 implements the interface on the ECDSA cryptosuite and this PR attempts to align that PR with the DI specification. This PR also fixes some misalignments between the base algorithms and the usage of the suite.

This PR doesn't attempt to align the selective disclosure algorithms, that might happen in a separate PR.


Preview | Diff

iherman commented 5 months ago

The issue was discussed in a meeting on 2024-02-14

View the transcript #### 1.1. Fix algorithm misalignments using new cryptosuite interface. (pr vc-data-integrity#244) _See github pull request [vc-data-integrity#244](https://github.com/w3c/vc-data-integrity/pull/244)._ **Manu Sporny:** processed a number of PRs across VCDM, DI, cryptosuites. need to talk about Jeffery Yaskin's PR (#244) to create an interface for all DI specs. _See github pull request [vc-di-ecdsa#57](https://github.com/w3c/vc-di-ecdsa/pull/57)._ **Manu Sporny:** that broke interfaces b/w DI specs. trying to get them re-aligned. 2 PRs - 1 for DI, 1 for ECDSA-SD. heads up to the group we're trying to align these interfaces. … some misalignment on how they would work. have a plan forward to address this. plan is for an interface in all DI specs that all have 'functions' each cryptosuite executes to create/verify proofs. a standard interface. … the functions to expose was under debate. based on discussion we will only define 2 functions on the interface: create proof and verify proof. … will require changes to algorithms across these specs. pushing more details into the cryptosuite specs. less in DI the spec. should not impact implementations. we know we will go through a 2nd CR. the interfaces are changing, not the algorithms. … are there any concerns/guidance before I start making those changes? > *Dave Longley:* +1 to those changes. **Ivan Herman:** presume that ECDSA then EDDSA and then BBS? **Manu Sporny:** correct. **Michael Jones:** think it takes us down a bad path to build interfaces that no one will build. we should not be creating APIs, that is out of scope. **Manu Sporny:** agree that APIs are out of scope, but that's not what we're creating here. **Michael Jones:** that is what you described. **Manu Sporny:** have discussed this before. we're discussing interfaces, which is what the w3c does, not in web IDL which would define an API. implementations are implementing in this way. they are abstract, not concrete web IDL interfaces. **Michael Jones:** I am missing context. what else are you planning to do? **Manu Sporny:** changing the interfaces that we had months ago, which Jefferey asked for. that PR had weeks of review and already went in. **Brent Zundel:** any other comments? **Manu Sporny:** no - that's the major PR I need feedback on.
msporny commented 5 months ago

Alright @jyasskin, @dlongley, @iherman, @TallTed, I've made another pass at this and attempted to apply each of your concerns... please re-review and let me know if further adjustments are needed.

msporny commented 4 months ago

Normative, multiple reviews, changes requested and made, no objections, merging.