1 Reply Latest reply on Dec 24, 2002 3:23 AM by Bruno Lowagie

    NullPointerException domainCache

    Bruno Lowagie Newbie

      I posted a problem earlier (security 3.0.1->3.0.4).
      I am already one step in the right direction thanks to Scott,
      but now I have a NullPointerException in the JaasSecurityManager: seems like the domainCache of my SecurityDomain is null.

      2002-12-20 11:28:59,417 INFO [be.ac.rug.security.loginmodules.LdapLoginModule]
      Identity: blowagie
      2002-12-20 11:28:59,417 INFO [be.ac.rug.security.loginmodules.LdapLoginModule] Identity (getRoleSets): blowagie
      2002-12-20 11:28:59,417 ERROR [org.jboss.ejb.plugins.LogInterceptor]
      RuntimeException:
      java.lang.NullPointerException
      at
      org.jboss.security.plugins.JaasSecurityManager.doesUserHaveRole(JaasSecurityManager.java:303)
      at
      org.jboss.ejb.plugins.SecurityInterceptor.checkSecurityAssociation(SecurityInterceptor.java:219)
      at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:94)
      at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:129)
      at org.jboss.ejb.EntityContainer.invokeHome(EntityContainer.java:487)
      at org.jboss.ejb.Container.invoke(Container.java:730)

      When I look in my logfiles, I see:
      2002-12-20 12:15:03,021 INFO [org.jboss.security.plugins.JaasSecurityManagerService] Starting
      2002-12-20 12:15:03,021 DEBUG [org.jboss.security.plugins.JaasSecurityManagerService] securityMgrCtxPath=java:/jaas
      2002-12-20 12:15:03,031 DEBUG [org.jboss.security.plugins.JaasSecurityManagerService] cachePolicyCtxPath=java:/timedCacheFactory
      2002-12-20 12:15:03,031 DEBUG [org.jboss.security.plugins.JaasSecurityManagerService] SecurityProxyFactory=org.jboss.security.SubjectSecurityProxyFactory@49d886
      2002-12-20 12:15:03,031 INFO [org.jboss.security.plugins.JaasSecurityManagerService] Started
      2002-12-20 12:15:03,041 INFO [org.jboss.security.plugins.JaasSecurityDomain.RUGSecurity] Starting
      2002-12-20 12:15:03,041 DEBUG [org.jboss.security.plugins.JaasSecurityDomain.RUGSecurity] Adding com.sun.net.ssl.internal.ssl.Provider
      2002-12-20 12:15:03,421 INFO [org.jboss.security.plugins.JaasSecurityManagerService] Added RUGSecurity, org.jboss.security.plugins.JaasSecurityDomain@69d02b to map
      2002-12-20 12:15:03,542 INFO [org.jboss.security.plugins.JaasSecurityDomain.RUGSecurity] Started

      So I guess the domainCache should be instantiated...
      What am I doing wrong?