Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.aspects.security
Class SecurityContext

    java.lang.Object
      org.jboss.aspects.security.SecurityContext

public class SecurityContext
extends Object

Obtain security information based on the current security domain.

Version:
  $Revision: 1.2.2.8 $
Author:
  Bill Burke

Field Summary
`protected static ThreadLocal` | `currentDomain`

Constructor Summary
`SecurityContext()`

Method Summary
`static Principal` | `getCallerPrincipal()` Get the caller's principal
`static Principal` | `getCurrentPrincipal()` Get the current principal.
`static boolean` | `isCallerInRole(String roleName)` Is the caller's security identity within the role Does not include current run-as
`static boolean` | `isCurrentInRole(String roleName)` Checks current identity is within roleName Does include current run-as

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### currentDomain

    protected static ThreadLocal currentDomain

Constructor Detail

### SecurityContext

    public SecurityContext()

Method Detail

### getCallerPrincipal

    public static Principal getCallerPrincipal()

  Get the caller's principal

  Returns:

### getCurrentPrincipal

    public static Principal getCurrentPrincipal()

  Get the current principal. Could be run-as, or propagated

  Returns:

### isCallerInRole

    public static boolean isCallerInRole(String roleName)

  Is the caller's security identity within the role Does not include current run-as

  Parameters:
    `roleName` -
  Returns:

### isCurrentInRole

    public static boolean isCurrentInRole(String roleName)

  Checks current identity is within roleName Does include current run-as

  Parameters:
    `roleName` -
  Returns:

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.