diff --git a/extensions/common/crypto/jwt-verifiable-credentials/src/main/java/org/eclipse/edc/verifiablecredentials/jwt/JwtPresentationVerifier.java b/extensions/common/crypto/jwt-verifiable-credentials/src/main/java/org/eclipse/edc/verifiablecredentials/jwt/JwtPresentationVerifier.java index 4c8ed9ca720..159198094d3 100644 --- a/extensions/common/crypto/jwt-verifiable-credentials/src/main/java/org/eclipse/edc/verifiablecredentials/jwt/JwtPresentationVerifier.java +++ b/extensions/common/crypto/jwt-verifiable-credentials/src/main/java/org/eclipse/edc/verifiablecredentials/jwt/JwtPresentationVerifier.java @@ -116,15 +116,15 @@ public Result verify(String serializedJwt, VerifierContext context) { if (!map.containsKey(VERIFIABLE_CREDENTIAL_JSON_KEY)) { return Result.failure("Presentation object did not contain mandatory object: " + VERIFIABLE_CREDENTIAL_JSON_KEY); } - var credentialTokens = extractCredentials(map.get(VERIFIABLE_CREDENTIAL_JSON_KEY)); + var rawCredentials = extractCredentials(map.get(VERIFIABLE_CREDENTIAL_JSON_KEY)); - if (credentialTokens.isEmpty()) { + if (rawCredentials.isEmpty()) { // todo: this is allowed by the spec, but it is semantic nonsense. Should we return failure or not? return Result.success(); } // every VC is represented as another JWT, so we verify all of them - for (String token : credentialTokens) { + for (String token : rawCredentials) { verificationResult = verificationResult.merge(context.withAudience(signedJwt.getJWTClaimsSet().getIssuer()).verify(token)); }