<div dir="ltr">Hi Dilek,<div><br></div><div>according to error log it seems that you are using variable "legal" in <b>inbound </b>mapping. IMHO legal variable is accessible only in outbound mapping. You can also try this trick <a href="https://stackoverflow.com/questions/216484/how-do-i-enumerate-all-the-defined-variables-in-a-groovy-script">https://stackoverflow.com/questions/216484/how-do-i-enumerate-all-the-defined-variables-in-a-groovy-script</a> to see all available variables in given groovy scope.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-08-11 10:52 GMT+02:00 Dilek Gider <span dir="ltr"><<a href="mailto:dilek.gider@basistek.com" target="_blank">dilek.gider@basistek.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Oskar,<div><br></div><div>I have an error on my resource like below:</div><div><br></div><div>SystemException: groovy.lang.<wbr>MissingPropertyException: No such property: legal for class: Script155 expression in mapping in inbound mapping for activation/<wbr>administrativeStatus in resource:ef2bc59b-76e0-48e2-<wbr>86d6-3d4f02d420db ({.../common/common-3}input=<wbr>PPV(ActivationStatusType:<wbr>ENABLED); ) in expression in mapping in inbound mapping for activation/<wbr>administrativeStatus in resource:ef2bc59b-76e0-48e2-<wbr>86d6-3d4f02d420db<br><div class="gmail_extra"><br></div><div class="gmail_extra">Midpoint version is 3.4.1, I have read link about Disable instead of Delete, and looked for example, there is no extra import needed for this.</div><div class="gmail_extra">Is it compatible with 3.4.1 version?</div><div><div class="h5"><div class="gmail_extra"><br></div><div class="gmail_extra"><div class="gmail_quote">On Fri, Jul 28, 2017 at 12:13 PM, Dilek Gider <span dir="ltr"><<a href="mailto:dilek.gider@basistek.com" target="_blank">dilek.gider@basistek.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Ok Oskar, I will try and reply, thank you very much.<br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 28, 2017 at 12:10 PM, Oskar Butovič - AMI Praha a.s. <span dir="ltr"><<a href="mailto:oskar.butovic@ami.cz" target="_blank">oskar.butovic@ami.cz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div style="font-size:12.8px"><font size="1"><source></font></div><div style="font-size:12.8px"><font size="1">                  <c:path>activation/effectiveSt<wbr>atus</c:path></font></div><div style="font-size:12.8px"><font size="1">               </source></font></div><div style="font-size:12.8px"><font size="1"><br></font></div><div style="font-size:12.8px"><font size="1">This should work.</font></div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-07-28 11:06 GMT+02:00 Dilek Gider <span dir="ltr"><<a href="mailto:dilek.gider@basistek.com" target="_blank">dilek.gider@basistek.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hello Oskar,<div><br></div><div>Thank you for your reply fast.</div><div>You mean that, I have to add new <source> to DN attribute mapping, then, in the script generate if-else condition to DN generation, right? </div><div>But how can I get "admisitrativestatustype.disab<wbr>le" parameter value to <source>? is it like this:</div><div><pre style="white-space:pre-wrap;color:rgb(0,0,0)"><source>
<path>$user/activation/adminis<wbr>trativeStatus</path>
</source></pre></div><div>My DN generation is below:</div><div><br></div><div><div><font size="1"> <attribute></font></div><div><font size="1">            <c:ref>ri:dn</c:ref></font></div><div><font size="1">            <displayName>Distinguished Name</displayName></font></div><div><font size="1">            <matchingRule xmlns:mr="<a href="http://prism.evolveum.com/xml/ns/public/matching-rule-3" target="_blank">http://prism.evolveu<wbr>m.com/xml/ns/public/matching-r<wbr>ule-3</a>">mr:distinguishedName</m<wbr>atchingRule></font></div><div><font size="1">            <tolerant>true</tolerant></font></div><div><font size="1">            <exclusiveStrong>false</exclus<wbr>iveStrong></font></div><div><font size="1">            <outbound></font></div><div><font size="1">               <authoritative>false</authori<wbr>tative></font></div><div><font size="1">               <exclusive>false</exclusive></font></div><div><font size="1">               <strength>normal</strength></font></div><div><font size="1">               <source></font></div><div><font size="1">                  <c:path>$user/fullName</c:path<wbr>></font></div><div><font size="1">               </source></font></div><div><font size="1">               <source></font></div><div><font size="1">                  <c:path>$user/organizationalUn<wbr>it</c:path></font></div><div><font size="1">               </source></font></div><div><font size="1">               <expression></font></div><div><font size="1">                  <script></font></div><div><font size="1">                     <code></font></div><div><font size="1">                         import javax.naming.ldap.Rdn</font></div><div><font size="1"><span style="white-space:pre-wrap">     </span>                     import javax.naming.ldap.LdapName</font></div><div><font size="1"><span style="white-space:pre-wrap">     </span>                     <a href="http://log.info" target="_blank">log.info</a>(fullName.toString()+' '+organizationalUnit.toString(<wbr>))     <span style="white-space:pre-wrap">  </span></font></div><div><font size="1">                         dn = new LdapName('DC=xxxx,DC=xxx')</font></div><div><font size="1">                         organizationalUnit.toString()<wbr>.tokenize('.').each { ouname -&gt; dn.add(new Rdn('OU',ouname)) }</font></div><div><font size="1"><span style="white-space:pre-wrap">                                           </span> dn.add('CN='+fullName.trim());</font></div><div><font size="1"><span style="white-space:pre-wrap">                                              </span> return dn.toString()<span style="white-space:pre-wrap">           </span></font></div><div><font size="1"><span style="white-space:pre-wrap">                                     </span></code></font></div><div><font size="1">                  </script></font></div><div><font size="1">               </expression></font></div><div><font size="1">            </outbound></font></div><div><font size="1">         </attribute></font></div><div><div class="m_-2368479913481406526gmail-m_103152204074636581m_-5942734349274580826h5"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 28, 2017 at 11:31 AM, Oskar Butovič - AMI Praha a.s. <span dir="ltr"><<a href="mailto:oskar.butovic@ami.cz" target="_blank">oskar.butovic@ami.cz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Helo Dilek,<div><br></div><div>I think that adding this logic by script to outbound mapping for ri:dn attribute should do it.</div><div><br></div><div>You also need to configure disable on delete according to this guide: <a href="https://wiki.evolveum.com/display/midPoint/Disable+instead+of+Delete" target="_blank">https://wiki.evolveum.c<wbr>om/display/midPoint/Disable+in<wbr>stead+of+Delete</a></div><div><br></div><div>Best Regards</div><div><br></div><div>Oskar Butovič</div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-07-28 10:24 GMT+02:00 Dilek Gider <span dir="ltr"><<a href="mailto:dilek.gider@basistek.com" target="_blank">dilek.gider@basistek.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi All,<div><br></div><div>I have a requirement that when a user deleted or disabled, I have to move this user on ldap to different ou, named as LEFT_USERS. Could you give any idea how can I configure this? I think it is changin DN, but where can I configure this and how?</div><div><br></div><div>My scenario is as follow:</div><div>- Sync users with HR db and update users in midpoint</div><div>- Send users changes to LDAP from midpoint</div><div><br></div><div>Thank you. </div></div>
<br>______________________________<wbr>_________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com" target="_blank">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/mail<wbr>man/listinfo/midpoint</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-2368479913481406526gmail-m_103152204074636581m_-5942734349274580826m_-6606155290453315598gmail-m_-7445925619075515776gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><table style="font-family:Verdana,Arial,Helvetica,sans-serif;border-collapse:collapse;padding:0px;margin:0px;border-width:0px;border-style:solid;width:482px"><tbody><tr style="padding:0px;margin:0px;border:0px solid gray"><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;width:160px;vertical-align:bottom;padding:0px;border:0px solid gray"><p><span style="font-size:14px;font-weight:bold">Oskar Butovič</span><br>solution architect<br><br>gsm: <a href="tel:+420%20774%20480%20101" value="+420774480101" target="_blank">[+420] 774 480 101</a><br>e-mail: <a href="mailto:oskar.butovic@ami.cz" target="_blank">oskar.butovic@ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-width:0px 1px 0px 0px;border-style:solid;border-color:gray rgb(204,204,204) gray gray;padding:0px">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;vertical-align:bottom;padding:0px;width:123px;border:0px solid gray"><p>AMI Praha a.s.<br>Pláničkova 11<br>162 00 Praha 6<br>tel.: <a href="tel:+420%20274%20783%20239" value="+420274783239" target="_blank">[+420] 274 783 239</a><br>web: <a href="http://www.ami.cz/" target="_blank">www.ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-width:0px 1px 0px 0px;border-style:solid;border-color:gray rgb(204,204,204) gray gray;padding:0px">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;margin:8px;width:116px;border:0px solid gray"><p><img src="http://www.ami.cz/images/podpis/ami_logo.gif" alt="AMI Praha a.s." style="border:0px"></p></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray"><td colspan="7" style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;width:480px;border:0px solid gray"><br><a href="http://www.ami.cz/reseni-a-sluzby/bezpecnost-dat/identity-management" target="_blank"><img src="http://www.ami.cz/images/podpis/AMI-podpis-IdM_1.png" alt="AMI Praha a.s." style="border:0px;width:480px;height:82px"></a></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray"><td colspan="7" style="color:rgb(128,128,128);font-family:Arial,sans-serif;font-size:11px;padding:0px;border:0px solid gray"><br>Textem tohoto e-mailu podepisující neslibuje uzavřít ani neuzavírá za společnost AMI Praha a.s.<br>jakoukoliv smlouvu. Každá smlouva, pokud bude uzavřena, musí mít výhradně písemnou formu.<br><br></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>
<br>______________________________<wbr>_________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com" target="_blank">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/mail<wbr>man/listinfo/midpoint</a><br>
<br></blockquote></div><br></div></div></div></div></div>
<br>______________________________<wbr>_________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com" target="_blank">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/mail<wbr>man/listinfo/midpoint</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-2368479913481406526gmail-m_103152204074636581m_-5942734349274580826gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><table style="font-family:Verdana,Arial,Helvetica,sans-serif;border-collapse:collapse;padding:0px;margin:0px;border-width:0px;border-style:solid;width:482px"><tbody><tr style="padding:0px;margin:0px;border:0px solid gray"><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;width:160px;vertical-align:bottom;padding:0px;border:0px solid gray"><p><span style="font-size:14px;font-weight:bold">Oskar Butovič</span><br>solution architect<br><br>gsm: <a href="tel:+420%20774%20480%20101" value="+420774480101" target="_blank">[+420] 774 480 101</a><br>e-mail: <a href="mailto:oskar.butovic@ami.cz" target="_blank">oskar.butovic@ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-width:0px 1px 0px 0px;border-style:solid;border-color:gray rgb(204,204,204) gray gray;padding:0px">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;vertical-align:bottom;padding:0px;width:123px;border:0px solid gray"><p>AMI Praha a.s.<br>Pláničkova 11<br>162 00 Praha 6<br>tel.: <a href="tel:+420%20274%20783%20239" value="+420274783239" target="_blank">[+420] 274 783 239</a><br>web: <a href="http://www.ami.cz/" target="_blank">www.ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-width:0px 1px 0px 0px;border-style:solid;border-color:gray rgb(204,204,204) gray gray;padding:0px">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;margin:8px;width:116px;border:0px solid gray"><p><img src="http://www.ami.cz/images/podpis/ami_logo.gif" alt="AMI Praha a.s." style="border:0px"></p></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray"><td colspan="7" style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;width:480px;border:0px solid gray"><br><a href="http://www.ami.cz/reseni-a-sluzby/bezpecnost-dat/identity-management" target="_blank"><img src="http://www.ami.cz/images/podpis/AMI-podpis-IdM_1.png" alt="AMI Praha a.s." style="border:0px;width:480px;height:82px"></a></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray"><td colspan="7" style="color:rgb(128,128,128);font-family:Arial,sans-serif;font-size:11px;padding:0px;border:0px solid gray"><br>Textem tohoto e-mailu podepisující neslibuje uzavřít ani neuzavírá za společnost AMI Praha a.s.<br>jakoukoliv smlouvu. Každá smlouva, pokud bude uzavřena, musí mít výhradně písemnou formu.<br><br></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>
<br>______________________________<wbr>_________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com" target="_blank">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/mail<wbr>man/listinfo/midpoint</a><br>
<br></blockquote></div><br></div></div>
</blockquote></div><br></div></div></div></div></div>
<br>______________________________<wbr>_________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/<wbr>mailman/listinfo/midpoint</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><table style="font-family:Verdana,Arial,Helvetica,sans-serif;border-collapse:collapse;padding:0px;margin:0px;border-width:0px!important;border-style:solid!important;width:482px!important"><tbody><tr style="padding:0px;margin:0px;border:0px solid gray!important"><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;width:160px;vertical-align:bottom;padding:0px;border:0px solid gray!important"><p><span style="font-size:14px;font-weight:bold">Oskar Butovič</span><br>solution architect<br><br>gsm: [+420] 774 480 101<br>e-mail: <a href="mailto:oskar.butovic@ami.cz" target="_blank">oskar.butovic@ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-right-width:1px;border-right-style:solid;border-right-color:rgb(204,204,204);padding:0px;border-top-width:0px!important;border-bottom-width:0px!important;border-left-width:0px!important;border-top-style:solid!important;border-bottom-style:solid!important;border-left-style:solid!important;border-top-color:gray!important;border-bottom-color:gray!important;border-left-color:gray!important">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray!important">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;vertical-align:bottom;padding:0px;width:123px;border:0px solid gray!important"><p>AMI Praha a.s.<br>Pláničkova 11<br>162 00 Praha 6<br>tel.: [+420] 274 783 239<br>web: <a href="http://www.ami.cz/" target="_blank">www.ami.cz</a></p></td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;border-right-width:1px;border-right-style:solid;border-right-color:rgb(204,204,204);padding:0px;border-top-width:0px!important;border-bottom-width:0px!important;border-left-width:0px!important;border-top-style:solid!important;border-bottom-style:solid!important;border-left-style:solid!important;border-top-color:gray!important;border-bottom-color:gray!important;border-left-color:gray!important">   </td><td style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;border:0px solid gray!important">   </td><td style="color:rgb(0,0,0);font-family:Arial,sans-serif;font-size:11px;margin:8px;border:0px solid gray!important;width:116px"><p><img src="http://www.ami.cz/images/podpis/ami_logo.gif" alt="AMI Praha a.s." style="border:0px"></p></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray!important"><td colspan="7" style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10px;padding:0px;width:480px;border:0px solid gray!important"><br><a href="http://www.ami.cz/reseni-a-sluzby/bezpecnost-dat/identity-management" target="_blank"><img src="http://www.ami.cz/images/podpis/AMI-podpis-IdM_1.png" alt="AMI Praha a.s." style="border:0px;width:480px!important;height:82px!important"></a></td></tr><tr style="padding:0px;margin:0px;border:0px solid gray!important"><td colspan="7" style="color:rgb(128,128,128);font-family:Arial,sans-serif;font-size:11px;padding:0px;border:0px solid gray!important"><br>Textem tohoto e-mailu podepisující neslibuje uzavřít ani neuzavírá za společnost AMI Praha a.s.<br>jakoukoliv smlouvu. Každá smlouva, pokud bude uzavřena, musí mít výhradně písemnou formu.<br><br></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>