| java.lang.Object com.pentaho.security.SecurityUtils
SecurityUtils | public class SecurityUtils (Code) | | A utility class with several static methods that are used to
either bind the Authentication to the IPentahoSession, retrieve
the Authentication from the IPentahoSession, and other various helper
functions.
author: mbatchel |
DefaultAnonymousRole | public static String DefaultAnonymousRole(Code) | | |
DefaultAnonymousUser | public static String DefaultAnonymousUser(Code) | | |
SESSION_PRINCIPAL | final public static String SESSION_PRINCIPAL(Code) | | |
canHaveACLS | public static boolean canHaveACLS(RepositoryFile aFile)(Code) | | Parameters: aFile - a boolean that indicates if this file can have ACLS placed on it. |
getAuthentication | public static Authentication getAuthentication(IPentahoSession session, boolean allowAnonymous)(Code) | | Looks in the provided session to get the ACEGI Authentication object out.
Optionally returns an "anonymous" Authentication if desired.
Parameters: session - Users' IPentahoSession object Parameters: allowAnonymous - If true, will return an anonymous Authentication object. the Authentication object from the session |
getPrincipal | public static Principal getPrincipal(IPentahoSession session)(Code) | | Gets the java.security.principal object from the IPentahoSession object
Parameters: session - The users' session The bound Principal |
hasAccess | public static boolean hasAccess(RepositoryFile aFile, int actionOperation, IPentahoSession session)(Code) | | Utility method for access negotiation. For performance, not all files will
be checked against the supplied voter.
Parameters: aFile - Parameters: actionOperation - Parameters: session - |
isGranted | public static boolean isGranted(IPentahoSession session, GrantedAuthority role)(Code) | | Utility method that communicates with the installed ACLVoter to determine
whether a particular role is granted to the specified user.
Parameters: session - The users' IPentahoSession Parameters: role - The role to look for true if the user is granted the specified role. |
isPentahoAdministrator | public static boolean isPentahoAdministrator(IPentahoSession session)(Code) | | Utility method that communicates with the installed ACLVoter to determine
administrator status
Parameters: session - The users IPentahoSession object true if the user is considered a Pentaho administrator |
setPrincipal | public static void setPrincipal(Principal principal, IPentahoSession session)(Code) | | Sets the java.security.principal object into the IPentahoSession object.
Parameters: principal - The principal from the servlet context Parameters: session - The users' IPentahoSession object |
|
|