locked
Redirect to application page after authentication RRS feed

  • Question

  • I am attempting to modify an existing web application to use claims-based authentication.  For my first experiment I modified the application using code copied from the relying party application in the Federation for Web Apps sample.  When I access a page in my application, it correctly redirects me to the FPSTS site that is part of the same sample.  After I authenticate, it redirects me back to the default page of my application.  What do I need to change to have it redirect back to the page of my application that the user initially accessed rather than the default page?

    Perhaps my question will be clearer with a specific example.  Suppose the user starts by accessing /app/abc.aspx.  After he gets redirected to the STS and authenticates, I want him to be redirected back to /app/abc.aspx but currently he gets redirected back to /app/.  What do I need to change?

    Tuesday, March 17, 2009 7:23 PM

Answers

All replies

  • Hi!

    The request parameter called "wreply" is in charge of this redirect.

    Setting this parameter depends on application you are using, if you are using application that has IDFX FederatedPassiveSignIn control to log in, then try to find the code following in your /app/abc.aspx:

    <idfx:FederatedPassiveSignIn ID="FederatedPassiveSignIn1" runat="server"
                       Issuer="https://localhost/PassiveSTSForClaimsAwareWebApp/Default.aspx"
                       Realm="https://localhost/WebControlBasedClaimsAwareWebApp"
                       VisibleWhenSignedIn="False">
    </idfx:FederatedPassiveSignIn> 

    and add the line like
    Reply="https://your.host.name/app/abc.aspx"

    after Realm= string.



    Monday, March 23, 2009 12:56 AM
    Moderator
  • Thanks for the reply.  I'm using "passiveRedirectEnabled=true" in the wsFederatedAuthentication configuration section instead of using the FederatedPassiveSignIn control.  Is there a way to have the "wreply" passed in this mode?
    Monday, March 23, 2009 1:58 PM