00-core.ldif: X.501, cl. 14.2.2: 2.5.15.16 subentryNameForm OC subentry MUST cn (#448)
| | |
| | | # Copyright 2006-2010 Sun Microsystems, Inc. |
| | | # Portions Copyright 2011-2016 ForgeRock AS. |
| | | # Portions Copyright 2013-2014 Manuel Gaupp |
| | | # Portions Copyright 2024 3A Systems, LLC |
| | | |
| | | # This file contains a core set of attribute type and objectlass definitions |
| | | # from several standard LDAP documents (primarily RFCs and IETF Internet |
| | |
| | | objectClasses: ( 1.2.826.0.1.3458854.2.1.1 NAME 'groupOfEntries' SUP top |
| | | STRUCTURAL MUST cn MAY ( member $ businessCategory $ seeAlso $ owner $ ou $ |
| | | o $ description ) X-ORIGIN 'draft-findlay-ldap-groupofentries' ) |
| | | |
| | | nameForms: ( 2.5.15.16 |
| | | NAME 'subentryNameForm' |
| | | DESC 'X.501, cl. 14.2.2: the Subentry name form' |
| | | OC subentry |
| | | MUST cn ) |
| | |
| | | "subtreeSpecification: {}", |
| | | "cn: test-subentry" |
| | | ); |
| | | //add OC subentry without DSR (warning level) |
| | | //Entry o=test-subentry2,ou=Accounts,dc=example,dc=com violates the Directory Server schema configuration because its RDN does not contain attribute cn that is required by name form subentryNameForm |
| | | assertThrows(new ThrowingRunnable() { |
| | | @Override |
| | | public void run() throws Throwable { |
| | | TestCaseUtils.addEntry( |
| | | "dn: o=test-subentry2,ou=Accounts,dc=example,dc=com", |
| | | "objectClass: top", |
| | |
| | | "subtreeSpecification: {}", |
| | | "cn: test-subentry2" |
| | | ); |
| | | |
| | | } |
| | | } |
| | | ); |
| | | int resultCode = TestCaseUtils.applyModifications(true, |
| | | "dn: cn=schema", |
| | | "changetype: modify", |
| | | "add: nameForms", |
| | | "nameForms: ( 2.5.15.16\n"+ |
| | | " NAME 'subentryNameForm'\n"+ |
| | | " DESC 'X.501, cl. 14.2.2: the Subentry name form'\n"+ |
| | | " OC subentry\n"+ |
| | | " MUST cn )", |
| | | "-", |
| | | "add: ditStructureRules", |
| | | "dITStructureRules: ( 177\n"+ |
| | | " NAME 'subentryStructure'\n"+ |