mirror of
https://github.com/keycloak/keycloak.git
synced 2026-01-10 15:32:05 -03:30
closes: #37944 Signed-off-by: Steve Hawkins <shawkins@redhat.com> (cherry picked from commit 47a750dd05fe96ab4af11e4acdeb32aeff26d37f)
This commit is contained in:
parent
8f37774f5a
commit
d573b407b7
@ -28,7 +28,7 @@ public final class HttpPropertyMappers {
|
||||
private static final String QUARKUS_HTTPS_CERT_KEY_FILES = "quarkus.http.ssl.certificate.key-files";
|
||||
private static final String QUARKUS_HTTPS_KEY_STORE_FILE = "quarkus.http.ssl.certificate.key-store-file";
|
||||
private static final String QUARKUS_HTTPS_TRUST_STORE_FILE = "quarkus.http.ssl.certificate.trust-store-file";
|
||||
private static final String QUARKUS_HTTPS_TRUST_STORE_FILE_TYPE = "quarkus.http.ssl.certificate.trust-store-file-type";
|
||||
public static final String QUARKUS_HTTPS_TRUST_STORE_FILE_TYPE = "quarkus.http.ssl.certificate.trust-store-file-type";
|
||||
private static final String QUARKUS_HTTPS_KEY_STORE_FILE_TYPE = "quarkus.http.ssl.certificate.key-store-file-type";
|
||||
|
||||
private HttpPropertyMappers(){}
|
||||
@ -115,7 +115,6 @@ public final class HttpPropertyMappers {
|
||||
fromOption(HttpOptions.HTTPS_TRUST_STORE_TYPE)
|
||||
.mapFrom(SecurityOptions.FIPS_MODE, HttpPropertyMappers::resolveKeyStoreType)
|
||||
.to(QUARKUS_HTTPS_TRUST_STORE_FILE_TYPE)
|
||||
.transformer(HttpPropertyMappers::resolveKeyStoreType)
|
||||
.paramLabel("type")
|
||||
.build(),
|
||||
fromOption(HttpOptions.HTTP_MAX_QUEUED_REQUESTS)
|
||||
|
||||
@ -46,7 +46,7 @@ import org.junit.Test;
|
||||
import org.keycloak.Config;
|
||||
import org.keycloak.config.CachingOptions;
|
||||
import org.keycloak.quarkus.runtime.configuration.ConfigArgsConfigSource;
|
||||
|
||||
import org.keycloak.quarkus.runtime.configuration.mappers.HttpPropertyMappers;
|
||||
import org.keycloak.quarkus.runtime.Environment;
|
||||
import org.keycloak.quarkus.runtime.vault.FilesKeystoreVaultProviderFactory;
|
||||
import org.keycloak.quarkus.runtime.vault.FilesPlainTextVaultProviderFactory;
|
||||
@ -513,6 +513,15 @@ public class ConfigurationTest extends AbstractConfigurationTest {
|
||||
assertEquals(expected, createConfig().getConfigValue("quarkus.http.ssl.certificate.files").getValue());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testHttpTrustStoreType() {
|
||||
ConfigArgsConfigSource.setCliArgs("--fips-mode=strict");
|
||||
assertEquals("BCFKS", createConfig().getConfigValue(HttpPropertyMappers.QUARKUS_HTTPS_TRUST_STORE_FILE_TYPE).getValue());
|
||||
|
||||
ConfigArgsConfigSource.setCliArgs("--https-trust-store-type=jks");
|
||||
assertEquals("jks", createConfig().getConfigValue(HttpPropertyMappers.QUARKUS_HTTPS_TRUST_STORE_FILE_TYPE).getValue());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testCacheMaxCount() {
|
||||
int maxCount = 500;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user