• Resolved Michael

    (@mgparisi)


    Hello,

    I’m a developer working on this new site that used a plugin that was similar to yours but has not been updated and is now insecure. We are being told your plugin is the best thing around. I will be installing it.

    My question is regarding the redirecting after login to the original page. I was going to add the page to the query string and pass it to the login page we got. After the login I wanted to set the redirect to the url in the query string.

    Sounds simple… We are willing to work with your code and use your hooks or add new hooks for this. I got a few questions.

    A) is this at all possible? Do you know a plugin that works with yours?
    B) Anything I need to do to pass the URL?
    C) Can we get a brief overview on how your plugin works?
    ** How does the server pass the login info to the remote server?
    **** Does it redirect the user to the other page, then sends them back or is it an iframe?
    ** How can we tell the login was a success?

    Thanks!

    • This topic was modified 5 years, 4 months ago by Michael.
Viewing 1 replies (of 1 total)
  • Plugin Author miniOrange

    (@cyberlord92)

    Hi,

    Thank you for reaching out to us!

    Glad to know that you decided to go with the best WordPress plugin for Single Sign-On ??

    To answer your question, the plugin internally handles redirecting the logged in users back to the same page from where the login was initiated.
    You don’t need to manually pass the URL in the query string for this. This is handled by the RelayState parameter.
    Allow me to explain how the login flow works with the plugin.

    When the SSO flow is initiated from your site, either using a login widget or shortcode or using the auto-redirect feature, the plugin sends a SAMLRequest to the configured Identity Provider. Along with this request, the plugin also passes a RelayState parameter either as a query string or as a POST parameter (depending on the login binding type configured in the plugin). This RelayState parameter is basically a relative URL of the page from where the login was initiated.
    At this point, the users are redirected to the IdP login page on the same browser tab (not in an iframe) and after successful authentication, the IdP sends a SAMLResponse along with the same RelayState parameter back to the WordPress site.
    The plugin processes this response and redirects the user to the RelayState URL.
    Hence the user lands on the same page from where the login was initiated.

    NOTE: In our premium plugins, you can also configure a static RelayState URL in the plugin so that all your users get redirected to this URL after logging in, no matter from where the login was initiated.
    After validating the SAMLResponse, the plugin sets the WordPress auth cookie and hence the user gets logged into your site. If the user doesn’t already exist in your site, the plugin will automatically create a new user account based on the attributes sent by your IdP.

    Let me know if you have any more questions.

    Thanks,
    Gaurav Singh

Viewing 1 replies (of 1 total)
  • The topic ‘Redirect to referring page.’ is closed to new replies.