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

Errors in VC Issuance with Wallet (SIOP) & VC Presentation #96

Open
anukul-mohil opened this issue Feb 18, 2024 · 1 comment
Open

Errors in VC Issuance with Wallet (SIOP) & VC Presentation #96

anukul-mohil opened this issue Feb 18, 2024 · 1 comment

Comments

@anukul-mohil
Copy link

Overview:

In attempting to use the OID4VC-demo for VC issuance and presentation with the Sphereon wallet, I've hit two major roadblocks:

  • Failure in VC issuance through the wallet("Use your wallet option")
  • Errors in VC presentation for authentication.

Here are details of the two issues.

Issues Encountered:

Issue 1: Error During VC Issuance with Wallet (SIOP) Option

Steps to Reproduce:

Initiated the agent, frontend-vci, and frontend-vp containers as per the provided instructions.
Attempted VC issuance using the "Use your wallet" option on the credential issuer interface.

Expected Behavior:

Smooth integration and interaction between the Sphereon wallet and the OID4VC-demo to issue the VC.

Actual Behavior:

Error seen on Sphereon wallet:
Unable to present credentials: Error: Error 500: {"error": "Could not verify auth status"}.

Error seen on Agent container(oid4vc-demo-ssi-agent):
2024-02-18 17:35:38 Authorization Response (siop-sessions 2024-02-18 17:35:38 { 2024-02-18 17:35:38   "expires_in": "300", 2024-02-18 17:35:38   "state": "034a3a98-89a6-4e66-8cac-166e7c113571", 2024-02-18 17:35:38   "presentation_submission": "{\"id\":\"l5QeJMoMqFTnQCjy5O85g\",\"definition_id\":\"sphereonWalletIdentity\",\"descriptor_map\":[{\"id\":\"ace7aff1-0234-4f35-9d21-251668a60950\",\"format\":\"jwt_vc\",\"path\":\"$.verifiableCredential[0]\"}]}", 2024-02-18 17:35:38   "vp_token": "..." 2024-02-18 17:35:38 } 2024-02-18 17:35:38 Supplied presentation_submission was a string instead of JSON. Correctig, but external party should fix their implementation! 2024-02-18 17:35:38 URI: {"expires_in":"300","state":"034a3a98-89a6-4e66-8cac-166e7c113571","presentation_submission":{"id":"l5QeJMoMqFTnQCjy5O85g","definition_id":"sphereonWalletIdentity","descriptor_map":[{"id":"ace7aff1-0234-4f35-9d21-251668a60950","format":"jwt_vc","path":"$.verifiableCredential[0]"}]},"vp_token":"..."} 2024-02-18 17:35:38 TypeError: Cannot read properties of undefined (reading 'payload') 2024-02-18 17:35:38     at AuthorizationResponse.<anonymous> (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sphereon/did-auth-siop/dist/authorization-response/AuthorizationResponse.js:116:102) 2024-02-18 17:35:38     at Generator.next (<anonymous>) 2024-02-18 17:35:38     at fulfilled (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sphereon/did-auth-siop/dist/authorization-response/AuthorizationResponse.js:5:58) 2024-02-18 17:35:38     at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 2024-02-18 17:35:38 sendErrorResponse (500): Could not verify auth status 2024-02-18 17:35:38 error message: Cannot read properties of undefined (reading 'payload') 2024-02-18 17:35:38 error object: {} 2024-02-18 17:35:38 Original error stack (if any) and REST API error stack: 2024-02-18 17:35:38 TypeError: Cannot read properties of undefined (reading 'payload') 2024-02-18 17:35:38     at AuthorizationResponse.<anonymous> (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sphereon/did-auth-siop/dist/authorization-response/AuthorizationResponse.js:116:102) 2024-02-18 17:35:38     at Generator.next (<anonymous>) 2024-02-18 17:35:38     at fulfilled (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sphereon/did-auth-siop/dist/authorization-response/AuthorizationResponse.js:5:58) 2024-02-18 17:35:38     at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 2024-02-18 17:35:38 Error 2024-02-18 17:35:38     at sendErrorResponse (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]_@[email protected][email protected]/node_modules/@sphereon/ssi-express-support/dist/express-utils.js:23:23) 2024-02-18 17:35:38     at /opt/oid4vc-demo/node_modules/.pnpm/@[email protected][email protected][email protected]_ny4ssxtrad5zz6thktcyxgrcgm/node_modules/@sphereon/ssi-sdk.siopv2-oid4vp-rp-rest-api/dist/siop-api-functions.js:72:64 2024-02-18 17:35:38     at Generator.throw (<anonymous>) 2024-02-18 17:35:38     at rejected (/opt/oid4vc-demo/node_modules/.pnpm/@[email protected][email protected][email protected]_ny4ssxtrad5zz6thktcyxgrcgm/node_modules/@sphereon/ssi-sdk.siopv2-oid4vp-rp-rest-api/dist/siop-api-functions.js:6:65) 2024-02-18 17:35:38     at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 2024-02-18 17:35:38 POST /siop/definitions/sphereonWalletIdentity/auth-responses/4db5e562-1af4-45de-910c-1481b3eb9f43 500 38.958 ms - 40

Issue 2: VC Presentation Demo Compatibility and Error

Steps to Reproduce:

Stored VCs issued from the OID4VC-demo's issuer page (localhost:5001) in the Sphereon wallet.
Attempted to authenticate by presenting a VC at the verifier demo (localhost:5002) through the Sphereon wallet.

Expected Behavior:

On presenting the appropriate VC, the expectation was to authenticate and sign in seamlessly within the demo environment, utilizing the VCs issued by the localhost issuer.

Actual Behavior:

The Sphereon wallet did not list the VCs issued by the localhost issuer as compatible for presentation, leading to a failure in authentication.
Resorting to using a VC issued from "https://ssi.sphereon.com/demo/issuer/#/credentials/select" for presentation, which ideally should not be necessary, resulted in the following error on localhost:5002 webpage:
Uncaught runtime errors: ERROR Cannot read properties of undefined (reading 'payload')     at handleError (http://localhost:5002/static/js/bundle.js:79723:58)     at http://localhost:5002/static/js/bundle.js:79746:7
This unexpected behavior suggests a missing link in the VC compatibility or support within the OID4VC-demo, particularly with the VCs issued by its own issuer demo.

Request for Support:

Facing challenges with VC issuance and presentation in the OID4VC-demo, I'm seeking assistance to resolve these critical issues. Any support or guidance to overcome these hurdles would be greatly appreciated.
Please let me know if you need further details or logs to facilitate troubleshooting.

@anukul-mohil anukul-mohil changed the title Errors in VC Issuance with Wallet (SIOP) & VC Presentation in OID4VC-demo Errors in VC Issuance with Wallet (SIOP) & VC Presentation Feb 18, 2024
@noobookbig
Copy link

Got the same problem
Issue 1: Error During VC Issuance with Wallet (SIOP) Option

I think It cause by SD-JWT was missing when docker build got 404 not found, I have got a log from VP frontend container

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/calculateDigest.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@s [email protected]/node_modules/@sd-jwt/decode/src/disclosures/calculateDigest.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/decodePayload.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd- [email protected]/node_modules/@sd-jwt/decode/src/disclosures/decodePayload.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/fromArray.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd-jwt+ [email protected]/node_modules/@sd-jwt/decode/src/disclosures/fromArray.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/fromString.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd-jwt [email protected]/node_modules/@sd-jwt/decode/src/disclosures/fromString.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/index.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd-jwt+deco [email protected]/node_modules/@sd-jwt/decode/src/disclosures/index.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/disclosures/toArray.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd-jwt+de [email protected]/node_modules/@sd-jwt/decode/src/disclosures/toArray.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/index.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/nod e_modules/@sd-jwt/decode/src/index.ts'

Failed to parse source map from '/opt/oid4vc-demo/node_modules/.pnpm/@[email protected]/node_modules/@sd-jwt/decode/src/jwt/fromCompact.ts' file: Error: ENOENT: no such file or directory, open '/opt/oid4vc-demo/node_modules/.pnpm/@sd-jwt+decode @0.2.0/node_modules/@sd-jwt/decode/src/jwt/fromCompact.ts'

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

2 participants