Antonio Braccolino, Identity & Access, home
EN · Language: English
← All terms

IAM glossary

What is Assertion?

SAML assertion

The signed XML document in which a SAML identity provider states who the user is, when they signed in and with which attributes. The service provider must check signature, audience and validity window.

How it works

In SAML, after the user signs in at the identity provider, the IdP builds an assertion: an XML document that says who the user is (NameID), when and how they authenticated (AuthnStatement), for which application it is valid (Audience), until when (NotOnOrAfter) and which attributes they have (email, groups).

The IdP signs the assertion with its private key and the browser carries it to the service provider inside a SAMLResponse. The SP verifies the signature with the IdP certificate it trusts, checks audience, time window and recipient, and only then creates a session.

A simple example

Anna clicks “Sign in with the company account” on the expense app. The company IdP sends back an assertion stating “NameID: anna@company.com, Audience: expenses-app, valid until 10:05, groups: finance”, signed. The expense app checks the signature and the audience and lets Anna in with finance permissions.

Common mistakes

  • Accepting assertions without checking the signature, or checking a signature that covers a different part of the XML (signature wrapping attacks).
  • Ignoring Audience and time conditions, so an assertion for another app or an old one is accepted.
  • Forgetting to update the IdP certificate before it expires, which breaks every login at once.

See it at work