What it is
SAML, short for Security Assertion Markup Language, is a long-standing standard for single sign-on in workplaces. You log in once with your company's identity provider, such as a corporate directory, and then reach many other apps without typing a password again. Those apps trust the identity provider's word that you are who you say you are.
An analogy: SAML works like a concert wristband. The gate staff check your ticket once and give you a band. Every stage after that looks at the band and does not ask for the ticket again.
How it works
Two roles are involved. The identity provider knows who you are. The service provider is the app you want to use. When you open the app, it redirects you to the identity provider. After you sign in, the identity provider sends back a signed XML document called an assertion, which states who you are and sometimes your group or role. The app checks the signature, the time limits and the intended audience, and if everything is in order, it lets you in.
The signature is the whole point. Without it, anyone could write an assertion claiming to be an administrator. Sources on SAML security stress that an app must verify the signature against the certificate it expects from that identity provider, and must reject unsigned or wrongly signed assertions.
Where it goes wrong
SAML relies on parsing XML, and subtle parsing mistakes have caused real vulnerabilities. A well-known class is signature wrapping, where an attacker arranges a document so that the part that was signed differs from the part the app reads. Other mistakes include skipping the check for expiry, audience or replay of an old assertion.
For this reason, security guidance recommends using a well-maintained SAML library and not writing your own signature handling. A missing signature check is also a classic finding in penetration testing, and automated tools that probe for it make weak implementations easy targets.
Why it matters if you build with AI
AI products often get sold to companies, and companies expect single sign-on. Supporting SAML is part of that, and so is getting it right. It sits alongside other identity standards such as OAuth and passkeys, and it complements multi-factor authentication. An AI agent that logs in on a user's behalf needs its own identity too, which is the problem agent identity addresses.
What to remember
SAML proves identity but does not grant everything by itself. Apps still decide what each person may do, following least privilege.