Currently Being Moderated

SimpleServerLoginModule

VERSION 3

Created on: Mar 1, 2004 6:57 PM by nrichards - Last Modified:  Jun 26, 2004 12:49 AM by ariels

SimpleServerLoginModule

 

A simple server login module useful to quick setup of security for testing

purposes. It implements the following simple algorithm:

  • if password is null, authenticate the user and assign an identity of "guest"

      and a role of "guest".

  • else if password is equal to the user name, assign an identity equal to

      the username and both "user" and "guest" roles

  • else authentication fails.

 

 

Example login-config.xml usage:


    <application-policy name="simple">
        <authentication>
            <login-module code="org.jboss.security.auth.spi.SimpleServerLoginModule" 
                          flag="required" ></login-module>
       </authentication>
    </application-policy>

 

Example web.xml usage:


    <security-constraint>
        <web-resource-collection>
            <!-- configure resources to protect here -->
        </web-resource-collection>
        <auth-constraint>
            <role-name>user</role-name> 
        </auth-constraint>
    </security-constraint>

 

Example jboss-web.xml usage:


    <jboss-web>
        <security-domain>java:/jaas/simple</security-domain>
    </jboss-web>

 

 

 

 

   

 

Average User Rating
(0 ratings)




There are no comments on this article

More Like This

  • Retrieving data ...