This is unreleased documentation for SUSE® Rancher Manager v2.16 (Unreleased).

Configue Generic SAML

The Generic Security Assertion Markup Language (SAML) authentication provider lets users log in to SUSE Rancher Prime. They can use credentials from any SAML 2.0 Identity Provider (IdP).

Use it when your IdP has no dedicated provider in SUSE Rancher Prime, for example Auth0, Google Workspace or CA Siteminder.

Generic SAML uses the same SAML implementation as the other SAML providers in SUSE Rancher Prime. It adds settings for the NameID format, the signature algorithm, IdP-initiated login and forced re-authentication.

Prerequisites

Consult the documentation for your IdP to complete the following prerequisites:

  • Ensure that you have a SAML 2.0 IdP that you can configure.

  • In your IdP, create a SAML application, also called a SAML client or service provider, with the following settings:

    Setting Value

    Assertion Consumer Service (ACS) URL, also called Single Sign-On URL or Reply URL

    https://yourRancherHostURL/v1-saml/genericsaml/saml/acs

    Entity ID, also called Audience URI or SP Entity ID

    https://yourRancherHostURL/v1-saml/genericsaml/saml/metadata, or the value you enter in the Entity ID Field in SUSE Rancher Prime

    Single Logout (SLO) URL, optional

    https://yourRancherHostURL/v1-saml/genericsaml/saml/slo

  • In the SAML application, configure attribute statements that send the following user details in the SAML assertion:

    • A display name

    • A user name

    • A value that is unique for every user

    • The groups that the user belongs to

  • Configure the IdP to sign the SAML response, the assertion, or both. SUSE Rancher Prime rejects SAML responses where neither is signed.

  • Download the IdP metadata XML file. The root element of the file must be EntityDescriptor.

    Metadata generation

    SUSE Rancher Prime generates the service provider metadata at https://yourRancherHostURL/v1-saml/genericsaml/saml/metadata only after you configure and save the Generic SAML provider.

Configuring Generic SAML in Rancher

Follow these steps to configure Generic SAML in SUSE Rancher Prime:

  1. In the top left corner, click ☰ > Users & Authentication.

  2. In the left navigation menu, click Auth Provider.

  3. Click Generic SAML.

  4. Complete the Configure a generic SAML provider form. For help with the fields, see the configuration reference.

  5. Click Enable.

    SUSE Rancher Prime redirects you to the IdP login page. Enter your IdP credentials to validate the Generic SAML configuration.

    Browser pop-up blockers and IdP login pages

    Your browser pop-up blocker can prevent the identity provider (IdP) login page from opening. If the login page does not appear, disable the pop-up blocker for this site or allow pop-ups in your browser settings.

Result: SUSE Rancher Prime is configured to work with your SAML IdP. Your users can now log into SUSE Rancher Prime using their IdP credentials.

SAML provider caveats

Generic SAML doesn’t support OpenLDAP user and group search. This has the following effects:

  • SUSE Rancher Prime doesn’t validate users and groups when you assign permissions to them.

  • User search returns only users who already logged in to SUSE Rancher Prime through this provider. SUSE Rancher Prime matches the search text against their user name and display name.

  • To add a user who hasn’t logged in yet, enter the exact user ID, that is, the value of the UID Field attribute.

  • SUSE Rancher Prime doesn’t search for groups. To add a group, enter the exact group name that the IdP sends in the Groups Field attribute.

Configuration reference

Field Description

Display Name Field

The attribute that contains the display name of users.

Example: displayName

User Name Field

The attribute that contains the user name.

Example: email

UID Field

The attribute that is unique to every user.

Example: email

Groups Field

The attribute that contains the groups that the user belongs to.

Example: groups

Entity ID Field

The entity ID of SUSE Rancher Prime as a service provider. It must match the entity ID configured in the IdP application.

Default: https://yourRancherHostURL/v1-saml/genericsaml/saml/metadata

Rancher API Host

The URL of your Rancher server.

Private Key / Certificate

A key and certificate pair. SUSE Rancher Prime uses the private key to sign SAML requests and to decrypt encrypted assertions. The IdP uses the certificate to verify the signature.

Metadata XML

The IdP metadata XML file.

NameID Format

The NameID format that SUSE Rancher Prime requests from the IdP. Options are Unspecified, Email Address, Transient and Persistent.

Default: Unspecified

Signature Algorithm

The algorithm SUSE Rancher Prime uses to sign SAML requests. Options are RSA-SHA256, RSA-SHA1 and RSA-SHA512.

Default: RSA-SHA256

Allow IdP-initiated login

If selected, SUSE Rancher Prime accepts SAML responses that the IdP sends without a prior request from Rancher. Users can then start the login from the IdP portal.

Default: Cleared

Force re-authentication

If selected, SUSE Rancher Prime asks the IdP to authenticate the user again, even if the user already has a session with the IdP.

Default: Cleared

Generating a key and certificate pair

You can generate a key and certificate pair with an openssl command. For example:

openssl req -x509 -sha256 -nodes -days 365 -newkey rsa:2048 -keyout myservice.key -out myservice.crt
Security risks of IdP-initiated login

IdP-initiated login is more exposed to replay and login cross-site request forgery attacks than service provider initiated login.

Select Allow IdP-initiated login only if your users need to start the login from the IdP portal.

IdP-initiated login behavior

After an IdP-initiated login, SUSE Rancher Prime logs the user in but doesn’t redirect the browser to the SUSE Rancher Prime UI. The browser shows a blank page. To continue, open the Rancher URL in the browser.

Weak signature algorithm

RSA-SHA1 is a weak algorithm. Using it can expose your authentication process to security risks.

Use RSA-SHA1 only if your IdP doesn’t support RSA-SHA256 or RSA-SHA512.

Troubleshooting

If the login fails, first verify the settings of the SAML application in your IdP. The SUSE Rancher Prime debug logs can help you find the cause of the problem. For more information, see How can I enable debug logging.

Forbidden message displayed after IdP login

You can enter your credentials on the IdP login page, but SUSE Rancher Prime displays a Forbidden message afterward. To resolve this issue, follow these steps:

  1. Check the SUSE Rancher Prime debug log.

  2. If the log displays SAML ERROR: signature element not present, configure your IdP to sign the SAML response, the assertion, or both.

HTTP 404 when accessing the metadata URL

SUSE Rancher Prime serves the metadata at /v1-saml/genericsaml/saml/metadata only after you configure and save Generic SAML. Configure and save the provider, and then access the metadata again.

Configuring SAML Single Logout (SLO)

Rancher supports the ability to configure SAML SLO. Options include logging out of the Rancher application only, logging out of Rancher and registered applications tied to the external authentication provider, or a prompt asking the user to choose between the previous options. The steps below outline configuration from the application GUI:

The Log Out behavior configuration section only appears if the SAML authentication provider allows for SAML SLO.

  1. Sign in to Rancher using a standard user or an administrator role to configure SAML SLO.

  2. In the top left corner, click ☰ > Users & Authentication.

  3. In the left navigation menu, click Auth Provider.

  4. Under the section Log Out behavior, choose the appropriate SLO setting as described below:

    Setting Description

    Log out of Rancher and not authentication provider

    Choosing this option will only logout the Rancher application and not external authentication providers.

    Log out of Rancher and authentication provider (includes all other applications registered with authentication provider)

    Choosing this option will logout Rancher and all external authentication providers along with any registered applications linked to the provider.

    Allow the user to choose one of the above in an additional log out step

    Choosing this option presents users with a choice of logout method as described above.