A user can hold a newly refreshed token and still be relying on authentication completed hours ago. For a high-risk action, that gap matters more than the assurance setting on your login screen. It also exposes a design question that architects keep answering differently: when you adopt step-up authentication from an identity provider, where does the policy actually live?
What Cognito's step-up claims tell you
Amazon Cognito now supports step-up authentication using standard OpenID Connect claims. You request a target level with acr_values and optionally max_age. Cognito returns the achieved level in acr, the methods used in amr, and the time of the last interactive authentication in auth_time.
Cognito defines four fixed levels. Level 1 is password only. Level 2 is a single one-time password over SMS or email. Level 3 is a passkey alone, or a password plus an SMS or email one-time password. Level 4 is a password plus a Time-Based One-Time Password.
The debate is about enforcement. Should you treat the provider's level system as your assurance policy, or treat it only as evidence that your own policy engine consumes? Both camps are serious. Both have scars.
The case for approach A: lean on the identity provider
Teams in this camp argue that centralization is the point. If Cognito owns the factor combinations and issues the claims itself, you get a consistent, auditable statement of authentication strength. Cognito computes these claims; you can't add to or suppress them with a pre-token-generation Lambda trigger. That tamper-resistance is a real feature.
The practical arguments follow from it:
- Fewer moving parts. Application teams request a level and compare a claim. They don't build factor-orchestration logic or maintain their own challenge flows.
- Consistent semantics across applications. Level 4 means the same factor combination everywhere in the user pool. Auditors get one definition to review.
- Lower implementation risk. Rolling your own step-up is where subtle bugs live. A provider-maintained flow, including the redirect to managed login, has had more scrutiny than a bespoke one.
- Standards alignment.
acrandamrcome from OpenID Connect Core, so downstream services can reason about them without proprietary parsing.
For a small team with a handful of applications, this is a defensible position. Let the provider be the authority on what happened, and keep your code thin.
The case for approach B: the provider reports, your code decides
The opposing camp starts from a narrower claim about what Cognito actually does. It acts only on what you send. It doesn't infer the level you meant. If you omit the parameter or request the wrong level, the user may not be stepped up at all. And the token honestly reports the level reached based on what your application requested. Nothing in that sequence refuses a sensitive operation on your behalf.
That's the core of the argument. Deciding that a transfer needs level 4, checking acr against that requirement, and denying the request when it falls short is enforcement that your application and API perform. Cognito produces evidence; your code acts on it.
Practitioners in this camp point to several failure modes that a "trust the provider" posture hides:
- Freshness is a separate input. A token refresh preserves
acrandamr, butauth_timestill records the last interactive authentication. A refreshed token carries a newiatand an oldauth_time. If your authorization path checks onlyacr, a level 4 session from the morning satisfies a high-value request in the afternoon. - Level labels aren't framework equivalences. The factor combinations are fixed, and any mapping to NIST SP 800-63 or eIDAS is yours to make and defend. Level 3 isn't automatically "AAL2," and a label in a token is not a compliance attestation.
- Stale values happen. If you rename the ACR URIs after tokens are issued, older tokens can carry a value that matches no configured level. Cognito treats that as unrecognized rather than an error. Your code needs a deliberate answer. Ranking an unknown
acras zero is one way to fail closed, but you should make that behavior explicit. - Replay and binding. Without a nonce sent in the request and verified on the returned ID token, you can't tie the result to the request you made.
This camp's conclusion is that the provider can't carry risk thresholds, because it has no idea what a "high-value transfer" is.
Divide authentication evidence from policy
Almost nobody ends up purely in either camp. The pattern that holds up in practice splits the work by what each side can know.
The provider is the authority on facts: which factors were completed, at what level, and when. The application is the authority on policy: which operations need which level, how fresh the proof must be, and what happens when the evidence is missing or ambiguous.
In a typical design, you'd see these habits:
- A written threshold table per operation. Not per application. A banking app might set a baseline at level 2 and require level 4 for transfers above $1,000. The threshold, the rationale, and an owner are documented where reviewers can find them.
- Checks at the point of action. The API, not just the UI, compares the achieved claims to the operation's requirement. A front-end redirect is a convenience; the API's refusal is the control.
- Check before redirecting. Inspect the token already held so you don't send a user through reauthentication they've already satisfied.
- Validate the returned token. Confirm
acr,auth_time, and the nonce on the freshly issued token before proceeding. - Freshness where it matters. Add
max_agefor the highest-risk actions so reauthentication is forced even when the token was refreshed seconds ago. - A policy for unrecognized
acr. Default to deny for high-risk operations. Theamrlist stays meaningful even when a renamed level string goes stale, so you can use it as supporting evidence, such as confirming a Time-Based One-Time Password factor was used, but a deliberate rule should say when that's acceptable. - Test the edges. Exercise refreshed tokens, renamed URIs, and requests with a missing
acr_values. These are the paths that fail quietly.
One practical constraint belongs in the planning conversation early: requesting step-up in Cognito requires the Essentials or Plus feature plan.
Use Cognito for evidence, not policy
Approach B is correct on the principle; approach A is correct on the mechanics. Use the provider for what it does well, which is issuing claims based on the factors completed and running the factor flows. But don't let the existence of a level system persuade anyone that a sensitive operation is protected.
The risk is a quiet one. A team enables assurance levels, sees acr in tokens, and assumes the work is done. Nothing breaks. Nothing is enforced either, until an auditor or an attacker finds the operation that never checked.
The tradeoff is real. Owning enforcement means more code, more tests, and a threshold table someone has to maintain. For a small portfolio, that overhead can feel heavy. But the alternative is delegating a policy decision to a system that doesn't have the context to make it.
Treat Cognito's levels as evidence, your thresholds as policy, and your API as the place where the two meet. If you can't point to the line of code that refuses an under-assured request, you don't have step-up. You have a login screen with extra steps.





