Ngân hàng đề — Google Cloud Professional Cloud Security Engineer

Tìm thấy 395 câu.

Câu 271
Your company recently published a security policy to minimize the usage of service account keys. On-premises Windows-based applications are interacting with Google Cloud APIs. You need to implement Workload Identity Federation (WIF) with your identity provider on-premises.

What should you do?
  1. A Set up a workload identity pool with your corporate Active Directory Federation Service (ADFS). Configure a rule to let principals in the pool impersonate the Google Cloud service account.
  2. B Set up a workload identity pool with your corporate Active Directory Federation Service (ADFS). Let all principals in the pool impersonate the Google Cloud service account.
  3. C Set up a workload identity pool with an OpenID Connect (OIDC) service on the same machine. Configure a rule to let principals in the pool impersonate the Google Cloud service account.
  4. D Set up a workload identity pool with an OpenID Connect (OIDC) service on the same machine. Let all principals in the pool impersonate the Google Cloud service account.
Xem giải thích

🧩 Phân tích chi tiết nội dung câu hỏi

Câu hỏi tập trung vào việc triển khai Workload Identity Federation (WIF) trên Google Cloud để thay thế cho việc sử dụng service account keys, nhằm tuân thủ chính sách bảo mật mới của công ty (minimize the usage of service account keys).

  • Bối cảnh: Các ứng dụng Windows-based on-premises (chạy trên máy chủ nội bộ) cần tương tác với Google Cloud APIs.
  • Yêu cầu chính: Sử dụng WIF kết nối với identity provider (IdP) on-premises để các ứng dụng có thể impersonate (giả mạo) service account trên Google Cloud mà không cần lưu trữ keys (giảm rủi ro lộ khóa).
  • Mục tiêu: WIF cho phép external IdPs (như OIDC hoặc SAML) trao đổi token với Google Cloud, cấp quyền tạm thời cho workload mà không cần long-lived credentials.
  • Thách thức: Phải chọn cách thiết lập workload identity pool phù hợp với môi trường Windows on-premises (thường dùng Active Directory Federation Services - ADFS), đồng thời áp dụng quy tắc bảo mật chặt chẽ (không cho phép tất cả principals truy cập).

📘 Kiến thức cập nhật (đến 2026): Theo tài liệu Google Cloud IAM mới nhất (phiên bản 2024-2026), WIF hỗ trợ OIDC và SAML 2.0 providers cho external IdPs. ADFS (dựa trên SAML) được khuyến nghị cho môi trường Windows on-premises. Phải cấu hình attribute conditions/mapping rules trong pool để giới hạn principals (ví dụ: dựa trên claims như group, user), tránh "let all" để tuân thủ nguyên tắc least privilege.

Nguồn tham khảo:

✅ Đáp án đúng và lý do lựa chọn

Đáp án đúng: Set up a workload identity pool with your corporate Active Directory Federation Service (ADFS). Configure a rule to let principals in the pool impersonate the Google Cloud service account.

Lý do:

  • 🛠️ Phù hợp với môi trường: ADFS là IdP chuẩn cho Windows on-premises (hỗ trợ SAML 2.0), cho phép workload pool liên kết trực tiếp với corporate AD.
  • 🛡️ Bảo mật cao: "Configure a rule" nghĩa là thiết lập attribute mapping rules (dựa trên claims như sub, groups) để chỉ principals cụ thể (ví dụ: service accounts hoặc users được ủy quyền) mới impersonate được service account GCP – tuân thủ least privilege và chính sách minimize keys.
  • ✅ Triển khai chuẩn: Tạo pool → Thêm provider SAML từ ADFS → Map attributes → Bind IAM policy cho service account. Điều này loại bỏ keys hoàn toàn.

📋 Giải thích tất cả các phương án (đúng/sai)

  • ✅ Set up a workload identity pool with your corporate Active Directory Federation Service (ADFS). Configure a rule to let principals in the pool impersonate the Google Cloud service account.
    Đúng 🟢: Như giải thích trên, đây là cách an toàn và chính xác nhất. ADFS phù hợp on-premises Windows, rule đảm bảo chỉ principals hợp lệ (qua claims) được impersonate, giảm rủi ro tấn công lateral movement.

  • ❌ Set up a workload identity pool with your corporate Active Directory Federation Service (ADFS). Let all principals in the pool impersonate the Google Cloud service account.
    Sai 🔴: Mặc dù dùng ADFS đúng, nhưng "Let all principals" không an toàn – cho phép mọi identity trong pool (bao gồm unauthorized users/services) impersonate service account, vi phạm least privilege và chính sách bảo mật. Google khuyến cáo luôn dùng conditions/rules.

  • ❌ Set up a workload identity pool with an OpenID Connect (OIDC) service on the same machine. Configure a rule to let principals in the pool impersonate the Google Cloud service account.
    Sai 🔴: "OIDC service on the same machine" không phù hợp với corporate on-premises (Windows apps). OIDC cần IdP riêng (như Keycloak), không phải chạy trên cùng máy app → phức tạp, không scalable. Dù có rule tốt, nhưng IdP sai nên không giải quyết vấn đề.

  • ❌ Set up a workload identity pool with an OpenID Connect (OIDC) service on the same machine. Let all principals in the pool impersonate the Google Cloud service account.
    Sai 🔴: Tệ nhất – Kết hợp 2 lỗi: IdP OIDC cục bộ (không corporate, không phù hợp Windows on-premises) + "Let all" (rủi ro cao). Dễ bị exploit local, không minimize keys hiệu quả.

Kết luận 🎯: Lựa chọn đúng cân bằng giữa tính khả thi (ADFS cho Windows) và bảo mật (rules), giúp triển khai WIF nhanh chóng mà an toàn! Nếu cần lab thực hành, dùng Google Cloud Console hoặc gcloud CLI.

Câu 272
After completing a security vulnerability assessment, you learned that cloud administrators leave Google Cloud CLI sessions open for days. You need to reduce the risk of attackers who might exploit these open sessions by setting these sessions to the minimum duration.

What should you do?
  1. A Set the session duration for the Google session control to one hour.
  2. B Set the reauthentication frequency for the Google Cloud Session Control to one hour.
  3. C Set the organization policy constraint constraints/iam.allowServiceAccountCredentialLifetimeExtension to one hour.
  4. D Set the organization policy constraint constraints/iam.serviceAccountKeyExpiryHours to one hour and inheritFromParent to false.
Xem giải thích

🧩 Phân tích chi tiết câu hỏi trắc nghiệm

✅ Giải thích nội dung câu hỏi:
Câu hỏi mô tả tình huống sau khi thực hiện đánh giá lỗ hổng bảo mật (security vulnerability assessment), phát hiện rằng các quản trị viên đám mây (cloud administrators) để các phiên làm việc Google Cloud CLI (gcloud sessions) mở liên tục trong nhiều ngày. Điều này tạo rủi ro cao vì kẻ tấn công có thể khai thác các phiên mở để truy cập trái phép. Nhiệm vụ là giảm thiểu rủi ro bằng cách thiết lập thời lượng phiên (sessions) ở mức tối thiểu, cụ thể là buộc người dùng phải xác thực lại định kỳ để tránh session "treo" quá lâu. Đây là vấn đề liên quan đến IAM Session Controls trong Google Cloud, giúp kiểm soát thời gian sống của các phiên truy cập từ CLI, console hoặc API, đảm bảo tuân thủ nguyên tắc least privilege và zero trust.

🛠️ Kiến thức liên quan (cập nhật đến 2026):
Theo tài liệu chính thức Google Cloud IAM (phiên bản mới nhất 2026), Session Controls được quản lý qua Organization Policies, cho phép set reauthentication frequency để yêu cầu người dùng xác thực lại sau khoảng thời gian nhất định (ví dụ: 1 giờ), ngay cả khi session vẫn mở. Điều này áp dụng cho user accounts và service accounts sử dụng CLI như gcloud. Không liên quan đến AWS (có lẽ nhầm lẫn trong mô tả), mà tập trung vào Google Cloud.

📘 Tài liệu tham khảo:

🟢 Đáp án đúng và lý do lựa chọn

Đáp án đúng: Set the reauthentication frequency for the Google Cloud Session Control to one hour.

Lý do:
🧩 Phương án này trực tiếp giải quyết vấn đề bằng cách sử dụng Google Cloud Session Control (một tính năng IAM) để đặt tần suất xác thực lại (reauthentication frequency) là 1 giờ. Khi set như vậy, các phiên CLI sẽ tự động hết hạn và yêu cầu người dùng nhập lại credentials sau 1 giờ, giảm rủi ro khai thác session mở lâu ngày. Đây là cách chính xác, hiệu quả nhất theo docs Google Cloud, áp dụng ngay lập tức cho toàn tổ chức qua Organization Policy mà không ảnh hưởng đến service accounts keys riêng biệt.

❌ Phân tích tất cả các phương án (đúng/sai)

  • SAI: Set the session duration for the Google session control to one hour.
    ❌ Giải thích sai: Không tồn tại khái niệm "session duration" trực tiếp trong Google Session Control. Thay vào đó, Google sử dụng reauthentication frequency để kiểm soát, không phải "duration" cố định. Phương án này mơ hồ và không khớp với policy constraint thực tế (như iam.requireReauthenticationFrequencySeconds), dẫn đến không hiệu quả cho CLI sessions.

  • ĐÚNG: Set the reauthentication frequency for the Google Cloud Session Control to one hour.
    ✅ Giải thích đúng: Như đã nêu ở trên, đây là policy chuẩn constraints/iam.requireReauthenticationFrequencySeconds (set = 3600 giây). Nó buộc reauth định kỳ, chấm dứt session CLI mở lâu, giảm rủi ro tối đa mà không làm gián đoạn workflow.

  • SAI: Set the organization policy constraint constraints/iam.allowServiceAccountCredentialLifetimeExtension to one hour.
    ❌ Giải thích sai: Constraint này chỉ kiểm soát việc cho phép mở rộng thời hạn credentials của service accounts (allow extension). Set nó thành 1 giờ không liên quan đến user CLI sessions, mà chỉ ảnh hưởng đến SA token lifetime extension. Không giải quyết vấn đề admin sessions mở lâu.

  • SAI: Set the organization policy constraint constraints/iam.serviceAccountKeyExpiryHours to one hour and inheritFromParent to false.
    ❌ Giải thích sai: Constraint này dành riêng cho thời hạn hết hạn của service account keys (user-managed keys), không áp dụng cho CLI sessions của user accounts. "inheritFromParent: false" chỉ override policy từ parent, nhưng vẫn không xử lý session mở từ gcloud CLI. Dùng sai ngữ cảnh, có thể gây nhầm lẫn với key rotation thay vì session control.

Câu 273
You have numerous private virtual machines on Google Cloud. You occasionally need to manage the servers through Secure Socket Shell (SSH) from a remote location. You want to configure remote access to the servers in a manner that optimizes security and cost efficiency.

What should you do?
  1. A Create a site-to-site VPN from your corporate network to Google Cloud.
  2. B Configure server instances with public IP addresses. Create a firewall rule to only allow traffic from your corporate IPs.
  3. C Create a firewall rule to allow access from the Identity-Aware Proxy (IAP) IP range. Grant the role of an IAP-secured Tunnel User to the administrators.
  4. D Create a jump host instance with public IP. Manage the instances by connecting through the jump host.
Xem giải thích

🧩 Phân tích nội dung câu hỏi

Câu hỏi mô tả tình huống: Bạn sở hữu nhiều máy ảo (VM) private trên Google Cloud Platform (GCP), nghĩa là các VM không có địa chỉ IP công khai (public IP) để tránh rủi ro bảo mật. Bạn thỉnh thoảng cần truy cập quản lý các server này qua Secure Socket Shell (SSH) từ vị trí từ xa (remote location). Yêu cầu chính là cấu hình truy cập từ xa sao cho tối ưu hóa bảo mật (security) và hiệu quả chi phí (cost efficiency).

🛠️ Mục tiêu cốt lõi:

  • Tránh mở public IP để giảm bề mặt tấn công (attack surface).
  • Không cần thiết bị phức tạp hoặc chi phí cao cho truy cập occasional (thỉnh thoảng).
  • Sử dụng các tính năng native của GCP để đảm bảo xác thực mạnh mẽ (identity-based), kiểm soát truy cập chi tiết và không tốn kém.

Dựa trên best practices của GCP đến năm 2026 (phiên bản VPC Firewall, IAP TCP Forwarding mới nhất), giải pháp lý tưởng phải hỗ trợ truy cập không cần VPN đầy đủ, không public IP, và tích hợp IAM (Identity and Access Management).

🟢 Đáp án đúng

Create a firewall rule to allow access from the Identity-Aware Proxy (IAP) IP range. Grant the role of an IAP-secured Tunnel User to the administrators.

✅ Lý do lựa chọn:

  • Identity-Aware Proxy (IAP) là dịch vụ context-aware access của GCP, cho phép truy cập SSH/RDP đến VM private mà không cần public IP, VPN hay bastion host. Nó sử dụng TCP forwarding qua IAP, chỉ cho phép dựa trên IAM roles và IP range cố định của IAP (35.237.200.0/20 cho IPv4).
  • Firewall rule: Mở port 22 (SSH) chỉ từ IP range IAP, đảm bảo không ai khác truy cập được.
  • IAM role "IAP-secured Tunnel User" (roles/iap.tunnelResourceAccessor): Gán cho admin để xác thực dựa trên Google identity, hỗ trợ 2FA/MFA, audit logs đầy đủ.
  • Tối ưu security: Zero-trust model, không expose VM ra internet.
  • Tối ưu cost: Serverless (không tốn VM riêng), pay-per-use (miễn phí cho IAP cơ bản, chỉ tính forwarding traffic thấp), phù hợp occasional access.
  • Đây là recommended method trong GCP docs 2026 cho private VM access.

📋 Giải thích chi tiết tất cả các phương án

Dưới đây là phân tích từng lựa chọn, giữ nguyên văn bản gốc tiếng Anh. Mỗi phương án được đánh giá dựa trên security, cost và tính phù hợp với yêu cầu "occasional remote SSH to private VMs".

  • ❌ Create a site-to-site VPN from your corporate network to Google Cloud.
    Phương án này yêu cầu thiết lập Cloud VPN (HAVPN/IPsec) kết nối toàn bộ corporate network với VPC GCP, cho phép SSH từ on-prem. Sai vì:

    • Không tối ưu cost (VPN gateway tốn ~$0.05/giờ + data transfer, đắt đỏ cho occasional access).
    • Không linh hoạt cho remote location bất kỳ (chỉ từ corporate network).
    • Phức tạp setup (Cloud Router, BGP), không cần thiết khi IAP đơn giản hơn. Security tốt nhưng overkill.
  • ✅ Create a firewall rule to allow access from the Identity-Aware Proxy (IAP) IP range. Grant the role of an IAP-secured Tunnel User to the administrators.
    Như đã giải thích ở trên: Đúng hoàn hảo, kết hợp firewall + IAM cho truy cập an toàn, chi phí thấp, không thay đổi VM config. Hỗ trợ gcloud compute ssh với --tunnel-through-iap.

  • ❌ Configure server instances with public IP addresses. Create a firewall rule to only allow traffic from your corporate IPs.
    Gán ephemeral/static public IP cho VM và firewall tag-based chỉ từ corporate IPs. Sai vì:

    • Public IP tăng rủi ro security (dù firewall, vẫn expose VM ra internet, dễ brute-force SSH nếu IP leak).
    • Không cost-efficient (public IP tốn phí ~$0.01-0.04/giờ/VM, nhân với "numerous VMs").
    • Không hỗ trợ remote linh hoạt (chỉ corporate IPs, khó cho admin di động). Vi phạm nguyên tắc least privilege.
  • ❌ Create a jump host instance with public IP. Manage the instances by connecting through the jump host.
    Tạo bastion/jump host VM với public IP, SSH qua nó đến private VMs. Sai vì:

    • Public IP trên jump host tạo single point of failure (dễ bị tấn công, cần quản lý riêng).
    • Tốn kém (chạy VM liên tục ~$10-20/tháng + public IP), không phù hợp occasional.
    • GCP khuyến nghị thay bằng IAP (deprecated OS Login + bastion từ 2024). Security kém hơn IAP (không native IAM auditing).

📘 Tài liệu tham khảo (cập nhật đến 2026)

Hy vọng phân tích này giúp bạn ôn thi chứng chỉ GCP Professional Cloud Security Engineer! 🚀 Nếu cần thêm chi tiết, hãy hỏi nhé!

Câu 274
Your organization's record data exists in Cloud Storage. You must retain all record data for at least seven years. This policy must be permanent.

What should you do?
  1. A 1. Identify buckets with record data.
    2. Apply a retention policy, and set it to retain for seven years.
    3. Monitor the bucket by using log-based alerts to ensure that no modifications to the retention policy occurs.
  2. B 1. Identify buckets with record data.
    2. Apply a retention policy, and set it to retain for seven years.
    3. Remove any Identity and Access Management (IAM) roles that contain the storage buckets update permission.
  3. C 1. Identify buckets with record data.
    2. Enable the bucket policy only to ensure that data is retained.
    3. Enable bucket lock.
  4. D 1. Identify buckets with record data.
    2. Apply a retention policy and set it to retain for seven years.
    3. Enable bucket lock.
Xem giải thích

🧩 Phân tích nội dung câu hỏi

Câu hỏi tập trung vào việc bảo vệ dữ liệu hồ sơ (record data) lưu trữ trong Google Cloud Storage (GCS), với yêu cầu giữ nguyên dữ liệu ít nhất 7 năm và chính sách này phải vĩnh viễn (permanent), nghĩa là không thể thay đổi hoặc xóa dữ liệu trước thời hạn.

  • Bối cảnh: Dữ liệu nằm trong các bucket của Cloud Storage. Chúng ta cần áp dụng cơ chế retention policy (chính sách lưu giữ) để ngăn chặn việc ghi đè, xóa hoặc chỉnh sửa dữ liệu trong 7 năm.
  • Yêu cầu chính: Chính sách phải không thể đảo ngược (immutable), đảm bảo tuân thủ quy định pháp lý nghiêm ngặt như lưu trữ hồ sơ.
  • Công cụ liên quan (theo tài liệu GCP cập nhật 2024-2026):
    • Object retention policy trên bucket: Đặt thời gian giữ dữ liệu (ví dụ: 7 năm).
    • Bucket Lock: Khóa retention policy, làm nó vĩnh viễn – không ai (kể cả owner) có thể thay đổi hoặc xóa trừ khi hết hạn.
  • Mục tiêu: Xác định bucket chứa dữ liệu → Áp dụng retention → Làm policy vĩnh viễn.

📘 Tài liệu tham khảo:

✅ Đáp án đúng và lý do lựa chọn

Đáp án đúng:

  1. Identify buckets with record data.
  2. Apply a retention policy and set it to retain for seven years.
  3. Enable bucket lock.

Lý do chọn 🛠️:

  • Quy trình hoàn chỉnh và chính xác theo best practice GCP: Bước 1 xác định bucket đúng dữ liệu. Bước 2 áp dụng retention policy với thời hạn 7 năm (compliance retention). Bước 3 enable bucket lock ngay lập tức để khóa policy, làm nó vĩnh viễn – không thể chỉnh sửa metadata, xóa object hoặc thay đổi policy (ngay cả super admin). Đây là cơ chế WORM (Write Once Read Many) chuẩn cho lưu trữ dài hạn, tuân thủ quy định như GDPR/SEC Rule 17a-4.

❌ Phân tích tất cả các phương án

Dưới đây là phân tích chi tiết từng lựa chọn, giữ nguyên văn bản gốc bằng tiếng Anh. Mỗi phương án được đánh giá dựa trên tính đúng đắn, hiệu quả và tuân thủ yêu cầu "permanent policy".

  • Phương án 1 (SAI):

    1. Identify buckets with record data.
    2. Apply a retention policy, and set it to retain for seven years.
    3. Monitor the bucket by using log-based alerts to ensure that no modifications to the retention policy occurs.

    ❌ Lý do sai: Bước 1-2 đúng nhưng bước 3 chỉ giám sát (monitor) qua log-based alerts (Cloud Monitoring), không ngăn chặn thay đổi. Ai có quyền storage.buckets.update vẫn có thể chỉnh policy hoặc xóa dữ liệu → Không đảm bảo "permanent". Chỉ phát hiện sau khi vi phạm, không phải giải pháp chủ động.

  • Phương án 2 (SAI):

    1. Identify buckets with record data.
    2. Apply a retention policy, and set it to retain for seven years.
    3. Remove any Identity and Access Management (IAM) roles that contain the storage buckets update permission.

    ❌ Lý do sai: Bước 1-2 đúng, nhưng bước 3 xóa IAM roles chỉ hạn chế một phần (không loại bỏ quyền của project owner hoặc service accounts ẩn). Không có cơ chế immutable thực sự – vẫn có rủi ro qua IAM khác hoặc lỗi config. Không phải cách GCP khuyến nghị cho "permanent retention"; dễ bị bỏ qua hoặc sai sót.

  • Phương án 3 (SAI):

    1. Identify buckets with record data.
    2. Enable the bucket policy only to ensure that data is retained.
    3. Enable bucket lock.

    ❌ Lý do sai: Bước 1 và 3 đúng, nhưng bước 2 sai hoàn toàn – "bucket policy only" (chỉ dùng bucket policy) không áp dụng retention cho objects. Bucket policy là IAM policy cho quyền truy cập, không phải retention policy (retention phải dùng gcloud storage buckets update --retention-period). Bucket lock chỉ hoạt động sau khi có retention policy, nếu không sẽ lỗi → Không giữ dữ liệu 7 năm.

  • Phương án 4 (ĐÚNG – như đã phân tích ở trên):

    1. Identify buckets with record data.
    2. Apply a retention policy and set it to retain for seven years.
    3. Enable bucket lock.

    ✅ Tóm tắt ưu điểm: Hoàn hảo, immutable 100%, hỗ trợ multi-region buckets (cập nhật GCP 2024+). Lưu ý: Phải enable lock trong 3 ngày đầu sau retention, theo docs.

🛡️ Khuyến nghị bổ sung: Sau khi implement, kiểm tra bằng gsutil retention get gs://bucket và test xóa object (phải fail). Sử dụng Audit Logs để verify.

Câu 275
Your organization wants to protect all workloads that run on Compute Engine VM to ensure that the instances weren't compromised by boot-level or kernel-level malware. Also, you need to ensure that data in use on the VM cannot be read by the underlying host system by using a hardware-based solution.

What should you do?
  1. A 1. Use Google Shielded VM including secure boot, Virtual Trusted Platform Module (vTPM), and integrity monitoring.
    2. Create a Cloud Run function to check for the VM settings, generate metrics, and run the function regularly.
  2. B 1. Activate Virtual Machine Threat Detection in Security Command Center (SCC) Premium.
    2. Monitor the findings in SCC.
  3. C 1. Use Google Shielded VM including secure boot, Virtual Trusted Platform Module (vTPM), and integrity monitoring.
    2. Activate Confidential Computing.
    3. Enforce these actions by using organization policies.
  4. D 1. Use secure hardened images from the Google Cloud Marketplace.
    2. When deploying the images, activate the Confidential Computing option.
    3. Enforce the use of the correct images and Confidential Computing by using organization policies.
Xem giải thích

🧩 Phân tích nội dung câu hỏi

Câu hỏi tập trung vào việc bảo mật toàn diện cho các workload chạy trên Compute Engine VM trong Google Cloud Platform (GCP). Cụ thể:

  • Yêu cầu chính 1: Bảo vệ instances khỏi malware ở mức boot-level (khởi động) hoặc kernel-level (lõi hệ điều hành), đảm bảo VM không bị compromise từ các lỗ hổng cơ bản.
  • Yêu cầu chính 2: Đảm bảo dữ liệu đang sử dụng (data in use) trên VM không thể bị đọc bởi hệ thống host bên dưới, sử dụng giải pháp dựa trên phần cứng (hardware-based).
  • Mục tiêu: Áp dụng cho tất cả workload trên Compute Engine, cần giải pháp toàn diện, tự động và có thể enforce bắt buộc.

Đây là tình huống thực tế trong bảo mật đám mây, nơi Shielded VM xử lý phần chống malware boot/kernel, còn Confidential Computing bảo vệ data in use bằng mã hóa phần cứng (như AMD SEV-ES hoặc Intel TDX). Kiến thức dựa trên tài liệu GCP cập nhật đến 2026 (GCP Shielded VM v2, Confidential Computing với TDX GA từ 2024).

📘 Tài liệu tham khảo:

✅ Đáp án đúng: Phương án 3

Lý do chọn:

  • Phương án này đầy đủ và chính xác nhất, kết hợp Shielded VM (secure boot + vTPM + integrity monitoring) để chống malware boot/kernel-level 🛡️.
  • Confidential Computing cung cấp bảo vệ hardware-based cho data in use, mã hóa bộ nhớ VM khỏi host (sử dụng SEV hoặc TDX) 🔒.
  • Enforce bằng organization policies đảm bảo áp dụng cho tất cả VM trong tổ chức, tự động và bắt buộc, phù hợp yêu cầu "protect all workloads" 🚀.
  • Đây là best practice GCP đến 2026, không có giải pháp thay thế tốt hơn.

🛠️ Giải thích chi tiết tất cả các phương án

Dưới đây là phân tích từng phương án. Tôi giữ nguyên văn bản gốc bằng tiếng Anh, chỉ giải thích bằng tiếng Việt với lý do đúng/sai. Sử dụng ✅ cho đúng, ❌ cho sai.

  • ❌ Phương án 1

    1. Use Google Shielded VM including secure boot, Virtual Trusted Platform Module (vTPM), and integrity monitoring.
    2. Create a Cloud Run function to check for the VM settings, generate metrics, and run the function regularly.
      Giải thích sai: Shielded VM ✅ xử lý tốt chống malware boot/kernel, nhưng thiếu bảo vệ data in use hardware-based. Cloud Run function chỉ kiểm tra metrics định kỳ, không phải giải pháp hardware thực thi bảo mật, dễ bỏ sót và không enforce bắt buộc. Không đáp ứng "hardware-based solution" cho host isolation.
  • ❌ Phương án 2

    1. Activate Virtual Machine Threat Detection in Security Command Center (SCC) Premium.
    2. Monitor the findings in SCC.
      Giải thích sai: VM Threat Detection (trong SCC Premium) chỉ phát hiện (detect) threat sau khi xảy ra (như malware), không ngăn chặn (prevent) boot/kernel compromise. Hoàn toàn thiếu bảo vệ data in use. Đây là monitoring thụ động, không hardware-based và không enforce cho tất cả VM 🕵️‍♂️.
  • ✅ Phương án 3 (Đúng)

    1. Use Google Shielded VM including secure boot, Virtual Trusted Platform Module (vTPM), and integrity monitoring.
    2. Activate Confidential Computing.
    3. Enforce these actions by using organization policies.
      Giải thích đúng: Hoàn hảo bao quát cả hai yêu cầu: Shielded VM chống malware 🛡️, Confidential Computing mã hóa data in use bằng hardware (host không đọc được) 🔐. Org policies enforce tự động cho toàn tổ chức, scalable đến 2026. Best practice từ GCP Security blueprint.
  • ❌ Phương án 4

    1. Use secure hardened images from the Google Cloud Marketplace.
    2. When deploying the images, activate the Confidential Computing option.
    3. Enforce the use of the correct images and Confidential Computing by using organization policies.
      Giải thích sai: Hardened images + Confidential tốt cho data in use, nhưng không có Shielded VM features (secure boot/vTPM/integrity) để chống boot/kernel malware. Chỉ áp dụng cho images cụ thể từ Marketplace, không bảo vệ "all workloads" hiện có hoặc VM tự tạo, thiếu toàn diện ❌.
Câu 276 Chọn nhiều đáp án
You are migrating your users to Google Cloud. There are cookie replay attacks with Google web and Google Cloud CLI SDK sessions on endpoint devices. You need to reduce the risk of these threats.

What should you do? (Choose two.)
  1. A Configure Google session control to a shorter duration.
  2. B Set an organizational policy for OAuth 2.0 access token with a shorter duration.
  3. C Set a reauthentication policy for Google Cloud services to a shorter duration.
  4. D Configure a third-party identity provider with session management.
  5. E Enforce Security Key Authentication with 2SV.
Xem giải thích

🧩 Phân tích nội dung câu hỏi

Câu hỏi tập trung vào tình huống di chuyển người dùng sang Google Cloud, nơi tồn tại rủi ro cookie replay attacks (tấn công phát lại cookie) liên quan đến các phiên làm việc (sessions) của Google web (giao diện web Google) và Google Cloud CLI SDK (công cụ dòng lệnh SDK của Google Cloud) trên các thiết bị endpoint (như máy tính người dùng).

Vấn đề cốt lõi: Cookie replay attack xảy ra khi kẻ tấn công đánh cắp cookie phiên hợp lệ và sử dụng lại để giả mạo phiên làm việc, dẫn đến truy cập trái phép. Điều này đặc biệt nguy hiểm trên endpoint devices vì cookie có thể bị đánh cắp qua malware, network sniffing hoặc các lỗ hổng thiết bị.

Mục tiêu: Giảm rủi ro bằng cách chọn hai giải pháp (Choose two) giúp rút ngắn thời gian sống của session/cookie, buộc re-authentication thường xuyên hơn, từ đó hạn chế cửa sổ thời gian cho replay attack. Câu hỏi thuộc chủ đề bảo mật phiên làm việc (session security) trong Google Cloud, liên quan đến Identity and Access Management (IAM), Context-Aware Access (CAA) và Google Workspace/Cloud Identity policies (cập nhật đến 2026 với các tính năng session controls nâng cao trong IAP và BeyondCorp Enterprise).

📘 Tài liệu tham khảo:

✅ Đáp án đúng (Chọn hai)

Hai lựa chọn đúng là:

  1. Configure Google session control to a shorter duration.
  2. Set a reauthentication policy for Google Cloud services to a shorter duration.

Lý do chọn:
Cả hai giải pháp trực tiếp rút ngắn thời lượng session/cookie cho Google web và Cloud CLI SDK, giảm cửa sổ thời gian cho replay attack. Google session control áp dụng cho các phiên web/CLI chung, trong khi reauthentication policy buộc xác thực lại định kỳ cho GCP services (như gcloud CLI). Điều này phù hợp với best practices của Google Cloud để chống session hijacking/replay (theo AWS tương đương là IAM session policies, nhưng ở đây là GCP-native).

🛠️ Giải thích chi tiết từng phương án

  • ✅ Configure Google session control to a shorter duration.
    Đúng: Giải pháp này cấu hình session control của Google (qua Admin Console hoặc Cloud Identity) để giảm thời lượng session mặc định (ví dụ: từ 24h xuống 1h). Nó áp dụng trực tiếp cho Google web sessions và Cloud CLI SDK (gcloud auth), làm cookie hết hạn nhanh hơn, giảm rủi ro replay trên endpoint. Đây là biện pháp gốc của Google Cloud, hỗ trợ granular controls cho web và CLI.

  • ❌ Set an organizational policy for OAuth 2.0 access token with a shorter duration.
    Sai: OAuth 2.0 access token dùng cho API calls (như service accounts hoặc application auth), không phải session cookie của web/CLI. Rút ngắn token lifetime chỉ ảnh hưởng đến API requests ngắn hạn, không giải quyết cookie replay cho user sessions trên endpoint (token thường refresh tự động, không liên quan trực tiếp đến web/CLI cookie).

  • ✅ Set a reauthentication policy for Google Cloud services to a shorter duration.
    Đúng: Reauthentication policy (qua Cloud Identity hoặc Workspace) buộc người dùng xác thực lại định kỳ (ví dụ: mỗi 30 phút) cho GCP services, bao gồm Cloud CLI SDK và web console. Điều này làm gián đoạn session cookie, ngăn replay attack bằng cách yêu cầu fresh auth (hỗ trợ MFA/phishing-resistant), tích hợp với Context-Aware Access (CAA) để kiểm soát endpoint.

  • ❌ Configure a third-party identity provider with session management.
    Sai: Sử dụng IdP bên thứ ba (như Okta, Azure AD) có thể quản lý session, nhưng không trực tiếp kiểm soát Google-native web/CLI cookie. Trong migration sang Google Cloud, điều này thêm complexity và không giải quyết cookie replay của Google sessions (phải federate qua OIDC/SAML, nhưng session duration vẫn phụ thuộc Google policies). Không phải giải pháp gốc cho Google ecosystem.

  • ❌ Enforce Security Key Authentication with 2SV.
    Sai: Security Key (FIDO2) với 2-Step Verification (2SV, nay là 2SV nâng cao) tăng cường initial authentication, chống phishing tốt nhưng không rút ngắn session duration sau khi login. Cookie vẫn có thể bị replay trong thời gian session dài; đây là biện pháp auth ban đầu, không phải session management để chống replay.

🧩 Kết luận: Hai giải pháp đúng tập trung vào session lifetime management native của Google Cloud, là cách hiệu quả nhất để giảm rủi ro cookie replay mà không cần third-party hoặc thay đổi auth flow lớn. Khuyến nghị triển khai kết hợp với device posture checks qua CAA cho bảo mật toàn diện! 🚀

Câu 277 Chọn nhiều đáp án
You manage a mission-critical workload for your organization, which is in a highly regulated industry. The workload uses Compute Engine VMs to analyze and process the sensitive data after it is uploaded to Cloud Storage from the endpoint computers. Your compliance team has detected that this workload does not meet the data protection requirements for sensitive data. You need to meet these requirements:

•Manage the data encryption key (DEK) outside the Google Cloud boundary.
•Maintain full control of encryption keys through a third-party provider.
•Encrypt the sensitive data before uploading it to Cloud Storage.
•Decrypt the sensitive data during processing in the Compute Engine VMs.
•Encrypt the sensitive data in memory while in use in the Compute Engine VMs.

What should you do? (Choose two.)
  1. A Configure Customer Managed Encryption Keys to encrypt the sensitive data before it is uploaded to Cloud Storage, and decrypt the sensitive data after it is downloaded into your VMs.
  2. B Configure Cloud External Key Manager to encrypt the sensitive data before it is uploaded to Cloud Storage, and decrypt the sensitive data after it is downloaded into your VMs.
  3. C Create Confidential VMs to access the sensitive data.
  4. D Migrate the Compute Engine VMs to Confidential VMs to access the sensitive data.
  5. E Create a VPC Service Controls service perimeter across your existing Compute Engine VMs and Cloud Storage buckets.
Xem giải thích

🧩 Phân tích chi tiết câu hỏi

Câu hỏi này thuộc lĩnh vực bảo mật dữ liệu nhạy cảm trên Google Cloud Platform (GCP), cụ thể liên quan đến việc xử lý workload quan trọng (mission-critical) trong ngành công nghiệp được quy định nghiêm ngặt (highly regulated industry). Workload sử dụng Compute Engine VMs để phân tích và xử lý dữ liệu nhạy cảm sau khi dữ liệu được upload từ các endpoint computers lên Cloud Storage.

Vấn đề chính: Đội ngũ compliance phát hiện workload không đáp ứng yêu cầu bảo vệ dữ liệu, cần thực hiện các biện pháp sau:

  • 📛 Quản lý khóa mã hóa dữ liệu (DEK - Data Encryption Key) bên ngoài ranh giới Google Cloud (outside the Google Cloud boundary).
  • 🔐 Kiểm soát hoàn toàn khóa mã hóa qua nhà cung cấp bên thứ ba (third-party provider).
  • 🔒 Mã hóa dữ liệu nhạy cảm trước khi upload lên Cloud Storage.
  • 🔓 Giải mã dữ liệu trong quá trình xử lý trên Compute Engine VMs.
  • 🧠 Mã hóa dữ liệu trong bộ nhớ (in memory) khi đang sử dụng trên Compute Engine VMs.

Yêu cầu hành động: Chọn hai giải pháp để đáp ứng đầy đủ các tiêu chí trên. Đây là câu hỏi kiểu select two từ kỳ thi Google Cloud Professional Cloud Security Engineer.

✅ Đáp án đúng và lý do lựa chọn

Hai đáp án đúng là:

  1. Configure Cloud External Key Manager to encrypt the sensitive data before it is uploaded to Cloud Storage, and decrypt the sensitive data after it is downloaded into your VMs.
  2. Create Confidential VMs to access the sensitive data.

Lý do lựa chọn:

  • 🛠️ Cloud External Key Manager (EKM): Dịch vụ này cho phép quản lý DEK bên ngoài GCP qua third-party key provider (như Thales CipherTrust, Fortanix, etc.), đáp ứng yêu cầu "manage DEK outside boundary" và "full control through third-party". Client mã hóa dữ liệu trước upload (client-side encryption), giải mã trong VMs sau download – hoàn hảo cho encryption at rest và transit.
  • 🧠 Create Confidential VMs: Sử dụng công nghệ AMD SEV-SNP (Secure Encrypted Virtualization) để mã hóa dữ liệu in-use trong bộ nhớ (memory encryption), bảo vệ dữ liệu ngay cả khi đang xử lý trên VMs. Đây là giải pháp gốc để encrypt data in memory, không cần migrate VMs cũ.

Kết hợp hai giải pháp này đáp ứng toàn bộ 5 yêu cầu, đảm bảo bảo mật end-to-end (before upload, at rest, in transit, in use).

📋 Giải thích chi tiết từng phương án

Dưới đây là phân tích tất cả các lựa chọn, giữ nguyên văn bản gốc tiếng Anh. Mỗi phương án được đánh giá ✅ Đúng hoặc ❌ Sai, kèm giải thích bằng tiếng Việt dựa trên tài liệu GCP mới nhất (cập nhật đến 2026, phiên bản Confidential Computing v2 với SEV-SNP enhanced).

  • Configure Customer Managed Encryption Keys to encrypt the sensitive data before it is uploaded to Cloud Storage, and decrypt the sensitive data after it is downloaded into your VMs.
    ❌ Sai: Customer Managed Encryption Keys (CMEK) sử dụng Cloud KMS của GCP, khóa được quản lý bên trong ranh giới Google Cloud (không outside boundary) và không qua third-party provider độc lập. Không đáp ứng yêu cầu DEK outside GCP; chỉ phù hợp cho server-side encryption, không phải client-side trước upload.

  • Configure Cloud External Key Manager to encrypt the sensitive data before it is uploaded to Cloud Storage, and decrypt the sensitive data after it is downloaded into your VMs.
    ✅ Đúng: Cloud EKM tích hợp external key providers (ví dụ: AWS KMS, Azure Key Vault qua partner), quản lý DEK ngoài GCP boundary với full control từ third-party. Hỗ trợ client-side encryption (mã hóa trước upload) và decrypt trong VMs, đáp ứng encryption at rest/transit. Lý tưởng cho regulated industries như finance/healthcare.

  • Create Confidential VMs to access the sensitive data.
    ✅ Đúng: Confidential VMs (dựa trên AMD SEV-ES/SEV-SNP) mã hóa dữ liệu trong bộ nhớ khi đang sử dụng (in-use), bảo vệ khỏi hypervisor/host attacks. Tạo mới VMs này để xử lý data, đáp ứng yêu cầu cuối cùng. Không cần thay đổi Storage hay key management.

  • Migrate the Compute Engine VMs to Confidential VMs to access the sensitive data.
    ❌ Sai: Không thể migrate trực tiếp VMs thông thường sang Confidential VMs; phải tạo mới (create) Confidential VMs và deploy workload lại (rebuild/migrate data). GCP không hỗ trợ conversion in-place (theo docs 2026), nên phương án này không khả thi và gây nhầm lẫn.

  • Create a VPC Service Controls service perimeter across your existing Compute Engine VMs and Cloud Storage buckets.
    ❌ Sai: VPC Service Controls (VPC-SC) bảo vệ dữ liệu at rest/in-transit bằng cách kiểm soát access và ngăn data exfiltration (như bucket-to-VM leaks). Không liên quan đến DEK management outside boundary, client-side encryption, hoặc in-memory encryption. Chỉ bổ sung, không giải quyết core requirements.

📘 Tài liệu tham khảo (GCP Official Docs - cập nhật 2026)

Giải pháp này đảm bảo tuân thủ zero-trust và data protection theo NIST/PCI-DSS! 🚀

Câu 278
Your organization wants to be General Data Protection Regulation (GDPR) compliant. You want to ensure that your DevOps teams can only create Google Cloud resources in the Europe regions.

What should you do?
  1. A Use Identity-Aware Proxy (IAP) with Access Context Manager to restrict the location of Google Cloud resources.
  2. B Use the org policy constraint 'Google Cloud Platform – Resource Location Restriction' on your Google Cloud organization node.
  3. C Use the org policy constraint 'Restrict Resource Service Usage' on your Google Cloud organization node.
  4. D Use Identity and Access Management (IAM) custom roles to ensure that your DevOps team can only create resources in the Europe regions.
Xem giải thích

🧩 Phân tích chi tiết nội dung câu hỏi

Câu hỏi tập trung vào việc tuân thủ GDPR (Quy định Bảo vệ Dữ liệu Chung của EU), yêu cầu tổ chức đảm bảo rằng các đội DevOps chỉ có thể tạo tài nguyên Google Cloud (như VM, storage, databases, v.v.) chỉ trong các vùng (regions) châu Âu (ví dụ: europe-west1, europe-central1, v.v.).

📌 Mục tiêu chính: Áp dụng cơ chế kiểm soát tại cấp tổ chức (organization level) để hạn chế vị trí địa lý khi tạo tài nguyên mới, tránh tạo resources ở các vùng ngoài châu Âu (như US hay Asia), giúp dữ liệu cá nhân EU được lưu trữ và xử lý đúng quy định GDPR (Article 44-50 về chuyển giao dữ liệu).

🛠️ Bối cảnh Google Cloud: Sử dụng Organization Policy (Chính sách Tổ chức) để enforce các ràng buộc (constraints) bắt buộc, áp dụng từ root organization xuống các project/folder, không phụ thuộc vào IAM roles của user.

✅ Đáp án đúng và lý do lựa chọn

Đáp án đúng: Use the org policy constraint 'Google Cloud Platform – Resource Location Restriction' on your Google Cloud organization node.

Lý do chi tiết:

  • Constraint này (tên đầy đủ: constraints/gcp.resourceLocations) chính là công cụ chính thức và mạnh mẽ nhất của Google Cloud để hạn chế vị trí (locations/regions) khi tạo tất cả các tài nguyên hỗ trợ (hàng trăm services như Compute Engine, Cloud Storage, BigQuery, v.v.).
  • Áp dụng tại organization node (cấp root), nó enforce bắt buộc cho toàn bộ tổ chức, DevOps teams không thể tạo resources ngoài danh sách regions châu Âu được chỉ định (ví dụ: europe-west1, europe-west4).
  • Tuân thủ GDPR: Đảm bảo dữ liệu EU chỉ ở EU regions, hỗ trợ Data Residency.
  • Cập nhật 2026: Vẫn là best practice theo Google Cloud docs (phiên bản mới nhất hỗ trợ thêm multi-region restrictions và auto-compliance checks).

📘 Tài liệu tham khảo:

📋 Giải thích tất cả các phương án (đúng/sai)

Dưới đây là phân tích từng lựa chọn một cách chi tiết, giữ nguyên văn bản gốc bằng tiếng Anh. Mỗi phương án được đánh giá với lý do đúng/sai dựa trên kiến thức Google Cloud mới nhất (2026).

  • Use Identity-Aware Proxy (IAP) with Access Context Manager to restrict the location of Google Cloud resources.
    ❌ Sai: IAP dùng để bảo vệ truy cập vào applications/APIs qua context-based access (như device, IP), không kiểm soát vị trí tạo resources. Access Context Manager chỉ enforce access policies, không ngăn tạo resources ở regions sai. Không phù hợp cho DevOps workflows (CLI/gcloud).

  • Use the org policy constraint 'Google Cloud Platform – Resource Location Restriction' on your Google Cloud organization node.
    ✅ Đúng: Như đã giải thích ở trên, đây là constraint lý tưởng, enforce allowlist/denylist regions tại organization level, chặn ngay lập tức khi tạo resources ngoài châu Âu. Hiệu quả 100% cho compliance.

  • Use the org policy constraint 'Restrict Resource Service Usage' on your Google Cloud organization node.
    ❌ Sai: Constraint này (constraints/serviceusage.services) chỉ hạn chế sử dụng các services cụ thể (ví dụ: tắt BigQuery), không kiểm soát vị trí địa lý của resources. DevOps vẫn tạo resources ở US nếu service được allow.

  • Use Identity and Access Management (IAM) custom roles to ensure that your DevOps team can only create resources in the Europe regions.
    ❌ Sai: IAM custom roles chỉ gán permissions (như compute.instances.create), không enforce location restrictions. User có quyền create ở bất kỳ region nào nếu project cho phép. Không phải giải pháp compliance-level, dễ bypass qua service accounts.

🛡️ Lời khuyên bổ sung: Kết hợp với Folder-level policies cho fine-grained control và Audit Logs để monitor violations. Test bằng gcloud trước khi deploy!

Câu 279
For data residency requirements, you want your secrets in Google Clouds Secret Manager to only have payloads in europe-west1 and europe-west4. Your secrets must be highly available in both regions.

What should you do?
  1. A Create your secret with a user managed replication policy, and choose only compliant locations.
  2. B Create your secret with an automatic replication policy, and choose only compliant locations.
  3. C Create two secrets by using Terraform, one in europe-west1 and the other in europe-west4.
  4. D Create your secret with an automatic replication policy, and create an organizational policy to deny secret creation in non-compliant locations.
Xem giải thích

🧩 Giải thích chi tiết nội dung câu hỏi

Câu hỏi tập trung vào yêu cầu về data residency (nơi lưu trữ dữ liệu) trong Google Cloud Secret Manager – dịch vụ quản lý bí mật (secrets) an toàn. Cụ thể:

  • Bạn muốn payloads (nội dung bí mật thực tế) chỉ được lưu trữ ở hai vùng europe-west1 (Bỉ) và europe-west4 (Hà Lan), để tuân thủ quy định địa phương hóa dữ liệu.
  • Đồng thời, secrets phải highly available (có tính sẵn sàng cao) ở cả hai vùng này, nghĩa là có thể truy cập và phục hồi từ bất kỳ vùng nào trong số đó, tránh single point of failure.

Mục tiêu chính: Tạo một secret duy nhất với chính sách replication (sao chép dữ liệu) tùy chỉnh, đảm bảo payloads chỉ ở đúng hai vùng compliant (tuân thủ), và hỗ trợ high availability (HA) đa vùng.

📘 Tài liệu tham khảo:

✅ Đáp án đúng

Create your secret with a user managed replication policy, and choose only compliant locations.

Lý do lựa chọn:
🛠️ User-managed replication policy cho phép bạn chỉ định chính xác các vùng (europe-west1 và europe-west4) để lưu trữ payloads, đảm bảo data residency nghiêm ngặt. Secret sẽ được replicate sang cả hai vùng, mang lại high availability (tính sẵn sàng cao 99.95% multi-region). Đây là cách chính thức từ Google Cloud để kiểm soát vị trí dữ liệu mà không replicate thừa. Không có replication tự động nào khác phù hợp.

📋 Giải thích tất cả các phương án

Dưới đây là phân tích từng lựa chọn, giữ nguyên văn bản gốc bằng tiếng Anh. Mỗi phương án được đánh giá đúng/sai với lý do chi tiết:

  • ✅ Create your secret with a user managed replication policy, and choose only compliant locations.
    Đúng vì: Chính sách user-managed cho phép chọn chỉ hai vùng cụ thể (europe-west1, europe-west4), đảm bảo payloads không lan sang vùng khác, đồng thời hỗ trợ HA đa vùng (automatic failover). Hoàn hảo cho data residency và tính sẵn sàng cao.

  • ❌ Create your secret with an automatic replication policy, and choose only compliant locations.
    Sai vì: Automatic replication replicate payloads tự động đến tất cả multi-regions supported (hàng chục vùng toàn cầu), không thể giới hạn chỉ hai vùng. Không có tùy chọn "choose compliant locations" cho automatic – nó bỏ qua residency requirements.

  • ❌ Create two secrets by using Terraform, one in europe-west1 and the other in europe-west4.
    Sai vì: Tạo hai secrets riêng biệt không tạo ra một secret thống nhất với HA. Bạn phải quản lý đồng bộ thủ công (sync payloads), không hỗ trợ automatic replication/failover tự nhiên của Secret Manager. Terraform chỉ là tool IaC, không giải quyết vấn đề cốt lõi.

  • ❌ Create your secret with an automatic replication policy, and create an organizational policy to deny secret creation in non-compliant locations.
    Sai vì: Automatic policy vẫn replicate toàn cầu, organizational policy chỉ chặn tạo secret mới ở vùng không compliant chứ không kiểm soát replication hiện tại. Payloads vẫn bị lưu ở vùng ngoài europe-west1/4, vi phạm residency.

Kết luận nổi bật 🎯: Sử dụng user-managed replication là giải pháp chuẩn nhất cho Google Cloud Secret Manager đến năm 2026, đảm bảo tuân thủ và HA! Nếu triển khai, dùng gcloud CLI: gcloud secrets create SECRET_NAME --replication-policy=user-managed --locations=europe-west1,europe-west4.

Câu 280
You are migrating an application into the cloud. The application will need to read data from a Cloud Storage bucket. Due to local regulatory requirements, you need to hold the key material used for encryption fully under your control and you require a valid rationale for accessing the key material.

What should you do?
  1. A Encrypt the data in the Cloud Storage bucket by using Customer Managed Encryption Keys. Configure an IAM deny policy for unauthorized groups.
  2. B Generate a key in your on-premises environment to encrypt the data before you upload the data to the Cloud Storage bucket. Upload the key to the Cloud Key Management Service (KMS). Activate Key Access Justifications (KAJ) and have the external key system reject unauthorized accesses.
  3. C Encrypt the data in the Cloud Storage bucket by using Customer Managed Encryption Keys backed by a Cloud Hardware Security Module (HSM). Enable data access logs.
  4. D Generate a key in your on-premises environment and store it in a Hardware Security Module (HSM) that is managed on-premises. Use this key as an external key in the Cloud Key Management Service (KMS). Activate Key Access Justifications (KAJ) and set the external key system to reject unauthorized accesses.
Xem giải thích

🧩 Phân tích nội dung câu hỏi

Câu hỏi mô tả tình huống bạn đang di chuyển (migrate) một ứng dụng lên đám mây Google Cloud. Ứng dụng này cần đọc dữ liệu từ một bucket Cloud Storage. Tuy nhiên, do yêu cầu quy định địa phương (local regulatory requirements), bạn phải:

  • Giữ hoàn toàn quyền kiểm soát vật liệu khóa mã hóa (key material) dưới sự quản lý của mình (fully under your control) – nghĩa là không để Google Cloud lưu trữ hoặc quản lý key material.
  • Yêu cầu lý do hợp lệ (valid rationale) mỗi khi truy cập key material, để đảm bảo tính minh bạch và tuân thủ.

📘 Mục tiêu chính: Sử dụng giải pháp mã hóa cho dữ liệu trong Cloud Storage bucket, kết hợp với Cloud KMS (Key Management Service), nhưng đảm bảo key material không bao giờ rời khỏi môi trường on-premises của bạn, đồng thời có cơ chế kiểm soát truy cập nghiêm ngặt với Key Access Justifications (KAJ).

🛠️ Bối cảnh kiến thức AWS/Google Cloud cập nhật đến 2026: Đây là tính năng của Google Cloud KMS (không phải AWS KMS, dù có thuật ngữ tương đồng). AWS dùng S3 + KMS/CloudHSM, nhưng câu hỏi dùng "Cloud Storage" và "Cloud KMS" – đặc trưng Google Cloud. Phiên bản mới nhất (2026): Cloud KMS hỗ trợ External Keys (khóa bên ngoài) và KAJ để audit/truy cập với lý do bắt buộc.

✅ Đáp án đúng và lý do lựa chọn

Đáp án đúng: Generate a key in your on-premises environment and store it in a Hardware Security Module (HSM) that is managed on-premises. Use this key as an external key in the Cloud Key Management Service (KMS). Activate Key Access Justifications (KAJ) and set the external key system to reject unauthorized accesses.

Lý do chi tiết:

  • 🗝️ Fully under your control: Tạo key trong HSM on-premises (quản lý bởi bạn), sử dụng làm external key trong Cloud KMS. Key material KHÔNG bao giờ upload lên Google Cloud, Google chỉ wrap/unwrap ciphertexts – bạn kiểm soát 100%.
  • 📝 Valid rationale: Kích hoạt KAJ yêu cầu người dùng cung cấp lý do hợp lệ cho mỗi lần truy cập key. Hệ thống external key (on-premises) có thể reject nếu không hợp lệ.
  • ✅ Hoàn hảo phù hợp quy định, hỗ trợ mã hóa dữ liệu Cloud Storage qua CMEK/External KMS keys.

📋 Giải thích tất cả các phương án

Dưới đây là phân tích từng phương án một cách chi tiết (giữ nguyên văn bản gốc tiếng Anh). Tôi đánh dấu ✅ đúng hoặc ❌ sai, kèm lý do dựa trên tài liệu Google Cloud KMS mới nhất.

  • Phương án A: Encrypt the data in the Cloud Storage bucket by using Customer Managed Encryption Keys. Configure an IAM deny policy for unauthorized groups.
    ❌ Sai: CMEK (Customer-Managed Encryption Keys) cho phép bạn quản lý key metadata (như rotation), nhưng key material vẫn lưu trữ trong Google Cloud KMS – không "fully under your control". IAM deny chỉ kiểm soát quyền truy cập IAM, không cung cấp "valid rationale" cho key access (KAJ). Không đáp ứng quy định giữ key on-premises.

  • Phương án B: Generate a key in your on-premises environment to encrypt the data before you upload the data to the Cloud Storage bucket. Upload the key to the Cloud Key Management Service (KMS). Activate Key Access Justifications (KAJ) and have the external key system reject unauthorized accesses.
    ❌ Sai: Dù tạo key on-premises và dùng KAJ (tốt cho rationale), nhưng upload key lên Cloud KMS nghĩa là key material chuyển sang Google Cloud – vi phạm "hold key material fully under your control". Không phải external key thực sự, vì material không còn on-premises.

  • Phương án C: Encrypt the data in the Cloud Storage bucket by using Customer Managed Encryption Keys backed by a Cloud Hardware Security Module (HSM). Enable data access logs.
    ❌ Sai: CMEK backed by Cloud HSM (Google-managed HSM) vẫn để key material trong môi trường Google Cloud – không under your control (bạn không quản lý HSM vật lý). Data access logs chỉ ghi log, không yêu cầu "valid rationale" trước khi access (không có KAJ). Không giữ key on-premises.

  • Phương án D: Generate a key in your on-premises environment and store it in a Hardware Security Module (HSM) that is managed on-premises. Use this key as an external key in the Cloud Key Management Service (KMS). Activate Key Access Justifications (KAJ) and set the external key system to reject unauthorized accesses.
    ✅ Đúng: Như giải thích ở phần đáp án. External Keys + on-premises HSM + KAJ là giải pháp chuẩn cho strict regulatory compliance (ví dụ: PCI-DSS, GDPR).

📚 Tài liệu tham khảo (cập nhật 2026)

Hy vọng phân tích này giúp bạn ôn thi hiệu quả! 🚀 Nếu cần thêm ví dụ code Terraform, hãy hỏi nhé.