Interview Prep/DevSecOps/Compliance as Code, Threat Modeling & Incident Response

How do you design security logging so it is useful and affordable?

IntermediateProductionCompliance as Code, Threat Modeling & Incident Response
Answer

Split logs by value and query frequency:

  • Hot tier (SIEM): high-value sources used for detection: IdP sign-ins, CloudTrail management events, Kubernetes audit, GuardDuty and EDR alerts, WAF blocks.
  • Warm/cold tier (S3 + Athena, or a security data lake such as Amazon Security Lake in OCSF format): high-volume sources like VPC Flow Logs, DNS logs, S3 data events, queried during investigations.
  • Normalise fields (OCSF or ECS) so queries work across sources.
  • Set retention per source to meet compliance (often 1 year) and investigation needs.

The SIEM bill usually scales with ingestion, so not everything belongs there.

All DevSecOps questions Roadmap: Policy as code

More on Compliance as Code, Threat Modeling & Incident Response