Capital One Cloud Breach
A misconfigured web firewall was tricked into asking AWS for its own credentials, which could read Capital One's storage buckets.
- Severity
- Front-page news
- Difficulty
- intermediate
- Companies
- Capital One, Amazon Web Services
- Tech
- AWS, SSRF, Instance metadata service, IAM, ModSecurity WAF, S3
- Root cause
- injection / unsafe parsing, insecure defaults, stolen credentials
The story
Quick (1 min)
In July 2019, US bank Capital One announced that an outsider had stolen personal data on about 100 million people in the US and 6 million in Canada, mostly credit card application details going back to 2005.
The data was stored in Amazon's cloud. Capital One ran a web application firewall (a security filter for web traffic) that was set up wrongly. Per KrebsOnSecurity's source, the attacker tricked it into making a request to an internal cloud service that hands out temporary credentials. Those credentials had far more access than they needed, enough to list and read the bank's stored files.
Capital One learned about it from an outside researcher through its responsible disclosure program. The FBI arrested the person responsible.
The lesson: in the cloud, a small misconfiguration plus overly broad permissions can expose huge amounts of data.
Keep reading to the end to earn XP.Read. XP earned.
Engineer (2 min)
The cloud building blocks. On AWS, a server can ask a local instance metadata service for temporary credentials tied to its IAM role. Whatever the role is allowed to do, those credentials can do.
The attack (per KrebsOnSecurity's source). Capital One used the open-source ModSecurity WAF with Apache in AWS. The WAF was misconfigured, so the intruder could "trick the firewall into relaying requests to a key back-end resource", the metadata service. That's server-side request forgery (SSRF): making a server send requests on the attacker's behalf.
Too much permission. The WAF's role "was assigned too many permissions": it could list every S3 bucket it had access to and read their contents. With the credentials, the intruder downloaded the data.
Amazon's view. AWS said "the intrusion was caused by a misconfiguration of a web application firewall and not the underlying infrastructure," and described it as a misconfiguration of the Capital One-designed web application. Cloudflare's Evan Johnson argued SSRF had become "the most serious vulnerability facing organizations that use public clouds," and noted ModSecurity's default rules didn't detect SSRF.
What was taken (Capital One): application data from 2005 to early 2019 (names, addresses, birth dates, self-reported income); some customer status data; about 140,000 SSNs; about 80,000 linked bank account numbers; and about 1 million Canadian Social Insurance Numbers. No card numbers or login credentials were compromised.
Interview takeaway: treat SSRF as critical in the cloud. Restrict access to metadata endpoints, apply least privilege to every role, and monitor for unusual bulk data access.
Keep reading to the end to earn XP.Read. XP earned.
Deep dive (2 min)
Timeline (Capital One, Wikipedia)
- 22–23 March 2019: the unauthorised access occurs.
- 17 July 2019: an external security researcher reports the configuration vulnerability through Capital One's Responsible Disclosure Program.
- 19 July 2019: Capital One determines that an outside individual obtained personal information.
- 29 July 2019: public disclosure; the FBI arrests Paige Thompson, a former Amazon Web Services software engineer (Wikipedia).
- 2022: Thompson is convicted of five felonies and two misdemeanours and sentenced to time served and five years of probation (Wikipedia).
Impact (Capital One)
- About 100 million people in the US and 6 million in Canada.
- Largest category: credit card application data from 2005 to early 2019.
- Portions of customer data: credit scores, limits, balances, payment history, and fragments of transaction data from 23 days in 2016–2018.
- About 140,000 US SSNs, 80,000 linked bank account numbers, and about 1 million Canadian SINs.
- "No credit card account numbers or log-in credentials were compromised."
- The government said it believed the data had been recovered, with no evidence it was used for fraud or shared.
How it was discovered
Not by internal monitoring but through the Responsible Disclosure Program: an outside researcher reported the issue on 17 July. Months had passed since the March access.
Debate over responsibility
KrebsOnSecurity's analysis captures the shared responsibility model's grey area. Amazon said its infrastructure wasn't at fault and pointed customers to tools like Access Advisor (to trim role permissions) and AWS WAF. Critics argued the metadata service made SSRF too damaging by default.
Key quote
"The misconfiguration of the WAF allowed the intruder to trick the firewall into relaying requests to a key back-end resource on the AWS platform." (KrebsOnSecurity, citing a source with direct knowledge of the investigation)
Keep reading to the end to earn XP.Read. XP earned.
Failure replay
Step by step, what broke and what it hit next. Showing the key steps. Switch to Engineer or Deep dive for every step.
- Before Mar 2019WAF serverdegraded
A ModSecurity web application firewall in AWS is misconfigured, and its IAM role has broad S3 read access.
Affects: Metadata service
- Mar 22–23, 2019Attackercompromised
The attacker sends crafted requests that trick the WAF into relaying a request to the internal metadata service (SSRF).
Affects: WAF server
- Mar 22–23Metadata servicecompromised
The metadata service hands back temporary credentials for the WAF's IAM role, as it's designed to.
Affects: Attacker
- Mar 22–23S3 bucketscompromised
Using those credentials, the attacker lists and downloads bucket contents, data on about 106 million people.
- Jul 17, 2019Security researcherhealthy
An outside researcher reports the vulnerability through Capital One's responsible disclosure program.
Affects: WAF server
- Jul 19, 2019WAF serverrecovering
Capital One confirms the intrusion and fixes the issue immediately.
- Jul 29, 2019Customersrecovering
Public disclosure and an FBI arrest. The government believes the data was recovered.
Impact
- Who was affected
- About 100 million people in the US and 6 million in Canada, mainly credit card applicants (2005 to early 2019); 140,000 SSNs, 80,000 bank account numbers and about 1 million Canadian SINs.
- How long
- Access occurred on 22–23 March 2019; undetected until a researcher's report on 17 July 2019.
- Cost
- not disclosed in our sources
Lessons
- SSRF in the cloud can expose credentials through metadata services; block or harden metadata access.
- Apply least privilege to every IAM role; a firewall didn't need to read every bucket.
- Responsible disclosure programs catch what internal monitoring misses.
- Monitor for unusual bulk reads and listing of storage.
- Security tools themselves need secure configuration and review.
Quiz
What type of attack was used against Capital One's WAF, according to KrebsOnSecurity?
The answer is Server-side request forgery (SSRF). The WAF was tricked into relaying requests to the AWS metadata service.
Check answer
Server-side request forgery (SSRF). The WAF was tricked into relaying requests to the AWS metadata service.
Why could the stolen credentials read so much data?
The answer is The WAF's IAM role had far more permissions than it needed, including listing and reading S3 buckets. Krebs's source said the WAF was assigned too many permissions.
Check answer
The WAF's IAM role had far more permissions than it needed, including listing and reading S3 buckets. Krebs's source said the WAF was assigned too many permissions.
How did Capital One find out about the breach?
The answer is An external researcher reported it through its Responsible Disclosure Program. The report came on 17 July 2019; the access had happened in March.
Check answer
An external researcher reported it through its Responsible Disclosure Program. The report came on 17 July 2019; the access had happened in March.
What did Amazon say caused the intrusion?
The answer is A misconfiguration of the web application firewall, not the underlying infrastructure. AWS said the cause was the WAF misconfiguration, not AWS IAM or the metadata service.
Check answer
A misconfiguration of the web application firewall, not the underlying infrastructure. AWS said the cause was the WAF misconfiguration, not AWS IAM or the metadata service.
Interview prep
Try answering out loud before you open the model answer.
- security
Explain how SSRF can lead to a cloud data breach, using Capital One as the example.
Show model answer
SSRF tricks a server into sending requests on the attacker's behalf. In AWS, servers can fetch temporary credentials from the instance metadata service for their IAM role. Capital One's misconfigured WAF could be made to relay a request to the metadata service, returning credentials for the WAF's role. That role was overly permissive and could list and read S3 buckets, so the attacker downloaded the data. Defences: block metadata access from apps that don't need it or require session-token-protected metadata requests, validate and allow-list outbound requests, apply least privilege to roles, and alert on unusual S3 access.
A strong answer hits:
- SSRF definition
- Metadata service returns role credentials
- Over-permissive role led to bulk S3 access
- Metadata hardening, least privilege, monitoring
How did your answer compare? - system design
How would you design IAM permissions for an internet-facing component like a web application firewall?
Show model answer
Start from zero: grant only what the component needs. A WAF typically needs to write logs and read its own config, not read customer data buckets. Use separate roles per service, resource-level restrictions (specific bucket ARNs, prefixes), and conditions (source VPC, encryption). Review unused permissions regularly with access analysis tools, add guardrails at the account level that block risky access patterns, and alert on anomalies such as a WAF role suddenly listing buckets.
A strong answer hits:
- Least privilege per component
- Resource-level scoping and conditions
- Regular unused-permission reviews
- Organisation guardrails and anomaly alerts
How did your answer compare? - behavioural
An outside researcher emails you claiming they found a serious vulnerability in your production systems. How do you respond?
Show model answer
Thank them, acknowledge quickly, and route the report to the security team through an established disclosure process. Triage urgently and verify the issue safely. If it's real, contain and fix it, investigate for prior exploitation (Capital One found data had already been taken months earlier), and involve legal and law enforcement as needed. Keep the researcher updated and credit them if appropriate. A good responsible disclosure program turns outsiders into an early warning system.
A strong answer hits:
- Fast acknowledgement and clear process
- Verify, contain, fix
- Investigate past exploitation
- Communicate and credit
How did your answer compare?
Go deeper
- Official report2019 Capital One Cyber Incident — What HappenedCapital One, link checked 2026-11-25
- ArticleWhat We Can Learn from the Capital One HackKrebsOnSecurity, link checked 2026-11-25
- ArticleCapital One — July 2019 data breachWikipedia, link checked 2026-11-25