You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2007/10/19 18:47:12 UTC
svn commit: r586528 - in /directory:
apacheds/branches/bigbang/constants/src/main/java/org/apache/directory/server/ldap/constants/
apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/
apacheds/branches/bigbang/core/src/main/ja...
Author: elecharny
Date: Fri Oct 19 09:47:06 2007
New Revision: 586528
URL: http://svn.apache.org/viewvc?rev=586528&view=rev
Log:
o Moved some generic Ldap constants from apacheds-constants to shared-ldap
o Used those constants in the code instead of strings
Removed:
directory/apacheds/branches/bigbang/constants/src/main/java/org/apache/directory/server/ldap/constants/SaslQoP.java
directory/apacheds/branches/bigbang/constants/src/main/java/org/apache/directory/server/ldap/constants/SupportedSASLMechanisms.java
Modified:
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AbstractAuthenticator.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AnonymousAuthenticator.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/LdapPrincipal.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/SimpleAuthenticator.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/StrongAuthenticator.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACITupleFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxValueCountFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MicroOperationFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RestrictedByFilter.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/CoreContextFactory.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/LdapJndiProperties.java
directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxImmSubFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxValueCountFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MicroOperationFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RestrictedByFilterTest.java
directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/jndi/LdapJndiPropertiesTest.java
directory/apacheds/branches/bigbang/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/LastRequestType.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/LdapServer.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/SessionRegistry.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/DefaultBindHandler.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/AbstractSaslCallbackHandler.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/BindHandlerChain.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ConfigureChain.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/CramMd5MechanismHandler.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/DigestMd5MechanismHandler.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GetLdapContext.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GssapiMechanismHandler.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ReturnSuccess.java
directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/SaslFilter.java
directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACIItem.java
directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACITuple.java
directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ItemFirstACIItem.java
directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/UserFirstACIItem.java
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java Fri Oct 19 09:47:06 2007
@@ -80,7 +80,7 @@
import org.apache.directory.server.schema.registries.DefaultRegistries;
import org.apache.directory.server.schema.registries.OidRegistry;
import org.apache.directory.server.schema.registries.Registries;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
import org.apache.directory.shared.ldap.constants.ServerDNConstants;
import org.apache.directory.shared.ldap.exception.LdapAuthenticationNotSupportedException;
@@ -490,13 +490,13 @@
public DirContext getJndiContext() throws NamingException
{
- return this.getJndiContext( null, null, null, "none", "" );
+ return this.getJndiContext( null, null, null, AuthenticationLevel.NONE.toString(), "" );
}
public DirContext getJndiContext( String dn ) throws NamingException
{
- return this.getJndiContext( null, null, null, "none", dn );
+ return this.getJndiContext( null, null, null, AuthenticationLevel.NONE.toString(), dn );
}
@@ -688,7 +688,7 @@
* If bind is strong make sure we have the principal name
* set within the environment, otherwise complain
*/
- if ( "strong".equalsIgnoreCase( authentication ) )
+ if ( AuthenticationLevel.STRONG.toString().equalsIgnoreCase( authentication ) )
{
if ( principal == null )
{
@@ -700,7 +700,7 @@
* If bind is simple make sure we have the credentials and the
* principal name set within the environment, otherwise complain
*/
- else if ( "simple".equalsIgnoreCase( authentication ) )
+ else if ( AuthenticationLevel.SIMPLE.toString().equalsIgnoreCase( authentication ) )
{
if ( credential == null )
{
@@ -718,7 +718,7 @@
* If bind is none make sure credentials and the principal
* name are NOT set within the environment, otherwise complain
*/
- else if ( "none".equalsIgnoreCase( authentication ) )
+ else if ( AuthenticationLevel.NONE.toString().equalsIgnoreCase( authentication ) )
{
if ( credential != null )
{
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AbstractAuthenticator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AbstractAuthenticator.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AbstractAuthenticator.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AbstractAuthenticator.java Fri Oct 19 09:47:06 2007
@@ -46,7 +46,7 @@
*
* @param type the type of this authenticator (e.g. <tt>'simple'</tt>, <tt>'none'</tt>...)
*/
- protected AbstractAuthenticator(String type)
+ protected AbstractAuthenticator( String type )
{
this.authenticatorType = type;
}
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AnonymousAuthenticator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AnonymousAuthenticator.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AnonymousAuthenticator.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/AnonymousAuthenticator.java Fri Oct 19 09:47:06 2007
@@ -23,6 +23,7 @@
import javax.naming.NamingException;
import org.apache.directory.server.core.jndi.ServerContext;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
import org.apache.directory.shared.ldap.name.LdapDN;
@@ -40,7 +41,7 @@
*/
public AnonymousAuthenticator()
{
- super( "none" );
+ super( AuthenticationLevel.NONE.toString() );
}
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/LdapPrincipal.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/LdapPrincipal.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/LdapPrincipal.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/LdapPrincipal.java Fri Oct 19 09:47:06 2007
@@ -25,7 +25,7 @@
import javax.naming.Name;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
import org.apache.directory.shared.ldap.util.StringTools;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/SimpleAuthenticator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/SimpleAuthenticator.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/SimpleAuthenticator.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/SimpleAuthenticator.java Fri Oct 19 09:47:06 2007
@@ -52,7 +52,7 @@
import org.apache.directory.server.core.collective.CollectiveAttributeInterceptor;
import org.apache.directory.server.core.event.EventInterceptor;
import org.apache.directory.server.core.trigger.TriggerInterceptor;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.constants.LdapSecurityConstants;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
import org.apache.directory.shared.ldap.exception.LdapAuthenticationException;
@@ -132,10 +132,9 @@
* Creates a new instance.
* @
*/
- @SuppressWarnings( "unchecked" )
public SimpleAuthenticator()
{
- super( "simple" );
+ super( AuthenticationLevel.SIMPLE.toString() );
credentialCache = new LRUMap( DEFAULT_CACHE_SIZE );
}
@@ -143,10 +142,9 @@
* Creates a new instance, with an initial cache size
* @param cacheSize the size of the credential cache
*/
- @SuppressWarnings( "unchecked" )
public SimpleAuthenticator( int cacheSize )
{
- super( "simple" );
+ super( AuthenticationLevel.SIMPLE.toString() );
credentialCache = new LRUMap( cacheSize > 0 ? cacheSize : DEFAULT_CACHE_SIZE );
}
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/StrongAuthenticator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/StrongAuthenticator.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/StrongAuthenticator.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/StrongAuthenticator.java Fri Oct 19 09:47:06 2007
@@ -23,7 +23,7 @@
import javax.naming.NamingException;
import org.apache.directory.server.core.jndi.ServerContext;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
@@ -43,7 +43,7 @@
*/
public StrongAuthenticator()
{
- super( "strong" );
+ super( AuthenticationLevel.STRONG.toString() );
}
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java Fri Oct 19 09:47:06 2007
@@ -48,8 +48,8 @@
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.server.schema.registries.OidRegistry;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACITupleFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACITupleFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACITupleFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/ACITupleFilter.java Fri Oct 19 09:47:06 2007
@@ -28,8 +28,8 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilter.java Fri Oct 19 09:47:06 2007
@@ -29,8 +29,8 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxImmSubFilter.java Fri Oct 19 09:47:06 2007
@@ -31,9 +31,9 @@
import org.apache.directory.server.core.schema.SchemaInterceptor;
import org.apache.directory.server.core.subtree.SubentryInterceptor;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
import org.apache.directory.shared.ldap.filter.ExprNode;
import org.apache.directory.shared.ldap.filter.PresenceNode;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxValueCountFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxValueCountFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxValueCountFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MaxValueCountFilter.java Fri Oct 19 09:47:06 2007
@@ -30,10 +30,10 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.ProtectedItem.MaxValueCountItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MicroOperationFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MicroOperationFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MicroOperationFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MicroOperationFilter.java Fri Oct 19 09:47:06 2007
@@ -29,8 +29,8 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilter.java Fri Oct 19 09:47:06 2007
@@ -29,9 +29,9 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilter.java Fri Oct 19 09:47:06 2007
@@ -29,9 +29,9 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java Fri Oct 19 09:47:06 2007
@@ -34,11 +34,11 @@
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.server.schema.registries.OidRegistry;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.ProtectedItem.MaxValueCountItem;
import org.apache.directory.shared.ldap.aci.ProtectedItem.RestrictedByItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
import org.apache.directory.shared.ldap.name.LdapDN;
import org.apache.directory.shared.ldap.schema.AttributeType;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilter.java Fri Oct 19 09:47:06 2007
@@ -30,9 +30,9 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.server.core.subtree.SubtreeEvaluator;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RestrictedByFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RestrictedByFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RestrictedByFilter.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authz/support/RestrictedByFilter.java Fri Oct 19 09:47:06 2007
@@ -30,10 +30,10 @@
import org.apache.directory.server.core.partition.PartitionNexusProxy;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.ProtectedItem.RestrictedByItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/CoreContextFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/CoreContextFactory.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/CoreContextFactory.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/CoreContextFactory.java Fri Oct 19 09:47:06 2007
@@ -20,17 +20,15 @@
package org.apache.directory.server.core.jndi;
-import org.apache.directory.server.core.configuration.*;
import org.apache.directory.server.core.DirectoryService;
-import org.apache.directory.server.core.partition.PartitionNexusProxy;
-import org.apache.directory.server.core.interceptor.context.AddContextPartitionOperationContext;
-import org.apache.directory.server.core.interceptor.context.RemoveContextPartitionOperationContext;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
import org.apache.directory.shared.ldap.util.StringTools;
-import javax.naming.spi.InitialContextFactory;
-import javax.naming.*;
import javax.naming.ConfigurationException;
+import javax.naming.Context;
+import javax.naming.NamingException;
+import javax.naming.spi.InitialContextFactory;
import java.util.Hashtable;
@@ -105,7 +103,7 @@
Object value = env.get( Context.SECURITY_AUTHENTICATION );
if ( value == null )
{
- authentication = "none";
+ authentication = AuthenticationLevel.NONE.toString();
}
else
{
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/LdapJndiProperties.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/LdapJndiProperties.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/LdapJndiProperties.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/LdapJndiProperties.java Fri Oct 19 09:47:06 2007
@@ -28,7 +28,7 @@
import javax.naming.Context;
import javax.naming.NamingException;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapConfigurationException;
import org.apache.directory.shared.ldap.name.LdapDN;
import org.apache.directory.shared.ldap.util.StringTools;
@@ -82,11 +82,11 @@
}
else
{
- if ( "none".equals( authentication ) )
+ if ( AuthenticationLevel.NONE.toString().equals( authentication ) )
{
level = AuthenticationLevel.NONE;
}
- else if ( "simple".equals( authentication ) )
+ else if ( AuthenticationLevel.SIMPLE.toString().equals( authentication ) )
{
level = AuthenticationLevel.SIMPLE;
}
@@ -150,12 +150,12 @@
if ( credobj == null )
{
props.level = AuthenticationLevel.NONE;
- props.mechanisms.add( "none" );
+ props.mechanisms.add( AuthenticationLevel.NONE.toString() );
}
else
{
props.level = AuthenticationLevel.SIMPLE;
- props.mechanisms.add( "simple" );
+ props.mechanisms.add( AuthenticationLevel.SIMPLE.toString() );
}
}
else if ( !( authentication instanceof String ) )
@@ -165,15 +165,15 @@
}
else
{
- if ( "none".equals( authentication ) )
+ if ( AuthenticationLevel.NONE.toString().equals( authentication ) )
{
props.level = AuthenticationLevel.NONE;
- props.mechanisms.add( "none" );
+ props.mechanisms.add( AuthenticationLevel.NONE.toString() );
}
- else if ( "simple".equals( authentication ) )
+ else if ( AuthenticationLevel.SIMPLE.toString().equals( authentication ) )
{
props.level = AuthenticationLevel.SIMPLE;
- props.mechanisms.add( "simple" );
+ props.mechanisms.add( AuthenticationLevel.SIMPLE.toString() );
}
else
{
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java Fri Oct 19 09:47:06 2007
@@ -28,12 +28,12 @@
import org.apache.directory.server.core.partition.tree.BranchNode;
import org.apache.directory.server.core.partition.tree.LeafNode;
import org.apache.directory.server.core.partition.tree.Node;
-import org.apache.directory.server.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.server.schema.registries.OidRegistry;
import org.apache.directory.shared.ldap.MultiException;
import org.apache.directory.shared.ldap.NotImplementedException;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.exception.LdapInvalidAttributeIdentifierException;
import org.apache.directory.shared.ldap.exception.LdapNameNotFoundException;
import org.apache.directory.shared.ldap.exception.LdapNoSuchAttributeException;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/HighestPrecedenceFilterTest.java Fri Oct 19 09:47:06 2007
@@ -31,10 +31,10 @@
import org.apache.directory.server.core.authz.support.HighestPrecedenceFilter;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
/**
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxImmSubFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxImmSubFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxImmSubFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxImmSubFilterTest.java Fri Oct 19 09:47:06 2007
@@ -34,6 +34,7 @@
import org.apache.directory.server.core.partition.PartitionNexus;
import org.apache.directory.server.schema.registries.Registries;
import org.apache.directory.shared.ldap.aci.*;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.ldif.Entry;
import org.apache.directory.shared.ldap.message.AttributesImpl;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxValueCountFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxValueCountFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxValueCountFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MaxValueCountFilterTest.java Fri Oct 19 09:47:06 2007
@@ -35,11 +35,11 @@
import org.apache.directory.server.core.authz.support.MaxValueCountFilter;
import org.apache.directory.server.core.authz.support.OperationScope;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
import org.apache.directory.shared.ldap.aci.ProtectedItem.MaxValueCountItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.message.AttributeImpl;
import org.apache.directory.shared.ldap.message.AttributesImpl;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MicroOperationFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MicroOperationFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MicroOperationFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MicroOperationFilterTest.java Fri Oct 19 09:47:06 2007
@@ -32,10 +32,10 @@
import org.apache.directory.server.core.authz.support.MicroOperationFilter;
import org.apache.directory.server.core.authz.support.OperationScope;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
/**
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificProtectedItemFilterTest.java Fri Oct 19 09:47:06 2007
@@ -35,10 +35,10 @@
import org.apache.directory.server.core.authz.support.MostSpecificProtectedItemFilter;
import org.apache.directory.server.core.authz.support.OperationScope;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.filter.PresenceNode;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/MostSpecificUserClassFilterTest.java Fri Oct 19 09:47:06 2007
@@ -35,10 +35,10 @@
import org.apache.directory.server.core.authz.support.MostSpecificUserClassFilter;
import org.apache.directory.server.core.authz.support.OperationScope;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java Fri Oct 19 09:47:06 2007
@@ -42,12 +42,12 @@
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.server.schema.registries.OidRegistry;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
import org.apache.directory.shared.ldap.aci.ProtectedItem.MaxValueCountItem;
import org.apache.directory.shared.ldap.aci.ProtectedItem.RestrictedByItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.message.AttributeImpl;
import org.apache.directory.shared.ldap.message.AttributesImpl;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java Fri Oct 19 09:47:06 2007
@@ -36,10 +36,10 @@
import org.apache.directory.server.core.authz.support.RelatedUserClassFilter;
import org.apache.directory.server.core.subtree.SubtreeEvaluator;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RestrictedByFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RestrictedByFilterTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RestrictedByFilterTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/authz/support/RestrictedByFilterTest.java Fri Oct 19 09:47:06 2007
@@ -35,11 +35,11 @@
import org.apache.directory.server.core.authz.support.OperationScope;
import org.apache.directory.server.core.authz.support.RestrictedByFilter;
import org.apache.directory.shared.ldap.aci.ACITuple;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
import org.apache.directory.shared.ldap.aci.MicroOperation;
import org.apache.directory.shared.ldap.aci.ProtectedItem;
import org.apache.directory.shared.ldap.aci.UserClass;
import org.apache.directory.shared.ldap.aci.ProtectedItem.RestrictedByItem;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.message.AttributeImpl;
import org.apache.directory.shared.ldap.message.AttributesImpl;
Modified: directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/jndi/LdapJndiPropertiesTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/jndi/LdapJndiPropertiesTest.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/jndi/LdapJndiPropertiesTest.java (original)
+++ directory/apacheds/branches/bigbang/core/src/test/java/org/apache/directory/server/core/jndi/LdapJndiPropertiesTest.java Fri Oct 19 09:47:06 2007
@@ -26,7 +26,7 @@
import org.apache.commons.lang.ArrayUtils;
import org.apache.directory.server.core.jndi.LdapJndiProperties;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapConfigurationException;
import org.apache.directory.shared.ldap.util.StringTools;
Modified: directory/apacheds/branches/bigbang/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/LastRequestType.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/LastRequestType.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/LastRequestType.java (original)
+++ directory/apacheds/branches/bigbang/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/messages/value/LastRequestType.java Fri Oct 19 09:47:06 2007
@@ -24,6 +24,8 @@
import java.util.Collections;
import java.util.List;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+
/**
* @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
@@ -34,7 +36,7 @@
/**
* Constant for the "none" last request type.
*/
- public static final LastRequestType NONE = new LastRequestType( 0, "none" );
+ public static final LastRequestType NONE = new LastRequestType( 0, AuthenticationLevel.NONE.toString() );
/**
* Constant for the "time of initial ticket" last request type.
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/LdapServer.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/LdapServer.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/LdapServer.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/LdapServer.java Fri Oct 19 09:47:06 2007
@@ -38,8 +38,6 @@
import org.apache.directory.server.core.DirectoryService;
import org.apache.directory.server.core.partition.PartitionNexus;
-import org.apache.directory.server.ldap.constants.SaslQoP;
-import org.apache.directory.server.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.server.ldap.support.AbandonHandler;
import org.apache.directory.server.ldap.support.AddHandler;
import org.apache.directory.server.ldap.support.BindHandler;
@@ -66,6 +64,8 @@
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.shared.asn1.codec.Asn1CodecDecoder;
import org.apache.directory.shared.asn1.codec.Asn1CodecEncoder;
+import org.apache.directory.shared.ldap.constants.SaslQoP;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.exception.LdapConfigurationException;
import org.apache.directory.shared.ldap.exception.LdapNamingException;
import org.apache.directory.shared.ldap.message.AbandonRequest;
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/SessionRegistry.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/SessionRegistry.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/SessionRegistry.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/SessionRegistry.java Fri Oct 19 09:47:06 2007
@@ -33,6 +33,7 @@
import javax.naming.spi.InitialContextFactory;
import org.apache.directory.server.core.jndi.ServerLdapContext;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
import org.apache.directory.shared.ldap.message.AbandonableRequest;
import org.apache.directory.shared.ldap.message.Request;
@@ -275,7 +276,7 @@
{
//noinspection unchecked
Hashtable<String, Object> cloned = ( Hashtable<String, Object> ) env.clone();
- cloned.put( Context.SECURITY_AUTHENTICATION, "none" );
+ cloned.put( Context.SECURITY_AUTHENTICATION, AuthenticationLevel.NONE.toString() );
cloned.remove( Context.SECURITY_PRINCIPAL );
cloned.remove( Context.SECURITY_CREDENTIALS );
ctx = new InitialLdapContext( cloned, connCtls );
@@ -345,7 +346,7 @@
{
//noinspection unchecked
Hashtable<String, Object> cloned = ( Hashtable<String, Object> ) env.clone();
- cloned.put( Context.SECURITY_AUTHENTICATION, "none" );
+ cloned.put( Context.SECURITY_AUTHENTICATION, AuthenticationLevel.NONE.toString() );
cloned.remove( Context.SECURITY_PRINCIPAL );
cloned.remove( Context.SECURITY_CREDENTIALS );
ctx = new InitialLdapContext( cloned, connCtls );
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/DefaultBindHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/DefaultBindHandler.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/DefaultBindHandler.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/DefaultBindHandler.java Fri Oct 19 09:47:06 2007
@@ -24,6 +24,8 @@
import org.apache.directory.server.core.jndi.ServerLdapContext;
import org.apache.directory.server.ldap.LdapServer;
import org.apache.directory.server.ldap.support.bind.BindHandlerChain;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.exception.LdapException;
import org.apache.directory.shared.ldap.message.*;
import org.apache.directory.shared.ldap.name.LdapDN;
@@ -57,9 +59,6 @@
/** A class to handle SASL bind requests */
private IoHandlerCommand saslBindHandler;
- /** Definition of SIMPLE and STRONG authentication constants */
- private static final String SIMPLE_AUTHENTICATION_LEVEL = "simple";
-
/** An empty Contol array used to get back the controls if any */
private static final MutableControl[] EMPTY_CONTROL = new MutableControl[0];
@@ -226,7 +225,7 @@
// First, deal with Simple Authentication
// Guard clause: Reject SIMPLE mechanism.
- if ( !supportedMechanisms.contains( "SIMPLE" ) )
+ if ( !supportedMechanisms.contains( SupportedSASLMechanisms.SIMPLE ) )
{
LOG.error( "Bind error : SIMPLE authentication not supported. Please check the server.xml configuration file (supportedMechanisms field)" );
@@ -237,7 +236,7 @@
}
// Initialize the environment which will be used to create the context
- Hashtable<String, Object> env = getEnvironment( bindRequest, SIMPLE_AUTHENTICATION_LEVEL );
+ Hashtable<String, Object> env = getEnvironment( bindRequest, AuthenticationLevel.SIMPLE.toString() );
// Now, get the context
LdapContext ctx = getLdapContext( session, bindRequest, env );
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/AbstractSaslCallbackHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/AbstractSaslCallbackHandler.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/AbstractSaslCallbackHandler.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/AbstractSaslCallbackHandler.java Fri Oct 19 09:47:06 2007
@@ -21,6 +21,7 @@
import org.apache.directory.server.core.DirectoryService;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.exception.LdapException;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.directory.shared.ldap.message.LdapResult;
@@ -261,7 +262,7 @@
env.put( Context.INITIAL_CONTEXT_FACTORY, "org.apache.directory.server.core.jndi.CoreContextFactory" );
env.put( Context.SECURITY_PRINCIPAL, "uid=admin,ou=system" );
env.put( Context.SECURITY_CREDENTIALS, "secret" );
- env.put( Context.SECURITY_AUTHENTICATION, "simple" );
+ env.put( Context.SECURITY_AUTHENTICATION, AuthenticationLevel.SIMPLE.toString() );
return env;
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/BindHandlerChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/BindHandlerChain.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/BindHandlerChain.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/BindHandlerChain.java Fri Oct 19 09:47:06 2007
@@ -38,8 +38,7 @@
*/
public BindHandlerChain( DirectoryService directoryService, SessionRegistry registry )
{
- addLast( "configureChain", new ConfigureChain() );
- addLast( "handleSasl", new HandleSasl( directoryService ) );
+ addLast( "configureChain", new ConfigureChain( directoryService ) );
addLast( "getLdapContext", new GetLdapContext( registry ) );
addLast( "returnSuccess", new ReturnSuccess() );
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ConfigureChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ConfigureChain.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ConfigureChain.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ConfigureChain.java Fri Oct 19 09:47:06 2007
@@ -20,6 +20,12 @@
package org.apache.directory.server.ldap.support.bind;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.directory.server.core.DirectoryService;
import org.apache.directory.server.core.authn.LdapPrincipal;
import org.apache.directory.server.core.partition.PartitionNexus;
import org.apache.directory.server.kerberos.shared.crypto.encryption.EncryptionType;
@@ -28,9 +34,10 @@
import org.apache.directory.server.kerberos.shared.store.operations.GetPrincipal;
import org.apache.directory.server.ldap.LdapServer;
import org.apache.directory.server.protocol.shared.ServiceConfigurationException;
-import org.apache.directory.server.protocol.shared.store.ContextOperation;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.message.BindRequest;
+import org.apache.directory.shared.ldap.message.BindResponse;
import org.apache.directory.shared.ldap.message.LdapResult;
import org.apache.directory.shared.ldap.message.ResultCodeEnum;
import org.apache.directory.shared.ldap.name.LdapDN;
@@ -39,13 +46,15 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import javax.naming.Context;
import javax.naming.NamingException;
import javax.naming.directory.DirContext;
import javax.security.auth.Subject;
import javax.security.auth.kerberos.KerberosKey;
import javax.security.auth.kerberos.KerberosPrincipal;
import javax.security.sasl.Sasl;
-import java.util.*;
+import javax.security.sasl.SaslException;
+import javax.security.sasl.SaslServer;
/**
@@ -58,6 +67,20 @@
private DirContext ctx;
+ /**
+ * A Hashed Adapter mapping SASL mechanisms to their handlers.
+ */
+ private final Map<String, MechanismHandler> handlers;
+
+ public ConfigureChain( DirectoryService directoryService )
+ {
+ Map<String, MechanismHandler> map = new HashMap<String, MechanismHandler>();
+ map.put( SupportedSASLMechanisms.CRAM_MD5, new CramMd5MechanismHandler( directoryService ) );
+ map.put( SupportedSASLMechanisms.DIGEST_MD5, new DigestMd5MechanismHandler( directoryService ) );
+ map.put( SupportedSASLMechanisms.GSSAPI, new GssapiMechanismHandler( directoryService ) );
+ handlers = Collections.unmodifiableMap( map );
+
+ }
public void execute( NextCommand next, IoSession session, Object message ) throws Exception
{
@@ -74,7 +97,7 @@
Set<String> activeMechanisms = ldapServer.getSupportedMechanisms();
- if ( activeMechanisms.contains( "GSSAPI" ) )
+ if ( activeMechanisms.contains( SupportedSASLMechanisms.GSSAPI ) )
{
try
{
@@ -109,10 +132,96 @@
*/
session.setAttribute( "sessionMechanism", bindRequest.getSaslMechanism() );
- next.execute( session, message );
+ handleSasl( next, session, bindRequest );
}
+
+ /**
+ * Deal with a SASL bind request
+ */
+ public void handleSasl( NextCommand next, IoSession session, BindRequest bindRequest ) throws Exception
+ {
+ String sessionMechanism = bindRequest.getSaslMechanism();
+
+ if ( sessionMechanism.equals( SupportedSASLMechanisms.SIMPLE ) )
+ {
+ /*
+ * This is the principal name that will be used to bind to the DIT.
+ */
+ session.setAttribute( Context.SECURITY_PRINCIPAL, bindRequest.getName() );
+
+ /*
+ * These are the credentials that will be used to bind to the DIT.
+ * For the simple mechanism, this will be a password, possibly one-way hashed.
+ */
+ session.setAttribute( Context.SECURITY_CREDENTIALS, bindRequest.getCredentials() );
+
+ next.execute( session, bindRequest );
+ }
+ else
+ {
+ MechanismHandler mechanismHandler = handlers.get( sessionMechanism );
+
+ if ( mechanismHandler == null )
+ {
+ LOG.error( "Handler unavailable for " + sessionMechanism );
+ throw new IllegalArgumentException( "Handler unavailable for " + sessionMechanism );
+ }
+
+ SaslServer ss = mechanismHandler.handleMechanism( session, bindRequest );
+
+ LdapResult result = bindRequest.getResultResponse().getLdapResult();
+ if ( !ss.isComplete() )
+ {
+ try
+ {
+ /*
+ * SaslServer will throw an exception if the credentials are null.
+ */
+ if ( bindRequest.getCredentials() == null )
+ {
+ bindRequest.setCredentials( new byte[0] );
+ }
+
+ byte[] tokenBytes = ss.evaluateResponse( bindRequest.getCredentials() );
+
+ if ( ss.isComplete() )
+ {
+ /*
+ * There may be a token to return to the client. We set it here
+ * so it will be returned in a SUCCESS message, after an LdapContext
+ * has been initialized for the client.
+ */
+ session.setAttribute( "saslCreds", tokenBytes );
+
+ /*
+ * If we got here, we're ready to try getting an initial LDAP context.
+ */
+ next.execute( session, bindRequest );
+ }
+ else
+ {
+ LOG.info( "Continuation token had length " + tokenBytes.length );
+ result.setResultCode( ResultCodeEnum.SASL_BIND_IN_PROGRESS );
+ BindResponse resp = ( BindResponse ) bindRequest.getResultResponse();
+ resp.setServerSaslCreds( tokenBytes );
+ session.write( resp );
+ LOG.debug( "Returning final authentication data to client to complete context." );
+ }
+ }
+ catch ( SaslException se )
+ {
+ LOG.error( se.getMessage() );
+ result.setResultCode( ResultCodeEnum.INVALID_CREDENTIALS );
+ result.setErrorMessage( se.getMessage() );
+ session.write( bindRequest.getResultResponse() );
+ }
+ }
+ }
+ }
+
+
/**
* Create a list of all the configured realms.
*/
@@ -150,7 +259,7 @@
try
{
- entry = ( PrincipalStoreEntry ) execute( ldapServer, getPrincipal );
+ entry = findPrincipal( ldapServer, getPrincipal );
}
catch ( Exception e )
{
@@ -178,7 +287,7 @@
return subject;
}
- private Object execute( LdapServer ldapServer, ContextOperation operation ) throws Exception
+ private PrincipalStoreEntry findPrincipal( LdapServer ldapServer, GetPrincipal getPrincipal ) throws Exception
{
if ( ctx == null )
{
@@ -195,6 +304,6 @@
}
}
- return operation.execute( ctx, null );
+ return (PrincipalStoreEntry)getPrincipal.execute( ctx, null );
}
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/CramMd5MechanismHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/CramMd5MechanismHandler.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/CramMd5MechanismHandler.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/CramMd5MechanismHandler.java Fri Oct 19 09:47:06 2007
@@ -21,6 +21,7 @@
import org.apache.directory.server.core.DirectoryService;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.mina.common.IoSession;
@@ -66,7 +67,7 @@
CallbackHandler callbackHandler = new CramMd5CallbackHandler( directoryService, session, bindRequest );
- ss = Sasl.createSaslServer( "CRAM-MD5", "ldap", saslHost, saslProps, callbackHandler );
+ ss = Sasl.createSaslServer( SupportedSASLMechanisms.CRAM_MD5, "ldap", saslHost, saslProps, callbackHandler );
session.setAttribute( SASL_CONTEXT, ss );
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/DigestMd5MechanismHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/DigestMd5MechanismHandler.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/DigestMd5MechanismHandler.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/DigestMd5MechanismHandler.java Fri Oct 19 09:47:06 2007
@@ -21,6 +21,7 @@
import org.apache.directory.server.core.DirectoryService;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.mina.common.IoSession;
@@ -60,7 +61,7 @@
CallbackHandler callbackHandler = new DigestMd5CallbackHandler( directoryService, session, bindRequest );
- ss = Sasl.createSaslServer( "DIGEST-MD5", "ldap", saslHost, saslProps, callbackHandler );
+ ss = Sasl.createSaslServer( SupportedSASLMechanisms.DIGEST_MD5, "ldap", saslHost, saslProps, callbackHandler );
session.setAttribute( SASL_CONTEXT, ss );
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GetLdapContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GetLdapContext.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GetLdapContext.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GetLdapContext.java Fri Oct 19 09:47:06 2007
@@ -28,6 +28,8 @@
import javax.naming.ldap.LdapContext;
import org.apache.directory.server.ldap.SessionRegistry;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.exception.LdapException;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.directory.shared.ldap.message.MutableControl;
@@ -161,13 +163,13 @@
private String getAuthenticationLevel( String sessionMechanism )
{
- if ( sessionMechanism.equals( "SIMPLE" ) )
+ if ( sessionMechanism.equals( SupportedSASLMechanisms.SIMPLE ) )
{
- return "simple";
+ return AuthenticationLevel.SIMPLE.toString();
}
else
{
- return "strong";
+ return AuthenticationLevel.STRONG.toString();
}
}
}
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GssapiMechanismHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GssapiMechanismHandler.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GssapiMechanismHandler.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/GssapiMechanismHandler.java Fri Oct 19 09:47:06 2007
@@ -21,6 +21,7 @@
import org.apache.directory.server.core.DirectoryService;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.mina.common.IoSession;
@@ -67,7 +68,7 @@
{
public SaslServer run() throws Exception
{
- return Sasl.createSaslServer( "GSSAPI", "ldap", saslHost, saslProps, callbackHandler );
+ return Sasl.createSaslServer( SupportedSASLMechanisms.GSSAPI, "ldap", saslHost, saslProps, callbackHandler );
}
} );
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ReturnSuccess.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ReturnSuccess.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ReturnSuccess.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/ReturnSuccess.java Fri Oct 19 09:47:06 2007
@@ -22,6 +22,7 @@
import javax.security.sasl.SaslServer;
+import org.apache.directory.shared.ldap.constants.SupportedSASLMechanisms;
import org.apache.directory.shared.ldap.message.BindRequest;
import org.apache.directory.shared.ldap.message.BindResponse;
import org.apache.directory.shared.ldap.message.LdapResult;
@@ -72,7 +73,8 @@
/*
* If the SASL mechanism is DIGEST-MD5 or GSSAPI, we insert a SASLFilter.
*/
- if ( sessionMechanism.equals( "DIGEST-MD5" ) || sessionMechanism.equals( "GSSAPI" ) )
+ if ( sessionMechanism.equals( SupportedSASLMechanisms.DIGEST_MD5 ) ||
+ sessionMechanism.equals( SupportedSASLMechanisms.GSSAPI ) )
{
log.debug( "Inserting SaslFilter to engage negotiated security layer." );
Modified: directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/SaslFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/SaslFilter.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/SaslFilter.java (original)
+++ directory/apacheds/branches/bigbang/protocol-ldap/src/main/java/org/apache/directory/server/ldap/support/bind/SaslFilter.java Fri Oct 19 09:47:06 2007
@@ -24,7 +24,7 @@
import javax.security.sasl.SaslException;
import javax.security.sasl.SaslServer;
-import org.apache.directory.server.ldap.constants.SaslQoP;
+import org.apache.directory.shared.ldap.constants.SaslQoP;
import org.apache.mina.common.ByteBuffer;
import org.apache.mina.common.IoFilterAdapter;
import org.apache.mina.common.IoSession;
Modified: directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java (original)
+++ directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java Fri Oct 19 09:47:06 2007
@@ -29,7 +29,7 @@
import org.apache.directory.server.ldap.LdapServer;
import org.apache.directory.server.protocol.shared.store.LdifFileLoader;
import org.apache.directory.server.protocol.shared.store.LdifLoadFilter;
-import org.apache.directory.shared.ldap.aci.AuthenticationLevel;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
import org.apache.directory.shared.ldap.constants.SchemaConstants;
import org.apache.directory.shared.ldap.message.AttributesImpl;
import org.apache.directory.shared.ldap.name.LdapDN;
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACIItem.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACIItem.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACIItem.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACIItem.java Fri Oct 19 09:47:06 2007
@@ -25,6 +25,8 @@
import java.util.HashSet;
import java.util.Set;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+
/**
* An abstract class that provides common properties and operations for
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACITuple.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACITuple.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACITuple.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ACITuple.java Fri Oct 19 09:47:06 2007
@@ -27,6 +27,8 @@
import java.util.HashSet;
import java.util.Set;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+
/**
* A flatten entity which is converted from an {@link ACIItem}. The tuples are
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ItemFirstACIItem.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ItemFirstACIItem.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ItemFirstACIItem.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/ItemFirstACIItem.java Fri Oct 19 09:47:06 2007
@@ -25,6 +25,8 @@
import java.util.Collections;
import java.util.Set;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+
/**
* An {@link ACIItem} which specifies {@link ProtectedItem}s first and then
Modified: directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/UserFirstACIItem.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/UserFirstACIItem.java?rev=586528&r1=586527&r2=586528&view=diff
==============================================================================
--- directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/UserFirstACIItem.java (original)
+++ directory/shared/branches/bigbang/ldap/src/main/java/org/apache/directory/shared/ldap/aci/UserFirstACIItem.java Fri Oct 19 09:47:06 2007
@@ -25,6 +25,8 @@
import java.util.Collections;
import java.util.Set;
+import org.apache.directory.shared.ldap.constants.AuthenticationLevel;
+
/**
* An {@link ACIItem} which specifies {@link UserClass}es first and then