shiro-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jha...@apache.org
Subject svn commit: r749191 - in /incubator/jsecurity/import/trunk: src/org/jsecurity/authc/pam/ src/org/jsecurity/mgt/ test/org/jsecurity/authc/pam/
Date Mon, 02 Mar 2009 05:25:19 GMT
Author: jhaile
Date: Mon Mar  2 05:25:18 2009
New Revision: 749191

URL: http://svn.apache.org/viewvc?rev=749191&view=rev
Log:
Renamed ModularAuthenticationStrategy to AuthenticationStrategy and shortened subclass names
for JSEC-7.

Added:
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulStrategy.java
      - copied, changed from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulStrategy.java
      - copied, changed from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AuthenticationStrategy.java
      - copied, changed from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulStrategy.java
      - copied, changed from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulStrategyTest.java
      - copied, changed from r749156, incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategyTest.java
Removed:
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategyTest.java
Modified:
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AbstractAuthenticationStrategy.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularRealmAuthenticator.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/UnsupportedTokenException.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/package-info.java
    incubator/jsecurity/import/trunk/src/org/jsecurity/mgt/AuthenticatingSecurityManager.java

Modified: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AbstractAuthenticationStrategy.java
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AbstractAuthenticationStrategy.java?rev=749191&r1=749190&r2=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AbstractAuthenticationStrategy.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AbstractAuthenticationStrategy.java
Mon Mar  2 05:25:18 2009
@@ -24,14 +24,14 @@
 import java.util.Collection;
 
 /**
- * Abstract base implementation for JSecurity's concrete <code>ModularAuthenticationStrategy</code>
+ * Abstract base implementation for JSecurity's concrete <code>AuthenticationStrategy</code>
  * implementations.
  *
  * @author Jeremy Haile
  * @author Les Hazlewood
  * @since 0.9
  */
-public abstract class AbstractAuthenticationStrategy implements ModularAuthenticationStrategy
{
+public abstract class AbstractAuthenticationStrategy implements AuthenticationStrategy {
 
     /**
      * Simply returns <code>new {@link SimpleAuthenticationInfo SimpleAuthenticationInfo}();</code>,
which supports

Copied: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulStrategy.java
(from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategy.java)
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulStrategy.java?p2=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulStrategy.java&p1=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategy.java&r1=749156&r2=749191&rev=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategy.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AllSuccessfulStrategy.java
Mon Mar  2 05:25:18 2009
@@ -27,7 +27,7 @@
 import org.jsecurity.realm.Realm;
 
 /**
- * <tt>ModularAuthenticationStrategy</tt> implementation that requires <em>all</em>
configured realms to
+ * <tt>AuthenticationStrategy</tt> implementation that requires <em>all</em>
configured realms to
  * <b>successfully</b> process the submitted <tt>AuthenticationToken</tt>
during the log-in attempt.
  *
  * <p>If one or more realms do not support the submitted token, or one or more are
unable to acquire
@@ -37,10 +37,10 @@
  * @author Les Hazlewood
  * @since 0.2
  */
-public class AllSuccessfulModularAuthenticationStrategy extends AbstractAuthenticationStrategy
{
+public class AllSuccessfulStrategy extends AbstractAuthenticationStrategy {
 
     /** Private class log instance. */
-    private static final Log log = LogFactory.getLog(AllSuccessfulModularAuthenticationStrategy.class);
+    private static final Log log = LogFactory.getLog(AllSuccessfulStrategy.class);
 
     /**
      * Because all realms in this strategy must complete successfully, this implementation
ensures that the given

Copied: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulStrategy.java
(from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulModularAuthenticationStrategy.java)
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulStrategy.java?p2=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulStrategy.java&p1=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulModularAuthenticationStrategy.java&r1=749156&r2=749191&rev=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulModularAuthenticationStrategy.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AtLeastOneSuccessfulStrategy.java
Mon Mar  2 05:25:18 2009
@@ -23,7 +23,7 @@
 import org.jsecurity.authc.AuthenticationToken;
 
 /**
- * <tt>ModularAuthenticationStrategy</tt> implementation that requires <em>at
least one</em> configured realm to
+ * <tt>AuthenticationStrategy</tt> implementation that requires <em>at
least one</em> configured realm to
  * successfully process the submitted <tt>AuthenticationToken</tt> during the
log-in attempt.
  *
  * <p>This means any number of configured realms do not have to support the submitted
log-in token, or they may
@@ -33,13 +33,13 @@
  * <p>Note that this implementation will aggregate the account data from <em>all</em>
successfully consulted
  * realms during the authentication attempt. If you want only the account data from the first
successfully
  * consulted realm and want to ignore all subsequent realms, use the
- * {@link FirstSuccessfulAuthenticationStrategy FirstSuccessfulAuthenticationStrategy} instead.
+ * {@link FirstSuccessfulStrategy FirstSuccessfulAuthenticationStrategy} instead.
  *
  * @author Les Hazlewood
- * @see FirstSuccessfulAuthenticationStrategy FirstSuccessfulAuthenticationStrategy
+ * @see FirstSuccessfulStrategy FirstSuccessfulAuthenticationStrategy
  * @since 0.2
  */
-public class AtLeastOneSuccessfulModularAuthenticationStrategy extends AbstractAuthenticationStrategy
{
+public class AtLeastOneSuccessfulStrategy extends AbstractAuthenticationStrategy {
 
     /**
      * Ensures that the <code>aggregate</code> method argument is not <code>null</code>
and

Copied: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AuthenticationStrategy.java
(from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularAuthenticationStrategy.java)
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AuthenticationStrategy.java?p2=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AuthenticationStrategy.java&p1=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularAuthenticationStrategy.java&r1=749156&r2=749191&rev=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularAuthenticationStrategy.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/AuthenticationStrategy.java
Mon Mar  2 05:25:18 2009
@@ -26,7 +26,7 @@
 import java.util.Collection;
 
 /**
- * A <tt>ModularAuthenticationStrategy</tt> implementation assists the {@link
ModularRealmAuthenticator} during the
+ * A <tt>AuthenticationStrategy</tt> implementation assists the {@link ModularRealmAuthenticator}
during the
  * log-in process in a pluggable realm (PAM) environment.
  *
  * <p>The <tt>ModularRealmAuthenticator</tt> will consult implementations
of this interface on what to do during each
@@ -34,12 +34,12 @@
  * attempt must be successful for all realms, only 1 or more realms, no realms, etc.
  *
  * @author Les Hazlewood
- * @see org.jsecurity.authc.pam.AllSuccessfulModularAuthenticationStrategy AllSuccessfulModularAuthenticationStrategy
- * @see org.jsecurity.authc.pam.AtLeastOneSuccessfulModularAuthenticationStrategy AtLeastOneSuccessfulModularAuthenticationStrategy
- * @see org.jsecurity.authc.pam.FirstSuccessfulAuthenticationStrategy FirstSuccessfulAuthenticationStrategy
+ * @see AllSuccessfulStrategy AllSuccessfulAuthenticationStrategy
+ * @see AtLeastOneSuccessfulStrategy AtLeastOneSuccessfulAuthenticationStrategy
+ * @see FirstSuccessfulStrategy FirstSuccessfulAuthenticationStrategy
  * @since 0.2
  */
-public interface ModularAuthenticationStrategy {
+public interface AuthenticationStrategy {
 
     /**
      * Method invoked by the ModularAuthenticator signifying that the authentication process
is about to begin for the

Copied: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulStrategy.java
(from r749156, incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulAuthenticationStrategy.java)
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulStrategy.java?p2=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulStrategy.java&p1=incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulAuthenticationStrategy.java&r1=749156&r2=749191&rev=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulAuthenticationStrategy.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/FirstSuccessfulStrategy.java
Mon Mar  2 05:25:18 2009
@@ -26,17 +26,17 @@
 import java.util.Collection;
 
 /**
- * {@link ModularAuthenticationStrategy} implementation that only accepts the account data
from
+ * {@link AuthenticationStrategy} implementation that only accepts the account data from
  * the first successfully consulted Realm and ignores all subsequent realms.  This is slightly
  * different behavior than
- * {@link org.jsecurity.authc.pam.AtLeastOneSuccessfulModularAuthenticationStrategy AtLeastOneSuccessfulModularAuthenticationStrategy},
+ * {@link AtLeastOneSuccessfulStrategy AtLeastOneSuccessfulAuthenticationStrategy},
  * so please review both to see which one meets your needs better.
  *
  * @author Les Hazlewood
- * @see org.jsecurity.authc.pam.AtLeastOneSuccessfulModularAuthenticationStrategy AtLeastOneSuccessfulModularAuthenticationStrategy
+ * @see AtLeastOneSuccessfulStrategy AtLeastOneSuccessfulAuthenticationStrategy
  * @since 0.9
  */
-public class FirstSuccessfulAuthenticationStrategy extends AbstractAuthenticationStrategy
{
+public class FirstSuccessfulStrategy extends AbstractAuthenticationStrategy {
 
     /**
      * Returns <code>null</code> immediately, relying on this class's {@link
#merge merge} implementation to return

Modified: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularRealmAuthenticator.java
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularRealmAuthenticator.java?rev=749191&r1=749190&r2=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularRealmAuthenticator.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/ModularRealmAuthenticator.java
Mon Mar  2 05:25:18 2009
@@ -46,7 +46,7 @@
  * authenticator allows customized behavior for interpreting what happens when interacting
with multiple realms - for
  * example, you might require all realms to be successful during the attempt, or perhaps
only at least one must be
  * successful, or some other interpretation.  This customized behavior can be performed via
the use of a
- * {@link #setModularAuthenticationStrategy(ModularAuthenticationStrategy) ModularAuthenticationStrategy},
which
+ * {@link #setAuthenticationStrategy(AuthenticationStrategy) AuthenticationStrategy}, which
  * you can inject as a property of this class.
  *
  * <p>The strategy object provides callback methods that allow you to
@@ -54,13 +54,13 @@
  * in a mult-realm scenario, the strategy object is only utilized when more than one Realm
is configured.
  *
  * <p>For greater security in a multi-realm configuration, unless overridden, the default
implementation is the
- * {@link AllSuccessfulModularAuthenticationStrategy AllSuccessfulModularAuthenticationStrategy}
+ * {@link AllSuccessfulStrategy AllSuccessfulAuthenticationStrategy}
  *
  * @author Jeremy Haile
  * @author Les Hazlewood
  * @see #setRealms
- * @see AllSuccessfulModularAuthenticationStrategy
- * @see AtLeastOneSuccessfulModularAuthenticationStrategy
+ * @see AllSuccessfulStrategy
+ * @see AtLeastOneSuccessfulStrategy
  * @since 0.1
  */
 public class ModularRealmAuthenticator extends AbstractAuthenticator {
@@ -81,27 +81,27 @@
     /**
      * The authentication strategy to use during authentication attempts.
      */
-    private ModularAuthenticationStrategy modularAuthenticationStrategy;
+    private AuthenticationStrategy authenticationStrategy;
 
     /*--------------------------------------------
     |         C O N S T R U C T O R S           |
     ============================================*/
     /**
      * Default no-argument constructor which
-     * {@link #setModularAuthenticationStrategy(ModularAuthenticationStrategy) enables} 
a
-     * {@link org.jsecurity.authc.pam.AllSuccessfulModularAuthenticationStrategy AllSuccessfulModularAuthenticationStrategy}
+     * {@link #setAuthenticationStrategy(AuthenticationStrategy) enables}  a
+     * {@link AllSuccessfulStrategy AllSuccessfulAuthenticationStrategy}
      * by default.
      */
     public ModularRealmAuthenticator() {
-        ModularAuthenticationStrategy strategy = new AllSuccessfulModularAuthenticationStrategy();
-        setModularAuthenticationStrategy(strategy);
+        AuthenticationStrategy strategy = new AllSuccessfulStrategy();
+        setAuthenticationStrategy(strategy);
     }
 
     /**
      * Constructor which initializes this <code>Authenticator</code> with a single
realm to use during
      * an authentiation attempt.  Because
-     * this would set a single realm, no {@link #setModularAuthenticationStrategy(ModularAuthenticationStrategy)
-     * modularAuthenticationStrategy} would be used during authentication attempts.
+     * this would set a single realm, no {@link #setAuthenticationStrategy(AuthenticationStrategy)
+     * AuthenticationStrategy} would be used during authentication attempts.
      * @param realm the realm to consult during an authentication attempt.
      */
     public ModularRealmAuthenticator(Realm realm) {
@@ -112,7 +112,7 @@
      * Constructor which initializes this <code>Authenticator</code> with multiple
realms that will be
      * consulted during an authentication attempt, effectively enabling PAM (Pluggable Authentication
Module)
      * behavior according to the configured
-     * {@link #setModularAuthenticationStrategy(ModularAuthenticationStrategy) ModularAuthenticationStrategy}.
+     * {@link #setAuthenticationStrategy(AuthenticationStrategy) AuthenticationStrategy}.
      * @param realms the realms to consult during an authentication attempt.
      */
     public ModularRealmAuthenticator(List<Realm> realms) {
@@ -152,29 +152,29 @@
     }
 
     /**
-     * Returns the <tt>ModularAuthenticationStrategy</tt> utilized by this modular
authenticator during a multi-realm
+     * Returns the <tt>AuthenticationStrategy</tt> utilized by this modular authenticator
during a multi-realm
      * log-in attempt.  This object is only used when two or more Realms are configured.
      *
      * <p>Unless overridden by
-     * the {@link #setModularAuthenticationStrategy(ModularAuthenticationStrategy)} method,
the default implementation
-     * is the {@link AllSuccessfulModularAuthenticationStrategy}.
+     * the {@link #setAuthenticationStrategy(AuthenticationStrategy)} method, the default
implementation
+     * is the {@link AllSuccessfulStrategy}.
      *
-     * @return the <tt>ModularAuthenticationStrategy</tt> utilized by this modular
authenticator during a log-in attempt.
+     * @return the <tt>AuthenticationStrategy</tt> utilized by this modular authenticator
during a log-in attempt.
      * @since 0.2
      */
-    public ModularAuthenticationStrategy getModularAuthenticationStrategy() {
-        return modularAuthenticationStrategy;
+    public AuthenticationStrategy getAuthenticationStrategy() {
+        return authenticationStrategy;
     }
 
     /**
-     * Allows overriding the default <tt>ModularAuthenticationStrategy</tt> utilized
during multi-realm log-in attempts.
+     * Allows overriding the default <tt>AuthenticationStrategy</tt> utilized
during multi-realm log-in attempts.
      * This object is only used when two or more Realms are configured.
      *
-     * @param modularAuthenticationStrategy the strategy implementation to use during log-in
attempts.
+     * @param authenticationStrategy the strategy implementation to use during log-in attempts.
      * @since 0.2
      */
-    public void setModularAuthenticationStrategy(ModularAuthenticationStrategy modularAuthenticationStrategy)
{
-        this.modularAuthenticationStrategy = modularAuthenticationStrategy;
+    public void setAuthenticationStrategy(AuthenticationStrategy authenticationStrategy)
{
+        this.authenticationStrategy = authenticationStrategy;
     }
 
     /*--------------------------------------------
@@ -220,7 +220,7 @@
     }
 
     /**
-     * Performs the multi-realm authentication attempt by calling back to a {@link ModularAuthenticationStrategy}
object
+     * Performs the multi-realm authentication attempt by calling back to a {@link AuthenticationStrategy}
object
      * as each realm is consulted for <tt>AuthenticationInfo</tt> for the specified
<tt>token</tt>.
      *
      * @param realms the multiple realms configured on this Authenticator instance.
@@ -230,7 +230,7 @@
      */
     protected AuthenticationInfo doMultiRealmAuthentication(Collection<Realm> realms,
AuthenticationToken token) {
 
-        ModularAuthenticationStrategy strategy = getModularAuthenticationStrategy();
+        AuthenticationStrategy strategy = getAuthenticationStrategy();
 
         AuthenticationInfo aggregate = strategy.beforeAllAttempts(realms, token);
 

Modified: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/UnsupportedTokenException.java
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/UnsupportedTokenException.java?rev=749191&r1=749190&r2=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/UnsupportedTokenException.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/UnsupportedTokenException.java
Mon Mar  2 05:25:18 2009
@@ -26,7 +26,7 @@
  * supported by one or more configured {@link org.jsecurity.realm.Realm Realm}s.
  *
  * @author Les Hazlewood
- * @see ModularAuthenticationStrategy
+ * @see AuthenticationStrategy
  * @since 0.2
  */
 public class UnsupportedTokenException extends AuthenticationException {

Modified: incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/package-info.java
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/package-info.java?rev=749191&r1=749190&r2=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/package-info.java (original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/authc/pam/package-info.java Mon Mar
 2 05:25:18 2009
@@ -27,6 +27,6 @@
  * <p/>
  * How the <code>ModularRealmAuthenticator</code> actually coordinates this behavior
is configurable based on your
  * application's needs using an injectible
- * {@link org.jsecurity.authc.pam.ModularAuthenticationStrategy ModularAuthenticationStrategy}.
+ * {@link AuthenticationStrategy}.
  */
 package org.jsecurity.authc.pam;
\ No newline at end of file

Modified: incubator/jsecurity/import/trunk/src/org/jsecurity/mgt/AuthenticatingSecurityManager.java
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/src/org/jsecurity/mgt/AuthenticatingSecurityManager.java?rev=749191&r1=749190&r2=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/src/org/jsecurity/mgt/AuthenticatingSecurityManager.java
(original)
+++ incubator/jsecurity/import/trunk/src/org/jsecurity/mgt/AuthenticatingSecurityManager.java
Mon Mar  2 05:25:18 2009
@@ -19,7 +19,7 @@
 package org.jsecurity.mgt;
 
 import org.jsecurity.authc.*;
-import org.jsecurity.authc.pam.ModularAuthenticationStrategy;
+import org.jsecurity.authc.pam.AuthenticationStrategy;
 import org.jsecurity.authc.pam.ModularRealmAuthenticator;
 import org.jsecurity.realm.Realm;
 import org.jsecurity.util.LifecycleUtils;
@@ -87,20 +87,20 @@
     }
 
     /**
-     * Sets the {@link org.jsecurity.authc.pam.ModularAuthenticationStrategy ModularAuthenticationStrategy}
to use
+     * Sets the {@link org.jsecurity.authc.pam.AuthenticationStrategy} to use
      * in multi-realm environments.
      *
-     * @param strategy the <code>ModularAuthenticationStrategy</code> to use
in multi-realm environments.
+     * @param strategy the <code>AuthenticationStrategy</code> to use in multi-realm
environments.
      */
-    public void setModularAuthenticationStrategy(ModularAuthenticationStrategy strategy)
{
+    public void setAuthenticationStrategy(AuthenticationStrategy strategy) {
         if (!(this.authenticator instanceof ModularRealmAuthenticator)) {
-            String msg = "Configuring a ModularAuthenticationStrategy is only applicable
when the underlying " +
+            String msg = "Configuring a AuthenticationStrategy is only applicable when the
underlying " +
                     "Authenticator implementation is a " + ModularRealmAuthenticator.class.getName()
+
                     " implementation.  This SecurityManager has been configured with an Authenticator
of type " +
                     this.authenticator.getClass().getName();
             throw new IllegalStateException(msg);
         }
-        ((ModularRealmAuthenticator) this.authenticator).setModularAuthenticationStrategy(strategy);
+        ((ModularRealmAuthenticator) this.authenticator).setAuthenticationStrategy(strategy);
     }
 
     /**
@@ -128,7 +128,7 @@
     public void setAuthenticationListeners(Collection<AuthenticationListener> listeners)
{
         assertAuthenticatorListenerSupport();
         if (!(this.authenticator instanceof AuthenticationListenerRegistrar)) {
-            String msg = "Configuring a ModularAuthenticationStrategy is only applicable
when the underlying " +
+            String msg = "Configuring a AuthenticationStrategy is only applicable when the
underlying " +
                     "Authenticator implementation is a " + AuthenticationListenerRegistrar.class.getName()
+
                     " implementation.  This SecurityManager has been configured with an Authenticator
of type " +
                     this.authenticator.getClass().getName() + ", which does not implement
that interface.";

Copied: incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulStrategyTest.java
(from r749156, incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategyTest.java)
URL: http://svn.apache.org/viewvc/incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulStrategyTest.java?p2=incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulStrategyTest.java&p1=incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategyTest.java&r1=749156&r2=749191&rev=749191&view=diff
==============================================================================
--- incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulModularAuthenticationStrategyTest.java
(original)
+++ incubator/jsecurity/import/trunk/test/org/jsecurity/authc/pam/AllSuccessfulStrategyTest.java
Mon Mar  2 05:25:18 2009
@@ -26,17 +26,17 @@
 import org.jsecurity.realm.Realm;
 import org.jsecurity.realm.SimpleAccountRealm;
 import org.jsecurity.subject.PrincipalCollection;
-import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.*;
 import org.junit.Before;
 import org.junit.Test;
 
-public class AllSuccessfulModularAuthenticationStrategyTest {
+public class AllSuccessfulStrategyTest {
 
-    private AllSuccessfulModularAuthenticationStrategy strategy;
+    private AllSuccessfulStrategy strategy;
 
     @Before
     public void setUp() {
-        strategy = new AllSuccessfulModularAuthenticationStrategy();
+        strategy = new AllSuccessfulStrategy();
     }
 
     @Test



Mime
View raw message