From c781e8a57d3d05fa07729dbccff07bc1fab9d8e8 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Mon, 10 Aug 2009 16:24:10 -0400 Subject: Add a new objectclass, ipaObject, that will add a UUID to many IPA objects ipaObject is defined as an auxiliary objectclass so it is up to the plugin author to ensure that the objectclass is included an a UUID generated. ipaUniqueId is a MUST attribute so if you include the objectclass you must ensure that the uuid is generated. This also fixes up some unrelated unit test failures. --- ipalib/plugins/netgroup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ipalib/plugins/netgroup.py') diff --git a/ipalib/plugins/netgroup.py b/ipalib/plugins/netgroup.py index 9a2d750c..4aac0271 100644 --- a/ipalib/plugins/netgroup.py +++ b/ipalib/plugins/netgroup.py @@ -69,9 +69,9 @@ class netgroup_add(basegroup_add): ldap = self.api.Backend.ldap2 entry_attrs = self.args_options_2_entry(cn, **kw) - entry_attrs['ipauniqueid'] = str(uuid.uuid1()) - entry_attrs['objectclass'] = ['top', 'ipaassociation', _default_class] + entry_attrs['objectclass'] = ['top', 'ipaobject', 'ipaassociation', _default_class] entry_attrs.setdefault('nisdomainname', self.api.env.domain) + entry_attrs['ipauniqueid'] = str(uuid.uuid1()) dn = ldap.make_dn(entry_attrs, 'ipauniqueid', _container_dn) -- cgit