<div dir="ltr">Ok, so what would be the correct way of using the handlers? Should there be a client implementation using the HttpServletMessagePipeline? Or is it just as well to call the handlers straight on? I want to understand how the different components stick together.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div><br></div><div>--</div>Stefan</div></div>
<br><div class="gmail_quote">On Wed, May 4, 2016 at 11:06 PM, Brent Putman <span dir="ltr"><<a href="mailto:putmanb@georgetown.edu" target="_blank">putmanb@georgetown.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000"><span class="">
    <p><br>
    </p>
    <br>
    <div>On 5/4/16 4:30 PM, Stefan Rasmusson
      wrote:<br>
    </div>
    <blockquote type="cite">
      <div dir="ltr">There is something I'm not quite getting with the
        handlers. Can't I use the message handlers on the encoders?</div>
    </blockquote>
    <br></span>
    Yes, you can use a MessageHandler on any MessageContext, client-side
    or server-side.  In general, a MessageDecoder produces an inbound
    MessageContext, which you can then run handlers on.  Then you have
    your profile or flow logic. Then you construct and populate an
    outbound MessageContext.  You can then run handlers on that, and
    then it is encoded with a MessageDecoder.<span class=""><br>
    <br>
    <br>
    <br>
    <blockquote type="cite">
      <div dir="ltr"> I have managed to use them on the SOAP pipeline,
        but how can I use the MessageLifetimeSecurityHandler with
        the HTTPRedirectDeflateDecoder?<br>
      </div>
    </blockquote>
    <br></span>
    That's a server-side decoder, implementing that SAML binding.  It's
    going to produce a MessageContext, on which you can then run
    handlers.  Exactly *how* you do that is up to your code.  For
    example, the Shibboleth IdP is based on Spring Web Flow, and so we
    have flow actions that handle running one or more handlers on
    message contexts, both inbound and outbound.  That would be a good
    real world example to look at.<br>
    <br>
    In the pipeline-based SOAP client, it's the client impl that
    "orchestrates" the encoding, decoding and running the various
    handlers and the appropriate time. On the server side, order of
    operations is reversed.  It's going to be something else that
    orchestrates the execution of the logical message pipeline.  If not
    SWF, then you might do that in a servlet, or MVC controller or
    whatever.  It's going to be determined by your server-side design
    and framework.<br>
    <br>
    We don't use it in the IdP, but in package
    org.opensaml.messaging.pipeline.servlet I did add an interface and
    basic impl for a server-side pipeline, for holding the encoders,
    decoders and handlers, specialized for the server-side
    HttpServletRequest/-Response case..  Calling those would be up to
    you however, since it can't know how the "business logic" in the
    middle is going to work, and what the overall execution environment
    looks like.  <br>
  </div>

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