Search in sources :

Example 1 with LdapProviderConfig

use of org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapProviderConfig in project jackrabbit-oak by apache.

the class LargeLdapProviderTest method createIDP.

protected LdapIdentityProvider createIDP() {
    providerConfig = new LdapProviderConfig().setName(IDP_NAME).setHostname("127.0.0.1").setPort(LDAP_SERVER.getPort()).setBindDN(USER_DN).setBindPassword(USER_PWD).setGroupMemberAttribute("member");
    providerConfig.getUserConfig().setBaseDN(AbstractServer.EXAMPLE_DN).setObjectClasses("inetOrgPerson");
    providerConfig.getGroupConfig().setBaseDN(AbstractServer.EXAMPLE_DN).setObjectClasses(InternalLdapServer.GROUP_CLASS_ATTR);
    providerConfig.getAdminPoolConfig().setMaxActive(0);
    providerConfig.getUserPoolConfig().setMaxActive(0);
    return new LdapIdentityProvider(providerConfig);
}
Also used : LdapIdentityProvider(org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapIdentityProvider) LdapProviderConfig(org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapProviderConfig)

Example 2 with LdapProviderConfig

use of org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapProviderConfig in project jackrabbit-oak by apache.

the class LdapLoginTestBase method createIDP.

@Override
protected ExternalIdentityProvider createIDP() {
    LdapProviderConfig cfg = new LdapProviderConfig().setName("ldap").setHostname("127.0.0.1").setPort(LDAP_SERVER.getPort()).setBindDN(ServerDNConstants.ADMIN_SYSTEM_DN).setBindPassword(InternalLdapServer.ADMIN_PW).setGroupMemberAttribute(InternalLdapServer.GROUP_MEMBER_ATTR);
    cfg.getUserConfig().setBaseDN(AbstractServer.EXAMPLE_DN).setObjectClasses("inetOrgPerson");
    cfg.getGroupConfig().setBaseDN(AbstractServer.EXAMPLE_DN).setObjectClasses(InternalLdapServer.GROUP_CLASS_ATTR);
    cfg.getAdminPoolConfig().setMaxActive(0);
    cfg.getUserPoolConfig().setMaxActive(0);
    return new LdapIdentityProvider(cfg);
}
Also used : LdapIdentityProvider(org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapIdentityProvider) LdapProviderConfig(org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapProviderConfig)

Aggregations

LdapIdentityProvider (org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapIdentityProvider)2 LdapProviderConfig (org.apache.jackrabbit.oak.security.authentication.ldap.impl.LdapProviderConfig)2