Skip to Content.
Sympa Menu

grouper-users - Re: [grouper-users] Re: posixGroup provisioning through psp

Subject: Grouper Users - Open Discussion List

List archive

Re: [grouper-users] Re: posixGroup provisioning through psp


Chronological Thread 
  • From: Jeffrey Crawford <>
  • To: David Langenberg <>
  • Cc: Chris Hyzer <>, Gouper Users List <>
  • Subject: Re: [grouper-users] Re: posixGroup provisioning through psp
  • Date: Fri, 14 Nov 2014 12:54:25 -0800

Since I needed to POC posix groups I went ahead and created a DB resolver to just grab the id_index from the repository and return it using the the group's name as a reference, I'll post here for posterity:

psp-resolver.xml
----------------------------------------------------------------------------------------------------
  <!-- Tying into the repository database which may change in the future so no guarantees this will -->
  <!-- continue to work in the future, queryTimeout="0" is needed for PostgreSQL                    -->
  <resolver:DataConnector id="groupAttrs" xsi:type="dc:RelationalDatabase" queryTimeout="0" >

      <resolver:Dependency ref="GroupWithoutMermbershipsDataConnector" />
      <dc:ApplicationManagedConnection jdbcDriver="org.postgresql.Driver"
                                       jdbcURL="jdbc:postgresql://hostname:5432/somedb"
                                       jdbcUserName="someuser"
                                       jdbcPassword="secret" />

      <dc:QueryTemplate>
          <![CDATA[
              SELECT id,name,id_index FROM grouper_groups WHERE name = '$name.get(0)'
          ]]>
      </dc:QueryTemplate>

      <dc:Column columnName="id" attributeID="id" />
      <dc:Column columnName="id_index" attributeID="gidNumber" type="String" />
  </resolver:DataConnector>

  <resolver:AttributeDefinition
    id="groupGidNumber"
    xsi:type="ad:Simple"
    sourceAttributeID="gidNumber">
    <resolver:Dependency ref="groupAttrs" />
  </resolver:AttributeDefinition>
----------------------------------------------------------------------------------------------------

psp.xml
----------------------------------------------------------------------------------------------------
.
.
.
    <!-- The ldap group "id_index" attribute. (Hint: use for posixGroups) -->
    <attribute
      name="gidNumber"
      ref="groupGidNumber" />
.
.
.
----------------------------------------------------------------------------------------------------


Jeffrey

Both pilots and IT professionals require training and currency before charging into clouds!
---------------------------------------

On Fri, Nov 14, 2014 at 10:38 AM, David Langenberg <> wrote:
Ok, I'll take a peek at this again and let you know.

Stay tuned.

Dave

On Thu, Nov 13, 2014 at 12:54 PM, Jeffrey Crawford <> wrote:
Yes I just upgraded from 2.2.0 to 2.2.1.

I've tried defining the following in the psp-resolver but I'm still not able to map the idIndex to a gidNumber, so far I've tried the attribute name IntegerID from the Jira ticket and idIndex referenced in the page https://spaces.internet2.edu/display/Grouper/Integer+IDs+on+Grouper+objects neither seems to yield an actual number though:

psp.xml
--------------------------
.
.
.
    <!-- The ldap group "IndexID" attribute. (Hint use for posixGroups) -->
    <attribute
      name="gidNumber"
      ref="groupIdIndex" />
.
.
.
--------------------------

psp-resolver.xml
--------------------------
  <!-- The value of the group "idIndex" attribute is the group index ID in the UI:. -->
  <resolver:AttributeDefinition
    id="groupIdIndex"
    xsi:type="ad:Simple"
    sourceAttributeID="idIndex">
    <resolver:Dependency ref="GroupWithoutMermbershipsDataConnector" />
    <resolver:Dependency ref="UpdateGroupIdIndexChangeLogDataConnector" />
  </resolver:AttributeDefinition>

.
.
.

  <!-- Returns change log attributes representing the changing of a group's idIndex. -->
  <resolver:DataConnector
    id="UpdateGroupIdIndexChangeLogDataConnector"
    xsi:type="psp-grouper-changelog:ChangeLogDataConnector">
    <!-- The AND filter matches both child filters. -->
    <grouper:Filter xsi:type="grouper:AND">
      <!-- The ChangeLogEntry filter matches change log entries with the given category and action. -->
      <grouper:Filter
        xsi:type="psp-grouper-changelog:ChangeLogEntry"
        category="group"
        action=""updateGroup"" />
      <!-- The ChangeLogExactAttribute filter matches change log entries with the given attribute and value. -->
      <grouper:Filter
        xsi:type="psp-grouper-changelog:ChangeLogExactAttribute"
        name="propertyChanged"
        value="idIndex" />
    </grouper:Filter>
  </resolver:DataConnector>
----------------------------

Jeffrey



--
David Langenberg
Identity & Access Management
The University of Chicago




Archive powered by MHonArc 2.6.16.

Top of Page