You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by cc...@apache.org on 2007/07/14 09:55:59 UTC
svn commit: r556238 [8/8] - in /directory: apacheds/trunk-with-dependencies/
sandbox/ccustine/new_installers/apacheds/
sandbox/ccustine/new_installers/apacheds/benchmarks/
sandbox/ccustine/new_installers/apacheds/bootstrap-extract/
sandbox/ccustine/new...
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apache.schema
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apache.schema?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apache.schema (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apache.schema Sat Jul 14 00:55:44 2007
@@ -198,6 +198,10 @@
STRUCTURAL
MUST ( unixFilePath ) )
+# ===============
+# SP related
+# ===============
+
attributetype ( 1.3.6.1.4.1.18060.0.4.1.2.21
NAME 'fullyQualifiedJavaClassName'
DESC 'The fully qualified name for a (Java) class'
@@ -221,6 +225,54 @@
SUP distinguishedName
EQUALITY distinguishedNameMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12 )
+
+# New SP related schema
+
+attributetype ( 1.3.6.1.4.1.18060.0.4.1.5.1
+ NAME 'storedProcLangId'
+ EQUALITY caseExactIA5Match
+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
+ SINGLE-VALUE )
+
+attributetype ( 1.3.6.1.4.1.18060.0.4.1.5.2
+ NAME 'storedProcUnitName'
+ EQUALITY caseExactIA5Match
+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
+ SINGLE-VALUE )
+
+objectclass ( 1.3.6.1.4.1.18060.0.4.1.5.3
+ NAME 'storedProcUnit'
+ SUP top
+ ABSTRACT
+ MUST ( storedProcLangId $ storedProcUnitName ) )
+
+attributetype ( 1.3.6.1.4.1.18060.0.4.1.5.4
+ NAME 'javaByteCode'
+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.5 SINGLE-VALUE )
+
+objectclass ( 1.3.6.1.4.1.18060.0.4.1.5.5
+ NAME 'javaStoredProcUnit'
+ SUP storedProcUnit
+ STRUCTURAL
+ MUST ( javaByteCode ) )
+
+attributetype ( 1.3.6.1.4.1.18060.0.4.1.5.6
+ NAME 'javaxScriptLangId'
+ EQUALITY caseExactIA5Match
+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
+ SINGLE-VALUE )
+
+attributetype ( 1.3.6.1.4.1.18060.0.4.1.5.7
+ NAME 'javaxScriptCode'
+ EQUALITY caseExactIA5Match
+ SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
+ SINGLE-VALUE )
+
+objectclass ( 1.3.6.1.4.1.18060.0.4.1.5.8
+ NAME 'javaxScriptStoredProcUnit'
+ SUP storedProcUnit
+ STRUCTURAL
+ MUST ( javaxScriptLangId $ javaxScriptCode ) )
# ===============
# Trigger related
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apachemeta.schema
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apachemeta.schema?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apachemeta.schema (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-bootstrap/src/main/schema/apachemeta.schema Sat Jul 14 00:55:44 2007
@@ -28,6 +28,7 @@
# | 1.3.6.1.4.1.18060.0.4.0.0.3 | attributeTypeUsage |
# | 1.3.6.1.4.1.18060.0.4.0.0.4 | number |
# | 1.3.6.1.4.1.18060.0.4.0.0.5 | oidLen |
+# | 1.3.6.1.4.1.18060.0.4.0.0.6 | objectName |
# +------------------------------+-----------------------------+
#
# +------------------------------+-----------------------------+
@@ -80,7 +81,7 @@
# | Objectclasses OID | name |
# +------------------------------+-----------------------------+
# | 1.3.6.1.4.1.18060.0.4.0.3.1 | metaTop |
-# | 1.3.6.1.4.1.18060.0.4.0.3.2 | metaObjectclass |
+# | 1.3.6.1.4.1.18060.0.4.0.3.2 | metaObjectClass |
# | 1.3.6.1.4.1.18060.0.4.0.3.3 | metaAttributeType |
# | 1.3.6.1.4.1.18060.0.4.0.3.4 | metaSyntax |
# | 1.3.6.1.4.1.18060.0.4.0.3.5 | metaMatchingRule |
@@ -128,7 +129,7 @@
# the metaTop objectClass
#------------------------------------------------------------------------------
objectclass ( 1.3.6.1.4.1.18060.0.4.0.3.2
- NAME 'metaObjectclass'
+ NAME 'metaObjectClass'
DESC 'meta definition of the objectclass object'
SUP metaTop
STRUCTURAL
@@ -350,7 +351,7 @@
attributetype ( 1.3.6.1.4.1.18060.0.4.0.2.2 NAME 'm-name'
DESC 'The Object name'
EQUALITY caseIgnoreMatch
- SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{32768}
+ SYNTAX 1.3.6.1.4.1.18060.0.4.0.0.6{1024}
)
# --- m-description AttributeType ---------------------------------------------
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-extras/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-extras/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-extras/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-extras/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-schema-extras</artifactId>
@@ -15,12 +15,6 @@
</description>
<dependencies>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- <scope>provided</scope>
- </dependency>
-
<dependency>
<groupId>org.apache.directory.server</groupId>
<artifactId>apacheds-schema-registries</artifactId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-extras/src/main/java/org/apache/directory/server/schema/bootstrap/NisSyntaxProducer.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-extras/src/main/java/org/apache/directory/server/schema/bootstrap/NisSyntaxProducer.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-extras/src/main/java/org/apache/directory/server/schema/bootstrap/NisSyntaxProducer.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-extras/src/main/java/org/apache/directory/server/schema/bootstrap/NisSyntaxProducer.java Sat Jul 14 00:55:44 2007
@@ -61,14 +61,14 @@
syntax.setDescription( "RFC2307 NIS Netgroup Triple" );
syntax.setNames( new String[]
{ "NIS Netgroup Triple" } );
- syntax.setHumanReadible( true );
+ syntax.setHumanReadable( true );
cb.schemaObjectProduced( this, syntax.getOid(), syntax );
// 1.3.6.1.1.1.0.1 - RFC2307 Boot Parameter Syntax
syntax = new BootstrapSyntax( "1.3.6.1.1.1.0.1", syntaxCheckerRegistry );
syntax.setNames( new String[]
{ "NIS Boot Parameter" } );
- syntax.setHumanReadible( true );
+ syntax.setHumanReadable( true );
cb.schemaObjectProduced( this, syntax.getOid(), syntax );
}
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-registries/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-registries/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-registries/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-registries/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-schema-registries</artifactId>
@@ -16,12 +16,6 @@
<packaging>jar</packaging>
<dependencies>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- <scope>provided</scope>
- </dependency>
-
<dependency>
<groupId>${pom.groupId}</groupId>
<artifactId>apacheds-core-shared</artifactId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultOidRegistry.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultOidRegistry.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultOidRegistry.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultOidRegistry.java Sat Jul 14 00:55:44 2007
@@ -282,7 +282,7 @@
return;
}
- list = new ArrayList();
+ list = new ArrayList(2);
list.add( name );
list.add( value );
value = list;
Modified: directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultRegistries.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultRegistries.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultRegistries.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultRegistries.java Sat Jul 14 00:55:44 2007
@@ -396,7 +396,7 @@
// try
// {
// String schema = attributeTypeRegistry.getSchemaName( at.getOid() );
- // if ( ! hasMatchingRule && at.getSyntax().isHumanReadible() )
+ // if ( ! hasMatchingRule && at.getSyntax().isHumanReadable() )
// {
// errors.add( new NullPointerException( "attributeType "
// + at.getName() + " in schema " + schema + " with OID "
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-installers/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-installers/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-installers/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-installers/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-installers</artifactId>
@@ -28,6 +28,12 @@
</dependency>
<dependency>
+ <groupId>org.apache.directory.server</groupId>
+ <artifactId>apacheds-server-xml</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+
+ <dependency>
<groupId>org.apache.directory.daemon</groupId>
<artifactId>daemon-bootstrappers</artifactId>
<scope>provided</scope>
@@ -47,14 +53,18 @@
<dependency>
<groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- <version>1.2.25</version>
+ <artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j13</artifactId>
- <version>1.0.1</version>
+ <artifactId>jcl104-over-slf4j</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>nlog4j</artifactId>
+ <version>1.2.25</version>
</dependency>
<dependency>
@@ -83,11 +93,6 @@
</dependency>
<dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
- </dependency>
-
- <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
</dependency>
@@ -345,6 +350,31 @@
<goals>
<goal>generate</goal>
</goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>unpack-server-xml</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ <configuration>
+ <artifactItems>
+ <artifactItem>
+ <groupId>${pom.groupId}</groupId>
+ <artifactId>apacheds-server-xml</artifactId>
+ <version>${pom.version}</version>
+ </artifactItem>
+ </artifactItems>
+ <outputDirectory>${basedir}/src/main/installers</outputDirectory>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
+ </configuration>
</execution>
</executions>
</plugin>
Propchange: directory/sandbox/ccustine/new_installers/apacheds/server-installers/src/main/installers/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sat Jul 14 00:55:44 2007
@@ -0,0 +1,2 @@
+META-INF
+server.xml
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-installers/src/main/installers/rpm-apacheds.spec
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-installers/src/main/installers/rpm-apacheds.spec?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-installers/src/main/installers/rpm-apacheds.spec (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-installers/src/main/installers/rpm-apacheds.spec Sat Jul 14 00:55:44 2007
@@ -17,7 +17,7 @@
mkdir -p $RPM_BUILD_ROOT
cp -rf ${image.basedir} $RPM_BUILD_ROOT/%{name}-%{version}
cd $RPM_BUILD_ROOT
-tar -zcvf /usr/src/redhat/SOURCES/%{name}-%{version}.tar.gz %{name}-%{version}
+tar -zcvf %{_topdir}/SOURCES/%{name}-%{version}.tar.gz %{name}-%{version}
%setup -q
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-jndi/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-jndi/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-jndi/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-jndi/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-jndi</artifactId>
@@ -18,11 +18,6 @@
<packaging>jar</packaging>
<dependencies>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- <scope>provided</scope>
- </dependency>
<!--dependency>
<groupId>backport-util-concurrent</groupId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-jndi/src/main/java/org/apache/directory/server/jndi/ServerContextFactory.java Sat Jul 14 00:55:44 2007
@@ -43,7 +43,7 @@
import org.apache.directory.server.core.partition.PartitionNexus;
import org.apache.directory.server.dns.DnsConfiguration;
import org.apache.directory.server.dns.DnsServer;
-import org.apache.directory.server.dns.store.JndiRecordStoreImpl;
+import org.apache.directory.server.dns.store.jndi.JndiRecordStoreImpl;
import org.apache.directory.server.dns.store.RecordStore;
import org.apache.directory.server.kerberos.kdc.KdcConfiguration;
import org.apache.directory.server.kerberos.kdc.KerberosServer;
@@ -108,6 +108,7 @@
private static ChangePasswordServer udpChangePasswordServer;
private static NtpServer tcpNtpServer;
private static NtpServer udpNtpServer;
+ private static DnsServer tcpDnsServer;
private static DnsServer udpDnsServer;
private DirectoryService directoryService;
@@ -218,18 +219,28 @@
if ( log.isInfoEnabled() )
{
- log.info( "Unbind of NTP Service complete: " + udpNtpServer );
+ log.info( "Unbind of NTP Service (UDP) complete: " + udpNtpServer );
}
udpNtpServer = null;
}
+ if ( tcpDnsServer != null )
+ {
+ tcpDnsServer.destroy();
+ if ( log.isInfoEnabled() )
+ {
+ log.info( "Unbind of DNS Service (TCP) complete: " + tcpDnsServer );
+ }
+ tcpDnsServer = null;
+ }
+
if ( udpDnsServer != null )
{
udpDnsServer.destroy();
if ( log.isInfoEnabled() )
{
- log.info( "Unbind of DNS Service complete: " + udpDnsServer );
+ log.info( "Unbind of DNS Service (UDP) complete: " + udpDnsServer );
}
udpDnsServer = null;
}
@@ -638,6 +649,13 @@
DatagramAcceptorConfig udpConfig = new DatagramAcceptorConfig();
udpConfig.setThreadModel( threadModel );
+ SocketAcceptorConfig tcpConfig = new SocketAcceptorConfig();
+ tcpConfig.setDisconnectOnUnbind( false );
+ tcpConfig.setReuseAddress( true );
+ tcpConfig.setFilterChainBuilder( new DefaultIoFilterChainBuilder() );
+ tcpConfig.setThreadModel( threadModel );
+
+ tcpDnsServer = new DnsServer( dnsConfig, tcpAcceptor, tcpConfig, store );
udpDnsServer = new DnsServer( dnsConfig, udpAcceptor, udpConfig, store );
}
catch ( Throwable t )
Propchange: directory/sandbox/ccustine/new_installers/apacheds/server-main/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sat Jul 14 00:55:44 2007
@@ -1,3 +1,5 @@
+server.xml
+META-INF
server-work
example.com
.wtpmodules
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.bat
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.bat?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.bat (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.bat Sat Jul 14 00:55:44 2007
@@ -1,6 +1,7 @@
+@echo off
+
REM this script starts ApacheDS (as non-windows-service)
-@echo off
IF NOT exist target/apacheds-server-main-1.5.1-SNAPSHOT-app.jar GOTO :MVN
echo uber jar exists
@@ -8,8 +9,8 @@
:MVN
echo uber jar not found need to build it
- mvn clean assembly:assembly
+ call mvn clean assembly:assembly
GOTO :JAVA
:JAVA
- java -Dlog4j.configuration=file:///%cd%/log4j.properties -jar target/apacheds-server-main-1.5.1-SNAPSHOT-app.jar server.xml
+ java -Dlog4j.configuration="file:///%cd%/log4j.properties" -jar target/apacheds-server-main-1.5.1-SNAPSHOT-app.jar server.xml
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.sh
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.sh?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.sh (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-main/apacheds.sh Sat Jul 14 00:55:44 2007
@@ -6,4 +6,4 @@
mvn clean assembly:assembly
fi
-java -Dlog4j.configuration=file://$(pwd)/log4j.properties -jar target/apacheds-server-main-1.5.1-SNAPSHOT-app.jar server.xml
+java -Dlog4j.debug -Dlog4j.configuration=file:./log4j.properties -jar target/apacheds-server-main-1.5.1-SNAPSHOT-app.jar server.xml
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-main/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-main/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-main/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-main/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-main</artifactId>
@@ -18,17 +18,18 @@
</dependency>
<dependency>
+ <groupId>org.apache.directory.server</groupId>
+ <artifactId>apacheds-server-xml</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+
+ <dependency>
<groupId>org.apache.directory.daemon</groupId>
<artifactId>daemon-bootstrappers</artifactId>
<version>1.1.1-SNAPSHOT</version>
</dependency>
<dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- </dependency>
-
- <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
</dependency>
@@ -39,8 +40,8 @@
</dependency>
<dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl104-over-slf4j</artifactId>
</dependency>
<dependency>
@@ -52,6 +53,23 @@
<build>
<plugins>
<plugin>
+ <artifactId>maven-clean-plugin</artifactId>
+ <configuration>
+ <filesets>
+ <fileset>
+ <directory>.</directory>
+ <includes>
+ <include>*.log</include>
+ <include>server.xml</include>
+ <include>META-INF</include>
+ <include>example.com</include>
+ </includes>
+ <followSymlinks>false</followSymlinks>
+ </fileset>
+ </filesets>
+ </configuration>
+ </plugin>
+ <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
@@ -76,6 +94,31 @@
<classifier>app</classifier>
<appendAssemblyId>false</appendAssemblyId>
</configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>unpack-server-xml</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ <configuration>
+ <artifactItems>
+ <artifactItem>
+ <groupId>${pom.groupId}</groupId>
+ <artifactId>apacheds-server-xml</artifactId>
+ <version>${pom.version}</version>
+ </artifactItem>
+ </artifactItems>
+ <outputDirectory>${basedir}</outputDirectory>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
+ </configuration>
+ </execution>
+ </executions>
</plugin>
</plugins>
</build>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-main/src/main/assembly/apacheds-main.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-main/src/main/assembly/apacheds-main.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-main/src/main/assembly/apacheds-main.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-main/src/main/assembly/apacheds-main.xml Sat Jul 14 00:55:44 2007
@@ -16,6 +16,9 @@
<unpack>true</unpack>
<scope>runtime</scope>
<excludes>
+ <exclude>avalon-framework:avalon-framework</exclude>
+ <exclude>logkit:logkit</exclude>
+ <exclude>log4j:log4j</exclude>
<exclude>aopalliance:aopalliance</exclude>
<exclude>jasperreports:jasperreports</exclude>
<exclude>freemarker:freemarker</exclude>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-replication/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-replication/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-replication/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-replication/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-replication</artifactId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-sar/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-sar/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-sar/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-sar/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-sar</artifactId>
@@ -39,18 +39,18 @@
</dependency>
<dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-core</artifactId>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl104-over-slf4j</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
- <artifactId>spring-beans</artifactId>
+ <artifactId>spring-core</artifactId>
</dependency>
<dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-beans</artifactId>
</dependency>
<dependency>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-tools/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-tools/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-tools/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-tools/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-tools</artifactId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java Sat Jul 14 00:55:44 2007
@@ -22,12 +22,14 @@
import java.io.File;
import java.io.FileWriter;
+import java.io.IOException;
import java.io.PrintWriter;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
+import java.util.Hashtable;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -41,21 +43,45 @@
import jdbm.recman.BaseRecordManager;
import jdbm.recman.CacheRecordManager;
+import org.apache.directory.server.configuration.MutableServerStartupConfiguration;
import org.apache.directory.server.configuration.ServerStartupConfiguration;
+import org.apache.directory.server.core.DirectoryService;
+import org.apache.directory.server.core.DirectoryServiceConfiguration;
+import org.apache.directory.server.core.DirectoryServiceListener;
+import org.apache.directory.server.core.configuration.MutablePartitionConfiguration;
+import org.apache.directory.server.core.configuration.StartupConfiguration;
+import org.apache.directory.server.core.interceptor.InterceptorChain;
+import org.apache.directory.server.core.partition.PartitionNexus;
import org.apache.directory.server.core.partition.impl.btree.Tuple;
import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmIndex;
import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmMasterTable;
-//import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
+import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmPartition;
+import org.apache.directory.server.core.schema.PartitionSchemaLoader;
+import org.apache.directory.server.core.schema.SchemaManager;
+import org.apache.directory.server.schema.SerializableComparator;
+import org.apache.directory.server.schema.bootstrap.ApacheSchema;
+import org.apache.directory.server.schema.bootstrap.ApachemetaSchema;
import org.apache.directory.server.schema.bootstrap.BootstrapSchemaLoader;
+import org.apache.directory.server.schema.bootstrap.CoreSchema;
+import org.apache.directory.server.schema.bootstrap.Schema;
+import org.apache.directory.server.schema.bootstrap.SystemSchema;
+import org.apache.directory.server.schema.bootstrap.partition.DbFileListing;
import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
import org.apache.directory.server.schema.registries.DefaultOidRegistry;
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.server.tools.ToolCommandListener;
import org.apache.directory.server.tools.execution.BaseToolCommandExecutor;
import org.apache.directory.server.tools.util.ListenerParameter;
import org.apache.directory.server.tools.util.Parameter;
import org.apache.directory.server.tools.util.ToolCommandException;
+import org.apache.directory.shared.ldap.constants.SchemaConstants;
+import org.apache.directory.shared.ldap.exception.LdapConfigurationException;
+import org.apache.directory.shared.ldap.exception.LdapNamingException;
import org.apache.directory.shared.ldap.ldif.LdifUtils;
+import org.apache.directory.shared.ldap.message.AttributesImpl;
+import org.apache.directory.shared.ldap.message.ResultCodeEnum;
import org.apache.directory.shared.ldap.schema.AttributeType;
import org.apache.directory.shared.ldap.schema.UsageEnum;
import org.apache.directory.shared.ldap.util.Base64;
@@ -76,7 +102,7 @@
public static final String EXCLUDEDATTRIBUTES_PARAMETER = "excluded-attributes";
public static final String INCLUDEOPERATIONAL_PARAMETER = "include-operational";
- private DefaultRegistries bootstrapRegistries = new DefaultRegistries( "bootstrap",
+ private Registries bootstrapRegistries = new DefaultRegistries( "bootstrap",
new BootstrapSchemaLoader(), new DefaultOidRegistry() );
private Set<String> exclusions = new HashSet<String>();
private boolean includeOperational = false;
@@ -136,19 +162,147 @@
notifyExceptionListener( e );
}
}
+
+
+ private Registries loadRegistries() throws Exception
+ {
+ // --------------------------------------------------------------------
+ // Load the bootstrap schemas to start up the schema partition
+ // --------------------------------------------------------------------
+
+ // setup temporary loader and temp registry
+ BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+ OidRegistry oidRegistry = new DefaultOidRegistry();
+ final Registries registries = new DefaultRegistries( "bootstrap", loader, oidRegistry );
+
+ // load essential bootstrap schemas
+ Set<Schema> bootstrapSchemas = new HashSet<Schema>();
+ bootstrapSchemas.add( new ApachemetaSchema() );
+ bootstrapSchemas.add( new ApacheSchema() );
+ bootstrapSchemas.add( new CoreSchema() );
+ bootstrapSchemas.add( new SystemSchema() );
+ loader.loadWithDependencies( bootstrapSchemas, registries );
+
+ // run referential integrity tests
+ java.util.List errors = registries.checkRefInteg();
+ if ( !errors.isEmpty() )
+ {
+ NamingException e = new NamingException();
+ e.setRootCause( ( Throwable ) errors.get( 0 ) );
+ throw e;
+ }
+
+ SerializableComparator.setRegistry( registries.getComparatorRegistry() );
+
+ // --------------------------------------------------------------------
+ // Initialize schema partition or bomb out if we cannot find it on disk
+ // --------------------------------------------------------------------
+
+ // If not present then we need to abort
+ File schemaDirectory = new File( getLayout().getPartitionsDirectory(), "schema" );
+ if ( ! schemaDirectory.exists() )
+ {
+ throw new LdapConfigurationException( "The following schema directory from " +
+ "the installation layout could not be found:\n\t" + schemaDirectory );
+ }
+
+ MutablePartitionConfiguration schemaPartitionConfig = new MutablePartitionConfiguration();
+ schemaPartitionConfig.setId( "schema" );
+ schemaPartitionConfig.setCacheSize( 1000 );
+
+ DbFileListing listing = null;
+ try
+ {
+ listing = new DbFileListing();
+ }
+ catch( IOException e )
+ {
+ throw new LdapNamingException( "Got IOException while trying to read DBFileListing: " + e.getMessage(),
+ ResultCodeEnum.OTHER );
+ }
+
+ schemaPartitionConfig.setIndexedAttributes( listing.getIndexedAttributes() );
+ schemaPartitionConfig.setSuffix( "ou=schema" );
+
+ Attributes entry = new AttributesImpl();
+ entry.put( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC );
+ entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( SchemaConstants.ORGANIZATIONAL_UNIT_OC );
+ entry.put( SchemaConstants.OU_AT, "schema" );
+ schemaPartitionConfig.setContextEntry( entry );
+ JdbmPartition schemaPartition = new JdbmPartition();
+
+ DirectoryServiceConfiguration dsc = new DirectoryServiceConfiguration()
+ {
+ public Hashtable getEnvironment()
+ {
+ return null;
+ }
+
+ public String getInstanceId()
+ {
+ return "1";
+ }
+
+ public InterceptorChain getInterceptorChain()
+ {
+ return null;
+ }
+
+ public PartitionNexus getPartitionNexus()
+ {
+ return null;
+ }
+
+ public Registries getRegistries()
+ {
+ return registries;
+ }
+
+ public SchemaManager getSchemaManager()
+ {
+ return null;
+ }
+
+ public DirectoryService getService()
+ {
+ return null;
+ }
+
+ public DirectoryServiceListener getServiceListener()
+ {
+ return null;
+ }
+
+ public StartupConfiguration getStartupConfiguration()
+ {
+ return getConfiguration();
+ }
+
+ public boolean isFirstStart()
+ {
+ return false;
+ }
+ };
+
+ schemaPartition.init( dsc, schemaPartitionConfig );
+
+ // --------------------------------------------------------------------
+ // Initialize schema subsystem and reset registries
+ // --------------------------------------------------------------------
+
+ PartitionSchemaLoader schemaLoader = new PartitionSchemaLoader( schemaPartition, registries );
+ Registries globalRegistries = new DefaultRegistries( "global", schemaLoader, oidRegistry );
+ schemaLoader.loadEnabled( globalRegistries );
+ SerializableComparator.setRegistry( globalRegistries.getComparatorRegistry() );
+ return globalRegistries;
+ }
private void execute() throws Exception
{
getLayout().verifyInstallation();
- if ( true )
- {
- throw new RuntimeException( "Schema initialization is a bit messed up or needs to be " +
- "/n re-evaluated here." );
- }
-
- // loader.load( getConfiguration().getBootstrapSchemas(), bootstrapRegistries );
+ bootstrapRegistries = loadRegistries();
PrintWriter out = null;
if ( excludedAttributes != null )
@@ -169,7 +323,7 @@
{
out = new PrintWriter( new FileWriter( outputFile ) );
}
-
+
for ( int ii = 0; ii < partitions.length; ii++ )
{
File partitionDirectory = new File( getLayout().getPartitionsDirectory(), partitions[ii] );
@@ -226,6 +380,8 @@
configUrl = getLayout().getConfigurationFile().toURL();
factory = new FileSystemXmlApplicationContext( configUrl.toString() );
setConfiguration( ( ServerStartupConfiguration ) factory.getBean( "configuration" ) );
+ MutableServerStartupConfiguration msc = ( MutableServerStartupConfiguration ) getConfiguration();
+ msc.setWorkingDirectory( getLayout().getPartitionsDirectory() );
}
catch ( MalformedURLException e )
{
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/manifest/MANIFEST.MF
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/manifest/MANIFEST.MF?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/manifest/MANIFEST.MF (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-tools/src/main/manifest/MANIFEST.MF Sat Jul 14 00:55:44 2007
@@ -8,20 +8,28 @@
../lib/apacheds-protocol-kerberos-1.5.1-SNAPSHOT.jar
../lib/apacheds-protocol-ldap-1.5.1-SNAPSHOT.jar
../lib/apacheds-protocol-ntp-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-protocol-dns-1.5.1-SNAPSHOT.jar
../lib/apacheds-core-1.5.1-SNAPSHOT.jar
../lib/apacheds-core-shared-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-jdbm-store-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-btree-base-1.5.1-SNAPSHOT.jar
../lib/apacheds-server-jndi-1.5.1-SNAPSHOT.jar
../lib/apacheds-server-main-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-schema-registries-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-schema-bootstrap-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-bootstrap-partition-1.5.1-SNAPSHOT.jar
+ ../lib/apacheds-bootstrap-extract-1.5.1-SNAPSHOT.jar
../lib/commons-collections-3.2.jar
../lib/commons-lang-2.3.jar
../lib/commons-logging-1.1.jar
../lib/commons-cli-1.0.jar
../lib/jdbm-1.0.jar
- ../lib/mina-core-1.0.2.jar
+ ../lib/mina-core-1.0.3.jar
../lib/shared-asn1-codec-0.9.7-SNAPSHOT.jar
- ../lib/mina-filter-ssl-1.0.2.jar
+ ../lib/mina-filter-ssl-1.0.3.jar
../lib/shared-asn1-0.9.7-SNAPSHOT.jar
../lib/shared-ldap-0.9.7-SNAPSHOT.jar
+ ../lib/antlr-2.7.7.jar
../lib/spring-beans-1.2.9.jar
../lib/spring-context-1.2.9.jar
../lib/spring-core-1.2.9.jar
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-server-unit</artifactId>
@@ -22,16 +22,17 @@
</dependency>
<dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>nlog4j</artifactId>
- <scope>provided</scope>
- </dependency>
-
- <dependency>
<groupId>ldapsdk</groupId>
<artifactId>ldapsdk</artifactId>
<scope>test</scope>
</dependency>
+
+ <dependency>
+ <groupId>commons-net</groupId>
+ <artifactId>commons-net</artifactId>
+ <version>1.4.1</version>
+ <scope>test</scope>
+ </dependency>
<dependency>
<groupId>org.apache.directory.server</groupId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/KeyDerivationServiceITest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/KeyDerivationServiceITest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/KeyDerivationServiceITest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/KeyDerivationServiceITest.java Sat Jul 14 00:55:44 2007
@@ -84,7 +84,7 @@
// Add partition 'example'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "example" );
+ pcfg.setId( "example" );
pcfg.setSuffix( "dc=example,dc=com" );
Set<Object> indexedAttrs = new HashSet<Object>();
@@ -110,7 +110,7 @@
List<InterceptorConfiguration> list = configuration.getInterceptorConfigurations();
interceptorCfg.setName( KeyDerivationService.NAME );
- interceptorCfg.setInterceptor( new KeyDerivationService() );
+ interceptorCfg.setInterceptorClassName( "org.apache.directory.server.core.kerberos.KeyDerivationService" );
list.add( interceptorCfg );
configuration.setInterceptorConfigurations( list );
@@ -227,7 +227,8 @@
/**
- * Tests that the modification on an entry caused keys to be derived and modified.
+ * Tests that the modification of an entry caused keys to be derived and modified. The
+ * modify request contains both the 'userPassword' and the 'krb5PrincipalName'.
*
* @throws NamingException
* @throws IOException
@@ -335,6 +336,136 @@
attr = new AttributeImpl( "userPassword", newUserPassword );
attributes.put( attr );
attr = new AttributeImpl( KerberosAttribute.PRINCIPAL, newPrincipalName );
+ attributes.put( attr );
+
+ person = ( DirContext ) ctx.lookup( RDN );
+ person.modifyAttributes( "", DirContext.REPLACE_ATTRIBUTE, attributes );
+
+ // Read again from directory.
+ person = ( DirContext ) ctx.lookup( RDN );
+
+ attributes = person.getAttributes( "" );
+
+ if ( attributes.get( "userPassword" ) != null )
+ {
+ userPassword = ( byte[] ) attributes.get( "userPassword" ).get();
+ }
+
+ assertEquals( "password length", 24, userPassword.length );
+
+ if ( attributes.get( KerberosAttribute.VERSION ) != null )
+ {
+ keyVersionNumber = Integer.valueOf( ( String ) attributes.get( KerberosAttribute.VERSION ).get() );
+ }
+
+ assertEquals( "Key version number", 3, keyVersionNumber );
+ }
+
+
+ /**
+ * Tests that the modification of an entry caused keys to be derived and modified. The
+ * modify request contains only the 'userPassword'. The 'krb5PrincipalName' is to be
+ * obtained from the initial add of the user principal entry.
+ *
+ * @throws NamingException
+ * @throws IOException
+ */
+ public void testModifyDerivedKeysWithoutPrincipalName() throws NamingException, IOException
+ {
+ Hashtable<String, String> env = new Hashtable<String, String>();
+ env.put( Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory" );
+ env.put( Context.PROVIDER_URL, "ldap://localhost:" + port );
+
+ env.put( Context.SECURITY_AUTHENTICATION, "simple" );
+ env.put( Context.SECURITY_PRINCIPAL, "uid=hnelson,ou=users,dc=example,dc=com" );
+ env.put( Context.SECURITY_CREDENTIALS, "secret" );
+ env.put( "java.naming.ldap.attributes.binary", "krb5key" );
+
+ DirContext ctx = new InitialDirContext( env );
+
+ String newUserPassword = "secretsecret";
+
+ // Modify password.
+ Attributes attributes = new AttributesImpl( true );
+ Attribute attr = new AttributeImpl( "userPassword", newUserPassword );
+ attributes.put( attr );
+
+ DirContext person = ( DirContext ) ctx.lookup( RDN );
+ person.modifyAttributes( "", DirContext.REPLACE_ATTRIBUTE, attributes );
+
+ // Read again from directory.
+ person = ( DirContext ) ctx.lookup( RDN );
+
+ attributes = person.getAttributes( "" );
+
+ byte[] userPassword = null;
+
+ if ( attributes.get( "userPassword" ) != null )
+ {
+ userPassword = ( byte[] ) attributes.get( "userPassword" ).get();
+ }
+
+ // Could be 4 or 5 depending on whether AES-256 is enabled or not.
+ assertTrue( "Number of keys", attributes.get( "krb5key" ).size() > 3 );
+
+ byte[] testBytes =
+ { 0x73, 0x65, 0x63, 0x72, 0x65, 0x74, 0x73, 0x65, 0x63, 0x72, 0x65, 0x74 };
+ assertTrue( Arrays.equals( userPassword, testBytes ) );
+
+ Attribute krb5key = attributes.get( "krb5key" );
+ Map<EncryptionType, EncryptionKey> map = reconstituteKeyMap( krb5key );
+ EncryptionKey encryptionKey = map.get( EncryptionType.DES_CBC_MD5 );
+
+ byte[] testKeyBytes =
+ { ( byte ) 0x16, ( byte ) 0x4A, ( byte ) 0x6D, ( byte ) 0x89, ( byte ) 0x5D, ( byte ) 0x76, ( byte ) 0x0E,
+ ( byte ) 0x23 };
+
+ assertTrue( Arrays.equals( encryptionKey.getKeyValue(), testKeyBytes ) );
+ assertEquals( EncryptionType.DES_CBC_MD5, encryptionKey.getKeyType() );
+
+ int keyVersionNumber = -1;
+
+ if ( attributes.get( KerberosAttribute.VERSION ) != null )
+ {
+ keyVersionNumber = Integer.valueOf( ( String ) attributes.get( KerberosAttribute.VERSION ).get() );
+ }
+
+ assertEquals( "Key version number", 1, keyVersionNumber );
+
+ newUserPassword = "secretsecretsecret";
+
+ // Modify password.
+ attributes = new AttributesImpl( true );
+ attr = new AttributeImpl( "userPassword", newUserPassword );
+ attributes.put( attr );
+
+ person = ( DirContext ) ctx.lookup( RDN );
+ person.modifyAttributes( "", DirContext.REPLACE_ATTRIBUTE, attributes );
+
+ // Read again from directory.
+ person = ( DirContext ) ctx.lookup( RDN );
+
+ attributes = person.getAttributes( "" );
+
+ if ( attributes.get( "userPassword" ) != null )
+ {
+ userPassword = ( byte[] ) attributes.get( "userPassword" ).get();
+ }
+
+ assertEquals( "password length", 18, userPassword.length );
+
+ if ( attributes.get( KerberosAttribute.VERSION ) != null )
+ {
+ keyVersionNumber = Integer.valueOf( ( String ) attributes.get( KerberosAttribute.VERSION ).get() );
+ }
+
+ assertEquals( "Key version number", 2, keyVersionNumber );
+
+ newUserPassword = "secretsecretsecretsecret";
+
+ // Modify password.
+ attributes = new AttributesImpl( true );
+ attr = new AttributeImpl( "userPassword", newUserPassword );
attributes.put( attr );
person = ( DirContext ) ctx.lookup( RDN );
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/MiscTest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/MiscTest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/MiscTest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/MiscTest.java Sat Jul 14 00:55:44 2007
@@ -95,7 +95,7 @@
entry.put( oc );
oc.add( "top" );
oc.add( "domain" );
- partition.setName( "apache" );
+ partition.setId( "apache" );
partition.setContextEntry( entry );
partition.setIndexedAttributes( Collections.singleton( ( Object ) "dc" ) );
partitions.add( partition );
@@ -116,7 +116,7 @@
entry.put( oc );
oc.add( "top" );
oc.add( "domain" );
- partition.setName( "apache" );
+ partition.setId( "apache" );
partition.setContextEntry( entry );
partition.setIndexedAttributes( Collections.singleton( ( Object ) "dc" ) );
partitions.add( partition );
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/PasswordPolicyServiceITest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/PasswordPolicyServiceITest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/PasswordPolicyServiceITest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/PasswordPolicyServiceITest.java Sat Jul 14 00:55:44 2007
@@ -68,7 +68,7 @@
// Add partition 'example'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "example" );
+ pcfg.setId( "example" );
pcfg.setSuffix( "dc=example,dc=com" );
Set<Object> indexedAttrs = new HashSet<Object>();
@@ -94,7 +94,7 @@
List<InterceptorConfiguration> list = configuration.getInterceptorConfigurations();
interceptorCfg.setName( PasswordPolicyService.NAME );
- interceptorCfg.setInterceptor( new PasswordPolicyService() );
+ interceptorCfg.setInterceptorClassName( "org.apache.directory.server.core.kerberos.PasswordPolicyService" );
list.add( interceptorCfg );
configuration.setInterceptorConfigurations( list );
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslBindITest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslBindITest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslBindITest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslBindITest.java Sat Jul 14 00:55:44 2007
@@ -67,7 +67,7 @@
// Add partition 'example'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "example" );
+ pcfg.setId( "example" );
pcfg.setSuffix( "dc=example,dc=com" );
Set<Object> indexedAttrs = new HashSet<Object>();
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslGssapiBindITest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslGssapiBindITest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslGssapiBindITest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/SaslGssapiBindITest.java Sat Jul 14 00:55:44 2007
@@ -98,7 +98,7 @@
// Add partition 'example'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "example" );
+ pcfg.setId( "example" );
pcfg.setSuffix( "dc=example,dc=com" );
Set<Object> indexedAttrs = new HashSet<Object>();
@@ -124,7 +124,7 @@
List<InterceptorConfiguration> list = configuration.getInterceptorConfigurations();
interceptorCfg.setName( KeyDerivationService.NAME );
- interceptorCfg.setInterceptor( new KeyDerivationService() );
+ interceptorCfg.setInterceptorClassName( "org.apache.directory.server.core.kerberos.KeyDerivationService" );
list.add( interceptorCfg );
configuration.setInterceptorConfigurations( list );
Modified: directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/jndi/ServerContextFactoryTest.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/jndi/ServerContextFactoryTest.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/jndi/ServerContextFactoryTest.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/server-unit/src/test/java/org/apache/directory/server/jndi/ServerContextFactoryTest.java Sat Jul 14 00:55:44 2007
@@ -61,7 +61,7 @@
// Add partition 'testing'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "testing" );
+ pcfg.setId( "testing" );
pcfg.setSuffix( "ou=testing" );
indexedAttrs = new HashSet();
@@ -84,7 +84,7 @@
// Add partition 'example'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "example" );
+ pcfg.setId( "example" );
pcfg.setSuffix( "dc=example" );
indexedAttrs = new HashSet();
@@ -108,7 +108,7 @@
// Add partition 'MixedCase'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "mixedcase" );
+ pcfg.setId( "mixedcase" );
pcfg.setSuffix( "dc=MixedCase" );
indexedAttrs = new HashSet();
@@ -287,7 +287,7 @@
// Add partition 'test=testing'
pcfg = new MutablePartitionConfiguration();
- pcfg.setName( "testing" );
+ pcfg.setId( "testing" );
try
{
Propchange: directory/sandbox/ccustine/new_installers/apacheds/server-xml/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sat Jul 14 00:55:44 2007
@@ -0,0 +1,4 @@
+target
+.settings
+.classpath
+.project
Modified: directory/sandbox/ccustine/new_installers/apacheds/utils/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/utils/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/utils/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/utils/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.server</groupId>
- <artifactId>build</artifactId>
+ <artifactId>apacheds-parent</artifactId>
<version>1.5.1-SNAPSHOT</version>
</parent>
<artifactId>apacheds-utils</artifactId>
Modified: directory/sandbox/ccustine/new_installers/apacheds/utils/src/main/java/org/apache/directory/server/utils/AttributesFactory.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/apacheds/utils/src/main/java/org/apache/directory/server/utils/AttributesFactory.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/apacheds/utils/src/main/java/org/apache/directory/server/utils/AttributesFactory.java (original)
+++ directory/sandbox/ccustine/new_installers/apacheds/utils/src/main/java/org/apache/directory/server/utils/AttributesFactory.java Sat Jul 14 00:55:44 2007
@@ -137,7 +137,7 @@
{
Attributes entry = new AttributesImpl( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.TOP_OC, true );
entry.get( SchemaConstants.OBJECT_CLASS_AT ).add( MetaSchemaConstants.META_SYNTAX_OC );
- entry.put( MetaSchemaConstants.X_HUMAN_READIBLE_AT, getBoolean( syntax.isHumanReadible() ) );
+ entry.put( MetaSchemaConstants.X_HUMAN_READABLE_AT, getBoolean( syntax.isHumanReadable() ) );
entry.put( SchemaConstants.CREATORS_NAME_AT, schema.getOwner() );
entry.put( SchemaConstants.CREATE_TIMESTAMP_AT, DateUtils.getGeneralizedTime() );
injectCommon( syntax, entry );
@@ -316,7 +316,7 @@
*
* <pre>
* objectclass ( 1.3.6.1.4.1.18060.0.4.0.3.2
- * NAME 'metaObjectclass'
+ * NAME 'metaObjectClass'
* DESC 'meta definition of the objectclass object'
* SUP metaTop
* STRUCTURAL
Propchange: directory/sandbox/ccustine/new_installers/daemon/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sat Jul 14 00:55:44 2007
@@ -1,2 +1,3 @@
+target
workspace
*.iml
Modified: directory/sandbox/ccustine/new_installers/daemon/bootstrappers/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/daemon/bootstrappers/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/daemon/bootstrappers/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/daemon/bootstrappers/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.daemon</groupId>
- <artifactId>daemon</artifactId>
+ <artifactId>daemon-parent</artifactId>
<version>1.1.1-SNAPSHOT</version>
</parent>
<artifactId>daemon-bootstrappers</artifactId>
Modified: directory/sandbox/ccustine/new_installers/daemon/bootstrappers/src/main/java/org/apache/directory/daemon/Bootstrapper.java
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/daemon/bootstrappers/src/main/java/org/apache/directory/daemon/Bootstrapper.java?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/daemon/bootstrappers/src/main/java/org/apache/directory/daemon/Bootstrapper.java (original)
+++ directory/sandbox/ccustine/new_installers/daemon/bootstrappers/src/main/java/org/apache/directory/daemon/Bootstrapper.java Sat Jul 14 00:55:44 2007
@@ -110,21 +110,15 @@
URL[] jars = layout.getAllJars();
this.application = new URLClassLoader( jars, parentLoader );
- for ( int ii = 0; ii < jars.length; ii++ )
- {
- log.error( "Classloader jars are: " + jars[ii].toString() );
- }
-
if ( log.isDebugEnabled() )
{
StringBuffer buf = new StringBuffer();
buf.append( "Dependencies loaded by the application ClassLoader: \n" );
for ( int ii = 0; ii < jars.length; ii++ )
{
- log.error( "Classloader jars are: " + jars[ii].toString() );
buf.append( "\t" ).append( jars[ii] ).append( "\n" );
}
- log.error( "Classloader jars are: " + buf.toString() );
+ log.debug( buf.toString() );
}
}
Modified: directory/sandbox/ccustine/new_installers/daemon/plugin/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/daemon/plugin/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/daemon/plugin/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/daemon/plugin/pom.xml Sat Jul 14 00:55:44 2007
@@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.directory.daemon</groupId>
- <artifactId>daemon</artifactId>
+ <artifactId>daemon-parent</artifactId>
<version>1.1.1-SNAPSHOT</version>
</parent>
<artifactId>daemon-plugin</artifactId>
Modified: directory/sandbox/ccustine/new_installers/daemon/pom.xml
URL: http://svn.apache.org/viewvc/directory/sandbox/ccustine/new_installers/daemon/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/sandbox/ccustine/new_installers/daemon/pom.xml (original)
+++ directory/sandbox/ccustine/new_installers/daemon/pom.xml Sat Jul 14 00:55:44 2007
@@ -7,7 +7,7 @@
<version>7</version>
</parent>
<groupId>org.apache.directory.daemon</groupId>
- <artifactId>daemon</artifactId>
+ <artifactId>daemon-parent</artifactId>
<name>Apache Directory Daemon</name>
<packaging>pom</packaging>
<!-- note that this skipped a RC in being bumped up -->
@@ -28,6 +28,12 @@
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <version>1.4.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.slf4j</groupId>
<artifactId>nlog4j</artifactId>
<version>1.2.25</version>
</dependency>
@@ -42,6 +48,7 @@
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
+ <scope>test</scope>
</dependency>
<dependency>
Modified: directory/shared/trunk/asn1/pom.xml
URL: http://svn.apache.org/viewvc/directory/shared/trunk/asn1/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/shared/trunk/asn1/pom.xml (original)
+++ directory/shared/trunk/asn1/pom.xml Sat Jul 14 00:55:44 2007
@@ -21,8 +21,7 @@
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
- <artifactId>slf4j-simple</artifactId>
- <scope>provided</scope>
+ <artifactId>slf4j-api</artifactId>
</dependency>
</dependencies>
-->
Modified: directory/shared/trunk/pom.xml
URL: http://svn.apache.org/viewvc/directory/shared/trunk/pom.xml?view=diff&rev=556238&r1=556237&r2=556238
==============================================================================
--- directory/shared/trunk/pom.xml (original)
+++ directory/shared/trunk/pom.xml Sat Jul 14 00:55:44 2007
@@ -21,7 +21,6 @@
</modules>
<dependencies>
-
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
@@ -68,8 +67,9 @@
<groupId>org.slf4j</groupId>
<artifactId>nlog4j</artifactId>
<version>1.2.25</version>
+ <scope>test</scope>
</dependency>
-
+
<dependency>
<groupId>antlr</groupId>
<artifactId>antlr</artifactId>
@@ -80,6 +80,7 @@
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
+ <scope>test</scope>
</dependency>
<dependency>