<div dir="ltr"><div>Hi Tom,<br><br></div><div>This is an issue that's occurred when the OpenSAML library is not initialized properly. Just check <a href="https://stackoverflow.com/a/61699845/11383375">this</a> stackoverflow post (also the GitHub link attached in that post). <br></div><div><br></div><div>Thank you,<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jun 17, 2021 at 3:20 PM Tom Chiverton <<a href="mailto:tc@extravision.com">tc@extravision.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div>
    <p>For the benefit of the future, I couldn't find out what was
      wrong, so just hacked in a work around in my code :<br>
    </p>
    <p>if( attributeStatementBuilder == null ){<br>
                  //throw new
      MarshallingException("attributeStatementBuilder not found for
      "+AttributeStatement.DEFAULT_ELEMENT_NAME);<br>
                  attributeStatementBuilder = new
      AttributeStatementBuilder();</p>
    <p>            if( attributeStatementBuilder == null ){<br>
                      throw new
      MarshallingException("attributeStatementBuilder not found for
      "+AttributeStatement.DEFAULT_ELEMENT_NAME);<br>
                  }<br>
      }</p>
    <p>Tom<br>
    </p>
    <div>On 17/06/2021 09:41, Tom Chiverton
      wrote:<br>
    </div>
    <blockquote type="cite">
      
      <p>Hello again,</p>
      <p>I'm fairly sure some how that my code isn't getting a correctly
        setup <span>XMLObjectProviderRegistry,
          but can't see how to dump the configured one from a working
          project to see what might be up, or what the required
          configuration might be and set it.</span></p>
      <p><span>I can't seem to get
          XMLObjectBuilderFactory.getBuilders() to return anything
          except empty, which is weird, right ?</span></p>
      <p><span>Tom<br>
        </span></p>
      <div>On 15/06/2021 13:18, Tom Chiverton
        wrote:<br>
      </div>
      <blockquote type="cite">
        
        <p>[reposting from users@ as requested]</p>
        <p>Hi,</p>
        <p>I'm trying integrate some code that uses OpenSAML (v3). I'm
          trying to build a SAML IDP Response XML so it can be HTTP
          POST'ed to a SP (IDP-initiated SSO). This should be straight
          forward (!).<br>
        </p>
        <p>When I do <br>
        </p>
        <p><font face="monospace">AttributeStatementBuilder
            attributeStatementBuilder =<br>
                            (AttributeStatementBuilder)
            XMLObjectSupport.getBuilder(AttributeStatement.DEFAULT_ELEMENT_NAME);</font></p>
        <p>the result is null in my own project, but the same call in
          another project ( <a href="https://github.com/AlainODea/opensaml-idp-example" target="_blank">https://github.com/AlainODea/opensaml-idp-example</a>
          and in particular <a href="https://github.com/AlainODea/opensaml-idp-example/blob/a28aa97a8ecd63c0dbeb7a8f7464e2d4115dc569/src/main/java/com/alainodea/idp/service/AssertionFactory.java#L35" target="_blank">https://github.com/AlainODea/opensaml-idp-example/blob/a28aa97a8ecd63c0dbeb7a8f7464e2d4115dc569/src/main/java/com/alainodea/idp/service/AssertionFactory.java#L35</a>
          ) does not return null. <br>
        </p>
        <p>AttributeStatement.DEFAULT_ELEMENT_NAME is logging out as
          "{urn:oasis:names:tc:SAML:2.0:assertion}" in both cases.</p>
        <p>I assume I am missing some property (file ?) or
          initialisation / setup code somewhere, but there doesn't seem
          to be anything in the projects' wiki or the classes Java Doc
          pages to explain what it might be.<br>
          <br>
          I'm already doing these two, because the other project did,
          otherwise I get "XMLObjectProviderRegistry was not available
          from the ConfigurationService" from the getBuilder() call<br>
        </p>
        <p><font face="monospace">   
            org.opensaml.xmlsec.config.JavaCryptoValidationInitializer.init();<br>
               
            org.opensaml.core.config.InitializationService.initialize();</font>
        </p>
        <p>Could someone point me in the right direction ?</p>
        <div>
          
          
          
           --
          <table style="max-width:600px" width="100%" cellspacing="0" cellpadding="0" border="0" bgcolor="#FFFFFF">
            <tbody>
              <tr>
                <td style="line-height:20px;font-size:20px" height="20"> </td>
              </tr>
              <tr>
                <td style="line-height:1px;font-size:1px" height="1" bgcolor="#f2f5f7"><img src="https://extravision.s3.eu-west-1.amazonaws.com/images/blank.gif" style="display: block;" alt="" width="1" height="1"></td>
              </tr>
              <tr>
                <td style="line-height:20px;font-size:20px" height="20"> </td>
              </tr>
              <tr>
                <td width="100%" valign="top">
                  <table width="100%" cellspacing="0" cellpadding="0" border="0">
                    <tbody>
                      <tr>
                        <td width="100%" valign="top" align="left"> <strong>Tom Chiverton</strong><br>
                          Lead Developer </td>
                      </tr>
                      <tr>
                        <td style="line-height:20px;font-size:20px" height="20"> </td>
                      </tr>
                      <tr>
                        <td valign="top" align="left">
                          <table width="250" cellspacing="0" cellpadding="0" border="0">
                            <tbody>
                              <tr>
                                <td width="30" valign="top" align="left">e:</td>
                                <td width="220" valign="top" align="left"><a href="mailto:tc@extravision.com" target="_blank">tc@extravision.com</a></td>
                              </tr>
                              <tr>
                                <td valign="top" align="left">p:</td>
                                <td valign="top" align="left">0161‌ 817‌
                                  2929</td>
                              </tr>
                              <tr>
                                <td valign="top" align="left">t:</td>
                                <td valign="top" align="left">@extravision</td>
                              </tr>
                              <tr>
                                <td valign="top" align="left">w:</td>
                                <td valign="top" align="left">extravision‌.com‌</td>
                              </tr>
                            </tbody>
                          </table>
                        </td>
                      </tr>
                      <tr>
                        <td style="line-height:20px;font-size:20px" height="20"> </td>
                      </tr>
                      <tr>
                        <td width="100%" valign="top">
                          <table width="200" cellspacing="0" cellpadding="0" border="0">
                            <tbody>
                              <tr>
                                <td width="200" valign="top" align="left"> <a href="https://www.extravision.com" target="_blank"><img src="https://extravision.s3.eu-west-1.amazonaws.com/images/extravision-logo-on-light.png" style="display: block;" alt="Extravision" width="200" height="31" border="0"></a> </td>
                              </tr>
                            </tbody>
                          </table>
                        </td>
                      </tr>
                      <tr>
                        <td style="line-height:20px;font-size:20px" height="20"> </td>
                      </tr>
                      <tr>
                        <td valign="top" align="left">
                          <table width="100%" cellspacing="0" cellpadding="0" border="0">
                            <tbody>
                              <tr>
                                <td width="100%" valign="top" align="left">
                                  Registered in the UK at: Tomorrow‌,
                                  MediaCityUK‌, Salford‌ M50‌ 2AB.<br>
                                  Company Reg No: 05017214‌ VAT: GB 824‌
                                  5386‌ 19<br>
                                  <br>
                                  This e-mail is intended solely for the
                                  person to whom it is addressed and may
                                  contain confidential or privileged
                                  information. Any views or opinions
                                  presented in this e-mail are solely of
                                  the author and do not necessarily
                                  represent those of Extravision Ltd. </td>
                              </tr>
                            </tbody>
                          </table>
                        </td>
                      </tr>
                    </tbody>
                  </table>
                </td>
              </tr>
            </tbody>
          </table>
        </div>
        <br clear="all">
______________________________________________________________________<br>
        This email has been scanned by the Symantec Email Security.cloud
        service.<br>
        For more information please visit <a href="http://www.symanteccloud.com" target="_blank">http://www.symanteccloud.com</a><br>
______________________________________________________________________<br>
        <br clear="all">
______________________________________________________________________<br>
        This email has been scanned by the Symantec Email Security.cloud
        service.<br>
        For more information please visit <a href="http://www.symanteccloud.com" target="_blank">http://www.symanteccloud.com</a><br>
______________________________________________________________________<br>
        <br>
        <fieldset></fieldset>
      </blockquote>
    </blockquote>
  <br clear="all">
______________________________________________________________________<br>
This email has been scanned by the Symantec Email Security.cloud service.<br>
For more information please visit <a href="http://www.symanteccloud.com" target="_blank">http://www.symanteccloud.com</a><br>
______________________________________________________________________<br>
</div>


-- <br>
To unsubscribe from this list send an email to <a href="mailto:dev-unsubscribe@shibboleth.net" target="_blank">dev-unsubscribe@shibboleth.net</a><br>
</blockquote></div>