계: Environment

이 섹션에는 소스 코드 외부에 있지만 제작 중인 제품의 보안에는 여전히 중요한 내용이 모두 포함되어 있습니다. 이 섹션에서 다루는 문제들은 소스 코드와 직접적으로 관련이 없기 때문에 나머지 섹션과 분리했습니다.

GCP Terraform Misconfiguration: Insufficient GKE Cluster Monitoring

Abstract
이 Terraform 스크립트는 Google Kubernetes Engine 클러스터의 모니터링 서비스를 비활성화합니다.
Explanation
기본적으로 Google Kubernetes Engine(GKE) 클러스터는 Pod에서 Stackdriver Kubernetes Engine Monitoring Service로 메트릭을 보냅니다. 이 Terraform 스크립트는 GKE 클러스터를 설정하고 모니터링 서비스를 명시적으로 비활성화합니다. 메트릭이 없으면 보안 이벤트의 적절한 감지 및 신속한 대응에 저해됩니다.

예제 1: 다음 예제는 monitoring_servicenone으로 설정하여 GKE 클러스터의 모니터링 서비스를 비활성화하는 Terraform 구성을 보여줍니다.

resource "google_container_cluster" "cluster-demo" {
name = "name-demo"
location = "us-central1-a"
monitoring_service = "none"
...
}
References
[1] HashiCorp google_container_cluster
[2] Google Cloud Configuring Cloud Operations for GKE
[3] Standards Mapping - CIS Google Kubernetes Engine Benchmark Recommendation 5.7.1
[4] Standards Mapping - Common Weakness Enumeration CWE ID 778
[5] Standards Mapping - DISA Control Correlation Identifier Version 2 CCI-000172
[6] Standards Mapping - FIPS200 CM
[7] Standards Mapping - General Data Protection Regulation (GDPR) Indirect Access to Sensitive Data
[8] Standards Mapping - NIST Special Publication 800-53 Revision 4 AU-12 Audit Generation (P1)
[9] Standards Mapping - NIST Special Publication 800-53 Revision 5 AU-12 Audit Record Generation
[10] Standards Mapping - OWASP API 2023 API8 Security Misconfiguration
[11] Standards Mapping - OWASP Application Security Verification Standard 4.0 7.1.3 Log Content Requirements (L2 L3), 7.1.4 Log Content Requirements (L2 L3), 7.2.1 Log Processing Requirements (L2 L3), 7.2.2 Log Processing Requirements (L2 L3)
[12] Standards Mapping - OWASP Top 10 2017 A6 Security Misconfiguration, A10 Insufficient Logging and Monitoring
[13] Standards Mapping - OWASP Top 10 2021 A09 Security Logging and Monitoring Failures
[14] Standards Mapping - Payment Card Industry Data Security Standard Version 3.2.1 Requirement 10.2.1, Requirement 10.2.4, Requirement 10.3.4
[15] Standards Mapping - Payment Card Industry Data Security Standard Version 4.0 Requirement 10.2.1, Requirement 10.2.1.4, Requirement 10.2.2
[16] Standards Mapping - Payment Card Industry Data Security Standard Version 4.0.1 Requirement 10.2.1, Requirement 10.2.1.4, Requirement 10.2.2
[17] Standards Mapping - Payment Card Industry Software Security Framework 1.0 Control Objective 8.2 - Activity Tracking
[18] Standards Mapping - Payment Card Industry Software Security Framework 1.1 Control Objective 8.2 - Activity Tracking
[19] Standards Mapping - Payment Card Industry Software Security Framework 1.2 Control Objective 8.2 - Activity Tracking
[20] Standards Mapping - Security Technical Implementation Guide Version 4.11 APSC-DV-000830 CAT II
[21] Standards Mapping - Security Technical Implementation Guide Version 5.1 APSC-DV-000830 CAT II
[22] Standards Mapping - Security Technical Implementation Guide Version 5.2 APSC-DV-000830 CAT II
[23] Standards Mapping - Security Technical Implementation Guide Version 5.3 APSC-DV-000830 CAT II
[24] Standards Mapping - Security Technical Implementation Guide Version 6.1 APSC-DV-000830 CAT II
desc.structural.hcl.gcp_terraform_misconfiguration_insufficient_gke_cluster_monitoring