Following code removes NO_UPG_MAGIC from description when --noprivate option is used.
# delete description attribute NO_UPG_MAGIC if present if options.get('noprivate', False): if not options.get('all', False): desc_attr = ldap.get_entry(dn, ['description']) entry_attrs.update(desc_attr) if 'description' in entry_attrs and NO_UPG_MAGIC in entry_attrs['description']: entry_attrs['description'].remove(NO_UPG_MAGIC) kw = {'setattr': unicode('description=%s' % ','.join(entry_attrs['description']))} try: self.api.Command['user_mod'](keys[-1], **kw) except (errors.EmptyModlist, errors.NotFound): pass
It uses user-mod to achieve this action, what is very heavy way. ldap.update_entry() call should be enough.
Also would be great to have creation users resolved in different way, that do not require additional 1-2 searches in post callback.
Linked to Bugzilla bug: https://bugzilla.redhat.com/show_bug.cgi?id=1298288 (Red Hat Enterprise Linux 7)
4.4.0 was released, moving open tickets to 4.4.1
Moving to next major version. Fixing this bug is not critical in stabilization release.
Metadata Update from @mbasti: - Issue assigned to mbasti - Issue set to the milestone: FreeIPA 4.5
Metadata Update from @mbasti: - Issue close_status updated to: None - Issue set to the milestone: FreeIPA 4.5.1 (was: FreeIPA 4.5)
Metadata Update from @tdudlak: - Custom field component reset (from IPA) - Custom field keywords reset (from performance) - Custom field on_review reset (from 0) - Custom field rhbz reset (from https://bugzilla.redhat.com/show_bug.cgi?id=1298288) - Custom field test_coverage reset (from no) - Custom field type reset (from defect)
Metadata Update from @stlaz: - Custom field component adjusted to IPA - Custom field keywords adjusted to performance - Custom field rhbz adjusted to https://bugzilla.redhat.com/show_bug.cgi?id=1298288 - Custom field test_coverage adjusted to no - Custom field type adjusted to defect
Metadata Update from @stlaz: - Issue assigned to tdudlak (was: mbasti)
Metadata Update from @stlaz: - Assignee reset
Metadata Update from @tdudlak: - Custom field component reset (from IPA) - Custom field keywords reset (from performance) - Custom field rhbz reset (from https://bugzilla.redhat.com/show_bug.cgi?id=1298288) - Custom field test_coverage reset (from no) - Custom field type reset (from defect) - Issue assigned to tdudlak
Metadata Update from @mbasti: - Issue set to the milestone: FreeIPA 4.5.2 (was: FreeIPA 4.5.1)
FreeIPA 4.5.1 has been released, moving to FreeIPA 4.5.2 milestone
master:
ipa-4-5:
Metadata Update from @mbasti: - Issue close_status updated to: fixed - Issue status updated to: Closed (was: Open)
Log in to comment on this ticket.