Security Command Center のリージョン エンドポイント

このドキュメントでは、データ所在地が有効になっている場合に Security Command Center リソースを操作する方法について説明します。Security Command Center のデータ所在地を有効にできるのは、組織で Security Command Center を有効にしている場合のみです。

データ所在地コントロールがあるリソース

次の Security Command Center リソースタイプは、データ所在地コントロールの対象となります。

これらのリソースをプログラムまたはコマンドラインで操作するには、Security Command Center API のリージョン エンドポイントを使用する必要があります。 Google Cloud コンソールでこれらのリソースを操作するには、管轄区域の Google Cloud コンソールを使用する必要があります。

他のすべてのリソースタイプでは、デフォルトの API エンドポイントと Google Cloud コンソールを使用します。

リージョン エンドポイントについて

リージョン エンドポイントは、特定のロケーションにあるリソースへのアクセスを提供します。リージョン エンドポイントを使用すると、リクエストはエンドポイントのロケーションに直接転送されます。リージョン エンドポイントを使用して、他のロケーションのリソースにアクセスすることはできません。

リージョン エンドポイントを使用すると、リソースが保存中、使用中、転送中の場合に、リソースのデータ所在地コントロールを適用できます。

Security Command Center には複数のサービスが含まれています。データ所在地コントロールの対象となるリソースタイプの場合、次のサービスではリージョン エンドポイントを使用する必要があります。

Model Armor API
modelarmor.LOCATION.rep.googleapis.com
Security Command Center API
securitycenter.LOCATION.rep.googleapis.com
Google SecOps
Google SecOps のリファレンス ドキュメントをご覧ください。

LOCATION は、サービスでサポートされているロケーションに置き換えます。

他のすべてのリソースタイプでは、デフォルトのエンドポイントを使用する必要があります。

管轄区域の Google Cloud コンソールについて

管轄区域の Google Cloud コンソールを使用すると、Security Command Center を有効にする際にデータ所在地を有効にできます。また、特定ロケーションのリソースへのアクセスを許可することもできます。

管轄区域の Google Cloud コンソールを使用すると、リソースが保存中、使用中、転送中のときに、リソースのデータ所在地コントロールを適用できます。

管轄区域の Google Cloud コンソールでは、データ所在地コントロールの対象となるリソースタイプにのみアクセスできます。コンソールを開くには、お住まいの地域に応じた適切な URL を使用します。

欧州連合
フェデレーション ID ユーザー: console.eu.cloud.google
その他のすべてのユーザー: console.eu.cloud.google.com
サウジアラビア王国(KSA)
フェデレーション ID ユーザー: console.sa.cloud.google
その他のすべてのユーザー: console.sa.cloud.google.com
米国
フェデレーション ID ユーザー: console.us.cloud.google
その他のすべてのユーザー: console.us.cloud.google.com

他のすべてのリソースタイプでは、標準の Google Cloud コンソールを使用する必要があります。

リージョン エンドポイントのロケーション

このセクションでは、Security Command Center API と関連サービスでリージョン エンドポイントを使用できるロケーションの一覧を示します。

Security Command Center API のロケーション

Security Command Center API は、次のロケーションでリージョン エンドポイントとマルチリージョン エンドポイントを提供します。

欧州連合
eu
サウジアラビア王国(KSA)
me-central2
米国
us

Model Armor API のロケーション

Model Armor API は、次のロケーションにリージョン エンドポイントを指定します。

ヨーロッパ
europe-west1: ベルギー リーフアイコン 低 CO2
europe-west2: ロンドン リーフアイコン 低 CO2保存時のデータ所在地のみをサポート)
europe-west3: フランクフルト
europe-west4: オランダ リーフアイコン 低 CO2
米国
us-central1: アイオワ リーフアイコン 低 CO2
us-east1: サウス カロライナ
us-east4: 北バージニア
us-west1: オレゴン リーフアイコン 低 CO2
アジア太平洋
asia-southeast1: シンガポール (保存時のデータ所在地のみをサポート)
asia-south1: ムンバイ (保存時のデータ所在地のみをサポート)

Model Armor API は、次のロケーションにマルチリージョン エンドポイントを指定します。

欧州連合
eu
米国
us

AI 保護のロケーション

AI 保護(プレビュー版)のメリットを最大限に活用するには、AI ワークロードが次のリージョンにある必要があります。

欧州連合
europe-west4: オランダ リーフアイコン 低 CO2
米国
us-central1: アイオワ リーフアイコン 低 CO2
us-east4: 北バージニア
us-west1: オレゴン リーフアイコン 低 CO2

AI Protection は、次のロケーションにマルチリージョン エンドポイントを提供します。

欧州連合
eu
米国
us

利用できる機能はリージョンによって異なります。リージョンで利用できる機能と利用できない機能については、次の表をご覧ください。

リージョン Notebook Security Scanner Model Armor 使用できない機能
us-east7 ×
  • Vertex AI モデルは Model Armor で保護されません。
  • 検出結果は利用できません。
  • 2 つの Model Armor ウィジェットにデータがありません。
europe-west1
europe-west2
asia-southeast1
× パッケージの脆弱性の検出結果は使用できません。
その他のリージョン × ×
  • Vertex AI モデルは Model Armor で保護されません。
  • 検出結果は利用できません。
  • 2 つの Model Armor ウィジェットにデータがありません。
  • パッケージの脆弱性の検出結果は使用できません。

Google SecOps のロケーション

Google SecOps のロケーションのページをご覧ください。

リージョン エンドポイントのツール

データ所在地コントロールの対象となるリソースタイプを管理するには、クライアントを作成するか、コマンドを実行するときに、リージョン エンドポイントを指定する必要があります。

他のすべてのリソースタイプでは、デフォルトのエンドポイントを使用する必要があります。

gcloud

次の gcloud CLI コマンド グループでは、リージョン エンドポイントを使用する必要があります。

他のすべての gcloud scc コマンド グループでは、Security Command Center API のデフォルトのエンドポイントを使用する必要があります。

サービス エンドポイントを変更する

リージョン エンドポイントに切り替えるには、次のコマンドを実行します。

gcloud config set api_endpoint_overrides/SERVICE \
    https://SERVICE.LOCATION.rep.googleapis.com/

デフォルトのエンドポイントに切り替えるには、次のコマンドを実行します。

gcloud config unset api_endpoint_overrides/SERVICE

次のように置き換えます。

必要に応じて、リージョン エンドポイントを使用する gcloud CLI の名前付き構成を作成できます。gcloud CLI コマンドを実行する前に、gcloud config configurations activate コマンドを実行して、名前付き構成に切り替えることができます。

gcloud CLI コマンドを実行する

Security Command Center API の gcloud CLI コマンドを実行する場合は、常にロケーションを指定する必要があります。これには、いくつかの方法があります

  • --location フラグを使用します。
  • リソース名のフルパスを指定する場合は、projects/123/sources/456/locations/LOCATION/findings/a1b2c3 などのロケーションを含む形式にします。

次の例は、--location フラグの使用方法を示しています。

gcloud scc findings list コマンドを使用すると、特定のロケーションにある組織の検出結果が一覧表示されます。

後述のコマンドデータを使用する前に、次のように置き換えます。

gcloud scc findings list コマンドを実行します。

Linux、macOS、Cloud Shell

gcloud scc findings list ORGANIZATION_ID --location=LOCATION

Windows(PowerShell)

gcloud scc findings list ORGANIZATION_ID --location=LOCATION

Windows(cmd.exe)

gcloud scc findings list ORGANIZATION_ID --location=LOCATION

レスポンスには、検出結果のリストが含まれます。

Terraform

Terraform 構成を適用または削除する方法については、基本的な Terraform コマンドをご覧ください。 詳細については、Terraform プロバイダのリファレンス ドキュメントをご覧ください。

provider "google" {
  alias                              = "securitycenter_v2_endpoint_us"
  security_center_v2_custom_endpoint = "https://securitycenter.us.rep.googleapis.com/v2/"
}

Go

次のいずれかのリージョン エンドポイントを使用します。

Model Armor API
modelarmor.LOCATION.rep.googleapis.com:443
Security Command Center API
securitycenter.LOCATION.rep.googleapis.com:443

LOCATION は、サービスでサポートされているロケーションに置き換えます。

次のコードサンプルは、リージョン エンドポイントを使用する Security Command Center API クライアントの作成方法を示しています。

import (
	"context"
	"fmt"

	securitycenter "cloud.google.com/go/securitycenter/apiv2"
	"google.golang.org/api/option"
)

// createClientWithEndpoint creates a Security Command Center client for a
// regional endpoint.
func createClientWithEndpoint(repLocation string) error {
	// Assemble the regional endpoint URL using provided location.
	repEndpoint := fmt.Sprintf("securitycenter.%s.rep.googleapis.com:443", repLocation)
	// Instantiate client for regional endpoint. Use this client to access resources that
	// are subject to data residency controls, and that are located in the region
	// specified in repLocation.
	repCtx := context.Background()
	repClient, err := securitycenter.NewClient(repCtx, option.WithEndpoint(repEndpoint))
	if err != nil {
		return err
	}
	defer repClient.Close()

	return nil
}

Java

次のいずれかのリージョン エンドポイントを使用します。

Model Armor API
modelarmor.LOCATION.rep.googleapis.com:443
Security Command Center API
securitycenter.LOCATION.rep.googleapis.com:443

LOCATION は、サービスでサポートされているロケーションに置き換えます。

次のコードサンプルは、リージョン エンドポイントを使用する Security Command Center API クライアントの作成方法を示しています。


import com.google.cloud.securitycenter.v2.SecurityCenterClient;
import com.google.cloud.securitycenter.v2.SecurityCenterSettings;
import java.io.IOException;

public class CreateClientWithEndpoint {

  public static void main(String[] args) throws IOException {
    // TODO: Replace the value with the endpoint for the region in which your
    // Security Command Center data resides.
    String regionalEndpoint = "securitycenter.me-central2.rep.googleapis.com:443";
    SecurityCenterClient client = createClientWithEndpoint(regionalEndpoint);
    System.out.println("Client initiated with endpoint: " + client.getSettings().getEndpoint());
  }

  // Creates Security Command Center client for a regional endpoint.
  public static SecurityCenterClient createClientWithEndpoint(String regionalEndpoint)
      throws java.io.IOException {
    SecurityCenterSettings regionalSettings =
        SecurityCenterSettings.newBuilder().setEndpoint(regionalEndpoint).build();
    return SecurityCenterClient.create(regionalSettings);
  }
}

Python

次のいずれかのリージョン エンドポイントを使用します。

Model Armor API
modelarmor.LOCATION.rep.googleapis.com
Security Command Center API
securitycenter.LOCATION.rep.googleapis.com

LOCATION は、サービスでサポートされているロケーションに置き換えます。

次のコードサンプルは、リージョン エンドポイントを使用する Security Command Center API クライアントの作成方法を示しています。

from google.cloud import securitycenter_v2


def create_client_with_endpoint(api_endpoint) -> securitycenter_v2.SecurityCenterClient:
    """
    Creates a Security Command Center client for a regional endpoint.
    Args:
        api_endpoint: the regional endpoint's hostname, like 'securitycenter.REGION.rep.googleapis.com'
    Returns:
        securitycenter_v2.SecurityCenterClient: returns a client for the regional endpoint
    """
    regional_client = securitycenter_v2.SecurityCenterClient(
        client_options={"api_endpoint": api_endpoint}
    )
    print(
        "Regional client initiated with endpoint: {}".format(
            regional_client.api_endpoint
        )
    )
    return regional_client

REST

次の REST API リソースタイプにアクセスするには、リージョン サービス エンドポイントを使用する必要があります。

Model Armor API

エンドポイント: https://modelarmor.LOCATION.rep.googleapis.com

LOCATION は、サービスでサポートされているロケーションに置き換えます。

リソースタイプ: すべてのリソースタイプ

Security Command Center API

エンドポイント: https://securitycenter.LOCATION.rep.googleapis.com

LOCATION は、サービスでサポートされているロケーションに置き換えます。

リソースタイプ:

LOCATION は、サービスでサポートされているロケーションに置き換えます。

他のすべてのリソースタイプでは、デフォルトのエンドポイントを使用する必要があります。