Fix setting openldap realm ssl config
This change fixes the setup of the SSL configuration for the test openldap realm. The configuration was missing the realm identifier so the SSL settings being used were just the default JDK ones that do not trust the certificate of the idp fixture. See #37591
This commit is contained in:
parent
fc1c47649a
commit
642e45e9e6
|
@ -51,7 +51,7 @@ public class OpenLdapUserSearchSessionFactoryTests extends ESTestCase {
|
|||
private static final String LDAPCACERT_PATH = "/ca.crt";
|
||||
|
||||
@Before
|
||||
public void init() throws Exception {
|
||||
public void init() {
|
||||
Path caPath = getDataPath(LDAPCACERT_PATH);
|
||||
/*
|
||||
* Prior to each test we reinitialize the socket factory with a new SSLService so that we get a new SSLContext.
|
||||
|
@ -60,7 +60,7 @@ public class OpenLdapUserSearchSessionFactoryTests extends ESTestCase {
|
|||
*/
|
||||
globalSettings = Settings.builder()
|
||||
.put("path.home", createTempDir())
|
||||
.put("xpack.security.authc.realms.ldap.ssl.certificate_authorities", caPath)
|
||||
.put("xpack.security.authc.realms.ldap.oldap-test.ssl.certificate_authorities", caPath)
|
||||
.build();
|
||||
threadPool = new TestThreadPool("LdapUserSearchSessionFactoryTests");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue