From bd9374826d7acbd0d77d15cd2a81098e643eb6fa Mon Sep 17 00:00:00 2001 From: Severin Stampler Date: Wed, 4 Oct 2023 17:16:43 +0200 Subject: [PATCH] test: test issuer portal request without client_id parameter --- src/jvmTest/kotlin/id/walt/oid4vc/CI_JVM_Test.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/jvmTest/kotlin/id/walt/oid4vc/CI_JVM_Test.kt b/src/jvmTest/kotlin/id/walt/oid4vc/CI_JVM_Test.kt index 0f95998..038f8fd 100644 --- a/src/jvmTest/kotlin/id/walt/oid4vc/CI_JVM_Test.kt +++ b/src/jvmTest/kotlin/id/walt/oid4vc/CI_JVM_Test.kt @@ -728,7 +728,7 @@ class CI_JVM_Test : AnnotationSpec() { Auditor.getService().verify(credential, listOf(SignaturePolicy())).result shouldBe true } - val issuerPortalRequest = "openid-credential-offer://issuer.portal.walt.id/?credential_offer=%7B%22credential_issuer%22%3A%22https%3A%2F%2Fissuer.portal.walt.id%22%2C%22credentials%22%3A%5B%7B%22format%22%3A%22jwt_vc_json%22%2C%22types%22%3A%5B%22VerifiableCredential%22%2C%22OpenBadgeCredential%22%5D%2C%22credential_definition%22%3A%7B%22%40context%22%3A%5B%22https%3A%2F%2Fwww.w3.org%2F2018%2Fcredentials%2Fv1%22%2C%22https%3A%2F%2Fw3c-ccg.github.io%2Fvc-ed%2Fplugfest-1-2022%2Fjff-vc-edu-plugfest-1-context.json%22%2C%22https%3A%2F%2Fw3id.org%2Fsecurity%2Fsuites%2Fed25519-2020%2Fv1%22%5D%2C%22types%22%3A%5B%22VerifiableCredential%22%2C%22OpenBadgeCredential%22%5D%7D%7D%5D%2C%22grants%22%3A%7B%22authorization_code%22%3A%7B%22issuer_state%22%3A%22d8fbdcb1-ab37-4dc3-9154-a20ba15e7204%22%7D%2C%22urn%3Aietf%3Aparams%3Aoauth%3Agrant-type%3Apre-authorized_code%22%3A%7B%22pre-authorized_code%22%3A%22eyJhbGciOiJFZERTQSJ9.eyJzdWIiOiJkOGZiZGNiMS1hYjM3LTRkYzMtOTE1NC1hMjBiYTE1ZTcyMDQiLCJpc3MiOiJodHRwczovL2lzc3Vlci5wb3J0YWwud2FsdC5pZCIsImF1ZCI6IlRPS0VOIn0.uZD72h__1uO4nHjQbsPW7JnyKxSRyIECMIuW3RfXRjQFprlj30-F5MnPLEgX48GxL4EyVif8sZ9D40AGLwdfBg%22%2C%22user_pin_required%22%3Afalse%7D%7D%7D" + val issuerPortalRequest = "openid-credential-offer://issuer.portal.walt.id/?credential_offer=%7B%22credential_issuer%22%3A%22https%3A%2F%2Fissuer.portal.walt.id%22%2C%22credentials%22%3A%5B%7B%22format%22%3A%22jwt_vc_json%22%2C%22types%22%3A%5B%22VerifiableCredential%22%2C%22OpenBadgeCredential%22%5D%2C%22credential_definition%22%3A%7B%22%40context%22%3A%5B%22https%3A%2F%2Fwww.w3.org%2F2018%2Fcredentials%2Fv1%22%2C%22https%3A%2F%2Fw3c-ccg.github.io%2Fvc-ed%2Fplugfest-1-2022%2Fjff-vc-edu-plugfest-1-context.json%22%2C%22https%3A%2F%2Fw3id.org%2Fsecurity%2Fsuites%2Fed25519-2020%2Fv1%22%5D%2C%22types%22%3A%5B%22VerifiableCredential%22%2C%22OpenBadgeCredential%22%5D%7D%7D%5D%2C%22grants%22%3A%7B%22authorization_code%22%3A%7B%22issuer_state%22%3A%22c7228046-1a8e-4e27-a7b1-cd6479e1455f%22%7D%2C%22urn%3Aietf%3Aparams%3Aoauth%3Agrant-type%3Apre-authorized_code%22%3A%7B%22pre-authorized_code%22%3A%22eyJhbGciOiJFZERTQSJ9.eyJzdWIiOiJjNzIyODA0Ni0xYThlLTRlMjctYTdiMS1jZDY0NzllMTQ1NWYiLCJpc3MiOiJodHRwczovL2lzc3Vlci5wb3J0YWwud2FsdC5pZCIsImF1ZCI6IlRPS0VOIn0.On2_7P4vr5caTHKbWv2i0a604HQ-FaiuVZHH9kzEKK7mOdVHtNHoAZADpDJtowNCkhMQxruLbnqB7WvRQzufCg%22%2C%22user_pin_required%22%3Afalse%7D%7D%7D" //@Test suspend fun testIssuerPortalRequest() { @@ -749,7 +749,7 @@ class CI_JVM_Test : AnnotationSpec() { // make token request var tokenReq = TokenRequest( grantType = GrantType.pre_authorized_code, - clientId = testCIClientConfig.clientID, + //clientId = testCIClientConfig.clientID, redirectUri = credentialWallet.config.redirectUri, preAuthorizedCode = credOfferReq.credentialOffer!!.grants[GrantType.pre_authorized_code.value]!!.preAuthorizedCode, userPin = null