com.atlassian.seraph.auth
Interface RoleMapper
- All Superinterfaces:
- Initable
- All Known Implementing Classes:
- GroupRoleMapper
- public interface RoleMapper
- extends Initable
Determines whether an authenticated user has a "role" (permission) within the system, and specifically, whether
they have permission to log in to the system.
In applications using Seraph, role assignment is typically done by checking for membership of certain groups, eg:
- hasRole() implementation will map between group membership (eg. 'administrators' group) and roles (eg. 'delete_user', 'see_admin_pages').
- canLogin() implementation checks for membership of a global "users" group, thus allowing existing users' access to a
site to be revoked by removal from the "users" group.
Method Summary |
boolean |
canLogin(java.security.Principal user,
javax.servlet.http.HttpServletRequest request)
|
boolean |
hasRole(java.security.Principal user,
javax.servlet.http.HttpServletRequest request,
java.lang.String role)
|
Methods inherited from interface com.atlassian.seraph.Initable |
init |
hasRole
public boolean hasRole(java.security.Principal user,
javax.servlet.http.HttpServletRequest request,
java.lang.String role)
canLogin
public boolean canLogin(java.security.Principal user,
javax.servlet.http.HttpServletRequest request)
Copyright © 2008 Atlassian Software Systems Pty Ltd. All Rights Reserved.