Research controls
Security headers are control surfaces.
A header’s presence is one observation. A useful review follows the response route, the policy directives, and the actual question before it reaches a conclusion.
Security headers are often reduced to a list: present or absent. That inventory can be useful, but it is too thin to describe the security effect of a response. A better review asks which response a browser receives, where it came from, and what the policy actually says.
Presence is a starting point.
Seeing Content-Security-Policy, Strict-Transport-Security, or X-Content-Type-Options is useful configuration evidence. It does not, by itself, establish that an application is protected against every relevant issue.
A Content Security Policy can exist while still permitting broad script sources, unsafe execution behavior, or a legacy allowance that needs application-specific review. The precise conclusion is not a global “secure” or “insecure” label; it is an observation about a policy received on a particular response.
Review the response path.
Redirects and status-specific behavior matter. A browser may request one URL, receive a redirect, then process a different final response. Login pages, error responses, and application routes can also carry different header sets.
$ security-header-auditor https://example.test/account
request GET https://example.test/account
redirect 302 → https://example.test/login
final 200 /login
observed headers
strict-transport-security: max-age=31536000
content-security-policy: default-src 'self'; object-src 'none'
x-content-type-options: nosniff
The output above is illustrative. The review question is real: which response belongs in the report, and which route is relevant to the user’s flow? Retaining the redirect chain makes the observation more reproducible than silently treating the first response as the whole story.
Read the policy, not just the name.
Policies are configuration. Their directives are the substance of the control. A review can preserve the exact values, distinguish unknown behavior from absent behavior, and point out where manual browser or application-context inspection remains necessary.
- Record the requested URL, final URL, and response status.
- Keep an ordered redirect path when the request follows one.
- Preserve relevant header values rather than only a boolean score.
- Separate a deterministic configuration observation from an exploitability or impact claim.
Use a reportable observation matrix.
A compact record can make both the useful finding and its limit clear to the next reviewer.
| Observed | Supports | Does not establish |
|---|---|---|
| A selected header is absent from a final response. | A reproducible configuration observation for that route. | Exploitability, severity, or behavior across every route. |
| A CSP directive appears in the response. | An exact policy record suitable for targeted review. | That every feature is protected as intended. |
| A redirect reaches a different final URL. | Response context for the observed flow. | That unrelated flows share the same controls. |
Project context.
Security Header Auditor is a public Python CLI for authorized targets. It starts conservatively, records redirects, reviews selected headers, produces structured output, and documents the boundaries of its CSP checks. Its purpose is to make a narrow review repeatable—not to turn a header list into an unsupported vulnerability claim.