Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 584497 - RFE: Allow DNA plugin to set same value on multiple attributes
RFE: Allow DNA plugin to set same value on multiple attributes
Status: CLOSED CURRENTRELEASE
Product: 389
Classification: Retired
Component: Directory Server (Show other bugs)
1.2.6
All Linux
low Severity medium
: ---
: ---
Assigned To: Nathan Kinder
Viktor Ashirov
:
Depends On:
Blocks: 639035
  Show dependency treegraph
 
Reported: 2010-04-21 13:54 EDT by Rob Crittenden
Modified: 2015-12-07 11:37 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-12-07 11:37:31 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Proposed Patch (31.02 KB, patch)
2010-04-28 20:40 EDT, Nathan Kinder
nkinder: review?
rmeggins: review+
Details | Diff

  None (edit)
Description Rob Crittenden 2010-04-21 13:54:35 EDT
Description of problem:

In IPA we are trying to implement Magic Private Groups (MPG).

With MPG when a user is created a group is created with the same name and the gidNumber the same as the uidNumber.

Part of this is achieved with the Managed Entries plugin. The group is created/removed along with the user.

We currently use DNA to obtain a uidNumber (and gidNumber for new posix groups).

What we need for MPG is to set the gidNumber to the uidNumber when the user is created. This currently seems to happen prior to the Managed Entries plugin being executed which is a good thing, so we can use the gidNumber attribute from the user entry to populate the group entry.

Version-Release number of selected component (if applicable):

389-ds-base-1.2.6-0.3.a3.fc12.x86_64
Comment 1 Nathan Kinder 2010-04-28 20:40:02 EDT
Created attachment 409993 [details]
Proposed Patch

This patch allows one to set multiple dnaType attributes for a single
DNA range.  This allows the same value to be used for each dnaType
(such as ensuring the uidNumber and gidNumber are the same value
from the range when ading a posixAccount).

There are some differences with the way DNA works for multi-type
ranges.  For a value to be generated from a multi-type range, the
magic value must be specified to indicate which attributes should
use the newly generated value.  This allows a range to be shared
across different entry types (such as having a uidNumber/gidNumber
range that is used or posixAccount and posixGroup entries).  A
multi-type range will not generate a value for missing attributes
as DNA does for single-type ranges.

Since a range can have multiple types, the internal ordering of
config structs had to be changed to order by scope only.  It was
previously ordered by type and then scope, which allowed us to
easily detect if we had already generated a value for a given type.
This change required a number of helper functions to be added for
tracking and checking which types we have already generated values
for.
Comment 4 Nathan Kinder 2010-04-30 13:19:27 EDT
Pushed to master.  Thanks to Rich for his review!

Counting objects: 13, done.
Delta compression using 2 threads.
Compressing objects: 100% (7/7), done.
Writing objects: 100% (7/7), 4.96 KiB, done.
Total 7 (delta 5), reused 0 (delta 0)
To ssh://git.fedorahosted.org/git/389/ds.git
   0501282..a0b60b0  master -> master
Comment 6 Amita Sharma 2011-07-08 08:56:13 EDT
DNA startup 	100% (1/1) 	  	 
DNA run 	100% (61/61) 	  	 
DNA cleanup 	100% (1/1)

Hence VERIFIED.

Note You need to log in before you can comment on or make changes to this bug.