From 5aca5d76670440991cdfbd0a79cd4f35a65c9f44 Mon Sep 17 00:00:00 2001 From: mineme0110 Date: Wed, 20 Nov 2024 15:24:31 +0000 Subject: [PATCH] fix: update the jwt to have shortform of prosm did Signed-off-by: mineme0110 --- .../identus/pollux/core/service/CredentialServiceImpl.scala | 2 +- .../src/test/kotlin/steps/proofs/JwtProofSteps.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pollux/core/src/main/scala/org/hyperledger/identus/pollux/core/service/CredentialServiceImpl.scala b/pollux/core/src/main/scala/org/hyperledger/identus/pollux/core/service/CredentialServiceImpl.scala index 8fdcc7cd57..257fc3b604 100644 --- a/pollux/core/src/main/scala/org/hyperledger/identus/pollux/core/service/CredentialServiceImpl.scala +++ b/pollux/core/src/main/scala/org/hyperledger/identus/pollux/core/service/CredentialServiceImpl.scala @@ -1205,7 +1205,7 @@ class CredentialServiceImpl( maybeId = None, `type` = Set("VerifiableCredential"), // TODO: This information should come from Schema registry by record.schemaId - issuer = CredentialIssuer(jwtIssuer.did.toString, `type` = "Profile"), + issuer = CredentialIssuer(issuingDID.did.toString, `type` = "Profile"), issuanceDate = issuanceDate, maybeExpirationDate = record.validityPeriod.map(sec => issuanceDate.plusSeconds(sec.toLong)), maybeCredentialSchema = record.schemaUris.map(ids => diff --git a/tests/integration-tests/src/test/kotlin/steps/proofs/JwtProofSteps.kt b/tests/integration-tests/src/test/kotlin/steps/proofs/JwtProofSteps.kt index 7e70708b41..89a43232c1 100644 --- a/tests/integration-tests/src/test/kotlin/steps/proofs/JwtProofSteps.kt +++ b/tests/integration-tests/src/test/kotlin/steps/proofs/JwtProofSteps.kt @@ -36,7 +36,7 @@ class JwtProofSteps { @When("{actor} sends a request for jwt proof from trustedIssuer {actor} using {} schema presentation to {actor}") fun verifierSendsARequestForJwtProofPresentationToHolderUsingSchemaFromTrustedIssuer(verifier: Actor, issuer: Actor, schema: CredentialSchema, holder: Actor) { val verifierConnectionToHolder = verifier.recall("connection-with-${holder.name}").connectionId - val trustIssuer = issuer.recall("longFormDid") + val trustIssuer = issuer.recall("shortFormDid") val baseUrl = issuer.recall("baseUrl") val schemaGuid = issuer.recall(schema.name)!! val schemaId = "$baseUrl/schema-registry/schemas/$schemaGuid"