Purpose: A practical, repo-ready checklist that mirrors the DevSecOps pipeline stages and their gates. Use it as your team’s working agreement.
✅ Tip: Copy this file as DEVSECOPS_CHECKLIST.md in your repo. Create the PR template below at .github/pull_request_template.md.
- Set your severity gates (e.g., block CRITICAL/HIGH), coverage target (e.g., 80% line / 70% branch), and exception SLA (≤ 30 days).
- Assign Owners for each section (platform, security, app team).
- Review quarterly and tighten gates as your signal:noise improves.
- Branch protection on main (required reviews, required status checks, no force pushes).
-
CODEOWNERS, PR & issue templates;SECURITY.mdwith report process. - Enforce signed commits (GPG or Sigstore gitsign). Enable platform secret scanning + push protection.
- CI/CD tokens least-privilege; prefer OIDC to cloud (no long-lived keys). Default tokens to read where possible.
- Choose and document scanners & policies (SAST, SCA, IaC, container, DAST). Define vuln SLAs and exception flow with expiry.
- Enable Renovate/Dependabot (app deps + base images).
- SBOM format decided (CycloneDX/SPDX) + storage/retention.
- Container registry with immutable tags + retention policy.
- Release/tagging scheme (
vX.Y.Z,sha-<12>). - Observability baseline: logs, metrics, traces, error tracking; SLOs & alerting.
- Protections & CODEOWNERS enforced across repos.
- Exceptions tracked with owner + expiry date.
-
pre-commitconfigured with formatters/linters (Black/ESLint/golangci-lint, etc.). - Secrets scanner hook (Gitleaks/truffleHog).
- Block large binaries; use Git LFS policy if needed.
- Conventional Commits (optional hook to validate).
- Formatting & lint pass.
- No secrets detected (hard fail).
- No large binaries introduced unintentionally.
- Commit messages follow convention (if enforced).
- SAST: Semgrep and/or CodeQL configured; rulepacks tuned; fail on HIGH/CRITICAL (or custom policy).
- SCA: OSV-Scanner/Dependency-Check enabled; set license allow/deny list; auto-PRs for updates.
- SBOM: Syft to generate CycloneDX/SPDX; store as artifact.
- IaC: Checkov/tfsec for Terraform; kube-linter/kubeconform/Conftest for K8s.
- Tests & Coverage: tooling chosen (Jest/Pytest/go test); thresholds set in CI.
- Container build: multi-stage; distroless/Chainguard base; non-root; drop capabilities; read-only FS;
HEALTHCHECKpresent. - Image scanning: Trivy/Grype on PR image; fail on CRITICAL/HIGH (
ignore-unfixedtrue if policy allows). - Upload SARIF to code scanning; enable PR annotations.
- SAST: no new HIGH/CRITICAL (or approved, time-boxed exception).
- SCA: no HIGH/CRITICAL; no disallowed licenses.
- IaC: no critical misconfigs (public exposure, no encryption, bad network rules, etc.).
- Unit tests pass; coverage ≥ target.
- Image is minimal & non-root; capabilities minimized; read-only FS.
- Image vulnerability scan passes policy.
- SBOM generated & attached to CI artifacts.
- Test & coverage reports; SAST/SCA/IaC SARIF; SBOM; PR image reference.
- Per-PR namespace or preview env with TTL & auto teardown.
- Minimal seeded data; no PII; safe migrations.
- Secrets via External/Sealed Secrets (no inline secrets).
- OWASP ZAP baseline config; exclude login endpoints if needed.
- Preview URL posted as PR comment/status.
- Smoke & integration tests pass against preview URL.
- DAST baseline: no MEDIUM/HIGH.
- Basic perf sanity (e.g., p95 latency within budget).
- Optional: accessibility lint passes.
- ZAP report; preview link; test logs.
- No secrets introduced.
- SAST/SCA/IaC gates pass (or approved exception with expiry).
- Tests & coverage targets met.
- Image scan passes policy.
- DAST baseline passes.
- Reviewer approvals complete.
- Rebuild image from clean context on main (avoid cache poisoning).
- Tagging: immutable digest, sha-<12>, latest, and semver on release.
- Cosign keyless signing via OIDC; signatures pushed to registry.
- Generate provenance (SLSA) + SBOM attestation; attach to image.
- Deploy-side signature verification policy (Ratify/Connaisseur/Admission).
- SBOM regenerated and stored; vulnerabilities rescanned on main image.
- Image signed; signature & provenance verifiable.
- Registry tags immutable; digest recorded in release notes.
- Build metadata archived (who/what/when).
- Signed image (by digest), SBOM, SLSA attestation, release notes.
- Separate manifests repo watched by Argo CD/Flux (cluster creds read-only).
- Admission controls: Pod Security levels; OPA/Gatekeeper (non-root, capabilities, resource limits, labels, signature verify).
- Progressive rollout: Argo Rollouts/Flagger; metrics provider (Prometheus/Datadog) + success criteria.
- Secrets: External/Sealed Secrets; KMS CMK configured; rotation policy.
- Networking: NetworkPolicies; TLS/mTLS; HSTS on ingress.
- Resources & reliability: HPA, PDBs, requests/limits, quotas per namespace.
- Pre-deploy validation: kubeconform/kubeval +
kubectl diff --server-dry-run. - Environments: staging auto; prod requires manual approval (Environment gate).
- Manifest PR references signed image digest (avoid latest).
- Policy checks pass (OPA, signature, security contexts, limits present).
- Staging healthy; promotion PR only when green.
- Canary/blue-green meets metrics; auto-rollback on SLO breach.
- Post-deploy smoke + active DAST run; results attached.
- Deployment report (rollout, metrics, DAST) + changelog linked to commits.
- Runtime detection (Falco) with rules for crypto-miners, shell spawns, namespace escapes.
- CIS/Kube hardening: kube-bench; node OS patching cadence.
- Continuous image rescans; ticketing integration for new vulns.
- License compliance based on SBOM; allow/deny; third-party notices.
- Backups for stateful services; restore drill runbooks; RPO/RTO.
- Secrets rotation schedule; certificate expiry monitors.
- Central audit logs; retention; access reviews; MFA/SSO enforced.
- Incident response runbooks; on-call & paging; postmortem template.
- Weekly: vuln triage & exception expiry review.
- Monthly: IAM/RBAC review; base image updates.
- Quarterly: backup restore drill; threat-model refresh.
- Continuous: alert tuning; SLO & error budget tracking.
- Data classification & PII inventory.
- Encryption: TLS1.2+ in transit; KMS at rest.
- DLP & PII/secret lint in repos and logs.
- Data retention & deletion workflows (per policy).
- No PII in logs; scrubbing configured in APM.
- Access to prod data gated, auditable, and time-boxed.
- Standard Makefile/tasks (
make test,make build,make scan). - Fast local dev (containers/Dev Containers).
- Flaky test quarantine process.
- CI time budget met; healthy cache hit rate; no flakey tests on main.
- All security gates (SAST/SCA/IaC/Image, DAST baseline) green or exception approved with expiry.
- Tests pass & coverage ≥ target; docs & changelog updated.
- SBOM generated; image non-root; signed; provenance generated.
- Preview link posted; reviewer approvals complete.
## Summary
Describe the change and why.
## Issue
Closes #<id>
## Type of change
- [ ] Feature
- [ ] Bug fix
- [ ] Security hardening
- [ ] CI/CD only
- [ ] Docs
## Definition of Done
- [ ] SAST/SCA/IaC passed (or exception with expiry)
- [ ] Unit/integration tests passed; coverage ≥ target
- [ ] Container image non-root & scanned; no HIGH/CRITICAL
- [ ] SBOM attached to CI artifacts
- [ ] Preview URL posted; ZAP baseline no MEDIUM/HIGH
- [ ] Reviewed by code owner(s)
## Security/Privacy Impact
Any new endpoints, scopes, secrets, or data flows? If yes, note mitigations.
## Deployment Notes
Rollout plan (canary/blue-green), migrations, feature flags, rollback steps.
## Screenshots
(if UI)