Interview Prep/Monitoring & Observability/Logging: ELK/EFK, Loki & Log Shippers

Why should you not log secrets or PII, and how do you enforce it?

IntermediateConceptLogging: ELK/EFK, Loki & Log Shippers
Answer

Logs are copied to many systems with broad access and long retention, so a leaked token or card number in a log is a breach (and a GDPR/DPDP or PCI DSS violation).

Enforcement layers: logging library redaction (field allowlists, masking), linting in code review, and pipeline scrubbing (Fluent Bit modify/Lua filters, OTel Collector redaction or transform processor, Vector VRL redact). Defense in depth matters because one layer always misses something.

All Monitoring & Observability questions Roadmap: Logging & tracing

More on Logging: ELK/EFK, Loki & Log Shippers