# Source: https://docs.datadoghq.com/security/default_rules/dcf-339-120.md

---
title: Google Cloud unauthorized user activity
description: Datadog, the leading service for cloud-scale monitoring.
breadcrumbs: Docs > Datadog Security > OOTB Rules > Google Cloud unauthorized user activity
---

# Google Cloud unauthorized user activity
Classification:complianceTactic:[TA0001-initial-access](https://attack.mitre.org/tactics/TA0001)Technique:[T1078-valid-accounts](https://attack.mitre.org/techniques/T1078) 
## Goal{% #goal %}

Detect when unauthorized activity by a user is detected in Google Cloud.

## Strategy{% #strategy %}

Monitor Google Cloud logs and detect when a user account makes an API request and the request returns the status code equal to `7` within the log attribute `@data.protoPayload.status.code`. The status code `7` indicates the user account did not have permission to make the API call.

## Triage and response{% #triage-and-response %}

1. Investigate the user:`{{@usr.id}}` that made the unauthorized calls and confirm if there is a misconfiguration in IAM permissions or if an attacker compromised the user account.
1. If unauthorized, revoke access of compromised user account and rotate credentials.

## Changelog{% #changelog %}

22 June 2022 - Updated query, rule case and triage.