eclipse-edc / eclipse-edc/Connector

Status list credential deserialization problem

Open
#5,039 2 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
424
Forks
300
Avg merge
12h 19m
Merged PRs (30d)
37

Description

# Bug Report

## Describe the Bug

I am running into a problem with how the status list credential is being deserialized. I am referring to the following line:
https://github.com/eclipse-edc/Connector/blob/3dc011dc4b4b64f1b3f0719dd1d9386b208a1006/extensions/common/iam/verifiable-credentials/src/main/java/org/eclipse/edc/iam/verifiablecredentials/revocation/BaseRevocationListService.java#L173

In my case, the credential response is of media type `application/vc+jwt` and as such it is trying to deserialize a raw VC token jwt into a `BitstringStatusListCredential` which fails.

### Expected Behavior
Correct parsing of the status list credential

### Observed Behavior
I receive a `com.fasterxml.jackson.core.JsonParseException`:

`com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'eyJraWQiOiJkaWQ6d2ViOmF1dGhvcml0eSNhdXRob3JpdHkta2V5IiwiYWxnIjoiRWQyNTUxOSJ9': was expecting (JSON String, Number, Array, Object or token 'null', 'true' or 'false')
at [Source: REDACTED (`StreamReadFeature.INCLUDE_SOURCE_IN_LOCATION` disabled); line: 1, column: 78]`

## Steps to Reproduce

## Context Information
EDC 0.14.0-SNAPSHOT

## Detailed Description

## Possible Implementation

I am assuming something like:
https://github.com/eclipse-edc/Connector/blob/3dc011dc4b4b64f1b3f0719dd1d9386b208a1006/extensions/common/iam/identity-trust/identity-trust-core/src/main/java/org/eclipse/edc/iam/identitytrust/core/defaults/DefaultCredentialServiceClient.java#L133C60-L142

should be done instead.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.