Issue 7446 - slapadd OBSOLETE object class fails
Summary: slapadd OBSOLETE object class fails
Status: UNCONFIRMED
Alias: None
Product: OpenLDAP
Classification: Unclassified
Component: slapd (show other issues)
Version: unspecified
Hardware: All All
: --- normal
Target Milestone: ---
Assignee: OpenLDAP project
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-19 21:24 UTC by Michael Ströder
Modified: 2020-09-21 22:35 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Michael Ströder 2012-11-19 21:24:43 UTC
Full_Name: Michael Str�der
Version: HEAD
OS: 
URL: 
Submission from: (NULL) (79.227.170.198)


Importing an LDIF file with slapadd which contains entries with an object class
marked as OBSOLETE in the schema fails.

Importing entries with OBSOLETE attribute types seems to work just fine.

If object classes are marked as OBSOLETE it's clear that it should be impossible
to add new entries via LDAP based on such an object class. But it should still
be possible to restore old entries from backup.
Comment 1 ando@openldap.org 2012-11-19 21:48:29 UTC
> Full_Name: Michael Ströder
> Version: HEAD
> OS:
> URL:
> Submission from: (NULL) (79.227.170.198)
>
>
> Importing an LDIF file with slapadd which contains entries with an object
> class
> marked as OBSOLETE in the schema fails.
>
> Importing entries with OBSOLETE attribute types seems to work just fine.
>
> If object classes are marked as OBSOLETE it's clear that it should be
> impossible
> to add new entries via LDAP based on such an object class. But it should
> still
> be possible to restore old entries from backup.

Currently, slap_tool_entry_check() sets "manage" to 0 when calling
entry_schema_check(); setting it to !0 would allow loading of OBSOLETE
objectClasses.  Maybe "manage" should be passed to
slap_tool_entry_check(), and write tools (slapadd, slapmodify) could have
an explicit '-o manage' option to enable handling of these cases.

p.

-- 
Pierangelo Masarati
Associate Professor
Dipartimento di Ingegneria Aerospaziale
Politecnico di Milano

Comment 2 Michael Ströder 2012-11-19 22:12:16 UTC
masarati@aero.polimi.it wrote:
> Maybe "manage" should be passed to
> slap_tool_entry_check(), and write tools (slapadd, slapmodify) could have
> an explicit '-o manage' option to enable handling of these cases.

I'd regard slapadd to be in kind of a manage mode by default. E.g. it does not
check constraints. And as said OBSOLETE attribute types are already accepted.

Ciao, Michael.

Comment 3 OpenLDAP project 2017-04-13 15:25:12 UTC
Need to review slapadd behavior in this case.  Possibly add -o manage option to
flip the manage bit to true
Comment 4 Quanah Gibson-Mount 2017-04-13 15:25:12 UTC
changed notes
moved from Incoming to Software Bugs