GCP Vertex AI Role Granted to Principal
editGCP Vertex AI Role Granted to Principal
editIdentifies an IAM policy change on a Google Cloud project, folder, or organization that grants a Vertex AI role (roles/aiplatform.*) to a principal. Vertex AI roles control who can invoke models, deploy endpoints, run agents, and read prompt and training data. An adversary who has gained IAM administration rights can grant a Vertex AI role to an identity they control to keep model access after the original foothold is removed, or to run LLMjacking workloads under the victim’s billing. Google-managed service agent roles are excluded because Google grants them automatically when the API is enabled.
Rule type: query
Rule indices:
- logs-gcp.audit-*
Severity: medium
Risk score: 47
Runs every: 5m
Searches indices from: now-9m (Date Math format, see also Additional look-back time)
Maximum alerts per execution: 100
References:
Tags:
- Domain: Cloud
- Domain: GenAI
- Domain: Identity
- Data Source: GCP
- Data Source: Google Cloud Platform
- Platform: GCP
- Service: GCP Vertex AI
- Use Case: Identity and Access Audit
- Use Case: Threat Detection
- Tactic: Persistence
- Tactic: Privilege Escalation
- Threat: Unauthorized AI Usage
- Mitre Atlas: AML.T0012
- Resources: Investigation Guide
- Rule Type: Custom Query (KQL)
Version: 1
Rule authors:
- Elastic
Rule license: Elastic License v2
Investigation guide
editTriage and analysis
Investigating GCP Vertex AI Role Granted to Principal
A Google Cloud IAM policy change added a binding for a Vertex AI role (roles/aiplatform.*). Roles such as
roles/aiplatform.admin and roles/aiplatform.user allow the member to call models, manage endpoints and agents, and
access prompt and training data in the project.
Possible investigation steps
-
Identify the caller that changed the policy from
client.user.email, and reviewsource.ipanduser_agent.originalfor the change. -
Review
gcp.audit.service_data.policy_delta.binding_deltasfor the role and member that were added. Members outside the organization’s domain, newly created service accounts, andallUsersorallAuthenticatedUsersare the most concerning. -
Check
gcp.audit.resource_nameto see whether the grant was made at the project, folder, or organization level. Grants above the project level reach every project underneath. - Look for follow-on activity by the new member in Vertex AI audit logs, such as inference calls from new networks, endpoint deployment, or agent creation.
- Review other recent IAM changes by the same caller, especially service account key creation and grants of IAM admin roles.
False positive analysis
- Approved access requests for ML and data science teams. Confirm with the request owner.
- IAM automation that reapplies bindings. Exclude those service accounts by email.
Response and remediation
- If the grant is not authorized, remove the binding and review what the member accessed since the grant.
- Investigate how the caller obtained IAM administration rights, rotate its credentials, and review its other changes.
-
Restrict
resourcemanager.projects.setIamPolicyto a small set of administrators and consider an Organization Policy that limits allowed member domains.
Setup
editSetup
This rule requires Google Cloud Audit Logs ingested via the GCP integration (gcp.audit data stream). IAM policy
changes are Admin Activity audit logs and are always logged.
Rule query
editdata_stream.dataset: "gcp.audit"
and event.action: (
"SetIamPolicy" or
google.cloud.resourcemanager.v*.Folders.SetIamPolicy or
google.cloud.resourcemanager.v*.Organizations.SetIamPolicy or
google.cloud.resourcemanager.v*.Projects.SetIamPolicy
)
and not event.outcome: "failure"
and gcp.audit.service_data.policy_delta.binding_deltas:{
action: "ADD" and
role: (roles/aiplatform.* and not (*ServiceAgent or *serviceAgent))
}
Framework: MITRE ATT&CKTM
-
Tactic:
- Name: Persistence
- ID: TA0003
- Reference URL: https://attack.mitre.org/tactics/TA0003/
-
Technique:
- Name: Account Manipulation
- ID: T1098
- Reference URL: https://attack.mitre.org/techniques/T1098/
-
Sub-technique:
- Name: Additional Cloud Roles
- ID: T1098.003
- Reference URL: https://attack.mitre.org/techniques/T1098/003/
-
Tactic:
- Name: Privilege Escalation
- ID: TA0004
- Reference URL: https://attack.mitre.org/tactics/TA0004/
-
Technique:
- Name: Account Manipulation
- ID: T1098
- Reference URL: https://attack.mitre.org/techniques/T1098/
-
Sub-technique:
- Name: Additional Cloud Roles
- ID: T1098.003
- Reference URL: https://attack.mitre.org/techniques/T1098/003/