SAML
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.
- The service provider (SP), the application being accessed, creates a sign-in request.
- The browser redirects the user to the identity provider (IdP), such as an organization’s central login system.
- The IdP authenticates the user, often applying multi-factor authentication.
- The IdP returns a signed SAML response containing an assertion, a statement about the user’s identity.
- The SP validates the signature with the IdP certificate, plus the issuer, audience, and time limits.
- 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.
| Technology | Primary purpose | Common use |
|---|---|---|
| SAML | Federated sign-in | Enterprise web application SSO |
| OpenID Connect | Federated sign-in using JSON tokens | Modern web and mobile apps |
| OAuth 2.0 | Delegated API access | Letting one app access another service |
| LDAP | Directory lookup protocol | Reading 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.
on Emergent today

