Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Step by step AWS Cloud Hacking
Search
andresriancho
September 25, 2020
Technology
0
620
Step by step AWS Cloud Hacking
andresriancho
September 25, 2020
Tweet
Share
More Decks by andresriancho
See All by andresriancho
Step by step AWS Cloud Hacking
andresriancho
2
2.9k
Internet-Scale analysis of AWS Cognito Security
andresriancho
1
12k
Threat Modelling
andresriancho
0
1.5k
Automated Security Analysis AWS Clouds
andresriancho
1
3.3k
Injecting into URLs / Breaking URL-Encoding
andresriancho
0
260
Galería de Fallos en Unicornios
andresriancho
1
250
Esoteric Web Application Vulnerabilities
andresriancho
0
1.1k
String Compare Timing Attacks
andresriancho
0
630
Timing Attacks
andresriancho
1
380
Other Decks in Technology
See All in Technology
形式手法特論:コンパイラの「正しさ」は証明できるか? #burikaigi / BuriKaigi 2026
ytaka23
14
3.6k
Redshift認可、アップデートでどう変わった?
handy
1
120
「リリースファースト」の実感を届けるには 〜停滞するチームに変化を起こすアプローチ〜 #RSGT2026
kintotechdev
0
490
スクラムを一度諦めたチームにアジャイルコーチが入ってどう変化したか
kyamashiro73
0
140
AI駆動開発ライフサイクル(AI-DLC)の始め方
ryansbcho79
0
290
AIエージェントを5分で一気におさらい!AIエージェント「構築」元年に備えよう
yakumo
1
140
AWS re:Invent 2025 を振り返る
kazzpapa3
2
110
ECS_EKS以外の選択肢_ROSA入門_.pdf
masakiokuda
1
120
Introduction to Sansan Meishi Maker Development Engineer
sansan33
PRO
0
330
Bill One 開発エンジニア 紹介資料
sansan33
PRO
4
17k
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
3.6k
Next.js 16の新機能 Cache Components について
sutetotanuki
0
210
Featured
See All Featured
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
110
The Curse of the Amulet
leimatthew05
0
6.7k
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
0
270
Raft: Consensus for Rubyists
vanstee
141
7.3k
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
870
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
48
9.8k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
300
Chasing Engaging Ingredients in Design
codingconduct
0
93
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
43
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.3k
End of SEO as We Know It (SMX Advanced Version)
ipullrank
2
3.8k
Transcript
Ekoparty 2020 Andrés Riancho
2
3
None
5
need credentials • • • 6
7
IAM permissions 8
9 http://169.254.169.254/ /latest/meta-data/iam/security-credentials/ /latest/meta-data/iam/security-credentials/{role-name}
10
11 from urllib.request import urlopen from flask import request @app.route('/ssrf')
def handler(): url = request.args.get('url') return urlopen(url).read()
Instance metadata and S3 compromise
13
None
two ways to enumerate permissions IAM service In most cases
this will fail brute-force 15
Get* / List* / Describe* DryRun parameter 16
17 SUPPORTED_SERVICES = [ 'ec2', 's3' ]
18
./enumerate-iam.py
20
many things the attacker doesn't know. 21 { "Statement":[ {
"Effect":"Allow", "Action":[ "s3:*", "lambda:*", "..." ], "Resource":"*" } ] }
try to elevate privileges to a principal with full access
22 { "Statement":[ { "Effect":"Allow", "Action":[ "*", ], "Resource": "*" } ] }
Lambda function will have access to the IAM role 23
Getting * on *
None
existing trust policy in the AdminRole 26
27
28 { "Effect": "Allow", "Principal": { "AWS": "arn:aws:iam::925877178748:root" }, "Action":
"sts:AssumeRole" } { "Effect": "Allow", "Principal": { "AWS": ["arn:aws:iam::925877178748:root", "arn:aws:iam::320222540496:root"] }, "Action": "sts:AssumeRole" }
Never trust the trust policy
30 ARN for the backdoored role
None
32 most resources in the AWS account VPC is completely
isolated from the Internet
None
34 VPN between the attacker's workstation and a VPC
35
vpc-vpn-pivot
None
From zero to full pwn
None
40 • enumerate-iam • pacu • vpc-vpn-pivot Follow @AndresRiancho
None