<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    Hi,<br>
    <br>
    Congratulations. It looks like you have found a bug.<br>
    <br>
    This should work exactly the way as you are trying to use it. Please
    report that bug in the Jira. Also please specify the operation that
    you are trying to do when you are getting the exception so we can
    reproduce the issue easier. Thanks.<br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Radovan Semancik
Software Architect
evolveum.com
</pre>
    <br>
    <br>
    <div class="moz-cite-prefix">On 06/13/2016 10:17 AM, Oskar Butovič -
      AMI Praha a.s. wrote:<br>
    </div>
    <blockquote
cite="mid:CAE8MtZBFr5=kjkU4oUyPGsG07wzJ3an1miT3ohDGq75AzOMnNQ@mail.gmail.com"
      type="cite">
      <div dir="ltr"><span style="font-size:12.8px">Hello Everybody,</span>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">I am trying to add password for
          external application (google apps) as a new attribute for user
          because i need to store it and be able to edit it later. I
          tried to use ProtectedStringType in extension schema. But
          somehow this type doesnt work. Midpoint throws exception.</div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">relevant configuration:</div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">
          <div style="font-size:12.8px"><xsd:schema
            elementFormDefault="qualified"</div>
          <div style="font-size:12.8px">            targetNamespace="<a
              moz-do-not-send="true"
              href="http://avast.com/xml/ns/idmSchema"><a class="moz-txt-link-freetext" href="http://avast.com/xml/ns/idmSchema">http://avast.com/xml/ns/idmSchema</a></a>"</div>
          <div style="font-size:12.8px">            xmlns:tns="<a
              moz-do-not-send="true"
              href="http://avast.com/xml/ns/idmSchema"><a class="moz-txt-link-freetext" href="http://avast.com/xml/ns/idmSchema">http://avast.com/xml/ns/idmSchema</a></a>"</div>
          <div style="font-size:12.8px">            xmlns:a="<a
              moz-do-not-send="true"
              href="http://prism.evolveum.com/xml/ns/public/annotation-3"><a class="moz-txt-link-freetext" href="http://prism.evolveum.com/xml/ns/public/annotation-3">http://prism.evolveum.com/xml/ns/public/annotation-3</a></a>"</div>
          <div style="font-size:12.8px">            xmlns:c="<a
              moz-do-not-send="true"
              href="http://midpoint.evolveum.com/xml/ns/public/common/common-3"><a class="moz-txt-link-freetext" href="http://midpoint.evolveum.com/xml/ns/public/common/common-3">http://midpoint.evolveum.com/xml/ns/public/common/common-3</a></a>"</div>
          <div style="font-size:12.8px"><span class="" style="white-space:pre">                       </span>xmlns:t="<a
              moz-do-not-send="true"
              href="http://prism.evolveum.com/xml/ns/public/types-3"><a class="moz-txt-link-freetext" href="http://prism.evolveum.com/xml/ns/public/types-3">http://prism.evolveum.com/xml/ns/public/types-3</a></a>"</div>
          <div style="font-size:12.8px">            xmlns:xsd="<a
              moz-do-not-send="true"
              href="http://www.w3.org/2001/XMLSchema"><a class="moz-txt-link-freetext" href="http://www.w3.org/2001/XMLSchema">http://www.w3.org/2001/XMLSchema</a></a>"></div>
          <div style="font-size:12.8px"> </div>
          <div style="font-size:12.8px">    <xsd:complexType
            name="UserExtensionType"></div>
          <div style="font-size:12.8px">        <xsd:annotation></div>
          <div style="font-size:12.8px">            <xsd:appinfo></div>
          <div style="font-size:12.8px">                <a:extension
            ref="c:UserType"/></div>
          <div style="font-size:12.8px">            </xsd:appinfo></div>
          <div style="font-size:12.8px">        </xsd:annotation></div>
          <div style="font-size:12.8px">        <xsd:sequence></div>
          <div style="font-size:12.8px"><span class="" style="white-space:pre">                       </span><xsd:element
            name="googleAppsPassword" type="t:ProtectedStringType"
            minOccurs="0" maxOccurs="unbounded"></div>
          <div style="font-size:12.8px">               
            <xsd:annotation></div>
          <div style="font-size:12.8px">                   
            <xsd:appinfo></div>
          <div style="font-size:12.8px">                       
            <a:displayName>Google Apps
            Password</a:displayName></div>
          <div style="font-size:12.8px">                       
            <a:displayOrder>110</a:displayOrder></div>
          <div style="font-size:12.8px">                       
            <a:help>Password for google apps
            account</a:help></div>
          <div style="font-size:12.8px">                   
            </xsd:appinfo></div>
          <div style="font-size:12.8px">               
            </xsd:annotation></div>
          <div style="font-size:12.8px">            </xsd:element></div>
          <div style="font-size:12.8px"><br>
          </div>
          <div style="font-size:12.8px">exception:</div>
          <div style="font-size:12.8px"><br>
          </div>
          <div style="font-size:12.8px">
            <div style="font-size:12.8px">Caused by:
              org.xml.sax.SAXParseException: undefined simple or complex
              type 't:ProtectedStringType'</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.impl.parser.ParserContext$1.reportError(ParserContext.java:180)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.reportError(NGCCRuntimeEx.java:175)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.impl.parser.DelayedRef.resolve(DelayedRef.java:110)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.impl.parser.DelayedRef.run(DelayedRef.java:85)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.impl.parser.ParserContext.getResult(ParserContext.java:135)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.sun.xml.xsom.parser.XSOMParser.getResult(XSOMParser.java:214)
              ~[jaxb-xjc-2.2.10-b140310.1920.jar:2.2.10-b140310.1920]</div>
            <div style="font-size:12.8px">        at
              com.evolveum.midpoint.prism.schema.DomToSchemaProcessor.parseSchema(DomToSchemaProcessor.java:233)
              ~[prism-3.3.1.jar:na]</div>
            <div style="font-size:12.8px">        ... 75 common frames
              omitted</div>
            <div><br>
            </div>
          </div>
        </div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">Is it a right approach for storing
          passwords for external applications? Should i use another
          type? </div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">Thanks.</div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">Regards,</div>
        <div style="font-size:12.8px"><br>
        </div>
        <div style="font-size:12.8px">Oskar Butovič</div>
        <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 moz-do-not-send="true"
                                  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 moz-do-not-send="true"
                                  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;width:116px;border:0px
                              solid gray!important">
                              <p><img moz-do-not-send="true"
                                  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 moz-do-not-send="true"
href="http://www.ami.cz/reseni-a-sluzby/bezpecnost-dat/identity-management"
                                target="_blank"><img
                                  moz-do-not-send="true"
                                  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>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
midPoint mailing list
<a class="moz-txt-link-abbreviated" href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a>
<a class="moz-txt-link-freetext" href="http://lists.evolveum.com/mailman/listinfo/midpoint">http://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>