· Engineering notes
Security headers before you tag a release
Customer questionnaires ask for HSTS, CSP, cookies and CORS. Run the Lab grade, fill a pass/fail checklist, and block the release when session cookies or Origin reflection fail - not when the UI merely looks fine.

A green UI is not a header gate
Customer security questionnaires ask for HSTS, CSP, frame protections, cookie flags and CORS behaviour. Your app can render fine in Chrome and still fail those rows. Run a header check before you call the release done - not after the first customer sends a spreadsheet.
Use the free Lab tool: Security headers & CORS check. Pair TLS with SSL/TLS check if the questionnaire covers cipher suites.
What the Lab grade means for ship / no-ship
| Band (Lab) | Ship decision | What to do |
|---|---|---|
| Strong / pass on required headers | Ship for header questionnaire rows | Attach the graded URL + date to the release notes |
| Mixed: missing non-blocking headers (e.g. Permissions-Policy gaps) | Ship with ticket | Open ticket with owner; do not claim "full OWASP secure headers" |
| Fail: no HSTS on HTTPS prod, missing frame denial on login, cookies without Secure/HttpOnly on session | Block release | Fix nginx/CDN/app middleware before tag |
| CORS reflects arbitrary Origin with credentials | Block API web clients | Fix ACAO allowlist; re-test with credentialed request |
Grades are a triage aid, not a penetration test. For API object auth, use the OWASP API checklist and the BOLA tenant-swap protocol.
Artifact: release gate checklist
Paste into the PR or release checklist. Mark each row Pass / Fail / N/A with the Lab URL used.
## Security headers gate - release X.Y
Target URL: https://app.example.com/
Lab run: https://assertwise.com/en/tools/security-headers (date: ____)
[ ] HTTPS only in prod (HTTP redirects to HTTPS)
[ ] Strict-Transport-Security present (includeSubDomains if you control all hosts)
[ ] Content-Security-Policy present (or documented interim Report-Only with owner)
[ ] Clickjacking: CSP frame-ancestors or X-Frame-Options on login/app shell
[ ] X-Content-Type-Options: nosniff
[ ] Referrer-Policy set (not unsafe-url)
[ ] Permissions-Policy disables unused powerful features
[ ] Session cookie: Secure + HttpOnly (+ SameSite as designed)
[ ] CORS: Access-Control-Allow-Origin is not * when credentials=true
[ ] CORS: Origin reflection only for an explicit allowlist
Ship headers? Yes / No / Yes-with-tickets: ____
Official references: MDN HSTS, MDN CSP, OWASP Secure Headers Project.
False greens that questionnaires still catch
- ACAO: * with credentialed XHR - browsers block it; some proxies still look "open". Prefer an explicit allowlist.
- Reflecting any Origin - looks convenient for local demos; fails enterprise review.
- HSTS only on www while apex serves HTML without it - customers test both.
- CSP Report-Only forever - fine as a temporary step; do not mark the gate Pass until enforce mode exists or the ticket says why not.
Wire it into the PR without theatre
Minimum: one curl in CI against staging that asserts HSTS and X-Content-Type-Options exist. Deeper CSP diffs belong in a human review using the Lab grade. Do not invent a 40-header linter on day one.
curl -sI https://staging.example.com/ | tr -d '\r' | tee /tmp/headers.txt
grep -qi '^strict-transport-security:' /tmp/headers.txt
grep -qi '^x-content-type-options: *nosniff' /tmp/headers.txt
When the questionnaire is the buyer, point them at API testing for authz depth - headers alone do not prove BOLA is closed.
If you want the three header/CORS gaps that would fail a customer security questionnaire called out for your stack, book a free 20-min test audit.
Related misconfigs: 10 dangerous API configs.