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

feat: adapt to did core spec #430

Merged
merged 1 commit into from
Mar 26, 2021
Merged

feat: adapt to did core spec #430

merged 1 commit into from
Mar 26, 2021

Conversation

mirceanis
Copy link
Member

@mirceanis mirceanis commented Mar 26, 2021

This PR will make veramo compliant to did core spec.
More specifically, it will:

  • support DIDResolutionResult instead of DIDDocument for the did resolve step.
  • add base support for EcdsaSecp256k1VerificationKey2019 ( instead of just Secp256k1VerificationKey2018)
  • add base support for EcdsaSecp256k1RecoveryMethod2020
  • add base support for blockchainAccountId (instead of just ethereumAddress)
  • add base support for DID documents with verificationMethod and assertionMethod

The base support is added by updating the core dependencies: did-resolver@3.1 did-jwt-vc@2.0 did-jwt@5.0 as well as ethr-did-resolver and web-did-resolver

BREAKING CHANGES:

  • IResolver interface adapted to core spec. Returning DIDResolutionResult
  • No more EcdsaSignature for signers, only string output
  • Signers must accept Uint8Array input as well as string
  • Using EcdsaSecp256k1VerificationKey2019 and ...RecoveryMethod2020
  • using verificationMethod and blockchainAccountId from DID documents
  • deprecated UniversalResolver class in favor of getUniversalResolver() method

closes #418
closes #428
closes #417
closes #416
closes #412
closes #397
unblocks #384
fixes #394

BREAKING CHANGES:
* `IResolver` interface adapted to core spec
* No more `EcdsaSignature` for signers, only `string` output
* Signers must accept `Uint8Array` input as well as `string`
* Using EcdsaSecp256k1VerificationKey2019 and ...RecoveryMethod2020
* using `verificationMethod` and `blockchainAccountId` from DID documents
* deprecated `UniversalResolver` class in favor of `getUniversalResolver` method
@codecov
Copy link

codecov bot commented Mar 26, 2021

Codecov Report

Merging #430 (d2fea68) into next (0bf7b24) will decrease coverage by 1.69%.
The diff coverage is 64.00%.

❗ Current head d2fea68 differs from pull request most recent head 5a5f52c. Consider uploading reports for the commit 5a5f52c to get more accurate results

@@            Coverage Diff             @@
##             next     #430      +/-   ##
==========================================
- Coverage   67.58%   65.88%   -1.70%     
==========================================
  Files          62       68       +6     
  Lines        1530     1615      +85     
  Branches      247      264      +17     
==========================================
+ Hits         1034     1064      +30     
- Misses        400      450      +50     
- Partials       96      101       +5     

Copy link
Contributor

@simonas-notcat simonas-notcat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@mirceanis mirceanis merged commit 9712db0 into next Mar 26, 2021
@mirceanis mirceanis deleted the feat/new-did-resolvers branch March 26, 2021 15:36
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

Successfully merging this pull request may close these issues.

Missing credentialSubject.id property in JWT VC
2 participants