Hi,

When a user is created in eDir, I want to copy the Group Membership
attribute (and Security Equal) from other user already present in eDir
that we call "template user".


I'm using the Loopback driver for it, and trying with the XPath
expressions but without success.

My actual rule shows:

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE policy PUBLIC
"policy-builder-dtd" "C:\Archivos de
programa\Novell\Designer\eclipse\plugins\com.novel l.designer.idm.policyb
uilder_2.0.0.200710261247\DTD\dirxmlscript.dtd"><p olicy>
<rule>
<description>CloneGroupMembership</description>
<comment xml:space="preserve">Clonar la pertenencia a grupos del
usuario indicado en GodoCloneGroupMembership</comment>
<conditions>
<and>
<if-class-name mode="nocase" op="equal">User</if-class-name>
<if-operation mode="case" op="equal">add</if-operation>
<if-op-attr name="GodoCloneGroupMembership" op="available"/>
</and>
</conditions>
<actions>
<do-set-local-variable name="CloneGroupMembership" scope="policy">
<arg-string>
<token-src-attr name="GodoCloneGroupMembership"/>
</arg-string>
</do-set-local-variable>
<do-set-local-variable name="CopiaGrupos" scope="policy">
<arg-node-set>
<token-xpath expression='query:readObject($srcQueryProcessor, "",
$CloneGroupMembership, "", "Group Membership")'/>
</arg-node-set>
</do-set-local-variable>
<do-for-each>
<arg-node-set>
<token-xpath expression="$CopiaGrupos/attr/value"/>
</arg-node-set>
<arg-actions>
<do-add-src-attr-value name="Group Membership">
<arg-value>
<token-local-variable name="CopiaGrupos"/>
</arg-value>
</do-add-src-attr-value>
</arg-actions>
</do-for-each>
<do-clone-op-attr dest-name="Security Equals" src-name="Group
Membership"/>
</actions>
</rule>
</policy>


It's reading the source attribute correctly, but putting all the groups
as a concatenaded string to the destination attribute, in spite of put
them as a multivalued attribute.

I'm not used to XPath, so any help will be very appreciated.

Regards
Jose Luis

--