spruceid / didkit

A cross-platform toolkit for decentralized identity.
https://www.spruceid.dev/didkit/didkit
Apache License 2.0
274 stars 76 forks source link

Key expansion failed when issuing presentation using ldp proof format #346

Closed kenshin171 closed 1 year ago

kenshin171 commented 1 year ago

I have a verifiable credential that when I do a DIDKit.issuePresentation will get an exception with message Key expansion failed, but when i change the proof format to jwt i can successfully issue the presentation. Is there something wrong with my cerifiable credential? I am creating the verifiable presentation according to the test exampe here, just that the verifiable credential is from my backend. For this case the verifiable credential is signed using did:web key with ED25519 keys.

And one more request/question, can DIDkit allow signing of bbs+ signed verifiable credential? It seems to error out when issue presentation using a verifiable credential signed with bbs+ signatures.

My holder did is did:key format using ED25119 keys btw.

sbihel commented 1 year ago

That error means that one of the fields in your credential/presentation is not defined in the context. You can, for example, do the following:

      "@context": [
        "https://www.w3.org/2018/credentials/v1",
        {
          "@protected": true,
          "MyField": "myscheme:MyField",
        }
      ]

For bbs+, I will reply in #345.