AWS - CloudFront Post Exploitation
Tip
Nauči & vežbaj AWS Hacking:
HackTricks Training AWS Red Team Expert (ARTE)
Nauči & vežbaj GCP Hacking:HackTricks Training GCP Red Team Expert (GRTE)
Nauči & vežbaj Az Hacking:HackTricks Training Azure Red Team Expert (AzRTE)
Podržite HackTricks
- Pogledajte subscription plans!
- Pridružite se 💬 Discord group or the telegram group or pratite nas na Twitter 🐦 @hacktricks_live.
- Podelite hacking tricks slanjem PR-ova na HackTricks i HackTricks Cloud github repos.
CloudFront
Za više informacija pogledajte:
cloudfront:Delete*
Napadač kome je dodeljeno cloudfront:Delete* može izbrisati distribucije, politike i druge kritične CDN konfiguracione objekte — na primer distribucije, cache/origin policies, key groups, origin access identities, functions/configs i povezane resurse. To može dovesti do prekida usluge, gubitka sadržaja i uklanjanja konfiguracije ili forenzičkih artefakata.
Za brisanje distribucije napadač može koristiti:
aws cloudfront delete-distribution \
--id <DISTRIBUTION_ID> \
--if-match <ETAG>
Man-in-the-Middle
This blog post predlaže nekoliko različitih scenarija gde bi se Lambda mogla dodati (ili izmeniti ako se već koristi) u komunikaciju kroz CloudFront sa ciljem krađe korisničkih informacija (kao što je session cookie) i modifikovanja response (injektovanjem malicioznog JS skripta).
scenario 1: MitM where CloudFront is configured to access some HTML of a bucket
- Kreirajte zlonamernu function.
- Povežite je sa CloudFront distribution.
- Postavite event type na “Viewer Response”.
Pristupanjem response-u možete ukrasti korisnički cookie i ubaciti maliciozni JS.
scenario 2: MitM where CloudFront is already using a lambda function
- Modify the code of the Lambda function to steal sensitive information
You can check the tf code to recreate this scenarios here.
Tip
Nauči & vežbaj AWS Hacking:
HackTricks Training AWS Red Team Expert (ARTE)
Nauči & vežbaj GCP Hacking:HackTricks Training GCP Red Team Expert (GRTE)
Nauči & vežbaj Az Hacking:HackTricks Training Azure Red Team Expert (AzRTE)
Podržite HackTricks
- Pogledajte subscription plans!
- Pridružite se 💬 Discord group or the telegram group or pratite nas na Twitter 🐦 @hacktricks_live.
- Podelite hacking tricks slanjem PR-ova na HackTricks i HackTricks Cloud github repos.
HackTricks Cloud

