public class KerberosUserDirectoryProvider extends Object implements UserDirectoryProvider
KerberosUserDirectoryProvider is a UserDirectoryProvider that authenticates usernames using Kerberos.
For more information on configuration, see the README.txt file
| Modifier and Type | Field and Description |
|---|---|
protected String |
m_domain
Configuration: Domain
|
protected String |
m_knownusermsg
Configuration: KnownUserMsg
|
protected String |
m_logincontext
Configuration: LoginContext
|
protected boolean |
m_requirelocalaccount
Configuration: RequireLocalAccount
|
protected String |
m_servicelogincontext
Configuration: ServiceLoginContext
|
protected String |
m_serviceprincipal
Configuration: ServicePrincipal
|
| Constructor and Description |
|---|
KerberosUserDirectoryProvider() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
authenticateUser(String userId,
UserEdit edit,
String password)
Authenticate a user / password.
|
boolean |
authenticateWithProviderFirst(String id) |
void |
destroy()
Returns to uninitialized state.
|
boolean |
findUserByEmail(UserEdit edit,
String email)
Find a user object who has this email address.
|
boolean |
getUser(UserEdit edit)
Access a user object.
|
void |
getUsers(Collection<UserEdit> users)
Access a collection of UserEdit objects; if the user is found, update the information, otherwise remove the UserEdit object from the collection.
|
void |
init()
Final initialization, once all dependencies are set.
|
void |
setCachettl(int cachettl)
Deprecated.
No longer used. Use standard cache settings instead.
|
void |
setDomain(String domain)
Configuration: Domain Name (for E-Mail Addresses)
|
void |
setKnownUserMsg(String knownusermsg)
Configuration: Kerberos Error Message
|
void |
setLoginContext(String logincontext)
Configuration: Authentication Name
|
void |
setRequireLocalAccount(Boolean requirelocalaccount)
Configuration: Require Local Account
|
void |
setServiceLoginContext(String serviceLoginContext)
Configuration: Service Authentication Name
|
void |
setServicePrincipal(String serviceprincipal)
Configuration: GSSAPI Service Principal
|
protected String m_domain
protected String m_logincontext
protected String m_servicelogincontext
protected String m_serviceprincipal
protected boolean m_requirelocalaccount
protected String m_knownusermsg
public void setDomain(String domain)
domain - The domain in the form of "domain.tld"public void setLoginContext(String logincontext)
logincontext - The context to be used from the login.config file - default "KerberosAuthentication"public void setServiceLoginContext(String serviceLoginContext)
serviceLoginContext - The context for the service to be used from the login.config file - default "ServiceKerberosAuthentication"public void setServicePrincipal(String serviceprincipal)
serviceprincipal - The name of the service principal for GSSAPI. Needs to be set.public void setRequireLocalAccount(Boolean requirelocalaccount)
requirelocalaccount - Determine if a local account is required for user to authenticate - default "true"public void setKnownUserMsg(String knownusermsg)
knownusermsg - Start of error returned for bad logins by known users - default is from RFC 1510public void setCachettl(int cachettl)
cachettl - Time (in milliseconds) to cache authenticated usernamespublic void init()
public void destroy()
public boolean getUser(UserEdit edit)
getUser in interface UserDirectoryProvideredit - The user object (id is set) to fill in.public void getUsers(Collection<UserEdit> users)
getUsers in interface UserDirectoryProviderusers - The UserEdit objects (with id set) to fill in or remove.public boolean findUserByEmail(UserEdit edit, String email)
findUserByEmail in interface UserDirectoryProvideremail - The email address string.public boolean authenticateUser(String userId, UserEdit edit, String password)
authenticateUser in interface UserDirectoryProviderid - The user id.edit - The UserEdit matching the id to be authenticated (and updated) if we have one.password - The password.public boolean authenticateWithProviderFirst(String id)
authenticateWithProviderFirst in interface UserDirectoryProviderCopyright © 2005–2016 University of Michigan. All rights reserved.