I have a Spring Cloud based service.
It has in its application.yml the option
spring:
security:
oauth2:
client:
provider:
blitz-provider:
authorization-uri: https://111.111.111.11:8443/blitz/oauth/te
which tells him to request a Blitz service (security provider)
org.springframework.web.reactive.function.client.WebClientRequestException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at org.springframework.web.reactive.function.client.ExchangeFunctions$DefaultExchangeFunction.lambda$wrapException$9(ExchangeFunctions.java:136) ~[spring-webflux-6.1.5.jar:6.1.5]
Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException:
Error has been observed at the following site(s):
*__checkpoint ⇢ Request to POST https://111.111.111.11:8443/blitz/oauth/te [DefaultWebClient]
…
I visited the website of Blitz and exported its certificate (which is invalid by the way)
It is a PEM-file.
Would it make sense to use this certificate in communication assuming I import it in JKS store and add corresponding settings to application.yml or not? Or is it a better workaround?