0 Replies Latest reply on Nov 12, 2007 6:02 AM by manuel.martin

    Seam 2.0.0.GA and JAAS integration

    manuel.martin

      Hello,

      First of all, sorry for my english. Is not my first language :/

      I'm trying to integrate a Seam application with my custom JAAS Login Module of JBossAS 4.2.2.GA.

      I add the Login Module to JBoss login-config.xml:

      <application-policy name="webLogin">
       <authentication>
       <login-module ...>
       ...
       </login-module>
       </authentication>
      </application-policy>
      


      Then I add the restrictions in web.xml:

      <security-constraint>
      ...
      </security-constraint>
      
      <login-config>
       <auth-method>BASIC</auth-method>
       <realm-name>webLogin</ream-name>
      </login-config>
      
      ...
      


      And set the Login Module in jboss-web.xml:
      <jboss-web>
       <security-domain>java:jaas/webLogin</security-domain>
      </jboss-web>
      


      As I saw in reference documentation I add the security component in components.xml:
      <security:identity jaas-config-name="webLogin" />
      


      When I access to the application the container ask to me for a user and password, and seems to validate them correctly, but when I try to add web restrictions as s:hasRole('admin') the restriction doesn't work.

      I try to write the identity in the page #{identity.username} but allways username is blank.

      I don't know if I have something wrong in my configuration but I'm a bit dessesperate.

      Thanks in advance!