<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:"Arial Unicode MS";
panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
{font-family:"Arial Black";
panose-1:2 11 10 4 2 1 2 2 2 4;}
@font-face
{font-family:"\@Arial Unicode MS";
panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
{font-family:"Liberation Mono";
panose-1:2 7 4 9 2 2 5 2 4 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin-top:0cm;
margin-right:0cm;
margin-bottom:6.0pt;
margin-left:0cm;
line-height:112%;
font-size:10.0pt;
font-family:"Arial",sans-serif;
mso-fareast-language:EN-US;}
h1
{mso-style-priority:12;
mso-style-link:"\00DCberschrift 1 Zchn";
margin-top:18.0pt;
margin-right:0cm;
margin-bottom:6.0pt;
margin-left:21.25pt;
mso-add-space:auto;
text-indent:-21.25pt;
line-height:112%;
page-break-after:avoid;
mso-list:l2 level1 lfo2;
font-size:20.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;
font-weight:normal;}
h1.CxSpFirst
{mso-style-priority:12;
mso-style-link:"\00DCberschrift 1 Zchn";
mso-style-type:export-only;
margin-top:18.0pt;
margin-right:0cm;
margin-bottom:0cm;
margin-left:21.25pt;
margin-bottom:.0001pt;
mso-add-space:auto;
text-indent:-21.25pt;
line-height:112%;
page-break-after:avoid;
mso-list:l2 level1 lfo2;
font-size:20.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;
font-weight:normal;}
h1.CxSpMiddle
{mso-style-priority:12;
mso-style-link:"\00DCberschrift 1 Zchn";
mso-style-type:export-only;
margin-top:0cm;
margin-right:0cm;
margin-bottom:0cm;
margin-left:21.25pt;
margin-bottom:.0001pt;
mso-add-space:auto;
text-indent:-21.25pt;
line-height:112%;
page-break-after:avoid;
mso-list:l2 level1 lfo2;
font-size:20.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;
font-weight:normal;}
h1.CxSpLast
{mso-style-priority:12;
mso-style-link:"\00DCberschrift 1 Zchn";
mso-style-type:export-only;
margin-top:0cm;
margin-right:0cm;
margin-bottom:6.0pt;
margin-left:21.25pt;
mso-add-space:auto;
text-indent:-21.25pt;
line-height:112%;
page-break-after:avoid;
mso-list:l2 level1 lfo2;
font-size:20.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;
font-weight:normal;}
p.MsoListBullet, li.MsoListBullet, div.MsoListBullet
{mso-style-priority:17;
margin-top:0cm;
margin-right:0cm;
margin-bottom:6.0pt;
margin-left:21.25pt;
text-indent:-21.25pt;
line-height:112%;
mso-list:l1 level1 lfo4;
font-size:10.0pt;
font-family:"Arial",sans-serif;
mso-fareast-language:EN-US;}
p.MsoTitle, li.MsoTitle, div.MsoTitle
{mso-style-priority:10;
mso-style-link:"Titel Zchn";
margin-top:18.0pt;
margin-right:102.05pt;
margin-bottom:6.0pt;
margin-left:0cm;
mso-add-space:auto;
line-height:112%;
font-size:26.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;}
p.MsoTitleCxSpFirst, li.MsoTitleCxSpFirst, div.MsoTitleCxSpFirst
{mso-style-priority:10;
mso-style-link:"Titel Zchn";
mso-style-type:export-only;
margin-top:18.0pt;
margin-right:102.05pt;
margin-bottom:0cm;
margin-left:0cm;
margin-bottom:.0001pt;
mso-add-space:auto;
line-height:112%;
font-size:26.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;}
p.MsoTitleCxSpMiddle, li.MsoTitleCxSpMiddle, div.MsoTitleCxSpMiddle
{mso-style-priority:10;
mso-style-link:"Titel Zchn";
mso-style-type:export-only;
margin-top:0cm;
margin-right:102.05pt;
margin-bottom:0cm;
margin-left:0cm;
margin-bottom:.0001pt;
mso-add-space:auto;
line-height:112%;
font-size:26.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;}
p.MsoTitleCxSpLast, li.MsoTitleCxSpLast, div.MsoTitleCxSpLast
{mso-style-priority:10;
mso-style-link:"Titel Zchn";
mso-style-type:export-only;
margin-top:0cm;
margin-right:102.05pt;
margin-bottom:6.0pt;
margin-left:0cm;
mso-add-space:auto;
line-height:112%;
font-size:26.0pt;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;
mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#009DEC;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#933973;
text-decoration:underline;}
span.berschrift1Zchn
{mso-style-name:"\00DCberschrift 1 Zchn";
mso-style-priority:12;
mso-style-link:"\00DCberschrift 1";
font-family:"Arial Narrow",sans-serif;
color:#009DEC;}
span.TitelZchn
{mso-style-name:"Titel Zchn";
mso-style-priority:10;
mso-style-link:Titel;
font-family:"Arial Narrow",sans-serif;
color:#009DEC;}
span.E-MailFormatvorlage21
{mso-style-type:personal-compose;
font-family:"Arial",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;
font-family:"Arial",sans-serif;
mso-fareast-language:EN-US;}
.MsoPapDefault
{mso-style-type:export-only;
margin-bottom:6.0pt;
line-height:112%;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
{page:WordSection1;}
/* List Definitions */
@list l0
{mso-list-id:-119;
mso-list-type:simple;
mso-list-template-ids:-460561208;}
@list l0:level1
{mso-level-number-format:bullet;
mso-level-text:\F0B7;
mso-level-tab-stop:18.0pt;
mso-level-number-position:left;
margin-left:18.0pt;
text-indent:-18.0pt;
font-family:Symbol;}
@list l1
{mso-list-id:610864188;
mso-list-template-ids:-1039730736;}
@list l1:level1
{mso-level-number-format:bullet;
mso-level-style-link:Aufz\00E4hlungszeichen;
mso-level-text:\0131;
mso-level-tab-stop:21.25pt;
mso-level-number-position:left;
margin-left:21.25pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
mso-ascii-font-family:"Arial Black";
mso-hansi-font-family:"Arial Black";
mso-bidi-font-family:"Arial Black";}
@list l1:level2
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:42.55pt;
mso-level-number-position:left;
margin-left:42.5pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level3
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:63.8pt;
mso-level-number-position:left;
margin-left:63.75pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level4
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:3.0cm;
mso-level-number-position:left;
margin-left:85.0pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level5
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:106.3pt;
mso-level-number-position:left;
margin-left:106.25pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level6
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:127.6pt;
mso-level-number-position:left;
margin-left:127.5pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level7
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:148.85pt;
mso-level-number-position:left;
margin-left:148.75pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level8
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:6.0cm;
mso-level-number-position:left;
margin-left:170.0pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
font-family:"Arial",sans-serif;}
@list l1:level9
{mso-level-number-format:bullet;
mso-level-text:\25AA;
mso-level-tab-stop:191.35pt;
mso-level-number-position:left;
margin-left:191.25pt;
text-indent:-21.25pt;
mso-ansi-font-size:9.0pt;
mso-bidi-font-size:9.0pt;
mso-ascii-font-family:Arial;
mso-hansi-font-family:Arial;
mso-bidi-font-family:Arial;}
@list l2
{mso-list-id:628360796;
mso-list-template-ids:-1252723272;}
@list l2:level1
{mso-level-style-link:"\00DCberschrift 1";
mso-level-text:%1;
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:21.25pt;
text-indent:-21.25pt;}
@list l2:level2
{mso-level-text:"%1\.%2";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:29.75pt;
text-indent:-29.75pt;}
@list l2:level3
{mso-level-text:"%1\.%2\.%3";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:38.25pt;
text-indent:-38.25pt;}
@list l2:level4
{mso-level-text:"%1\.%2\.%3\.%4";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:46.8pt;
text-indent:-46.8pt;}
@list l2:level5
{mso-level-text:"%1\.%2\.%3\.%4\.%5";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:55.3pt;
text-indent:-55.3pt;}
@list l2:level6
{mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:63.8pt;
text-indent:-63.8pt;}
@list l2:level7
{mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6\.%7";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:72.3pt;
text-indent:-72.3pt;}
@list l2:level8
{mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6\.%7\.%8";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:80.8pt;
text-indent:-80.8pt;}
@list l2:level9
{mso-level-text:"%1\.%2\.%3\.%4\.%5\.%6\.%7\.%8\.%9";
mso-level-tab-stop:none;
mso-level-number-position:left;
margin-left:89.3pt;
text-indent:-89.3pt;}
ol
{margin-bottom:0cm;}
ul
{margin-bottom:0cm;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="DE" link="#009DEC" vlink="#933973">
<div class="WordSection1">
<p class="MsoNormal">Hi everyone,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span lang="EN-US">does anyone know the correct way (using the Java REST Client) to set the password of a specific resource account. I don’t want to set the midpoint password itself – I already have that working. I am trying the following,
but not succeeding. I am using the 3.9-SNAPSHOT builds of the java client from October 2019 as I cannot move the system performing the call to Java 11.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ObjectModifyService<ShadowType> oms = impersonateService.shadows().oid(rai.getOid()).modify();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">PasswordType password = new PasswordType();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ProtectedStringType passwordString = new ProtectedStringType(); <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">passwordString.getContent().add(newPassword);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">password.setValue(passwordString);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">password.setForceChange(Boolean.FALSE);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">oms.replace("credentials/password", password);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">oms.post();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">This does cause a modification, but in the audit it shows a “delete” + “add” for the credentials. This does not happen when changing the password via the UI. In addition, the password
is not valid on the resource after the REST call. Changing via the UI (where the audit shows just one modify) does work correctly.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">The other variation that I tried was :<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ObjectCredentialService<ShadowType> ocs = impersonateService.shadows().oid(rai.getOid()).credential();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ExecuteCredentialResetRequestType ecrrt = new ExecuteCredentialResetRequestType();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ecrrt.setResetMethod("passwordReset");<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">ecrrt.setUserEntry(newPassword);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">TaskFuture<ExecuteCredentialResetResponseType> task = ocs.executeResetPassword(ecrrt).apost();<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">but this results in an “ObjectNotFound” exception.
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">Thanks in advance!<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">Regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-family:"Liberation Mono"">Chris</span><span lang="EN-US"><o:p></o:p></span></p>
</div>
</body>
</html>