Oracle Cloud Infrastructure (OCI) IAM App Gateway can be used to add single-sign-on (SSO) authentication to applications that support HTTP header-based authentication but do not provide a direct standards-based integration with an identity provider.

This blog describes a selective SSO design for the Sales application in Siebel CRM 26.7 on OCI. The app is protected by App Gateway, while other apps retain their existing authentication methods.

The configuration is described at a solution level; installation of Siebel CRM or App Gateway components is outside the scope of this blog.

Solution Architecture

Fig 0.1: Solution Architecture
Siebel SSO
Fig 0.2: User experience of Siebel Sales using Single Sign On

The request path is shown below:

Browser
  |
  | HTTPS 443
  v
OCI Load Balancer
  |
  | HTTP 8080
  v
OCI IAM App Gateway
  |
  | HTTPS 443
  v
Siebel Application Interface
  |
  | HTTPS 4430
  v
Sales Object Manager (SSEObjMgr_enu)
  |
  v
SalesDBSecAdpt -> Siebel database
  • Public TLS is terminated at the OCI Load Balancer
  • App Gateway checks for an OCI IAM session and redirects an unauthenticated browser to the configured sign-in flow
  • After authentication, the mapped Siebel user ID is added to the request as an HTTP header
  • The Siebel Application Interface receives the header, reads it, then routes the request to the Sales Object Manager
  • The Object Manager uses a dedicated database-security adapter in ‘SSO’ mode to establish the Siebel session

NOTE: In this Siebel deployment, HTTPS port 4430 belongs to the external Apache Tomcat connector used by the containerized Application Interface. It is an internal, deployment-specific port; it is not the communication port between the Application Interface and the Sales Object Manager. Other Siebel deployments can use a different ingress and connector arrangement.

Currently, multiple applications are deployed with their own authentication methods.

Siebel applicationApplication Interface entryObject ManagerAuthentication
Salessales/enuSSEObjMgr_enuLocal (proposed for SSO)
Sales Mobilesalesm/enuSalesmObjMgr_enuLocal
Web Toolswebtools/enuSWToolsObjMgr_enuLocal
Fig 0.3: Existing applications & their respective login setup

For the purpose of this demo, we will work with the ‘SSEObjMgr_enu' object manager only.

Prerequisites

The following are required:

  • An operational Siebel environment with local administrative access
  • Administrative access to the Siebel security adapter, Application Interface profile, Sales Object Manager
  • An OCI IAM Identity Domain Adminstrator
  • An OCI IAM App Gateway deployment that can reach the Siebel endpoint
  • Users in the IAM domain with an attribute that can map to the Siebel username
  • A public DNS name and TLS certificate for the SSO endpoint

Section 1: Configure SSO in Siebel Management Controller (SMC)

Retain a local authentication Path

Verify that SMC, Web Tools and other applications are accessible so that configuration and recovery remain available. All Siebel configurations would be done in SMC. For this deployment, below are the example URLs:

https://<siebel-origin>/siebel/app/webtools/enu
https://<smc-host>/siebel/smc/index.html

Create a Dedicated Security Adapter

Instead of modifying the shared DBSecAdpt, create a new security adapter. Other applications can continue to reference the shared adapter. In SMC, open Configuration, select the target enterprise, and navigate to Profile Configuration. Add a profile using the following values:

ItemValue
Profile display nameSales DB SSO Adapter (example)
AliasSalesDBSecAdpt (example)
Subsystem typeSiebel DB Security Adapter (InfraSecAdpt_DB)
Fig 1.1: Enterprise Profile details (basic)
Fig 1.2: Creating the Enterprise Profile

Save the profile, and open its Advanced parameters. Configure the following settings:

SettingValue
Security Adapter DLL Namesscfsadb
Data Source NameThe Siebel server data source; ServerDataSrc in this deployment
Shared DB Username and PasswordProtected Siebel database credentials
Single Sign OnTrue
Trust TokenA new shared secret
Fig 1.3: Enterprise Profile details (advanced parameters)
Fig 1.4: Configuration of the dedicated Sales database-security adapter

To generate a random trust token, run the following command on a trusted terminal :

openssl rand -hex 24

Configure the same token in the dedicated adapter (Fig 1.4) and in the Sales entry of the Application Interface profile (Fig 1.7) later on. The token is a shared secret between these Siebel components; it is not a user password or password hash.

Align the Identity Header and Siebel Components

The following diagram shows how the authenticated identity maps to the Siebel USERID:

OCI IAM attribute: siebelUserId
        |
        v
Upstream request header: SSO_SIEBEL_USER
        |
        v
Application Interface User Specification
        |
        v
Siebel USERID

Create the users in the application administration, or review the User ID of the accounts.

Fig 1.5: Siebel user created to match the OCI IAM user

Next, configure the sales/enu Application Interface entry as follows:

SettingValue
Single Sign OnEnabled
User SpecificationSSO_SIEBEL_USER
Trust TokenSame value as SalesDBSecAdpt
Object ManagerSSEObjMgr_enu
Fig 1.6: Application Interface details
Fig 1.7: Sales-specific Web SSO configuration in the Application Interface profile

Associate the Sales Object Manager with the new adapter SalesDBSecAdpt, and set the adaptor mode to DBSSO.

SecAdptMode = DBSSO
SecAdptName = SalesDBSecAdpt
Fig 1.8: Security adapter assigned to the Sales Object Manager.

Section 2: Configure the Enterprise Application and App Gateway in OCI IAM

Define the Application and Resources

Configure the enterprise application with the public Sales URL:

https://<sso-host>/siebel/app/sales/enu

Add the following managed resources. Enable regular-expression matching for expressions that use .*.

PriorityPurposeResource URLAuthentication method
1Root favicon/favicon.icoPublic
2Static files/siebel/files/.*Public
3Static images/siebel/images/.*Public
4Static scripts/siebel/scripts/.*Public
5Static fonts/siebel/fonts/.*Public
6Static ENU resources/siebel/enu*Public
7Siebel Sales/siebel/app/sales/enu.*Form or Access token
Fig 2.1: List of managed resources in Enterprise App for Siebel Sales

App Gateway protects the Sales application path while allowing the presentation assets required by the Siebel interface to load without starting a separate authentication flow for each asset. Public access applies only to these static resources; it does not make Siebel application data public.

Fig 2.2: OCI IAM managed resources showing the Sales and public static-resource entries

Map the Siebel User

On the Siebel Sales managed resource, name the identity header (User Specification from Fig 1.6) & select the OCI IAM attribute from the list.

Fig 2.3: Managed resource authentication method & header mapping

In this demo, siebelUserId is the attribute that has the Siebel username of the respective users. App Gateway adds the resulting header to the request sent to Siebel. Populate the OCI IAM attribute siebelUserId of the users with the exact Siebel USERID assigned to each user.

Fig 2.4: OCI IAM user with custom attribute

Configure the App Gateway Mapping

Configure the App Gateway Host section:

ItemValue
Host identifierSiebelSalesHost (example)
Public host<sso-host>
App Gateway listenerHTTP 8080
SSL enabledNo, when TLS terminates at the OCI Load Balancer
Fig 2.5: Host settings for the App Gateway

In the App Gateway Apps section, map the enterprise application to the Siebel origin:

ItemValue
Enterprise applicationSiebel Sales
Resource prefix/
Origin serverhttps://<siebel-origin>:443/
Fig 2.6: App settings for the App Gateway

In this deployment, the App Gateway container uses host networking. NGINX inside the container listens directly on host TCP port 8080. When TLS terminates at the OCI Load Balancer, add the following request header before forwarding traffic to App Gateway:

is_ssl: ssl
Fig 2.7: A request header rule on OCI Load Balancer

This allows https:// callback URLs and secure cookies to be generated by the App Gateway even though the Load Balancer-to-App-Gateway connection uses HTTP.


Section 3: Supporting configuration considerations

Preserve the Public Application Address

Configure the public Fully Qualified Domain Name of the App Gateway in the Siebel Application Interface profile. This should match with the public host configuration of App Gateway in Fig 2.5.

Fig 3: FQDN setup of the AI profile

This prevents generated links, redirects, and cookies from referring to the internal Siebel address or bypassing App Gateway.

Allow larger request Headers

Requests protected by App Gateway carry IAM session cookies and identity headers in addition to the application cookies already used by Siebel. The combined request headers can therefore exceed the default limit of the Siebel Application Interface.

Siebel CRM 26.7 uses an Apache Tomcat application container for the Application Interface. For this particular deployment, the request-header limit is increased to 32KB.

/persistent/<ai-interface-pod>/applicationcontainer_external/conf/server.xml

<Connector
    port="4430"
    maxHttpRequestHeaderSize="32768"
    ... />

Note: The value should be applied through the supported declarative deployment configuration in production. Request-header growth should be monitored rather than increasing the limit without an identified requirement. Back up server.xml before changing it and restart or recreate only the Application Interface afterwards.

Prevent Origin bypass

The Siebel origin should accept application traffic only from the trusted App Gateway path. If the origin remains directly accessible to users, the protected URL can be bypassed and the identity header can potentially be supplied outside the intended authentication flow.


Section 4: Validate the sign on flow

Open a new browser session and navigate to the below:

https://<sso-host>/siebel/app/sales/enu

Verify the following behaviour:

  • The request is redirected by App Gateway to OCI IAM
  • The configured sign-in flow or external identity provider is invoked
  • The authentication callback returns through App Gateway
  • Siebel Sales opens without displaying the native Siebel login page

Logout limitation

Clicking on Logout from the user menu terminates the Siebel application session and returns the browser to the Siebel sign-in page, but it does not end the OCI IAM session. The Oracle Siebel Security Guide describes this behaviour in Known Issues in Siebel IDCS Integration and notes that scripting is required to invalidate the relevant browser cookie and navigate the user to the identity-service sign-in page.

To mitigate this, we appended the below code-snippet on the client-side JavaScript used by the Siebel login page:

/* BEGIN OCI IAM APP GATEWAY LOGOUT */
(function redirectAfterSiebelLogoff() {
    "use strict";

    try {
        var currentLocation = window.top.location;

        /* Apply the redirect only to the public SSO hostname */

        if (currentLocation.hostname !== "sso.tonmendu-bose.2bd.net") {
            return;
        }

        if (currentLocation.pathname !== "/siebel/app/sales/enu") {
            return;
        }

        var parameters = new URLSearchParams(currentLocation.search);
        var command = (parameters.get("SWECmd") || "").toLowerCase();

        /* Allow Siebel to process its native Logoff */

        if (command !== "logoff") {
            return;
        }

        var applicationUrl =
            currentLocation.origin + "/siebel/app/sales/enu";

        var appGatewayLogoutUrl =
            currentLocation.origin +
            "/cloudgate/logout.html?postlogouturl=" +
            encodeURIComponent(applicationUrl);

        window.top.location.replace(appGatewayLogoutUrl);
    } catch (error) {
        if (window.console && window.console.warn) {
            window.console.warn(
                "OCI IAM logout redirect could not be completed",
                error
            );
        }
    }
}());
/* END OCI IAM APP GATEWAY LOGOUT */

It performs three checks before redirecting to the App Gateway cloudgate-logout URL:

  • The browser is using the public SSO hostname
  • The request belongs to the Sales application
  • Siebel has processed a request containing SWECmd=Logoff

With this, a separate Form + Logout managed resource in App Gateway is no longer required. The customized login.js must be included in the persistent Siebel deployment artifact used to serve the Application Interface static content. For our deployment, the file was located at:

/siebel/mde/applicationcontainer_external/siebelwebroot/scripts/login.js

Conclusion

Single Sign On eliminates the need to maintain separate login/passwords. With this integration, administrations can leverage the capabilities of OCI IAM for better protecting the Siebel applications.


References