GCP - Storage Unauthenticated Enum
Reading time: 3 minutes
tip
Impara e pratica il hacking AWS:HackTricks Training AWS Red Team Expert (ARTE)
Impara e pratica il hacking GCP: HackTricks Training GCP Red Team Expert (GRTE)
Impara e pratica il hacking Azure:
HackTricks Training Azure Red Team Expert (AzRTE)
Supporta HackTricks
- Controlla i piani di abbonamento!
- Unisciti al ๐ฌ gruppo Discord o al gruppo telegram o seguici su Twitter ๐ฆ @hacktricks_live.
- Condividi trucchi di hacking inviando PR ai HackTricks e HackTricks Cloud repos su github.
Storage
Per ulteriori informazioni su Storage controlla:
Public Bucket Brute Force
Il formato di un URL per accedere a un bucket รจ https://storage.googleapis.com/<bucket-name>
.
I seguenti strumenti possono essere utilizzati per generare variazioni del nome fornito e cercare bucket mal configurati con quei nomi:
Inoltre, gli strumenti menzionati in:
GCP - Unauthenticated Enum & Access
Se scopri di poter accedere a un bucket potresti essere in grado di escalare ulteriormente, controlla:
GCP - Public Buckets Privilege Escalation
Search Open Buckets in Current Account
Con il seguente script raccolto da qui puoi trovare tutti i bucket aperti:
#!/bin/bash
############################
# Run this tool to find buckets that are open to the public anywhere
# in your GCP organization.
#
# Enjoy!
############################
for proj in $(gcloud projects list --format="get(projectId)"); do
echo "[*] scraping project $proj"
for bucket in $(gsutil ls -p $proj); do
echo " $bucket"
ACL="$(gsutil iam get $bucket)"
all_users="$(echo $ACL | grep allUsers)"
all_auth="$(echo $ACL | grep allAuthenticatedUsers)"
if [ -z "$all_users" ]
then
:
else
echo "[!] Open to all users: $bucket"
fi
if [ -z "$all_auth" ]
then
:
else
echo "[!] Open to all authenticated users: $bucket"
fi
done
done
tip
Impara e pratica il hacking AWS:HackTricks Training AWS Red Team Expert (ARTE)
Impara e pratica il hacking GCP: HackTricks Training GCP Red Team Expert (GRTE)
Impara e pratica il hacking Azure:
HackTricks Training Azure Red Team Expert (AzRTE)
Supporta HackTricks
- Controlla i piani di abbonamento!
- Unisciti al ๐ฌ gruppo Discord o al gruppo telegram o seguici su Twitter ๐ฆ @hacktricks_live.
- Condividi trucchi di hacking inviando PR ai HackTricks e HackTricks Cloud repos su github.