User: starksm 
  Date: 01/05/10 10:43:47

  Modified:    src/main/org/jboss/test/web/ejb StatelessSessionBean.java
  Log:
  Update the secured tests and add a DebugServlet
  
  Revision  Changes    Path
  1.2       +2 -6      
jbosstest/src/main/org/jboss/test/web/ejb/StatelessSessionBean.java
  
  Index: StatelessSessionBean.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/web/ejb/StatelessSessionBean.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- StatelessSessionBean.java 2001/05/05 20:59:35     1.1
  +++ StatelessSessionBean.java 2001/05/10 17:43:47     1.2
  @@ -11,7 +11,7 @@
   /** A simple session bean for testing declarative security.
   
   @author [EMAIL PROTECTED]
  -@version $Revision: 1.1 $
  +@version $Revision: 1.2 $
   */
   public class StatelessSessionBean implements SessionBean
   {
  @@ -47,11 +47,7 @@
           System.out.println("StatelessSessionBean.echo, arg="+arg);
           Principal p = sessionContext.getCallerPrincipal();
           System.out.println("StatelessSessionBean.echo, callerPrincipal="+p);
  -        boolean isCaller = sessionContext.isCallerInRole("EchoCaller");
  -        System.out.println("StatelessSessionBean.echo, 
isCallerInRole('EchoCaller')="+isCaller);
  -        if( isCaller == false )
  -            throw new SecurityException("Caller does not have EchoCaller role");
  -        return arg;
  +        return p.getName();
       }
       public void noop(ReferenceTest test, boolean optimized)
       {
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to