|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ApplicationSecurityManager
This interface defines the operations required of an Application Security Manager for
the RCP framework. The security manager is responsible for handling login and logout
requests, interacting with the AuthenticationManager
that
will perform the actual user authentication, and firing the events associated with
application security lifecycle. See ClientSecurityEvent
and its subclasses.
The Security Manager is available as an application service via
org.springframework.richclient.application.ApplicationServices#getSecurityManager
.
See SecurityAwareConfigurer
for more details on how to configure components for
automatic notification of security events.
DefaultApplicationSecurityManager
,
AuthenticationAware
,
LoginAware
,
SecurityAwareConfigurer
Method Summary | |
---|---|
org.acegisecurity.Authentication |
doLogin(org.acegisecurity.Authentication authentication)
Process a login attempt and fire all related events. |
org.acegisecurity.Authentication |
doLogout()
Perform a logout. |
org.acegisecurity.Authentication |
getAuthentication()
Get the authentication token for the currently logged in user. |
org.acegisecurity.AuthenticationManager |
getAuthenticationManager()
Get the authentication manager in use. |
boolean |
isUserInRole(String role)
Determine if the currently authenticated user has the role provided. |
boolean |
isUserLoggedIn()
Return if a user is currently logged in, meaning that a previous call to doLogin resulted in a valid authentication request. |
void |
setAuthenticationManager(org.acegisecurity.AuthenticationManager authenticationManager)
Set the authentication manager to use. |
Method Detail |
---|
org.acegisecurity.Authentication doLogin(org.acegisecurity.Authentication authentication) throws org.acegisecurity.AcegiSecurityException
AuthenticationFailedEvent
is published and the exception is
rethrown. If the authentication succeeds, then an AuthenticationEvent
is
published, followed by a LoginEvent
.
authentication
- token to use for the login attempt
AuthenticationManager.authenticate(org.acegisecurity.Authentication)
.
org.acegisecurity.AcegiSecurityException
- If the authentication attempt failsboolean isUserLoggedIn()
org.acegisecurity.Authentication getAuthentication()
boolean isUserInRole(String role)
role
- to check
org.acegisecurity.Authentication doLogout()
AuthenticationEvent
followed by a LogoutEvent
.
void setAuthenticationManager(org.acegisecurity.AuthenticationManager authenticationManager)
authenticationManager
- instance to use for authentication requestsorg.acegisecurity.AuthenticationManager getAuthenticationManager()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |