Package ome.security.auth
Class LdapConfig
- java.lang.Object
-
- ome.security.auth.LdapConfig
-
public class LdapConfig extends java.lang.Object
Static methods for dealing with LDAP (DN) and the "password" table.- Since:
- 3.0-Beta3
- See Also:
SecuritySystem
,LdapImpl
-
-
Constructor Summary
Constructors Constructor Description LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String)
settingsyncOnLogin
to false andbase
tonull
.LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String)
settingbase
tonull
.LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin, java.lang.String base)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String, String)
settingnewUserGroupOwner
tonull
.LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin, java.lang.String base, java.lang.String newUserGroupOwner)
Base constructor which stores allparse(String)
and stores all values for later lookup.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getGroupAttribute(java.lang.String key)
org.springframework.ldap.filter.Filter
getGroupFilter()
java.lang.String
getNewUserGroup()
java.lang.String
getNewUserGroupOwner()
java.lang.String
getUserAttribute(java.lang.String key)
org.springframework.ldap.filter.Filter
getUserFilter()
org.springframework.ldap.filter.Filter
groupnameFilter(java.lang.String groupname)
boolean
isEnabled()
boolean
isSyncOnLogin()
protected java.util.Map<java.lang.String,java.lang.String>
parse(java.lang.String mapping)
org.springframework.ldap.core.DistinguishedName
relativeDN(java.lang.String fullDNString)
Calculate the relative DN based on the current base.org.springframework.ldap.filter.Filter
usernameFilter(java.lang.String username)
-
-
-
Constructor Detail
-
LdapConfig
public LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String)
settingsyncOnLogin
to false andbase
tonull
.
-
LdapConfig
public LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String)
settingbase
tonull
.
-
LdapConfig
public LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin, java.lang.String base)
AsLdapConfig(boolean, String, String, String, String, String, boolean, String, String)
settingnewUserGroupOwner
tonull
.
-
LdapConfig
public LdapConfig(boolean enabled, java.lang.String newUserGroup, java.lang.String userFilter, java.lang.String groupFilter, java.lang.String userMapping, java.lang.String groupMapping, boolean syncOnLogin, java.lang.String base, java.lang.String newUserGroupOwner)
Base constructor which stores allparse(String)
and stores all values for later lookup.
-
-
Method Detail
-
usernameFilter
public org.springframework.ldap.filter.Filter usernameFilter(java.lang.String username)
-
groupnameFilter
public org.springframework.ldap.filter.Filter groupnameFilter(java.lang.String groupname)
-
relativeDN
public org.springframework.ldap.core.DistinguishedName relativeDN(java.lang.String fullDNString)
Calculate the relative DN based on the current base. For example, if the base is "ou=example" and the fullDNString is "cn=myuser,ou=example", then the returned DN will be "cn=myuser". Note: if constructor argumentbase
wasnull
then this will throw an exception.- Parameters:
fullDNString
- the full distinguished name, notnull
- Returns:
- the corresponding relative distinguished name, not
null
-
isEnabled
public boolean isEnabled()
-
isSyncOnLogin
public boolean isSyncOnLogin()
-
getNewUserGroup
public java.lang.String getNewUserGroup()
-
getNewUserGroupOwner
public java.lang.String getNewUserGroupOwner()
-
getUserFilter
public org.springframework.ldap.filter.Filter getUserFilter()
-
getGroupFilter
public org.springframework.ldap.filter.Filter getGroupFilter()
-
getUserAttribute
public java.lang.String getUserAttribute(java.lang.String key)
-
getGroupAttribute
public java.lang.String getGroupAttribute(java.lang.String key)
-
parse
protected java.util.Map<java.lang.String,java.lang.String> parse(java.lang.String mapping)
-
-