[jboss-cvs] jbosssx/src/main/org/jboss/security/jndi ...

Chris Griffith cegriff at ufl.edu
Fri Jul 21 15:37:38 EDT 2006


  User: j2ee_junkie
  Date: 06/07/21 15:37:38

  Modified:    src/main/org/jboss/security/jndi  Tag: Branch_4_0
                        LoginInitialContextFactory.java
  Log:
  JBAS-1477: Pass in the security-domain name to the login modules for error reporting
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.6.3   +6 -4      jbosssx/src/main/org/jboss/security/jndi/LoginInitialContextFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginInitialContextFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosssx/src/main/org/jboss/security/jndi/LoginInitialContextFactory.java,v
  retrieving revision 1.4.6.2
  retrieving revision 1.4.6.3
  diff -u -b -r1.4.6.2 -r1.4.6.3
  --- LoginInitialContextFactory.java	29 Oct 2005 05:06:35 -0000	1.4.6.2
  +++ LoginInitialContextFactory.java	21 Jul 2006 19:37:38 -0000	1.4.6.3
  @@ -29,9 +29,11 @@
   import javax.security.auth.login.LoginContext;
   import javax.security.auth.login.LoginException;
   
  -import org.jnp.interfaces.NamingContextFactory;
  +import org.jboss.security.SecurityConstants;
   import org.jboss.security.auth.callback.UsernamePasswordHandler;
   
  +import org.jnp.interfaces.NamingContextFactory;
  +
   /** A naming provider InitialContextFactory implementation that combines the authentication phase
    * with the InitialContext creation. During the getInitialContext callback from the JNDI naming
    * layer a JAAS LoginContext is created using the login configuration name passed in as
  @@ -43,7 +45,7 @@
    * @see javax.naming.spi.InitialContextFactory
    *
    * @author Scott.Stark at jboss.org
  - * @version $Revision: 1.4.6.2 $
  + * @version $Revision: 1.4.6.3 $
    */
   public class LoginInitialContextFactory extends NamingContextFactory
   {
  @@ -56,8 +58,8 @@
      public Context getInitialContext(Hashtable env)
         throws NamingException
      {
  -      // Get the login configuration name to use, defaulting to "other"
  -      String protocol = "other";
  +      // Get the login configuration name to use, initially set to default.
  +      String protocol = SecurityConstants.DEFAULT_APPLICATION_POLICY;
         Object prop = env.get(Context.SECURITY_PROTOCOL);
         if( prop != null )
            protocol = prop.toString();
  
  
  



More information about the jboss-cvs-commits mailing list