SAML

SAML is an open identity standard that lets an application accept a user's verified sign-in from a trusted identity provider. It enables single sign-on, so users can access connected web applications without entering separate passwords for each one. SAML 2.0 commonly uses signed XML assertions and is widely used for enterprise workforce access.

Build SAML-ready apps with Emergent.

What Is SAML?

SAML, or Security Assertion Markup Language, is an open standard that lets an application trust a user sign-in verified by another system. It supports federated identity and single sign-on (SSO), usually through signed XML messages in SAML 2.0. SAML proves who the user is, while the application still decides what that user is allowed to do.

How SAML Authentication Works

A common service provider initiated flow starts when a user opens an application.

  1. The service provider (SP), the application being accessed, creates a sign-in request.
  2. The browser redirects the user to the identity provider (IdP), such as an organization’s central login system.
  3. The IdP authenticates the user, often applying multi-factor authentication.
  4. The IdP returns a signed SAML response containing an assertion, a statement about the user’s identity.
  5. The SP validates the signature with the IdP certificate, plus the issuer, audience, and time limits.
  6. The SP creates an application session and may use relay state to return the user to the original page.

Metadata exchanges the trusted URLs, identifiers, and certificates needed for this connection.

SAML, OAuth 2.0, OpenID Connect, and LDAP Compared

These technologies solve related but different identity problems. SAML is not required for SSO, because OpenID Connect can also provide it.

TechnologyPrimary purposeCommon use
SAMLFederated sign-inEnterprise web application SSO
OpenID ConnectFederated sign-in using JSON tokensModern web and mobile apps
OAuth 2.0Delegated API accessLetting one app access another service
LDAPDirectory lookup protocolReading users and groups from a directory

SAML and OAuth can work together. For example, SAML can sign a workforce user into an application, while OAuth grants that application limited access to an API.

Benefits of SAML Single Sign-On

SAML centralizes authentication across connected applications.

  • Fewer passwords for users to manage.
  • Consistent multi-factor authentication policies.
  • Faster employee onboarding and access removal.
  • Central control through established enterprise identity providers.

Practical Limits of SAML

SAML remains widely used, but it is not the best fit for every software flow.

  • XML, certificates, and metadata can be difficult to configure.
  • It is designed mainly around browser redirects.
  • OpenID Connect often fits mobile and API-centric products better.
  • Application roles and permissions still need separate management.

Secure SAML Implementation Checks

Trust should be explicit and narrowly configured.

  • Validate signatures, issuer, audience, and assertion time conditions.
  • Allow only approved reply URLs and identity providers.
  • Rotate signing certificates before they expire.
  • Do not authorize users based on an email address alone.
  • Test session expiration and logout behavior.

Using SAML in Applications Built With Emergent

Teams building a business application should define their IdP, allowed domains, roles, redirect URLs, and session rules before adding enterprise SSO. An AI app builder can accelerate full-stack development, while planning identity alongside app design and development helps ensure SAML protects the right application paths. Build SAML-ready apps with Emergent.

Start Building
on Emergent today
Start Building