mirror of
https://github.com/OpenBankProject/OBP-API.git
synced 2026-02-06 15:47:01 +00:00
refactor/Enable mTLS for Redis, use p12 instead of jks
This commit is contained in:
parent
b4f3404482
commit
b79ea1cbbd
@ -168,11 +168,13 @@ jwt.use.ssl=false
|
||||
|
||||
## Enable mTLS for Redis, if set to true must set paths for the keystore and truststore locations
|
||||
# redis.use.ssl=false
|
||||
# Client
|
||||
# keystore.path.redis = client-keystore.p12
|
||||
## Client
|
||||
## PKCS#12 Format: combine private keys and certificates into .p12 files for easier transport
|
||||
# keystore.path.redis = path/to/client-keystore.p12
|
||||
# keystore.password.redis = keystore-password
|
||||
# Server
|
||||
# truststore.path.redis = path/to/ca.jks
|
||||
## Trust stores is a list of trusted CA certificates
|
||||
## Public certificate for the CA (used by clients and servers to validate signatures)
|
||||
# truststore.path.redis = path/to/ca.p12
|
||||
# truststore.password.redis = truststore-password
|
||||
|
||||
|
||||
|
||||
@ -56,7 +56,7 @@ object Redis extends MdcLoggable {
|
||||
private def configureSslContext(): SSLContext = {
|
||||
|
||||
// Load the CA certificate
|
||||
val trustStore = KeyStore.getInstance("JKS")
|
||||
val trustStore = KeyStore.getInstance("PKCS12")
|
||||
val trustStorePassword = APIUtil.getPropsValue("keystore.password.redis")
|
||||
.getOrElse(APIUtil.initPasswd).toCharArray
|
||||
val truststorePath = APIUtil.getPropsValue("truststore.path.redis").getOrElse("")
|
||||
|
||||
Loading…
Reference in New Issue
Block a user