Menu

1 / 2

Device code phishing and what it means for AWS

DEV Community: aws·Yuuki Yamashita·12 days ago
#LvMs1FH3
#devtoaws#devto#dev#device#code
Reading 0:00
15s threshold

You open Slack and see a message from someone claiming to be on your platform team: "Quick favor, go to the AWS sign-in page, it'll show a code, type XXXX-XXXX and approve it so I can finish setting up your access." The page it points to is real. The login screen is real. Your password and your MFA prompt are real. And yet, if you type that code in, the session that gets created does not belong to you anymore.

That's device code phishing, and it rides on a legitimate part of OAuth called the device authorization flow. AWS uses this flow in a few places, so it's worth understanding how it works, where it shows up, and what actually stops it.

What is the device authorization flow

The device authorization flow is defined in RFC 8628. It was built for devices that are awkward to type on: smart TVs, CLI tools, IoT boxes.

A familiar example is logging into Netflix or YouTube on a smart TV. The TV shows a short code and a URL. You open that URL on your phone, type the code, and sign in there instead.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.