Class AbstractSecurityContext
- java.lang.Object
-
- com.sun.enterprise.security.common.AbstractSecurityContext
-
- All Implemented Interfaces:
com.sun.enterprise.security.integration.AppServSecurityContext
,Serializable
- Direct Known Subclasses:
ClientSecurityContext
,SecurityContext
public abstract class AbstractSecurityContext extends Object implements com.sun.enterprise.security.integration.AppServSecurityContext, Serializable
This base class defines the methods that Security Context should exhibit. There are two places where a derived class are used. They are on the appclient side and ejb side. The derived classes can use thread local storage to store the security contexts.- Author:
- Harpreet Singh
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AbstractSecurityContext()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract Principal
getCallerPrincipal()
This method should be implemented by the subclasses to return the caller principal.abstract Subject
getSubject()
This method should be implemented by the subclasses to return the Credentials of the caller principal.
-
-
-
Method Detail
-
getCallerPrincipal
public abstract Principal getCallerPrincipal()
This method should be implemented by the subclasses to return the caller principal. This information may be redundant since the same information can be inferred by inspecting the Credentials of the caller.- Specified by:
getCallerPrincipal
in interfacecom.sun.enterprise.security.integration.AppServSecurityContext
- Returns:
- The caller Principal.
-
getSubject
public abstract Subject getSubject()
This method should be implemented by the subclasses to return the Credentials of the caller principal.- Specified by:
getSubject
in interfacecom.sun.enterprise.security.integration.AppServSecurityContext
- Returns:
- A credentials object associated with the current client invocation.
-
-