Skip to main content

How to implement SAML based SSO using Auth0

This tutorial explains the steps to implement SSO with SAML authentication using Auth0.
It involves using Auth0 as IdP and Kuroco as SP for SAML authentication.

Prerequisites​

This tutorial assumes that you have an account with Auth0.

Creating an App in Auth0​

Logging in to Auth0​

Log in to Auth0 here and click on the [Create Application] button at the top right of the screen under the [Applications] menu.

Image from Gyazo

Creating an App​

Enter a name of your choice, select "Regular Web Applications," and click [Create].

Image from Gyazo

Getting Configuration Information​

Once the app is created, navigate to the [Settings] tab.

Image from Gyazo

Scroll down to the bottom of the page and open [Advanced Settings].

Image from Gyazo

Downloading the Certificate​

Open the [Certificates] tab, click [Download Certificate] to download the certificate.
Choose the PEM file format.

Image from Gyazo

Getting the SAML Protocol URL​

Open the [Endpoints] tab and copy the SAML Protocol URL under the SAML section.

Image from Gyazo

Configuring Kuroco​

Adding SAML SP​

Click on [External System Integration] -> [Identity federation] -> [SAML SP] in the Kuroco admin panel.

Image from Gyazo

Click on [Add].

Image from Gyazo

Configure the fields in the SAML SP editing screen as follows.
Click on [Do you have a configuration file? Click here to display] to show the certificate input field.

Image from Gyazo

Image from Gyazo

Field Descriptions​

FieldDescription
Login SAML SP NameEnter a name of your choice.
Target DomainSelect [Management Screen].
Entity IDEnter any string.
CertificateClick on [Select File] and upload the certificate (.pem file) obtained from Auth0.
IDP URLEnter the SAML Protocol URL obtained from Auth0.
IDP Entity IDEnter the SAML Protocol URL obtained from Auth0 (same as IDP URL).
Expiration DateSet any date and time.
Use Login IDTurn off the checkbox.
Automatic User RegistrationTurn on the checkbox and select any group.
Allow IDP-initiated FlowTurn on the checkbox.
Binding MethodSelect "POST".

Checking the Login SAML SP ACS URI​

Click on the previously added [Login SAML SP Name].

Image from Gyazo

Copy the [Login SAML SP ACS URI] displayed.

Also, since the certificate file is missing, re-upload it for an update.

Image from Gyazo

Enabling SAML2 WEB APP on Auth0​

Go back to the App settings on Auth0 and click on the [SAML2 WEB APP] tab.

Image from Gyazo

Once the Addon settings open, enter the Login SAML SP ACS URI that you confirmed on the Kuroco admin screen into the Application Callback URL, and enter the following JSON into Settings.

{
"mappings": {
"name": "name1",
"email": "email"
}
}

Image from Gyazo

After configuring, scroll down to the bottom of the screen and click on [Enable].

Image from Gyazo

Once [SAML2 WEB APP] is enabled, the Auth0 configuration is complete.

Image from Gyazo

Verifying the functionality​

After the setup is complete, an SSO link will be displayed on Kuroco's login page.

Image from Gyazo

Clicking on the link will redirect you to the Auth0 login page.

Image from Gyazo

You will now be able to perform SAML login here.


Support

If you have any other questions, please contact us or check out Our Slack Community.