Cybersecurity
Secrets management
Passwords, keys and tokens outside the code: environment variables, secret managers, rotation and leaks.
Article
A .env.production file in a public repository for 20 minutes was enough for someone to start crypto miners in the pierogi shop's AWS account. We build proper secrets management – what counts as a secret, where environment variables stop being enough, AWS Secrets Manager vs Parameter Store, cached and rotation-aware reads in Node.js, CDK with database password rotation, dynamic secrets in Vault, gitleaks in pre-commit and CI, and OIDC instead of keys in the pipeline.
Related articles
- Kubernetes in production – Helm, namespaces and RBAC, NetworkPolicy, PDB, autoscaling, observability and GitOps
A cluster that works in a demo and a cluster you can trust with Friday-night sales are separated by a dozen decisions. We package the dumpling-shop API as a Helm chart, isolate teams with…
- IAM and least privilege on AWS – roles, policies, conditions, SCPs/RCPs, Access Analyzer and OIDC for GitHub Actions
We clean up permissions in the pierogi shop's AWS account – from "everyone has AdministratorAccess" to least privilege. Identities and roles instead of users, policy evaluation logic, ECS task and…
- A DevSecOps pipeline in GitHub Actions – threat modeling, SAST (Semgrep, CodeQL), SCA (npm audit, OSV), CycloneDX SBOMs, Trivy, DAST and dependency updates
We build a GitHub Actions pipeline that checks the pierogi store's security on every pull request – secrets (gitleaks), static analysis (Semgrep with custom rules, CodeQL), dependencies (npm audit,…
Around the topic
- The Twelve-Factor App article · web · The Twelve-Factor App
- Episode 99. SHHH! It’s a secret! (Storing API Keys / Passwords / tokens!) podcast · apple-podcasts · Java Pub House
- He Who Controls the Source podcast · apple-podcasts · Fallthrough
- #42 The Twelve-Factor App podcast · apple-podcasts · DevEnv - O programowaniu bez kaca
- Ditch User Secrets: Use Secrets Store in Development video · youtube · Zoran on C#
- 139: Claude Code’s Secrets Are Out podcast · apple-podcasts · Front-End Fire