Authentication policy and SSO
An authentication policy decides which evidence each situation needs: which methods count, how recent a sign-in must be, and who a stricter rule covers. With single sign-on, that decision has to travel from the identity providerA service that authenticates users and tells other applications about the sign-in, so those applications never handle the users' passwords. In OpenID Connect it is called an OpenID Provider. to each application, which then checks it for itself.
Choosing the evidence
Lab Photos' identity provider signs people in to more than one application: the photo app where Ava Archer keeps her albums, the print shop where she orders prints, and the support tool its own staff use. Ava may sign in with a password, an authenticator appSomething a person controls and uses to prove control of an account, such as a memorized password, an app that generates one-time codes, or a security key. It counts only after it has been registered to that account. or a passkeyA credential that your phone, computer or password manager creates for one website and keeps for you, unlocked with a fingerprint, face or PIN. Nothing you could type is sent, and it works only for the site it was made for, which helps it resist phishing.. Browsing her albums might need an ordinary sign-in, while Ben Okafor, on the help desk, exporting a customer's account data might need a passkey sign-in from the last few minutes. An authentication policy sets the evidence required for each situation.
Offering a method does not mean accepting it everywhere. Lab Photos might accept an authenticator-app code for Ava's albums while requiring a verified passkey for anything done in the support tool, applying the assurance levels from Authenticator assurance levels. The policy must also cover how people enroll methods and recover access, as Designing account recovery showed: if a text message could reset Ben's passkey, his account would be only as strong as that text message.
Configuring a policy
When Lab Photos' administrators set a policy, they decide which methods people can use and when a stronger or more recent check is required. Each choice affects people who already have accounts, not only new ones.
| Choice | Example consequence |
|---|---|
| Allowed methods | Can people enroll synced passkeys, security keys, authenticator apps, or other supported methods? |
| Required evidence | Does an action require any accepted method, MFA, or phishing-resistant MFA? |
| Scope | Which people, applications, roles, or actions does a rule cover? |
| Freshness and sessions | How recent must authentication be, and when must a session be renewed or ended? |
| Enrollment and recovery | How do people add replacements and recover access without bypassing the intended assurance? |
A rule's scope is often a role. Lab Photos can ask everyone who holds a management role, such as Ben's help desk role, for a second step every time, while customers like Ava choose for themselves. Giving someone that role then changes what is enough for them at their next sign-in.
Suppose Lab Photos requires passkeys for its staff but has not given them a way to enroll one. The new rule would stop their work. Administrators need to see who a change affects, arrange enrollment or backup methods, and introduce the rule in a controlled order, often with a deadline that gives everyone time to enroll before the rule is enforced. If rules overlap, the service needs a defined way to decide which one applies.
Fresh and stronger authentication
Ben signed in with a passkey this morning, but exporting a customer's data requires a check performed in the last few minutes. The support tool asks Ben to sign in again. This is reauthentication. If Ben had signed in just now with a password but the export requires a passkey, the tool asks for stronger evidence. This is step-up authentication.
A request can need both: a fresh check with a stronger method. Issuing a new tokenA piece of data issued by a trusted service that a client presents as a credential, for example to call an API or to report a sign-in. Some tokens carry readable claims; others are random strings that only the issuer can interpret. from an existing sessionThe ongoing connection between later requests and an earlier sign-in, so you are not asked for your password on every click. It is often tracked with a cookie holding an unpredictable session identifier. does not establish that Ben just authenticated, so the application needs trustworthy information about when and how the check occurred.
A policy can also respond to signals such as an unfamiliar device, an unusual location, or a sudden change of browser by asking for more evidence. This is often called risk-based or adaptive authentication. Those signals may shape the decision, but none of them proves something Ben knows, has, or is, so they never replace a factor the policy requires.
Carrying trust to an application
With single sign-on (SSO), which Trust across systems introduced, Ava signs in once at Lab Photos' identity provider and opens the print shop without entering credentials there again. The identity provider may reuse her existing session, or it may ask for a new check when the application's policy requires one.
OpenID ConnectAn identity layer on top of OAuth 2.0 that lets an application sign people in with an account at another service. It adds the ID token, standard claims, and discovery to the OAuth exchange. and SAMLThe Security Assertion Markup Language, a federation standard widely used for workplace single sign-on, in which the identity provider sends the application a signed assertion about the user. carry the authentication result from the identity provider to the application. Before creating its own session, the application validates that the result came from the expected provider, is meant for this application, is still valid, and belongs to the request it made.
In OpenID Connect, the ID tokenIn OpenID Connect, a signed JWT from the provider, addressed to one client, saying which account authenticated, when, and in answer to which request. It reports a sign-in and is not used to call APIs.'s auth_time claim tells the application when Ava authenticated, and its acr and amr claims, introduced with the assurance levels, describe the authentication context and methods, if Lab Photos and the application have agreed on their meaning. Some values have shared definitions: RFC 8176 lists common amr values, such as pwd for a password and hwk for a hardware-protected key, and an acr value may name an assurance levelA published level of confidence for a process such as identity proofing, where each higher level requires stronger evidence and checks. Levels let a claim like "we verified this person" mean the same thing from one service to the next. from a published framework such as NIST SP 800-63. The token's iat, its issue time, is not necessarily the time Ava signed in, and an absent method claim cannot be taken as proof of MFASigning in with more than one type of factor, such as a password plus a code from an enrolled authenticator app. Two passwords are still one factor type, however many screens they appear on..
{
"auth_time": 1790553600,
"acr": "urn:labphotos:example:phishing-resistant-mfa",
"amr": ["hwk", "pin", "mfa"]
}This fragment is illustrative, not a signed token. The amr values come from the RFC 8176 registry: hwk for a hardware-protected key, pin for the PIN that unlocked it and mfa because more than one factor was used. The acr value is Lab Photos' own name for a level, so the application needs a documented agreement about what it means. An application should expect only registered amr values or ones it has agreed with the provider, and never treat an unfamiliar value as proof of a method. The OpenID Connect lessons, starting with From delegated access to sign-in, follow the requests, claims and validation in detail.
After sign-in, each application can hold its own session. Ending Ava's identity-provider session does not automatically close every application's session, or take back tokens an application already holds.
Following a sensitive action
Ben opens the support tool through SSO and requests an export of a customer's account data. The support tool checks whether Ben currently holds a role that permits the export. It also checks whether the trusted sign-in result meets its requirements for method and recency.
Ben's session from this morning
- Role permits export
- Yes
- amr
- hwk, pin, mfa
- auth_time
- Three hours ago
Sent back to sign in again
Ben after a fresh sign-in
- Role permits export
- Yes
- amr
- hwk, pin, mfa
- auth_time
- A moment ago
Export allowed
No export role, fresh sign-in
- Role permits export
- No
- amr
- hwk, pin, mfa
- auth_time
- A moment ago
Refused: no export role
An absent method claim cannot be taken as proof of MFA.
If stronger or fresher evidence is needed, the tool sends Ben back to the identity provider for another check. When he returns, the tool validates the new result and checks its policy again. The support tool's APIAn application programming interface: a defined way for software to interact with a service. A web API offers endpoints where other programs send HTTP requests. enforces those conditions even if a request bypasses the visible export button.
If Ben cancels, the identity provider cannot perform the required check, or the result omits required evidence, the export remains blocked. A successful passkey check also cannot grant export permission to someone whose role does not include it, or whose role was removed in the meantime.
The SSO in this lesson rests on decades of earlier designs. History of SSO follows how a sign-in at one service came to be trusted by others, from shared computers and KerberosA ticket-based authentication protocol, used by Active Directory, in which a key distribution center issues time-limited tickets. A user presents a ticket to each service instead of sending a password. to SAML, OpenID Connect, and passkeys.
Check your understanding
Try these questions before moving on. If an answer isn't right, use the feedback and try again.
Try it in the Lab
- Single sign-on, fresh sign-ins and a stronger rule for role holdersSign in once and reach a second application without signing in again, force a fresh sign-in, make a role demand a second step, roll out a required method, and see what signing out ends.