nuts-foundation / nuts-node

The reference implementation of the Nuts specification. A decentralized identity network based on the w3c ssi concepts with practical functionality for the healthcare domain.
https://nuts-foundation.gitbook.io
GNU General Public License v3.0
22 stars 14 forks source link

Auth v2: "no matching credentials" results in status 500 #3203

Open reinkrul opened 1 week ago

reinkrul commented 1 week ago

Should probably be 400 Bad Request (or at least a 4xx range code) instead

POST http://localhost:8081/internal/auth/v2/did:web:mutt-classic-actually.ngrok-free.app:iam:c86b0d0d-62a6-49db-8b13-c31d580e3be1/request-service-access-token
Content-Type: application/json

{
  "verifier": "did:web:mutt-classic-actually.ngrok-free.app:iam:c86b0d0d-62a6-49db-8b13-c31d580e3be1",
  "scope": "zorgtoepassing"
}

yields:

HTTP/1.1 500 Internal Server Error
Content-Type: application/problem+json
Date: Fri, 21 Jun 2024 11:08:42 GMT
Content-Length: 92

{
  "detail": "no matching credentials",
  "status": 500,
  "title": "RequestServiceAccessToken failed"
}
woutslakhorst commented 1 week ago

400 - invalid request- no matching credentials

reinkrul commented 1 week ago

?

woutslakhorst commented 1 week ago

I added an answer to your "probably"