public class AuthenticationServiceImpl extends AbstractAuthenticationService implements ActivateableBean
GUEST_AUTHENTICATION_NOT_SUPPORTED| Constructor and Description |
|---|
AuthenticationServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
authenticate(java.lang.String userName,
char[] password)
Carry out an authentication attempt.
|
void |
authenticateAsGuest()
Authenticate as the guest user.
|
boolean |
authenticationExists(java.lang.String userName)
Check if the given authentication exists.
|
void |
clearCurrentSecurityContext()
Remove the current security information
|
int |
countTickets(boolean nonExpiredOnly) |
boolean |
getAllowsUserCreation() |
boolean |
getAllowsUserDeletion() |
boolean |
getAllowsUserPasswordChange() |
boolean |
getAuthenticationEnabled(java.lang.String userName)
Is an authentication enabled or disabled?
|
java.lang.String |
getCurrentTicket()
Get the current ticket as a string
|
java.lang.String |
getCurrentUserName()
Get the name of the currently authenticated user.
|
java.util.Set |
getDefaultAdministratorUserNames()
Gets a set of user names who should be considered 'administrators' by default.
|
java.util.Set |
getDefaultGuestUserNames()
Gets a set of user names who should be considered 'guests' by default.
|
java.lang.String |
getDomain() |
java.util.Set |
getDomains()
Get the domain to which this instance of an authentication service applies.
|
java.util.Set |
getDomainsThatAllowUserCreation()
Does this instance alow user to be created?
|
java.util.Set |
getDomainsThatAllowUserDeletion()
Does this instance allow users to be deleted?
|
java.util.Set |
getDomiansThatAllowUserPasswordChanges()
Does this instance allow users to update their passwords?
|
java.lang.String |
getNewTicket()
Get a new ticket as a string
|
java.util.Set |
getTicketComponents() |
java.util.Set |
getUsersWithTickets(boolean nonExpiredOnly) |
boolean |
guestUserAuthenticationAllowed()
Check if Guest user authentication is allowed.
|
void |
invalidateTicket(java.lang.String ticket)
Invalidate a single ticket by ID
|
int |
invalidateTickets(boolean expiredOnly) |
void |
invalidateUserSession(java.lang.String userName)
Invalidate any tickets held by the user.
|
boolean |
isActive()
Determines whether this bean is active.
|
boolean |
isCurrentUserTheSystemUser()
Is the current user the system user?
|
void |
setAllowsUserCreation(boolean allowsUserCreation) |
void |
setAllowsUserDeletion(boolean allowsUserDeletion) |
void |
setAllowsUserPasswordChange(boolean allowsUserPasswordChange) |
void |
setAuthenticationComponent(AuthenticationComponent authenticationComponent) |
void |
setDomain(java.lang.String domain) |
void |
setTicketComponent(org.alfresco.repo.security.authentication.TicketComponent ticketComponent) |
void |
validate(java.lang.String ticket)
Validate a ticket.
|
getAllowedUsers, getMaxUsers, preAuthenticationCheck, setSysAdminParamspublic void setTicketComponent(org.alfresco.repo.security.authentication.TicketComponent ticketComponent)
public void setAuthenticationComponent(AuthenticationComponent authenticationComponent)
public boolean isActive()
ActivateableBeanisActive in interface ActivateableBeantrue if this bean is activepublic void authenticate(java.lang.String userName,
char[] password)
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServiceauthenticate in interface AuthenticationServiceuserName - the usernamepassword - the passowrdorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic java.lang.String getCurrentUserName()
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServicegetCurrentUserName in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic void invalidateUserSession(java.lang.String userName)
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServiceinvalidateUserSession in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic java.util.Set getUsersWithTickets(boolean nonExpiredOnly)
getUsersWithTickets in class AbstractAuthenticationServicepublic void invalidateTicket(java.lang.String ticket)
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServiceinvalidateTicket in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic int countTickets(boolean nonExpiredOnly)
countTickets in class AbstractAuthenticationServicepublic int invalidateTickets(boolean expiredOnly)
invalidateTickets in class AbstractAuthenticationServicepublic void validate(java.lang.String ticket)
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServicevalidate in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic java.lang.String getCurrentTicket()
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServicegetCurrentTicket in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic java.lang.String getNewTicket()
AuthenticationServicegetNewTicket in interface AuthenticationServicepublic void clearCurrentSecurityContext()
AuthenticationServiceclearCurrentSecurityContext in interface AuthenticationServicepublic boolean isCurrentUserTheSystemUser()
AuthenticationServiceisCurrentUserTheSystemUser in interface AuthenticationServicepublic void authenticateAsGuest()
throws org.alfresco.repo.security.authentication.AuthenticationException
AuthenticationServiceauthenticateAsGuest in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionpublic boolean guestUserAuthenticationAllowed()
AuthenticationServiceguestUserAuthenticationAllowed in interface AuthenticationServicepublic boolean getAllowsUserCreation()
public void setAllowsUserCreation(boolean allowsUserCreation)
public boolean getAllowsUserDeletion()
public void setAllowsUserDeletion(boolean allowsUserDeletion)
public boolean getAllowsUserPasswordChange()
public void setAllowsUserPasswordChange(boolean allowsUserPasswordChange)
public java.lang.String getDomain()
public void setDomain(java.lang.String domain)
public java.util.Set getDomains()
AuthenticationServicegetDomains in interface AuthenticationServicepublic java.util.Set getDomainsThatAllowUserCreation()
AuthenticationServicegetDomainsThatAllowUserCreation in interface AuthenticationServicepublic java.util.Set getDomainsThatAllowUserDeletion()
AuthenticationServicegetDomainsThatAllowUserDeletion in interface AuthenticationServicepublic java.util.Set getDomiansThatAllowUserPasswordChanges()
AuthenticationServicegetDomiansThatAllowUserPasswordChanges in interface AuthenticationServicepublic java.util.Set getTicketComponents()
getTicketComponents in class AbstractAuthenticationServicepublic java.util.Set getDefaultAdministratorUserNames()
getDefaultAdministratorUserNames in interface AuthenticationServicepublic java.util.Set getDefaultGuestUserNames()
getDefaultGuestUserNames in interface AuthenticationServicepublic boolean authenticationExists(java.lang.String userName)
authenticationExists in interface AuthenticationServiceuserName - the usernamepublic boolean getAuthenticationEnabled(java.lang.String userName)
throws org.alfresco.repo.security.authentication.AuthenticationException
getAuthenticationEnabled in interface AuthenticationServiceorg.alfresco.repo.security.authentication.AuthenticationExceptionCopyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.