Skip to main content
Version: 4.42

Redtrust IdP integration with SAML 2.0

Overview

This tutorial shows you how to integrate Redtrust with an Identity Provider (IdP) using Security Assertion Markup Language (SAML) 2.0 to enable single sign-on (SSO). It's intended for developers and IT administrators, and assumes basic familiarity with common IdPs such as Microsoft Entra ID (formerly known as Azure Active Directory) or Google Workspace.

How SAML integration works

SAML 2.0 lets a Service Provider (SP) — Redtrust, in this case — trust an Identity Provider (IdP) to authenticate your users. When a user signs in, the IdP sends the SP a signed assertion: an XML document that vouches for the user's identity and carries attributes such as their email and name.

Setting up that trust is a two-way exchange. You copy some values from your IdP into Redtrust, and some values from Redtrust into your IdP:

Identity Provider
IdP

Your directory — Entra ID, Google Workspace, Okta, or any SAML 2.0 provider. It authenticates your users.

Copy into Redtrust →
  • Sign-in URL
  • Signing certificate
  • Attribute names
  • Entity ID
  • ACS (Reply) URL
  • Signing certificate (optional)
← Copy into your IdP
Redtrust
Service Provider · SP

Trusts the IdP to authenticate users. On login it receives a signed assertion vouching for the user's identity.

Keep this picture in mind as you work: Step 1 registers Redtrust in your IdP, and Step 2 configures Redtrust with your IdP's details. Step 3 is optional and only applies if your IdP requires signed authentication requests.

Each IdP uses slightly different names for the same values. Use this table to translate between them:

What Redtrust needsMicrosoft Entra IDGoogle WorkspaceGeneric SAML term
Sign-in URLLogin URLSSO URLSSO / sign-in URL
IdP signing certificateCertificate (Base64)CertificateX.509 signing certificate
User attributesAttributes & ClaimsAttribute mappingAssertion attributes / claims

You can optionally configure Redtrust to digitally sign SAML authentication requests, which some IdPs require. You can enable this while creating the domain or later by editing the domain settings.

Before you start

Make sure you have:

  • Administrator access to Redtrust and permission to create domains in the Access section.
  • Administrator access to the IdP you're integrating, with permission to create applications.
  • The user attributes (email, name, surname) available in your IdP's directory.
info

If you already have a SAML domain and only want to add signed-request configuration, go to the optional item in Step 2 and then to Step 3.

note

If your IdP requires it, you can download Redtrust's SP metadata from the administration console. Go to Access > Domains and click Export SP metadata in the ⋯ options of your SAML domain.

Step 1: Register Redtrust in your IdP

In this step you tell your IdP about Redtrust by registering it as an application, so the IdP knows where to send authenticated users. Sign in to the relevant console as an administrator and follow the steps for your IdP.

  1. In the Microsoft Entra admin center, go to Enterprise apps.

  2. Select + New application > Create your own application.

  3. In the Create your own application panel, enter Redtrust as the app name. Make sure Integrate any other application you don't find in the gallery (Non-gallery) is selected, then click Create.

  4. On the app's Overview page, go to the Getting Started section and select Set up single sign on > Get started, then choose SAML as the method. You land on the Set up Single Sign-On with SAML page, organized as a series of numbered panels you work through top to bottom.

  5. In the Basic SAML Configuration panel, click Edit (the pencil icon in the panel's top-right corner) and enter these two values:

    Identifier (Entity ID): how the IdP uniquely names Redtrust

    https://YOUR_REDTRUST_IP/YOUR_DOMAIN

    Reply URL (Assertion Consumer Service URL): where the IdP sends its response

    https://YOUR_REDTRUST_IP/Auth/SamlConsumer

    Where:

    • YOUR_REDTRUST_IP is the IP address or host name of your Redtrust server.
    • YOUR_DOMAIN is the domain alias you create in Step 2.

    Click Save.

  6. Keep this browser tab open, you will copy several values from it in Step 2.

For the full procedure, see Microsoft's Enable SAML single sign-on for an enterprise application.

Step 2: Create the domain in Redtrust

Now configure Redtrust with the values from your IdP.

  1. In Redtrust, go to Access > Domains and click New.
  2. In the dialog box:
    1. Add the alias you want to give the domain. The domain can match the users' email domain — the part after the @.
    2. Select SAML 2 as the domain type and click Next to see all configuration options.

The table below maps each Redtrust field to where you find its value in your IdP.

  1. Using the Entra ID tab you left open in Step 1, fill in each Redtrust field:

    Redtrust fieldWhere to find it in Entra ID
    Login URL (HTTP-redirect)Set up Redtrust panel > Login URL.
    IdP X509 certificate (for signature)SAML Certificates panel > Certificate (Base64). Download the file, open it in a text editor, and copy its contents.
    EmailAttributes & Claims panel > the emailaddress claim.
    NameAttributes & Claims panel > the givenname claim (the Entra ID user must have a first name configured).
    SurnameAttributes & Claims panel > the surname claim (the Entra ID user must have a surname configured).
  2. Fill in the rest of the fields:

    • Domain: The Entra ID domain in which you want to enable SSO.
    • Is it case sensitive?: No
    • ACS by index: No
  3. (Optional) Select Signed request if you want to sign SAML authentication requests. Under Certificate source, choose Generate self-signed certificate or Upload PFX/P12 certificate. This is the public part of the signing certificate, and you need it in Step 3. If you generate a self-signed certificate, you download it in the next step.

Step 3 (Optional): Add signed request configuration

Complete this step only if your IdP requires signed authentication requests, and you selected Signed request in Step 2.

  1. If you generated a self-signed certificate in Step 2, go to Access > Domains, select the domain you just created, and download the certificate.

  2. Back in the Entra ID application, open the Verification certificates (optional) panel and click Edit (the pencil icon).

    1. Select Require verification certificates.

    2. Click Upload certificate, select your certificate, then click Ok and Save.

Verify the integration

After configuring both sides, confirm that SSO works end to end. Use a test account that belongs to the configured SAML domain:

  1. In a private browser window, open the Redtrust sign-in page and enter the email address of a user in the SAML domain.
  2. Redtrust recognizes the domain and redirects you to your IdP. Sign in there.
  3. The IdP redirects you back to Redtrust, and you land authenticated.

If you aren't redirected, or authentication fails, see Troubleshooting.

Troubleshooting

Most SAML issues come from a value that doesn't match on both sides. Check these first:

SymptomLikely causeWhat to check
The IdP rejects the request or reports an invalid audienceThe Entity ID in the IdP doesn't match RedtrustConfirm the IdP Identifier (Entity ID) is exactly https://YOUR_REDTRUST_IP/YOUR_DOMAIN, with no trailing slash
Sign-in loops, or the IdP won't return the userThe ACS (Reply) URL is wrongConfirm the Reply URL is exactly https://YOUR_REDTRUST_IP/Auth/SamlConsumer
Signature validation failsThe IdP signing certificate in Redtrust is wrong or expiredRe-copy the current Certificate (Base64) from the IdP into Redtrust
The user signs in but Redtrust shows a missing name or emailAttribute names don't match the IdP's assertionAlign the Email, Name, and Surname attribute names with those the IdP sends
A time or "response too old" errorClock skew between the serversMake sure the IdP and Redtrust server clocks are synchronized (NTP)
Signed-request errors after enabling Signed requestThe IdP isn't verifying Redtrust's signing certificateComplete Step 3, or clear Signed request if your IdP doesn't require it

Summary

In this tutorial, you configured Redtrust as a Service Provider (SP) and integrated it with an Identity Provider (IdP) using SAML 2.0 to enable SSO. You registered Redtrust in the IdP, configured Redtrust to trust the IdP, and verified the sign-in flow. Your users can now authenticate with their existing credentials, improving both security and user experience.

Next steps

Was this page helpful?