|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.security.authentication.AbstractAuthenticationService
org.alfresco.repo.security.authentication.AbstractChainingAuthenticationService
public abstract class AbstractChainingAuthenticationService
A base class for chaining authentication services. Where appropriate, methods will 'chain' across multiple
AuthenticationService
instances, as returned by AbstractChainingAuthenticationService.getUsableAuthenticationServices()
.
Constructor Summary | |
---|---|
AbstractChainingAuthenticationService()
Instantiates a new abstract chaining authentication service. |
Method Summary | |
---|---|
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)
|
void |
createAuthentication(java.lang.String userName,
char[] password)
Create an authentication for the given user. |
void |
deleteAuthentication(java.lang.String userName)
Delete an authentication entry |
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.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? |
abstract MutableAuthenticationService |
getMutableAuthenticationService()
Gets the mutable authentication service. |
java.lang.String |
getNewTicket()
Get a new ticket as a string |
java.util.Set |
getTicketComponents()
|
protected abstract java.util.List |
getUsableAuthenticationServices()
Gets the authentication services across which methods will chain. |
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 nonExpiredOnly)
|
void |
invalidateUserSession(java.lang.String userName)
Invalidate any tickets held by the user. |
boolean |
isAuthenticationCreationAllowed()
Determines whether authentication creation is allowed. |
boolean |
isAuthenticationMutable(java.lang.String userName)
Determines whether this user's authentication may be mutated via the other methods. |
boolean |
isCurrentUserTheSystemUser()
Is the current user the system user? |
void |
setAuthentication(java.lang.String userName,
char[] newPassword)
Set the login information for a user (typically called by an admin user) |
void |
setAuthenticationEnabled(java.lang.String userName,
boolean enabled)
Enable or disable an authentication entry |
void |
updateAuthentication(java.lang.String userName,
char[] oldPassword,
char[] newPassword)
Update the login information for the user (typically called by the user) |
void |
validate(java.lang.String ticket)
Validate a ticket. |
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 |
Constructor Detail |
---|
public AbstractChainingAuthenticationService()
Method Detail |
---|
public abstract MutableAuthenticationService getMutableAuthenticationService()
protected abstract java.util.List getUsableAuthenticationServices()
public void createAuthentication(java.lang.String userName, char[] password) throws org.alfresco.repo.security.authentication.AuthenticationException
MutableAuthenticationService
createAuthentication
in interface MutableAuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void updateAuthentication(java.lang.String userName, char[] oldPassword, char[] newPassword) throws org.alfresco.repo.security.authentication.AuthenticationException
MutableAuthenticationService
updateAuthentication
in interface MutableAuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void setAuthentication(java.lang.String userName, char[] newPassword) throws org.alfresco.repo.security.authentication.AuthenticationException
setAuthentication
in interface MutableAuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void deleteAuthentication(java.lang.String userName) throws org.alfresco.repo.security.authentication.AuthenticationException
deleteAuthentication
in interface MutableAuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void setAuthenticationEnabled(java.lang.String userName, boolean enabled) throws org.alfresco.repo.security.authentication.AuthenticationException
setAuthenticationEnabled
in interface MutableAuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public boolean isAuthenticationMutable(java.lang.String userName)
isAuthenticationMutable
in interface MutableAuthenticationService
userName
- the user ID
true
if this user's authentication may be mutated via the other methods.public boolean isAuthenticationCreationAllowed()
isAuthenticationCreationAllowed
in interface MutableAuthenticationService
true
if authentication creation is allowedpublic boolean getAuthenticationEnabled(java.lang.String userName) throws org.alfresco.repo.security.authentication.AuthenticationException
getAuthenticationEnabled
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void authenticate(java.lang.String userName, char[] password) throws org.alfresco.repo.security.authentication.AuthenticationException
authenticate
in interface AuthenticationService
userName
- the usernamepassword
- the passowrd
org.alfresco.repo.security.authentication.AuthenticationException
public void authenticateAsGuest() throws org.alfresco.repo.security.authentication.AuthenticationException
authenticateAsGuest
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public boolean guestUserAuthenticationAllowed()
guestUserAuthenticationAllowed
in interface AuthenticationService
public boolean authenticationExists(java.lang.String userName)
authenticationExists
in interface AuthenticationService
userName
- the username
public java.lang.String getCurrentUserName() throws org.alfresco.repo.security.authentication.AuthenticationException
getCurrentUserName
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void invalidateUserSession(java.lang.String userName) throws org.alfresco.repo.security.authentication.AuthenticationException
invalidateUserSession
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void invalidateTicket(java.lang.String ticket) throws org.alfresco.repo.security.authentication.AuthenticationException
invalidateTicket
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public void validate(java.lang.String ticket) throws org.alfresco.repo.security.authentication.AuthenticationException
validate
in interface AuthenticationService
org.alfresco.repo.security.authentication.AuthenticationException
public java.lang.String getCurrentTicket()
getCurrentTicket
in interface AuthenticationService
public java.lang.String getNewTicket()
getNewTicket
in interface AuthenticationService
public void clearCurrentSecurityContext()
clearCurrentSecurityContext
in interface AuthenticationService
public boolean isCurrentUserTheSystemUser()
isCurrentUserTheSystemUser
in interface AuthenticationService
public java.util.Set getDomains()
getDomains
in interface AuthenticationService
public java.util.Set getDomainsThatAllowUserCreation()
getDomainsThatAllowUserCreation
in interface AuthenticationService
public java.util.Set getDomainsThatAllowUserDeletion()
getDomainsThatAllowUserDeletion
in interface AuthenticationService
public java.util.Set getDomiansThatAllowUserPasswordChanges()
getDomiansThatAllowUserPasswordChanges
in interface AuthenticationService
public java.util.Set getUsersWithTickets(boolean nonExpiredOnly)
getUsersWithTickets
in class AbstractAuthenticationService
public int countTickets(boolean nonExpiredOnly)
countTickets
in class AbstractAuthenticationService
public int invalidateTickets(boolean nonExpiredOnly)
invalidateTickets
in class AbstractAuthenticationService
public java.util.Set getTicketComponents()
getTicketComponents
in class AbstractAuthenticationService
public java.util.Set getDefaultAdministratorUserNames()
getDefaultAdministratorUserNames
in interface AuthenticationService
public java.util.Set getDefaultGuestUserNames()
getDefaultGuestUserNames
in interface AuthenticationService
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |