saurabh umathe
saurabh umathe

Reputation: 395

How can i get the logs of roles modifications on some specific IAM user in GCP

I need to know who modified(added or deleted) the roles for some specific IAM user in GCP. I could not get these details in GCP logging even after adding data write in audit logging for IAM permissions. Are we missing something here? enter image description here

Upvotes: 3

Views: 3953

Answers (1)

Gabriel Robledo Ahumada
Gabriel Robledo Ahumada

Reputation: 1701

You need to query either your Cloud project, folder, billing account, or organization for audit logs.

Here you have an example of a query to a Cloud project and filtering just the logs where a particular user is involved:

gcloud logging read "logName : projects/$YOUR_PROJECT_ID/logs/cloudaudit.googleapis.com AND \
protoPayload.response.bindings.members:[email protected]" --project=$YOUR_PROJECT_ID

Take a look at the official documentation for more information.

Upvotes: 3

Related Questions