SAML-based SSO for a Ruby application.

Sig 41 Reputation points

Hi there,
First of all, let me point out I'm totally new to the things below so, please, forgive me if it may feel silly.

I'm trying to develop a SAML-based SSO for a Ruby application.

In my Azure Active Directory admin center, I have created an enterprise application (SAML SSO Test) and set up single sign on as below.


On the Ruby side, I'm using the ruby-saml gem ( and I have configured it as described in the README

settings.sp_entity_id = url_base + "/saml/metadata"
settings.assertion_consumer_service_url = url_base + "/saml/acs"
settings.assertion_consumer_logout_service_url = url_base + "/saml/logout"

Where /saml/metadata returns the configuration in XML format.

Now, when I try to sign in I get the following error


What am I misisng here?
Where should I define the enitity_id in the SAML configuration on the Azure Active Directory admin center?

Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,806 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Siva-kumar-selvaraj 15,561 Reputation points

    Hello @Sig ,

    Thanks for reaching out.

    Looking at SAML authentication request, it seems that Ruby application sending following https://localhost:3000/saml/metadata as identifier so to fix this issue, you need to replace with same value in Azure AD enterprise application as shown below. Hope this helps.


    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.