0 Replies Latest reply on Mar 17, 2010 7:56 AM by Stefan Henz

    my security domain is not used

    Stefan Henz Newbie



      I've just realized with the help of  TRACE/DEBUG that instead of taking the application policy as defined in  the login-config.xml, namely


      <application-policy name="myWebApp">

                <login-module  code="org.jboss.security.auth.spi.LdapLoginModule">






      when trying to login on my EJB Webapplication,  always the default  configuration by any security domain that does not  have an

      application-policy entry with a matching name as defined  by default in the login-config.xml of JBoss 5.1.0.GA is used. And  because this default  should not be used of course no properties file  for this is defined. Uncommenting or deleting the default configuration  from the login-config.xml does not solve the problem, because my  application-policy for my security domain "myWebApp" is ignored.


      I don't  understand why this happpens. I've believed the security domain  "myWebApp" for the context-root "myWebApp" is correct, but most probably  not. I'll give the content of the according deployment descriptors  below for completness. Maybe somebody sees and knows what might cause  the problem:


      My  web.xml looks like:


      And the web.xml is:

      <?xml version="1.0"   encoding="UTF-8"?>

      <web-app version="2.5"
           xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">




      and  in the jboss-web.xml, I've defined the security domain, namely:


      The  jboss-web.xml has the content:

      <?xml version="1.0"   encoding="UTF-8"?>
      <!DOCTYPE jboss-web PUBLIC
            "-//JBoss//DTD Web Application 5.0//EN"


      and this is  security domain is also specified in the the jboss.xml:

      The  content of the  jboss.xml is:

      <?xml version="1.0"   encoding="UTF-8"?>


      Additional  I'm using also the application.xml deployment descriptor which has the  following content:

      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE  application
         PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE  Application 1.3//EN"

      Maybe somebody has an idea what's going wrong.