Why it matters
Set minimal headers even on JSON APIs behind TLS terminators.
Practical steps
- Threat-model sec secure headers: spoofed webhooks, leaked tokens, and confused-deputy admin actions.
- Implement set minimal headers even on JSON APIs behind TLS terminators with constant-time compares where secrets are involved.
- Never log raw tokens, signing secrets, or full payment payloads.
- Add unit tests that prove forgeries fail closed for sec secure headers.
- Document rotation and incident steps for sec secure headers in the security runbook.
Watch out for
- Copy-pasting outdated snippets for sec secure headers without re-reading current official docs.
- Shipping sec secure headers to production without a staging rehearsal and a documented rollback.