diff --git a/src/main/java/org/eclipse/tractusx/managedidentitywallets/service/JwtPresentationES256KService.java b/src/main/java/org/eclipse/tractusx/managedidentitywallets/service/JwtPresentationES256KService.java index 790c7b4fe..7c8e7380c 100644 --- a/src/main/java/org/eclipse/tractusx/managedidentitywallets/service/JwtPresentationES256KService.java +++ b/src/main/java/org/eclipse/tractusx/managedidentitywallets/service/JwtPresentationES256KService.java @@ -177,6 +177,7 @@ public SignedJWT createSignedJwt(URI id, Did didIssuer, String audience, Seriali private static SignedJWT createSignedES256KJwt(ECPrivateKey ecPrivateKey, JWTClaimsSet claimsSet, String issuer) { try { JWSSigner signer = new ECDSASigner(ecPrivateKey); + signer.getJCAContext().setProvider(BouncyCastleProviderSingleton.getInstance()); if (!signer.supportedJWSAlgorithms().contains(JWSAlgorithm.ES256K)) { throw new UnsupportedAlgorithmException(String.format("Invalid signing method. Supported signing methods: %s", signer.supportedJWSAlgorithms().stream().map(Algorithm::getName).collect(Collectors.joining(", "))));