SSORealm
| Modifier and Type | Method and Description |
|---|---|
| public Principal | Returns: The authenticated UserPrincipal.The username. username, Object The user credentials, normally a String password. credentials, Request The request to be authenticated. Additional
parameters may be extracted or set on this request as needed
for the authentication mechanism (none required for BASIC and
FORM authentication). request)Authenticate a users credentials. |
| public void | disassociate(Principal
A UserPrincipal allocated from this realm. user)Dissassociate the calling context with a Principal. |
| public String | |
| public Principal | |
| public boolean | Returns: True if the user can act in that role.A role name. role)Check if the user is in a role. |
| public void | |
| public Principal | |
| public Principal | |
| public boolean | Returns: True if this user is still authenticated.Re Authenticate a Principal. |
| authenticate | back to summary |
|---|---|
| public Principal authenticate(String username, Object credentials, Request request) Authenticate a users credentials. Implementations of this method may adorn the calling context to assoicate it with the authenticated principal (eg ThreadLocals). If such context associations are made, they should be considered valid until a UserRealm.deAuthenticate(UserPrincipal) call is made for this UserPrincipal.
| |
| disassociate | back to summary |
|---|---|
| public void disassociate(Principal user) Dissassociate the calling context with a Principal. This method is called when the calling context is not longer associated with the Principal. It should be used by an implementation to remove context associations such as ThreadLocals. The UserPrincipal object remains authenticated, as it may be associated with other contexts.
| |
| getName | back to summary |
|---|---|
| public String getName() | |
| getPrincipal | back to summary |
|---|---|
| public Principal getPrincipal(String username) Get the principal for a username. This method is not guaranteed to return a Principal for non-authenticated users. | |
| isUserInRole | back to summary |
|---|---|
| public boolean isUserInRole(Principal user, String role) Check if the user is in a role.
| |
| logout | back to summary |
|---|---|
| public void logout(Principal user) logout a user Principal. Called by authentication mechanisms (eg FORM) that can detect logout.
| |
| popRole | back to summary |
|---|---|
| public Principal popRole(Principal user) Pop role from a Principal. | |
| pushRole | back to summary |
|---|---|
| public Principal pushRole(Principal user, String role) Push role onto a Principal. This method is used to add a role to an existing principal. | |
| reauthenticate | back to summary |
|---|---|
| public boolean reauthenticate(Principal user) Re Authenticate a Principal. Authenicate a principal that has previously been return from the authenticate method. Implementations of this method may adorn the calling context to assoicate it with the authenticated principal (eg ThreadLocals). If such context associations are made, they should be considered valid until a UserRealm.deAuthenticate(UserPrincipal) call is made for this UserPrincipal.
| |