根據預設,Security Command Center 會加密靜態儲存的客戶內容。Security Command Center 會為您處理加密作業,您不必採取其他動作。這項做法稱為「Google 預設加密機制」。
如要控管加密金鑰,您可以在 Cloud KMS 中使用客戶自行管理的加密金鑰 (CMEK),並搭配 Security Command Center 等整合 CMEK 的服務。使用 Cloud KMS 金鑰可讓您控管保護等級、位置、輪替時間表、使用權限和存取權,以及加密範圍。 使用 Cloud KMS 還可追蹤金鑰用量、查看稽核記錄,以及控管金鑰生命週期。 您可以在 Cloud KMS 中控制及管理用來保護資料的對稱金鑰加密金鑰 (KEK),而不是由 Google 擁有及管理這些金鑰。
使用 CMEK 設定資源後,存取 Security Command Center 資源的體驗與使用 Google 預設加密類似。如要進一步瞭解加密選項,請參閱「客戶自行管理的加密金鑰 (CMEK)」。
為支援職責分離,並進一步控管金鑰存取權,建議您在不含其他 Google Cloud 資源的獨立專案中建立及管理金鑰。
如要為 Security Command Center 啟用 CMEK,您必須在啟用 Security Command Center 機構時,選擇 Cloud KMS 資料加密。啟用 Security Command Center 後,您就無法再設定資料加密。在專案層級啟用時,無法啟用 CMEK。詳情請參閱下列文章:
啟用 Security Command Center 時,您可以透過 CMEK 機構政策限制,強制執行加密設定。如要瞭解如何使用 CMEK 組織政策限制和 Security Command Center,請參閱本頁面的「CMEK 組織政策限制」一節。
事前準備
為 Security Command Center 設定 CMEK 前,請先完成下列步驟:
安裝並初始化 Google Cloud CLI:
-
Install the Google Cloud CLI.
-
-
If you're using an external identity provider (IdP), you must first sign in to the gcloud CLI with your federated identity.
-
To initialize the gcloud CLI, run the following command:
gcloud init
建立啟用 Cloud KMS 的專案。 Google Cloud 這是您的金鑰專案。
在正確位置建立金鑰環。金鑰環位置必須與您打算啟用 Security Command Center 的位置相符。
如要找出正確位置,請參閱本頁的「重要位置」。如要瞭解如何建立金鑰環,請參閱「建立金鑰環」。
在金鑰環上建立 Cloud KMS 金鑰。如需操作說明,請參閱「建立金鑰」一文。
為確保 Cloud Security Command Center 服務代理人具備加密及解密資料的必要權限,請要求管理員在 Cloud KMS 金鑰上,授予 Cloud Security Command Center 服務代理人 Cloud KMS CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter) IAM 角色。如要進一步瞭解如何授予角色,請參閱「管理專案、資料夾和組織的存取權」。
管理員或許也能透過自訂角色或其他預先定義的角色,授予 Cloud Security Command Center 服務代理程式必要權限。
金鑰位置
為 Security Command Center 建立 Cloud KMS 金鑰和金鑰環時,您必須使用與 Security Command Center 位置對應的位置。
如果您不打算為 Security Command Center 啟用資料落地設定,請在 us 位置建立 Cloud KMS 金鑰和金鑰環。
如要啟用資料落地設定,請選擇與 Security Command Center 位置對應的 Cloud KMS 位置:
| Security Command Center 位置 | Cloud KMS 金鑰位置 |
|---|---|
eu |
europe |
sa |
me-central2 |
us |
us |
變更 CMEK 金鑰
啟用 Security Command Center 時,如果使用 CMEK,就無法變更 Cloud KMS 金鑰或切換為 Google-owned and Google-managed encryption key。
您可以輪替 CMEK 金鑰,讓 Security Command Center 使用新的金鑰版本。不過,部分 Security Command Center 功能仍會使用舊金鑰 30 天。
支援的資源類型
CMEK 會加密下列 Security Command Center 資源類型的資料:
- 發現項目
- 通知設定
- BigQuery 匯出
- 忽略設定
CMEK 組織政策限制
如要強制 Security Command Center 使用 CMEK,您可以在機構、資料夾或專案層級,強制執行下列機構政策限制:
constraints/gcp.restrictNonCmekServices:必須使用 CMEK。如果您對機構強制執行constraints/gcp.restrictNonCmekServices,並將 Security Command Center 列為使用 CMEK 時必須受限的服務,則啟用 Security Command Center 時,必須啟用 CMEK。constraints/gcp.restrictCmekCryptoKeyProjects:規定 Security Command Center 的 CMEK 金鑰必須來自特定專案或一組專案。
如果您在啟用 Security Command Center 的機構強制執行這兩項限制,Security Command Center 會要求您啟用 CMEK,並規定 CMEK 金鑰必須位於特定專案中。
如要瞭解如何評估Google Cloud 資源階層 (機構、資料夾和專案) 的機構政策,請參閱「瞭解階層評估」。
如要瞭解如何使用 CMEK 組織政策的一般資訊,請參閱「CMEK 組織政策」。
為 Security Command Center 設定 CMEK
如要在 Security Command Center 中使用 CMEK,請按照下列步驟操作:
為機構啟用 Security Command Center 時,請選取「編輯資料加密」。
「編輯資料加密設定」窗格隨即開啟。
選取「Cloud KMS key」(Cloud KMS 金鑰)。
選取專案。
選取金鑰。您可以從任何 Google Cloud 專案選取金鑰,包括其他機構的專案。清單中只會顯示相容地點的鑰匙。
如要瞭解哪些主要位置與 Security Command Center 相容,請參閱本頁的「主要位置」一節。
點選「完成」,然後繼續啟用 Security Command Center。
為貴機構啟用 Security Command Center 後,Security Command Center 會使用您選擇的 Cloud KMS 金鑰加密資料。
CMEK 疑難排解
以下各節有助於解決支援 CMEK 的資源類型可能發生的問題。
還原服務代理的金鑰存取權
啟用 CMEK 後,Cloud Security Command Center 服務代理必須有權存取您的 Cloud KMS 金鑰。如果這個服務代理程式沒有金鑰的必要 IAM 角色,Security Command Center 的部分功能就無法正常運作。
如要判斷是否發生這個問題,請查看有權存取金鑰的主體清單。如果服務代理人設定正確,清單會包含具有識別碼 service-org-ORGANIZATION_NUMBER@security-center-api.iam.gserviceaccount.com 的主體,以及 Cloud KMS CryptoKey 加密者/解密者角色 (roles/cloudkms.cryptoKeyEncrypterDecrypter)。
如果沒有看到這個主體和角色,請將必要角色授予金鑰的服務代理程式:
gcloud kms keys add-iam-policy-binding KEY_NAME \
--keyring KEY_RING \
--location LOCATION \
--member=serviceAccount:service-org-ORGANIZATION_NUMBER@security-center-api.iam.gserviceaccount.com \
--role=roles/cloudkms.cryptoKeyEncrypterDecrypter
更改下列內容:
KEY_RING:Cloud KMS 金鑰的金鑰環LOCATION:Cloud KMS 金鑰的位置KEY_NAME:Cloud KMS 金鑰的名稱ORGANIZATION_NUMBER:您的機構號碼
還原已停用或排定刪除的金鑰
如果 Cloud KMS 金鑰或金鑰版本已停用,您可以啟用金鑰版本。
同樣地,如果 Cloud KMS 金鑰已排定刪除,您可以還原金鑰版本。金鑰毀損後無法復原,您也無法存取支援 CMEK 的 Security Command Center 資源。
解決建立受保護資源時發生的錯誤
如果您在啟用 Security Command Center 時選擇 Google-owned and Google-managed encryption keys ,然後在該機構內強制執行 CMEK 組織政策限制,就無法建立支援 CMEK 的新資源。
如果無法建立這些資源,請檢查是否為貴機構或該機構中的任何專案或資料夾強制執行 CMEK 組織政策限制。詳情請參閱本頁面的「CMEK 組織政策限制」。
配額與價格
在 Security Command Center 中使用 CMEK 時,專案可能會耗用 Cloud KMS 密碼編譯要求配額。在 Security Command Center 中讀取或寫入資料時,以 CMEK 加密的執行個體會耗用配額。 只有在使用硬體 (Cloud HSM) 或外部 (Cloud EKM) 金鑰時,使用 CMEK 金鑰的加密和解密作業才會影響 Cloud KMS 配額。 詳情請參閱 Cloud KMS 配額。
此外,Security Command Center 使用 CMEK 加密或解密資料時,系統會收取 Cloud KMS 費用。詳情請參閱 Cloud KMS 定價。