Package org.jboss.test.security.interfaces

Examples of org.jboss.test.security.interfaces.CalledSessionHome.create()


      InitialContext jndiContext = new InitialContext();
      Object obj = jndiContext.lookup("spec.CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found spec.CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.CallerBean");
      log.debug("Bean.invokeEcho('testLocalMethodAccess') -> "+bean.invokeEcho("testLocalMethodAccess"));
      bean.remove();
      sc.logout();
   }
View Full Code Here


      InitialContext jndiContext = new InitialContext();
      Object obj = jndiContext.lookup("spec.CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found spec.CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.CallerBean");
      log.debug("Bean.invokeEcho('testLocalMethodAccess') -> "+bean.invokeEcho("testLocalMethodAccess"));
      bean.remove();
      sc.logout();
   }
View Full Code Here

      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      try
      {
         log.debug("Found spec.CallerBean Home");
         home.create();
         fail("home.create Should have failed");
      }
      catch(Exception e)
      {
         log.debug("Got the expected exception",e);
View Full Code Here

      InitialContext jndiContext = new InitialContext();
      Object obj = jndiContext.lookup("spec.CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found spec.CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.CallerBean");
      log.debug("Bean.invokeEcho('testLocalMethodAccess') -> "+bean.invokeEcho("testLocalMethodAccess"));
      bean.remove();
      sc.logout();
   }
View Full Code Here

      InitialContext jndiContext = new InitialContext();
      Object obj = jndiContext.lookup("spec.CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found spec.CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.CallerBean");
      log.debug("Bean.invokeEcho('testLocalMethodAccess') -> "+bean.invokeEcho("testLocalMethodAccess"));
      bean.remove();
      sc.logout();
   }
View Full Code Here

      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      try
      {
         log.debug("Found spec.CallerBean Home");
         home.create();
         fail("home.create Should have failed");
      }
      catch(Exception e)
      {
         log.debug("Got the expected exception",e);
View Full Code Here

      InitialContext ctx = new InitialContext(env);
      Object obj = ctx.lookup("unchecked/MissingMethodBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found CalledSessionHome");
      CalledSession bean = home.create();
      log.debug("Created CalledSession");

      // This should pass due to login role
      bean.invokeEcho("testMissingIsUnchecked");
      // This should pass due to unchecked for missing method-permission
View Full Code Here

      InitialContext ctx = new InitialContext(env);
      Object obj = ctx.lookup("excluded/MissingMethodBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found CalledSessionHome");
      CalledSession bean = home.create();
      log.debug("Created CalledSession");

      // This should pass due to login role
      bean.invokeEcho("testMissingIsExcluded");
      // This should faile due to excluded for missing method-permission
View Full Code Here

      InitialContext jndiContext = new InitialContext();
      Object obj = jndiContext.lookup("spec.CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found spec.CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.CallerBean");
      log.debug("Bean.invokeEcho('testLocalMethodAccess') -> " + bean.invokeEcho("testLocalMethodAccess"));
      bean.remove();
   }
View Full Code Here

      login();
      Object obj = getInitialContext().lookup("spec.Level1CallerBean");
      obj = PortableRemoteObject.narrow(obj, CalledSessionHome.class);
      CalledSessionHome home = (CalledSessionHome) obj;
      log.debug("Found Level1CallerBean Home");
      CalledSession bean = home.create();
      log.debug("Created spec.Level1CallerBean");
      bean.callEcho();
      log.debug("Bean.callEcho() ok");
      bean.remove();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.