Class MutableAuthenticationServiceImpl
- java.lang.Object
-
- org.alfresco.repo.security.authentication.AbstractAuthenticationService
-
- org.alfresco.repo.security.authentication.AuthenticationServiceImpl
-
- org.alfresco.repo.security.authentication.MutableAuthenticationServiceImpl
-
- All Implemented Interfaces:
ActivateableBean,AuthenticationService,MutableAuthenticationService
public class MutableAuthenticationServiceImpl extends AuthenticationServiceImpl implements MutableAuthenticationService
The default implementation ofMutableAuthenticationService.- Author:
- dward
-
-
Field Summary
-
Fields inherited from class org.alfresco.repo.security.authentication.AbstractAuthenticationService
GUEST_AUTHENTICATION_NOT_SUPPORTED
-
-
Constructor Summary
Constructors Constructor Description MutableAuthenticationServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanauthenticationExists(java.lang.String userName)Check if the given authentication exists.voidcreateAuthentication(java.lang.String userName, char[] password)Create an authentication for the given user.voiddeleteAuthentication(java.lang.String userName)Delete an authentication entrybooleangetAuthenticationEnabled(java.lang.String userName)Is an authentication enabled or disabled?booleanisAuthenticationCreationAllowed()Determines whether authentication creation is allowed.booleanisAuthenticationMutable(java.lang.String userName)Determines whether this user's authentication may be mutated via the other methods.voidsetAuthentication(java.lang.String userName, char[] newPassword)Set the login information for a user (typically called by an admin user)voidsetAuthenticationDao(MutableAuthenticationDao authenticationDao)Sets the authentication dao.voidsetAuthenticationEnabled(java.lang.String userName, boolean enabled)Enable or disable an authentication entryvoidupdateAuthentication(java.lang.String userName, char[] oldPassword, char[] newPassword)Update the login information for the user (typically called by the user)-
Methods inherited from class org.alfresco.repo.security.authentication.AuthenticationServiceImpl
authenticate, authenticateAsGuest, clearCurrentSecurityContext, countTickets, getAllowsUserCreation, getAllowsUserDeletion, getAllowsUserPasswordChange, getCurrentTicket, getCurrentUserName, getDefaultAdministratorUserNames, getDefaultGuestUserNames, getDomain, getDomains, getDomainsThatAllowUserCreation, getDomainsThatAllowUserDeletion, getDomiansThatAllowUserPasswordChanges, getNewTicket, getPrevalidationTenantDomain, getProtectedUserKey, getTicketComponents, getUsersWithTickets, guestUserAuthenticationAllowed, invalidateTicket, invalidateTickets, invalidateUserSession, isActive, isCurrentUserTheSystemUser, isProtectionEnabled, isUserProtected, recordFailedAuthentication, setAllowsUserCreation, setAllowsUserDeletion, setAllowsUserPasswordChange, setAuthenticationComponent, setDomain, setPersonService, setProtectedUsersCache, setProtectionEnabled, setProtectionLimit, setProtectionPeriodSeconds, setTicketComponent, validate
-
Methods inherited from class org.alfresco.repo.security.authentication.AbstractAuthenticationService
getAllowedUsers, getMaxUsers, preAuthenticationCheck, setSysAdminParams
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.alfresco.service.cmr.security.AuthenticationService
authenticate, authenticateAsGuest, clearCurrentSecurityContext, getCurrentTicket, getCurrentUserName, getDefaultAdministratorUserNames, getDefaultGuestUserNames, getDomains, getDomainsThatAllowUserCreation, getDomainsThatAllowUserDeletion, getDomiansThatAllowUserPasswordChanges, getNewTicket, guestUserAuthenticationAllowed, invalidateTicket, invalidateUserSession, isCurrentUserTheSystemUser, validate
-
-
-
-
Method Detail
-
setAuthenticationDao
public void setAuthenticationDao(MutableAuthenticationDao authenticationDao)
Sets the authentication dao.- Parameters:
authenticationDao- the authentication dao
-
createAuthentication
public void createAuthentication(java.lang.String userName, char[] password) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from interface:MutableAuthenticationServiceCreate an authentication for the given user.- Specified by:
createAuthenticationin interfaceMutableAuthenticationService- Parameters:
userName- Stringpassword- char[]- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
updateAuthentication
public void updateAuthentication(java.lang.String userName, char[] oldPassword, char[] newPassword) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from interface:MutableAuthenticationServiceUpdate the login information for the user (typically called by the user)- Specified by:
updateAuthenticationin interfaceMutableAuthenticationService- Parameters:
userName- StringoldPassword- char[]newPassword- char[]- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
setAuthentication
public void setAuthentication(java.lang.String userName, char[] newPassword) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from interface:MutableAuthenticationServiceSet the login information for a user (typically called by an admin user)- Specified by:
setAuthenticationin interfaceMutableAuthenticationService- Parameters:
userName- StringnewPassword- char[]- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
deleteAuthentication
public void deleteAuthentication(java.lang.String userName) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from interface:MutableAuthenticationServiceDelete an authentication entry- Specified by:
deleteAuthenticationin interfaceMutableAuthenticationService- Parameters:
userName- String- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
getAuthenticationEnabled
public boolean getAuthenticationEnabled(java.lang.String userName) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from class:AuthenticationServiceImplIs an authentication enabled or disabled?- Specified by:
getAuthenticationEnabledin interfaceAuthenticationService- Overrides:
getAuthenticationEnabledin classAuthenticationServiceImpl- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
setAuthenticationEnabled
public void setAuthenticationEnabled(java.lang.String userName, boolean enabled) throws org.alfresco.repo.security.authentication.AuthenticationExceptionDescription copied from interface:MutableAuthenticationServiceEnable or disable an authentication entry- Specified by:
setAuthenticationEnabledin interfaceMutableAuthenticationService- Parameters:
userName- Stringenabled- boolean- Throws:
org.alfresco.repo.security.authentication.AuthenticationException
-
authenticationExists
public boolean authenticationExists(java.lang.String userName)
Description copied from class:AuthenticationServiceImplCheck if the given authentication exists.- Specified by:
authenticationExistsin interfaceAuthenticationService- Overrides:
authenticationExistsin classAuthenticationServiceImpl- Parameters:
userName- the username- Returns:
- Returns true if the authentication exists
-
isAuthenticationMutable
public boolean isAuthenticationMutable(java.lang.String userName)
Description copied from interface:MutableAuthenticationServiceDetermines whether this user's authentication may be mutated via the other methods.- Specified by:
isAuthenticationMutablein interfaceMutableAuthenticationService- Parameters:
userName- the user ID- Returns:
trueif this user's authentication may be mutated via the other methods.
-
isAuthenticationCreationAllowed
public boolean isAuthenticationCreationAllowed()
Description copied from interface:MutableAuthenticationServiceDetermines whether authentication creation is allowed.- Specified by:
isAuthenticationCreationAllowedin interfaceMutableAuthenticationService- Returns:
trueif authentication creation is allowed
-
-