8 Replies Latest reply on Apr 11, 2008 4:46 PM by Anil Saldanha

    Why do we need a security context to access a local ejb?

    Adrian Brock Master

      With the old SecurityAssociation we didn't need to login to access a local EJB.
      If the ejb was secured, it just failed because of the null principal,
      otherwise the request was allowed.

      21:00:26,618 ERROR [AbstractKernelController] Error installing to Start: name=jboss.test:service=CtsCmpServiceV1 state=Create mode=Manual requiredState=Installed
      java.lang.IllegalStateException: No security context for getPrincipal
       at org.jboss.ejb.plugins.local.BaseLocalProxyFactory$SecurityActions$1.getPrincipal(BaseLocalProxyFactory.java:535)
       at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invokeHome(BaseLocalProxyFactory.java:354)
       at org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:133)
       at $Proxy87.create(Unknown Source)
       at org.jboss.test.cts.service.CtsCmpService.startService(CtsCmpService.java:53)
      


      Try deploying testsuite/output/lib/cts-v1cmp-sar.ear in JBoss5