我正在尝试在Spring Boot项目上使用Spring Cloud Vault使用HashiCorp Vault。我将bootstrap.yml文件配置为使用应用角色和机密 ID 来获取密码
引导程序.yml
spring:
application:
name: pres
cloud:
vault:
authentication: APPROLE
app-role:
role-id: ${role-id}
secret-id: ${secret-id}
role: pres-read
app-role-path: approle
uri: https://hostname:8200
kv:
enabled: true
backend: secret
application-name: pres
profiles:
include: dev
在启动过程中,我收到以下异常
org.springframework.vault.authentication.VaultLoginException: Cannot login using org.springframework.web.client.ResourceAccessException: I/O error on POST request for "https://hostname:8200/v1/auth/approle/login": extension (5) should not be presented in certificate_request; nested exception is javax.net.ssl.SSLHandshakeException: extension (5) should not be presented in certificate_request
我正在使用弹簧云启动器保管库配置依赖项来访问保管库
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-vault-config</artifactId>
<version> 2.2.2.RELEASE</version>
</dependency>
好的。看起来这是一个Java TLS错误,希望Java团队能在Java 11.0.8中解决这个问题。
更新:此问题已在最新的 Java 11 版本中修复