0 Replies Latest reply on Mar 23, 2009 5:19 AM by rhodan76

    SecurityClient && random Principal == null

    rhodan76

      Hello,

      we used the SecurityClient approach to connect from an remote Client to an Jboss5 server.

      SecurityClient client = SecurityClientFactory.getSecurityClient();
      client.setSimple("anil", "mypass");
      client.login();
      


      Our Principal initially gets correctly authorized on server side, but randomly from time to time the ejbContext.getCallerPrincipal returned only "null".

      Just to let somebody with same problem know:
      client.setVmwideAssociation(true);


      fixed this problem. I don't really know why this behavior is, but it seems for me that the jaas context on client side per default is only bound to one thread, so that calls from other threads are not autenticated.

      The only thread i found discussing this was this one http://www.jboss.org/index.html?module=bb&op=viewtopic&t=138047

      Can somebody confirm my thesis ?