Service Portal with SSO enabled is redirecting to nav_to.do?uri=/sp.

Steps to Reproduce


  1. Enable the following plugins:
    • Multiple Provider Single Sign-On
    • Service Portal Plugins:
      • Service Portal - Core 1.1.0 Active com.glide.service-portal
      • Service Portal for Enterprise Service Management 1.1.0 Active com.glide.service-portal.esm (with demo data)
  2. Access Service Portal page with DB login:
    • https://<instancename>.service-now.com/sp
  3. Configure Single Sign-On on the instance using an identity provider.
  4. Ensure that a user can log in using SSO.
  5. Access the Service Portal (https://<instancename>.service-now.com/sp).
    Note that it now redirects to https://<instancename>.service-now.com/nav_to.do?uri=/sp.



The best integration with Service Portal is to configure glide.entry.page.script and create a function that forwards users to the correct home page. 

Alternatively, on the script include SAML2_update1, replace needNavFrame and add function isSPRequest as follows:

    needNavFrame: function (requestURI, request) {
        if (requestURI.indexOf("login_with_sso") >= 0) return false;
        if (requestURI.startsWith("/nav_to.do")) return false;
        if (requestURI.startsWith("/navpage.do")) return false;
        if (requestURI.startsWith("/saml_redirector.do")) return false;
        if (this.isCMSRequest(request)) return false;
        if (this.isSPRequest()) return false; // Here is the PRB712179 workaround 
        if (requestURI.equals("") || requestURI.equals("/")) return false;
        return true
    isSPRequest: function () {
        var isDirectRedirect = gs.getSession()
        this.logDebug("Is this a request from the servicePortal ?? : " + isDirectRedirect);
        if (isDirectRedirect != null && isDirectRedirect == "true") return true;
        return false

Related Problem: PRB712179

Seen In

Helsinki Patch 2
Helsinki Patch 2 Hot Fix 2
Helsinki Patch 3
Helsinki Patch 3 Hot Fix 2
Helsinki Patch 3 Hot Fix 7
Helsinki Patch 4
Helsinki Patch 5
Helsinki Patch 6 Hot Fix 1
Helsinki Patch 7

Fixed In


Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-01-24 11:10:23