2 Replies Latest reply on May 9, 2013 3:14 AM by Bond Chan

    Jboss 5 component security subject lookup

    Bond Chan Novice

      Hi,

       

      I have an issue of lookup JNDI "java:comp/env/security/subject" in jboss 5.1.0, which returns null, but works under jboss 4.2.3, by comparing the JNDView I found:

       

      1)for each componet jboss4.2.3 having the jndi java:comp/env/security/subject and which link to jndi java:/jaas/lrs/subject, but no exist in jboss5.1.0

      2)both jboss versions have jndi java:/jaas/lrs/  ---but subject can be looked up using jndi 'java:/jaas/lrs/subject' in jboss5.1.0

       

       

      Did I do some bad thing when upgrade from 4.2.3 to 5.1.0 ?

       

      see the JNDIView :

      ===========================================================

       

       

       

       

       

      JNDIView in jboss4.2.3

      1)


      Ejb Module: f3.jar

       

      java:comp namespace of the FinancialCentreCalendar bean:

       

        +- env (class: org.jnp.interfaces.NamingContext)
        |   +- security (class: org.jnp.interfaces.NamingContext)
        |   |   +- subject[link -> java:/jaas/lrs/subject] (class: javax.naming.LinkRef)
        |   |   +- security-domain[link -> java:/jaas/lrs] (class: javax.naming.LinkRef)

      2)

      java: Namespace

       

        +- ClusteredXAConnectionFactory (class: org.jboss.jms.client.JBossConnectionFactory)
        +- jaas (class: javax.naming.Context)
        |   +- DefaultDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- LoginDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- ServerMasterPassword (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- messaging (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- jmx-console (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- JbossmqDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- lrs (class: org.jboss.security.plugins.SecurityDomainContext)
        |   +- JmsXARealm (class: org.jboss.security.plugins.SecurityDomainContext)

      JNDIView in jboss 5.1.0

      1)

      Ejb 2.1 Module: "f3.jar"

       

      java:comp namespace of the FinancialCalendarService bean:

       

        +- TransactionSynchronizationRegistry[link -> java:TransactionSynchronizationRegistry] (class: javax.naming.LinkRef)
        +- env (class: org.jnp.interfaces.NamingContext)

      2)

      java: Namespace

       

      +- jaas (class: javax.naming.Context)

        |   +- jmx-console (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- ServerMasterPassword (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- messaging (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- lrs (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- DefaultDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- LoginDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- profileservice (class: org.jboss.security.plugins.SecurityDomainContext)

        |   +- JbossmqDSRealm (class: org.jboss.security.plugins.SecurityDomainContext)