Este documento explica como exportar e ingerir registros da análise do IAM no Google Security Operations usando o Cloud Storage. O analisador extrai informações de usuários e recursos dos dados JSON do IAM. Em seguida, ele mapeia os campos extraídos para a UDM, criando entidades de usuário com papéis associados e relacionamentos de recursos, enriquecendo o contexto de segurança na plataforma Google SecOps.
Antes de começar
Verifique se você atende aos seguintes pré-requisitos:
Instância do Google SecOps.
A IAM está configurada e ativa no seu ambiente Google Cloud .
Acesso privilegiado a Google Cloud e permissões adequadas para acessar os registros do IAM.
Na página Criar um bucket, insira as informações do seu bucket. Após cada uma das etapas a seguir, clique em Continuar para prosseguir para a próxima etapa:
Na seção Começar, faça o seguinte:
Insira um nome exclusivo que atenda aos requisitos de nome de bucket. Por exemplo, google-cloud-iam-logs.
Para ativar o namespace hierárquico, clique na seta de expansão para abrir a seção Otimizar para cargas de trabalho orientadas a arquivos e com uso intensivo de dados e selecione Ativar namespace hierárquico neste bucket.
Para adicionar um rótulo de bucket, clique na seta de expansão para abrir a seção Rótulos.
Clique em Adicionar rótulo e especifique uma chave e um valor para o rótulo.
Na seção Escolha onde armazenar seus dados, faça o seguinte:
Selecione um tipo de local.
Use o menu do tipo de local para selecionar um Local em que os dados de objetos no bucket serão armazenados permanentemente.
Para configurar a replicação entre buckets, abra a seção Configurar a replicação entre buckets.
Na seção Escolha uma classe de armazenamento para seus dados, selecione uma classe de armazenamento padrão para o bucket ou selecione Classe automática para gerenciamento automático da classe de armazenamento dos dados do bucket.
Na seção Escolha como controlar o acesso a objetos, selecione não para aplicar a prevenção de acesso público e selecione um modelo de controle de acesso para os objetos do bucket.
Na seção Escolha como proteger os dados do objeto, faça o seguinte:
Selecione qualquer uma das opções em Proteção de dados que você quer definir para o bucket.
Para escolher como os dados do objeto serão criptografados, clique na seta de expansão identificada como Criptografia de dados e selecione um Método de criptografia de dados.
Clique em Criar.
Configurar a exportação de registros da análise do IAM
Para STORAGE_BUCKET, diretamente do campo attachedResourceFullName no registro bruto, mas com todos os nomes de recursos finais removidos. Para conjuntos de dados do BigQuery, é o projectName (extraído de attachedResourceFullName) seguido por dois pontos e o campo datasetName (extraído de attachedResourceFullName).
relations.entity.resource.resource_type
Determinado pelo padrão do campo attachedResourceFullName no registro bruto.
relations.entity_type
Definido como RESOURCE, exceto para SERVICE_ACCOUNT, em que é definido como USER.
relations.relationship
Defina como MEMBER.
metadata.collected_timestamp
Diretamente do campo timestamp no registro bruto.
metadata.entity_type
Defina como USER.
metadata.product_name
Defina como GCP IAM ANALYSIS.
metadata.vendor_name
Defina como Google Cloud Platform.
iamBinding.role
entity.user.attribute.roles.name
Diretamente do campo iamBinding.role no registro bruto.
identityList.identities.name
entity.user.attribute.roles.type
Defina como SERVICE_ACCOUNT se o campo identityList.identities.name contiver a string serviceAccount.
entity.user.email_addresses
Se o campo identityList.identities.name contiver um símbolo @, ele será tratado como um endereço de e-mail.
entity.user.userid
Se o campo identityList.identities.name não contiver um símbolo @, ele será tratado como um User-ID.
identityList.identities.product_object_id
entity.user.product_object_id
Diretamente do campo identityList.identities.product_object_id no registro bruto.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-08-21 UTC."],[[["\u003cp\u003eThis document guides you through exporting and ingesting Google Cloud IAM Analysis logs into Google Security Operations (SecOps) using Cloud Storage.\u003c/p\u003e\n"],["\u003cp\u003eThe process involves creating a Cloud Storage bucket, configuring Google Cloud IAM Analysis log exports to that bucket, and setting up a feed in Google SecOps to ingest the logs.\u003c/p\u003e\n"],["\u003cp\u003eThe logs are parsed to extract user and resource information, which are then mapped to the Unified Data Model (UDM) within Google SecOps for enriched security context.\u003c/p\u003e\n"],["\u003cp\u003eYou will need a Google SecOps instance, an active Google Cloud IAM setup, and appropriate permissions to access IAM logs and configure Cloud Storage.\u003c/p\u003e\n"],["\u003cp\u003eThe document provides a UDM mapping table that details how various log fields from Cloud IAM Analysis are translated into UDM fields within the Google SecOps platform, enabling a standardized view of user and resource data.\u003c/p\u003e\n"]]],[],null,["# Collect Identity and Access Management (IAM) Analysis logs\n==========================================================\n\nSupported in: \nGoogle secops [SIEM](/chronicle/docs/secops/google-secops-siem-toc)\n| **Note:** This feature is covered by [Pre-GA Offerings Terms](https://chronicle.security/legal/service-terms/) of the Google Security Operations Service Specific Terms. Pre-GA features might have limited support, and changes to pre-GA features might not be compatible with other pre-GA versions. For more information, see the [Google SecOps Technical Support Service guidelines](https://chronicle.security/legal/technical-support-services-guidelines/) and the [Google SecOps Service Specific Terms](https://chronicle.security/legal/service-terms/).\n\nThis document explains how to export and ingest IAM Analysis logs into Google Security Operations using Cloud Storage. The parser extracts user and resource information from IAM JSON data. It then maps the extracted fields to the UDM, creating user entities with associated roles and resource relationships, ultimately enriching security context within the Google SecOps platform.\n\nBefore you begin\n----------------\n\nEnsure that you have the following prerequisites:\n\n- Google SecOps instance.\n- IAM is set up and active in your Google Cloud environment.\n- Privileged access to Google Cloud and appropriate permissions to access IAM logs.\n\nCreate a Cloud Storage bucket\n-----------------------------\n\n1. Sign in to the [Google Cloud console](https://console.cloud.google.com/).\n2. Go to the **Cloud Storage Buckets** page.\n\n [Go to Buckets](https://console.cloud.google.com/storage/browser)\n3. Click **Create**.\n\n4. On the **Create a bucket** page, enter your bucket information. After each of the following steps, click **Continue** to proceed to the next step:\n\n 1. In the **Get started** section, do the following:\n\n 1. Enter a unique name that meets the bucket name requirements; for example, **google-cloud-iam-logs**.\n 2. To enable hierarchical namespace, click the expander arrow to expand the **Optimize for file oriented and data-intensive workloads** section, and then select **Enable Hierarchical namespace on this bucket**.\n\n | **Note:** You cannot enable hierarchical namespace on an existing bucket.\n 3. To add a bucket label, click the expander arrow to expand the **Labels** section.\n\n 4. Click **Add label**, and specify a key and a value for your label.\n\n 2. In the **Choose where to store your data** section, do the following:\n\n 1. Select a **Location type**.\n 2. Use the location type menu to select a **Location** where object data within your bucket will be permanently stored.\n\n | **Note:** If you select the **dual-region** location type, you can also choose to enable **turbo replication** by using the relevant checkbox.\n 3. To set up cross-bucket replication, expand the **Set up cross-bucket replication** section.\n\n 3. In the **Choose a storage class for your data** section, either select a **default storage class** for the bucket, or select **Autoclass** for automatic storage class management of your bucket's data.\n\n 4. In the **Choose how to control access to objects** section, select **not** to enforce **public access prevention** , and select an **access control model** for your bucket's objects.\n\n | **Note:** If public access prevention is already enforced by your project's organization policy, the **Prevent public access** checkbox is locked.\n 5. In the **Choose how to protect object data** section, do the following:\n\n 1. Select any of the options under **Data protection** that you want to set for your bucket.\n 2. To choose how your object data will be encrypted, click the expander arrow labeled **Data encryption** , and select a **Data encryption method**.\n5. Click **Create**.\n\n| **Note:** Be sure to provide your Google SecOps service account with permissions to Read or Read \\& Write to the newly created bucket.\n\nConfigure IAM Analysis logs export\n----------------------------------\n\n1. Sign in to the [Google Cloud console](https://console.cloud.google.com/).\n2. Go to **Logging \\\u003e Log Router**.\n3. Click **Create Sink**.\n4. Provide the following configuration parameters:\n\n - **Sink Name** : enter a meaningful name; for example, `IAM-Analysis-Sink`.\n - **Sink Destination** : select **Cloud Storage Storage** and enter the URI for your bucket; for example, `gs://gcp-iam-analysis-logs`.\n - **Log Filter**:\n\n logName=\"*iam*\"\n resource.type=\"gce_instance\"\n\n Configure permissions for Cloud Storage\n ---------------------------------------\n\n5. Go to **IAM \\& Admin \\\u003e IAM**.\n\n6. Locate the **Cloud Logging** service account.\n\n7. Grant the **roles/storage.admin** on the bucket.\n\nSet up feeds\n------------\n\nTo configure a feed, follow these steps:\n\n1. Go to **SIEM Settings** \\\u003e **Feeds**.\n2. Click **Add New Feed**.\n3. On the next page, click **Configure a single feed**.\n4. In the **Feed name** field, enter a name for the feed; for example, **IAM Analysis Logs**.\n5. Select **Google Cloud Storage V2** as the **Source type**.\n6. Select **GCP IAM Analysis** as the **Log type**.\n7. Click **Get Service Account** next to the **Chronicle Service Account** field.\n8. Click **Next**.\n9. Specify values for the following input parameters:\n\n - **Storage Bucket URI** : Cloud Storage bucket URL; for example, `gs://gcp-iam-analysis-logs`.\n - **Source deletion options**: select the deletion option according to your preference.\n\n | **Note:** If you select the `Delete transferred files` or `Delete transferred files and empty directories` option, make sure that you granted appropriate permissions to the service account.\n - **Maximum File Age**: Includes files modified in the last number of days. Default is 180 days.\n\n10. Click **Next**.\n\n11. Review your new feed configuration in the **Finalize** screen, and then click **Submit**.\n\nUDM Mapping Table\n-----------------\n\n**Need more help?** [Get answers from Community members and Google SecOps professionals.](https://security.googlecloudcommunity.com/google-security-operations-2)"]]