CYART // SCHEMA · TOKEN-FLOW6 NODES · 6 LINKSVISIT1AUTH CODE + PKCE2CODE → TOKENS3BEARER ACCESS TOKEN4VERIFY SIGREFRESHACTOR · User — browserACTOR01UserbrowserSERVICE · Web app — BFF, httpOnly cookieSERVICE02Web appBFF, httpOnly cookieEDGE · Identity provider — login, MFA, consentEDGE03Identity providerlogin, MFA, consentSERVICE · Resource API — validates JWTSERVICE04Resource APIvalidates JWTDATA · JWKS — public keys, kid rotationDATA05JWKSpublic keys, kid rotationDATA · Refresh store — rotation + reuse detectionDATA06Refresh storerotation + reuse detection

OAuth consent phishing and token theft

Attacks that skip the password: illicit consent grants to malicious apps, attacker-in-the-middle phishing that steals session cookies after MFA, device code phishing, and abuse of app credentials, with the log evidence for each and the remediation that actually removes access.

🔒 PROBy ·Lesson·14 min read·Advanced → Staff
OAuth consent phishingtoken theftAiTM phishingdevice code phishingEntra IDsession hijacking

01Why tokens and consents matter

✓What you will learn
  • Investigate an illicit consent grant and remove it properly
  • Recognise attacker-in-the-middle token theft in sign-in logs
  • Spot device code phishing and app credential abuse
  • Know what revoking sessions does and does not invalidate

Modern identity attacks often never need the password again, or never need it at all. Once a user has authenticated, access is carried by tokens: short-lived access tokens presented to APIs, longer-lived refresh tokens that obtain new access tokens, and browser session cookies. An app that has been granted consent can obtain tokens for the user on its own. Steal or obtain any of these, and MFA has already been satisfied.

FigWhere tokens are issued and replayed
CYART // SCHEMA · TOKEN-FLOW6 NODES · 6 LINKSVISIT1AUTH CODE + PKCE2CODE → TOKENS3BEARER ACCESS TOKEN4VERIFY SIGREFRESHACTOR · User — browserACTOR01UserbrowserSERVICE · Web app — BFF, httpOnly cookieSERVICE02Web appBFF, httpOnly cookieEDGE · Identity provider — login, MFA, consentEDGE03Identity providerlogin, MFA, consentSERVICE · Resource API — validates JWTSERVICE04Resource APIvalidates JWTDATA · JWKS — public keys, kid rotationDATA05JWKSpublic keys, kid rotationDATA · Refresh store — rotation + reuse detectionDATA06Refresh storerotation + reuse detection
  • ACTOR
  • EDGE
  • SERVICE
  • DATA
  • Live flow
  • Lookup / async
//The user authenticates once with the identity provider, which issues tokens to the client. An attacker who steals a refresh token or session cookie, or who owns an app the user consented to, can request new access tokens without the password or MFA.
AttackWhat the attacker getsSurvives a password reset?
Consent phishing (malicious multi-tenant app)Delegated permissions such as Mail.Read with offline_access: tokens on demandYes, until the grant is removed
AiTM phishing (Evilginx-style reverse proxy)The session cookie issued after real MFAYes, until sessions are revoked
Device code phishingTokens issued to the attacker's device after the user enters a codeNot after sessions are revoked; registered devices may persist
App credential abuseA secret or certificate added to an existing privileged appYes: app credentials are independent of any user

This is an advanced module

Cloud & identity incident response is part of the Pro pass. 4 more sections — the deep dives, the final design, follow-ups and the test — unlock with it.

Already a cyart.io or studio.cyart.io member? Your pass code is in your Studio account.