|
InvalidAttributeValueException: SINGLE-VALUEd attribute type |
|
Subject: InvalidAttributeValueException: SINGLE-VALUEd attribute type
Author: eLDAP
In response to: SchemaViolationException: Missing Required Attribute Type
Posted on: 08/10/2006 03:37:37 AM
++++++++++++++++++++++++++++++++++ + + Test Run #3: Attribute Value: SINGLE-VALUE + ++++++++++++++++++++++++++++++++++
dn: cn=Joe Smith,cn=users,dc=mydomain,dc=com
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: inetOrgperson
cn: Joe Smith
sn: Smith
givenname: Joe
mail: bsmith@mydomain.com
employeeNumber: 123-45-6789
employeeNumber: 999-99-9999
-- Results From AD --javax.naming.directory.InvalidAttributeValueException: [LDAP: error code 19 - 00002081: AtrErr: DSID-03151122, #1: 0: 00002081: DSID-03151122, problem 1005 (CONSTRAINT_ATT_TYPE), data 0, Att 20262 (employeeNumber)]; remaining name 'cn=Joe Smith,cn=users,dc=mydomain,dc=com' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3001) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2934) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2740) at com.sun.jndi.ldap.LdapCtx.c_createSubcontext(LdapCtx.java:777) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_createSubcontext(ComponentDirContext.java:319) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:248) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:236) at javax.naming.directory.InitialDirContext.createSubcontext(InitialDirContext.java:176) -- Results From SunOne --javax.naming.directory.SchemaViolationException: [LDAP: error code 65 - Object Class Violation]; remaining name 'cn=Joe Smith,cn=users,dc=mydomain,dc=com' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3019) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2934) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2740) at com.sun.jndi.ldap.LdapCtx.c_createSubcontext(LdapCtx.java:777) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_createSubcontext(ComponentDirContext.java:319) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:248) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:236) at javax.naming.directory.InitialDirContext.createSubcontext(InitialDirContext.java:176) Why The entry's attribute type 'employeenumber' is defined as SINGLE-VALUE in the schema and thereafter it cannot bear more than one value. That's why AD and SunOne both forbid it being added with '123-45-6789' and '999-99-9999' as employeenumber's values.
>
> On 08/10/2006 03:24:56 AM eLDAP wrote:
++++++++++++++++++++++++++++++++++ + + Test Run #2: Missing Required Attribute Type (sn) + ++++++++++++++++++++++++++++++++++
dn: cn=Joe Smith,cn=users,dc=mydomain,dc=com
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: inetOrgperson
cn: Joe Smith
givenname: Joe
mail: bsmith@mydomain.com
-- Results From AD -- OK
-- Results From SunOne -- javax.naming.directory.SchemaViolationException: [LDAP: error code 65 - Object Class Violation]; remaining name 'cn=Joe Smith,cn=users,dc=mydomain,dc=com' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3019) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2934) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2740) at com.sun.jndi.ldap.LdapCtx.c_createSubcontext(LdapCtx.java:777) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_createSubcontext(ComponentDirContext.java:319) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:248) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.createSubcontext(PartialCompositeDirContext.java:236) at javax.naming.directory.InitialDirContext.createSubcontext(InitialDirContext.java:176)
Why The entry's attribute type 'sn' is specified in the MUST list of object class 'person' and thereafter it is required. That's why SunOne forbid it being added. It seems that AD does not care about the MUST list.
References:
|
|
|
|