From 688a9ffc80d3c6c21c9cf1b89b1a6d8ed7d0cc1d Mon Sep 17 00:00:00 2001
From: Valery Kharseko <vharseko@3a-systems.ru>
Date: Mon, 03 Mar 2025 13:24:49 +0000
Subject: [PATCH] [#208] FIX The definition for the attribute type declared that it should use the syntax which is not defined in the schema (#483)
---
opendj-core/src/main/java/org/forgerock/opendj/ldap/schema/CoreSchemaImpl.java | 35 +++++++++++++++++++++++++++++++++--
opendj-server-legacy/resource/schema/02-config.ldif | 10 +++++++++-
2 files changed, 42 insertions(+), 3 deletions(-)
diff --git a/opendj-core/src/main/java/org/forgerock/opendj/ldap/schema/CoreSchemaImpl.java b/opendj-core/src/main/java/org/forgerock/opendj/ldap/schema/CoreSchemaImpl.java
index ef018b8..7315787 100644
--- a/opendj-core/src/main/java/org/forgerock/opendj/ldap/schema/CoreSchemaImpl.java
+++ b/opendj-core/src/main/java/org/forgerock/opendj/ldap/schema/CoreSchemaImpl.java
@@ -14,6 +14,7 @@
* Copyright 2009-2010 Sun Microsystems, Inc.
* Portions copyright 2013-2016 ForgeRock AS.
* Portions copyright 2014 Manuel Gaupp
+ * Portions copyright 2025 3A Systems, LLC
*/
package org.forgerock.opendj.ldap.schema;
@@ -1582,6 +1583,14 @@
.extraProperties(RFC4512_ORIGIN)
.implementation(new BooleanSyntaxImpl())
.addToSchema();
+ //Expression syntax for Boolean
+ //
+ //Values of this syntax hold either a Boolean value, or a configuration expression that evaluates to a Boolean value.
+ builder.buildSyntax("1.3.6.1.4.1.36733.2.1.3.3.7")
+ .description(SYNTAX_BOOLEAN_DESCRIPTION)
+ .extraProperties(RFC4512_ORIGIN)
+ .implementation(new BooleanSyntaxImpl())
+ .addToSchema();
builder.buildSyntax(SYNTAX_COUNTRY_STRING_OID)
.description(SYNTAX_COUNTRY_STRING_DESCRIPTION)
@@ -1600,7 +1609,14 @@
.extraProperties(RFC4512_ORIGIN)
.implementation(new DirectoryStringSyntaxImpl())
.addToSchema();
-
+ //Expression syntax for Directory String
+ //
+ //Values of this syntax hold either an LDAP directory string value, or a configuration expression that evaluates to an LDAP directory string value.
+ builder.buildSyntax("1.3.6.1.4.1.36733.2.1.3.3.15")
+ .description(SYNTAX_DIRECTORY_STRING_DESCRIPTION)
+ .extraProperties(RFC4512_ORIGIN)
+ .implementation(new DirectoryStringSyntaxImpl())
+ .addToSchema();
builder.buildSyntax(SYNTAX_DIT_CONTENT_RULE_OID)
.description(SYNTAX_DIT_CONTENT_RULE_DESCRIPTION)
.extraProperties(RFC4512_ORIGIN)
@@ -1618,6 +1634,14 @@
.extraProperties(RFC4512_ORIGIN)
.implementation(new DistinguishedNameSyntaxImpl())
.addToSchema();
+ //Expression syntax for DN
+ //
+ //Values of this syntax hold either a DN value, or a configuration expression that evaluates to a DN value.
+ builder.buildSyntax("1.3.6.1.4.1.36733.2.1.3.3.12")
+ .description(SYNTAX_DN_DESCRIPTION)
+ .extraProperties(RFC4512_ORIGIN)
+ .implementation(new DistinguishedNameSyntaxImpl())
+ .addToSchema();
builder.buildSyntax(SYNTAX_ENHANCED_GUIDE_OID)
.description(SYNTAX_ENHANCED_GUIDE_DESCRIPTION)
@@ -1660,7 +1684,14 @@
.extraProperties(RFC4512_ORIGIN)
.implementation(new IntegerSyntaxImpl())
.addToSchema();
-
+ //Expression syntax for Integer
+ //
+ //Values of this syntax hold either an integer value, or a configuration expression that evaluates to an integer value.
+ builder.buildSyntax("1.3.6.1.4.1.36733.2.1.3.3.27")
+ .description(SYNTAX_INTEGER_DESCRIPTION)
+ .extraProperties(RFC4512_ORIGIN)
+ .implementation(new IntegerSyntaxImpl())
+ .addToSchema();
builder.buildSyntax(SYNTAX_JPEG_OID)
.description(SYNTAX_JPEG_DESCRIPTION)
.extraProperties(RFC4512_ORIGIN)
diff --git a/opendj-server-legacy/resource/schema/02-config.ldif b/opendj-server-legacy/resource/schema/02-config.ldif
index 697a1ae..a950d83 100644
--- a/opendj-server-legacy/resource/schema/02-config.ldif
+++ b/opendj-server-legacy/resource/schema/02-config.ldif
@@ -15,7 +15,7 @@
# Portions Copyright 2011 profiq, s.r.o.
# Portions Copyright 2012 Manuel Gaupp
# Portions copyright 2015 Edan Idzerda
-# Portions copyright 2023-2024 3A Systems LLC
+# Portions copyright 2023-2025 3A Systems LLC
# This file contains the attribute type and objectclass definitions for use
# with the Directory Server configuration.
@@ -23,6 +23,14 @@
objectClass: top
objectClass: ldapSubentry
objectClass: subschema
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.4 DESC 'Duration in milli-seconds' X-SUBST '1.3.6.1.4.1.1466.115.121.1.27' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.5 DESC 'Size in bytes' X-SUBST '1.3.6.1.4.1.1466.115.121.1.27' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.6 DESC 'Timer metric' X-SUBST '1.3.6.1.4.1.36733.2.1.3.1' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.7 DESC 'Summary metric' X-SUBST '1.3.6.1.4.1.36733.2.1.3.1' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.8 DESC 'Filesystem path' X-SUBST '1.3.6.1.4.1.1466.115.121.1.15' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.9 DESC 'CSN (Change Sequence Number)' X-SUBST '1.3.6.1.4.1.1466.115.121.1.15' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.10 DESC 'Counter metric' X-SUBST '1.3.6.1.4.1.1466.115.121.1.27' X-ORIGIN 'OpenDJ Directory Server' )
+ldapSyntaxes: ( 1.3.6.1.4.1.36733.2.1.3.11 DESC 'Host port' X-SUBST '1.3.6.1.4.1.1466.115.121.1.15' X-ORIGIN 'OpenDJ Directory Server' )
attributeTypes: ( 1.3.6.1.4.1.26027.1.1.1
NAME 'ds-cfg-java-class'
EQUALITY caseExactMatch
--
Gitblit v1.10.0