Please review (take 3): [Bug 612771] RHDS 8.1/389 v1.2.5 accepts 2 identical entries with different DN formats
by Noriko Hosoi
https://bugzilla.redhat.com/show_bug.cgi?id=612771
https://bugzilla.redhat.com/attachment.cgi?id=432203&action=diff
https://bugzilla.redhat.com/attachment.cgi?id=432203&action=edit
(In reply to comment #7)
> > (From update of attachment 431976 [details])
> > An entry may already have an nsUniqueID attribute - in that case, we should use
> > it. I was hoping we could use an attribute already in the entry for the
> > renaming - I guess when you're not using replication, the nsUniqueID is not
> > generated? If so, perhaps we could just use entryid instead of nsuniqueid?
>
Thanks, Rich! Fixed it. I confirmed nsUniqueId is always assigned regardless
of the replication use. Now, upgradednformat utility picks up UUID from the
entry and add nsuniqueid=<UUID> to the DN if duplicated DN is found. (The
upgrade fails if UUID is not found in the entry, which should not happen.)
Since it always uses the existing UUID, we don't have to reindex nsuniqueid.
Thus, I removed the following special treatment for nsuniqueid since it is not
needed any longer.
> > Also, at
> > https://bugzilla.redhat.com/attachment.cgi?id=431976&action=diff#a/ldap/s...
> > - nsuniqueid will never have a DN value?
>
Thanks,
--noriko
13 years, 2 months
Please review: [Bug 612771] RHDS 8.1/389 v1.2.5 accepts 2 identical entries with different DN formats
by Noriko Hosoi
https://bugzilla.redhat.com/show_bug.cgi?id=612771
https://bugzilla.redhat.com/attachment.cgi?id=431626&action=diff
https://bugzilla.redhat.com/attachment.cgi?id=431626&action=edit
http://directory.fedoraproject.org/wiki/Upgrade_to_New_DN_Format#Another_...
Fix Description:
This patch fixes the upgradednformat utility to eliminate the
duplicated DNs found in the upgrading time. If DN: attr0=value0,
attr1=value1,...,attrn=valuen exists in the DB and identical DN
is found, the second DN is renamed to attr0=dup_value0,attr1=value1,
...,attrn=valuen. The modification is logged in the error log.
Detailed Change Description:
70upgradednformat.pl - replaced the server up/down checking code
with the conservative algorithm.
ancestorid.c - When creating a new ancestorid index file, changed
to truncate (initialize) the file.
back-ldbm.h - introduced a new macro DBOPEN_TRUNCATE to specify
the truncated db open (used for opening ancestorid)
introduced an error code LDBM_ERROR_FOUND_DUPDN to
represent the duplicated DN error.
dblayer.c - added a code to open a db file with the truncated
option (DB_TRUNCATE).
import-threads.c - instead of e_deleted_attrs, use e_aux_attrs
to stash attributes to delete in the worker
thread and/or entrydn and parentid foreman
function.
upgradedn_producer - for the UPGRADEDNFORMAT mode, use
obsolete dn normalizer to distinguish
the duplicated DNs.
foreman_do_parentid - in case parent& child relationship
has been updated in the upgradednformat,
takes care of the changes.
foreman_do_entrydn - if a duplicated DN is detected, return
the specific error code LDBM_ERROR_FOUND_DUPDN.
import_foreman - if received LDBM_ERROR_FOUND_DUPDN
from foreman_do_entrydn, replace the DN
to<leaf_attr>=dup_<leaf_value>,<rest> and
pass it to foreman_do_entrydn again.
- enabled the parentid index update
(foreman_do_parentid) for the
UPGRADEDNFORMAT case, too.
import.c - for the UPGRADEDNFORMAT mode, only indexes which
associates with the DN syntax attribute were
reindexed. CN and OU are added to the list.
import.h - added a macro IMPORT_ADD_OP_ATTRS_SAVE_OLD_PID to
specify the original parentid is stored in e_aux_attrs
before replaced with the new one, which is used in
foreman_do_parentid.
ldif2ldbm.c - add_op_attrs - if the macro IMPORT_ADD_OP_ATTRS_SAVE_OLD_PID
is passed, the parentid is set to e_aux_attrs.
ldbm_back_ldbm2index - initialized the local txn object.
dn.c - resurrected once dead old slapi_dn_normalize as
slapi_dn_normalize_original used in upgradedn_producer.
entry.c - create an entry using the obsolete dn normalizer
slapi_dn_normalize_original if
SLAPI_STR2ENTRY_USE_OBSOLETE_DNFORMAT flag is passed.
slap.h - introduced e_aux_attrs to Slapi_Entry
slapi-plugin.h - defined a macro SLAPI_STR2ENTRY_USE_OBSOLETE_DNFORMAT
13 years, 2 months
Please review: [Bug 610281] fix coverity Defect Type: Control flow issues
by Noriko Hosoi
https://bugzilla.redhat.com/show_bug.cgi?id=610281
Attachments
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429110> (1.53 KB, patch)
2010-07-02 12:42 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429110>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429110&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429110&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429117> (1.12 KB, patch)
2010-07-02 13:06 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429117>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429117&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429117&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429121> (1.54 KB, patch)
2010-07-02 13:32 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429121>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429121&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429121&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429127> (1.88 KB, patch)
2010-07-02 13:48 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429127>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429127&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429127&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429131> (1.54 KB, patch)
2010-07-02 14:05 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429131>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429131&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429131&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429139> (1.64 KB, patch)
2010-07-02 14:37 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429139>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429139&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429139&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429143> (1.38 KB, patch)
2010-07-02 14:47 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429143>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429143&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429143&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429159> (2.27 KB, patch)
2010-07-02 16:38 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429159>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429159&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429159&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429165> (1.79 KB, patch)
2010-07-02 16:55 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429165>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429165&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429165&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429183> (6.19 KB, patch)
2010-07-02 18:16 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429183>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429183&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429183&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429187> (2.83 KB, patch)
2010-07-02 18:47 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429187>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429187&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429187&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429188> (2.38 KB, patch)
2010-07-02 19:05 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429188>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429188&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429188&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429189> (1.47 KB, patch)
2010-07-02 19:17 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429189>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429189&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429189&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429192> (1.22 KB, patch)
2010-07-02 19:29 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429192>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429192&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429192&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429193> (1.32 KB, patch)
2010-07-02 19:37 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429193>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429193&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429193&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429199> (1.86 KB, patch)
2010-07-02 20:17 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429199>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429199&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429199&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429201> (1.30 KB, patch)
2010-07-02 20:25 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429201>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429201&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429201&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429202> (1.18 KB, patch)
2010-07-02 20:40 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429202>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429202&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429202&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429203> (1.18 KB, patch)
2010-07-02 20:47 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429203>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429203&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429203&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=429205> (1.07 KB, patch)
2010-07-02 21:00 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_429205>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=429205&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=429205&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430208> (1.43 KB, patch)
2010-07-07 20:41 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430208>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430208&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430208&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430209> (1.40 KB, patch)
2010-07-07 20:54 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430209>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430209&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430209&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430211> (1.63 KB, patch)
2010-07-07 21:08 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430211>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430211&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430211&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430212> (1.63 KB, patch)
2010-07-07 21:20 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430212>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430212&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430212&action=diff>
*git* <https://bugzilla.redhat.com/attachment.cgi?id=430428> (2.78 KB,
patch)
2010-07-08 13:22 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430428>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430428&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430428&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430435> (2.43 KB, patch)
2010-07-08 13:54 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430435>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430435&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430435&action=diff>
*git patch file (master)*
<https://bugzilla.redhat.com/attachment.cgi?id=430438> (1.74 KB, patch)
2010-07-08 14:06 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430438>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430438&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430438&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430442> (2.72 KB, patch)
2010-07-08 14:30 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430442>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430442&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430442&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430445> (2.91 KB, patch)
2010-07-08 15:13 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430445>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430445&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430445&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430450> (1.11 KB, patch)
2010-07-08 15:22 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430450>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430450&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430450&action=diff>
*git patch file (9.0)*
<https://bugzilla.redhat.com/attachment.cgi?id=430462> (9.83 KB, patch)
2010-07-08 16:27 EDT
<https://bugzilla.redhat.com/show_bug.cgi?id=610281#attach_430462>,
Noriko Hosoi <mailto:nhosoi@redhat.com> /no flags/ Details
<https://bugzilla.redhat.com/attachment.cgi?id=430462&action=edit> |
Diff <https://bugzilla.redhat.com/attachment.cgi?id=430462&action=diff>
Thanks,
--noriko
13 years, 2 months