org.apache.openejb.test.servlet
Class SecureEJB

java.lang.Object
  extended by org.apache.openejb.test.servlet.SecureEJB
All Implemented Interfaces:
SecureEJBLocal

@DeclareRoles(value={"user","manager","UNKNOWN","runas"})
public class SecureEJB
extends Object
implements SecureEJBLocal


Constructor Summary
SecureEJB()
           
 
Method Summary
 void allowManagerMethod()
           
 void allowRunasMethod()
           
 void allowUnknownMethod()
           
 void allowUserMethod()
           
 void denyAllMethod()
           
 Principal getCallerPrincipal()
           
 boolean isCallerInRole(String role)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SecureEJB

public SecureEJB()
Method Detail

getCallerPrincipal

public Principal getCallerPrincipal()
Specified by:
getCallerPrincipal in interface SecureEJBLocal

isCallerInRole

public boolean isCallerInRole(String role)
Specified by:
isCallerInRole in interface SecureEJBLocal

allowUserMethod

@RolesAllowed(value="user")
public void allowUserMethod()
Specified by:
allowUserMethod in interface SecureEJBLocal

allowManagerMethod

@RolesAllowed(value="manager")
public void allowManagerMethod()
Specified by:
allowManagerMethod in interface SecureEJBLocal

allowUnknownMethod

@RolesAllowed(value="UNKNOWN")
public void allowUnknownMethod()
Specified by:
allowUnknownMethod in interface SecureEJBLocal

allowRunasMethod

@RolesAllowed(value="runas")
public void allowRunasMethod()
Specified by:
allowRunasMethod in interface SecureEJBLocal

denyAllMethod

@DenyAll
public void denyAllMethod()
Specified by:
denyAllMethod in interface SecureEJBLocal

toString

public String toString()
Overrides:
toString in class Object


Copyright © 1999-2013 The Apache OpenEJB development community. All Rights Reserved.