Set-Cookie Auditor
Parse every Set-Cookie attribute, decode values and flag missing Secure, HttpOnly, SameSite or prefix mistakes — locally.
Raw headers
Audit context
optionalNeeded to check Domain compatibility — without a host the tool cannot judge whether a Domain is too wide. Credential flags use the name heuristic sess/auth/token/sid/jwt/login and label non-credential cookies as warnings.
Audit verdicts
no inputPaste Set-Cookie headers to audit them
One header per line (or a comma-joined proxy copy). Results update as you type; nothing leaves your browser.
Examples
Missing flags on a session cookie
session=abc; Path=/FAIL: Secure missing → add Secure. FAIL: HttpOnly missing → add HttpOnly. WARN: SameSite missing → set Lax.The name heuristic treats session as credential-bearing, so the two omissions are hard failures rather than generic warnings.
__Host- prefix violation
__Host-sid=xyz; Path=/; Domain=example.com; Secure; HttpOnly; SameSite=LaxFAIL — __Host- prefix · no Domain: forbids any Domain attribute. Secure and Path=/ checks pass.6265bis requires __Host- cookies to be host-only, so even a Domain matching the current host is a violation.
Comma-joined proxy copy
a=1; Expires=Wed, 21 Oct 2035 07:28:00 GMT; Secure, b=2; HttpOnly; Path=/2 cookies: the RFC date's comma is preserved; the comma before b=2 starts a new cookie.A comma only splits when the following token looks like name=, which keeps dates and quoted values intact.
Expired cookie with an RFC 850 date
legacy=1; Expires=Wednesday, 21-Oct-2020 07:28:00 GMTFAIL — already expired; red EXPIRED badge on the card.All three accepted date formats resolve to the same instant rules, so a legacy format still gets a correct expiry verdict.
About this tool
Set-Cookie Auditor turns pasted response headers into an actionable security review. Each cookie is parsed with RFC 6265 rules — the first '=' splits the name from the value, attributes are case-insensitive, and unknown attributes are listed without judgment — then scored in a flag matrix where every row carries a PASS, WARN or FAIL label, the rule it enforces, and a one-line fix.
The checks go beyond flag presence: SameSite=None without Secure is a hard failure, __Host- and __Secure- prefixes are validated rule by rule, Max-Age takes precedence over Expires, Expires dates are parsed with the RFC 6265 §5.1.1 acceptance grammar (including two-digit years), and expired cookies, public-suffix Domains and duplicate name+scope shadowing are called out. An optional origin host makes Domain compatibility checks computable rather than guessed.
Values are inspected with clearly labeled heuristics: JWT-shaped values reveal their decoded header and claims with exp/iat as dates, printable base64 and percent-encoded values get a decoded preview, and opaque values are shown as-is. JWTs are never signature-verified. You can diff a before/after cookie set to see which flags changed during a fix, copy a corrected Set-Cookie line per card, and export the whole review as Markdown. Parsing is local and session-only — no header, token or session identifier is uploaded, stored or carried in the URL.
What this tool does not do
- Static flag analysis only: no browser is involved, so no request-behavior or third-party blocking simulation is performed.
- Expires uses the RFC 6265 §5.1.1 grammar only; exotic or locale-specific formats are reported as unparsed rather than guessed.
- Cookie-name credential detection is a documented default regex (sess|auth|token|sid|jwt|login), not a semantic understanding of your application.
- Domain compatibility needs an origin host; without one, only public-suffix rejection and scope notes are available.
- JWT/base64/percent-encoding detection is heuristic. JWTs are decoded without signature verification and decoded bytes that are not mostly printable are left unpreviewed.
- At most 500 cookies are rendered per paste; no persistence, URL state or network request is used because headers can carry live session identifiers.
How to use this tool
Paste the headers
Paste one Set-Cookie header per line, a comma-joined proxy copy, or a Cookie request header. Header-name prefixes and CRLF line endings are stripped automatically.
Confirm the mode
Auto-detection looks for known attributes, multiple lines and multiple name=value pairs. Use the Auto / Set-Cookie / Cookie header buttons to override a wrong guess.
Add the origin host
Enter the host that set the cookies so Domain compatibility can be checked. Leave it blank for a pure syntax and flag review.
Read the cards
Each card shows parsed attributes, a flag matrix with text verdicts and fixes, scope notes and a decode panel. Hover a finding to see its rule.
Fix and compare
Copy a corrected header from a card, paste the previous header set into Compare, and check which flags moved from FAIL to PASS. Export the Markdown report for a change ticket.
Use cases
App-sec review of an auth flow
Paste every Set-Cookie from login, refresh and logout responses to find missing Secure/HttpOnly, invalid SameSite=None and over-broad Domain attributes in one pass.
Debug a SameSite login regression
See the exact SameSite value and whether Secure is present, then diff before/after headers to confirm the flag actually changed after a deployment.
Verify a __Host- rollout
Check the three named prefix rules independently; a stray Domain or Path=/app is reported with the specific rule it breaks.
Sanity-check a cookie store dump
Paste a Cookie request header to inspect name=value pairs without meaningless flag warnings, or decode a JWT-shaped value to check exp without verifying signatures.
Checks and what each one enforces
| Check | Rule applied |
|---|---|
| Secure / HttpOnly | Missing on a name matching sess|auth|token|sid|jwt|login is FAIL; missing on any other name is WARN. |
| SameSite | Absent → WARN (browsers default to Lax); Strict/Lax → PASS; None + Secure → PASS; None without Secure or an unknown value → FAIL. |
| __Host- prefix | Three separate rules: Secure present, Path=/ exactly, and no Domain attribute. Expiry does not change prefix validity. |
| __Secure- prefix | Secure must be present; no other prefix-specific requirement is imposed. |
| Expires / Max-Age | RFC 1123, RFC 850 and asctime dates only; 70–99 → 19xx and 00–69 → 20xx. Max-Age wins when both exist; Max-Age ≤ 0 means immediate deletion, not a session cookie. |
| Domain / Path | Host-only vs .example.com scope note; public suffixes such as com or co.uk are FAIL; origin host compatibility is checked when supplied. |
| Name / size / duplicates | RFC token name validation, the common 4096-byte per-cookie budget, and same-name+same-scope shadowing warnings. |
The rendering cap is 500 cookies per paste; the full input count is reported and the report export covers the rendered cards.
Common mistakes
Mistake:Assuming an expired __Host- cookie is a prefix violation.
Fix:The 6265bis prefix rules are Secure, Path=/ and no Domain. Expiry is a separate check; this tool reports it as its own FAIL row.
Mistake:Treating Max-Age=0 as a session cookie.
Fix:RFC 6265 maps Max-Age ≤ 0 to immediate deletion. Session means neither Max-Age nor Expires is present — the card labels both states differently.
Mistake:Expecting any parseable date string to be honored by browsers.
Fix:Only RFC 1123, RFC 850 and asctime are in the §5.1.1 grammar. Unparseable dates are labeled WARN and treated as session cookies; no lenient Date.parse fallback is used.
Mistake:Judging whether a Domain is too wide without knowing the setting host.
Fix:Add the origin host in Audit context. Without it the tool shows scope notes and rejects public suffixes, but does not guess compatibility.
Mistake:Trusting decoded JWT claims as authenticated identity.
Fix:The decode panel is an unsigned view: header and payload are parsed for convenience, but the signature, issuer and audience are not verified.
Frequently asked questions
What does SameSite=Lax actually allow?
Lax sends the cookie on same-site requests and on top-level cross-site navigations that use a safe method such as GET, but not on cross-site subrequests like images, fetch calls or form POSTs. It is the browser default when SameSite is absent, which is why a missing attribute is reported as a warning rather than a hard failure. Use Strict when the cookie should never follow cross-site navigation, and SameSite=None; Secure only when a deliberate cross-site flow needs it.
When is __Host- required?
__Host- is not mandatory for all cookies; it is an opt-in prefix that gives you a browser-enforced guarantee that the cookie is host-only and sent only over HTTPS. 6265bis requires three things: the Secure attribute, Path=/ exactly, and no Domain attribute at all. The auditor checks each rule separately and names the violated one. A cookie that expires does not become a prefix violation — expiry is reported independently.
Why do Set-Cookie headers use commas in Expires dates?
RFC 1123 dates such as Wed, 21 Oct 2026 07:28:00 GMT and RFC 850 dates such as Wednesday, 21-Oct-26 07:28:00 GMT contain a comma by design. Because multiple Set-Cookie headers are sometimes joined onto one line by proxies, a naive comma split cuts the date in half. This tool only starts a new cookie at a comma followed by a name= token, so dates and quoted values remain intact.
Does Secure matter on localhost?
Browsers have special-case exceptions that may let a Secure cookie be set on localhost even over http, but that behavior is not portable to staging or production and does not make the flag optional in your code. Keep Secure on auth cookies and test the production-like host over HTTPS. The auditor reports the flag statically and does not simulate browser localhost exceptions.
Can two cookies have the same name?
Yes, but only when Domain and Path differ. Browsers key cookies by name+domain+path, so a later Set-Cookie with the same triple replaces the earlier cookie instead of coexisting with it. That silent overwrite is a common cause of broken logins. The auditor adds a duplicate name+scope warning to the later card so you can catch it before it reaches production.
Is my session data sent anywhere when I use this tool?
No. Parsing, decoding, diffing and Markdown export all run in your browser tab. Nothing is uploaded, stored in local storage, or placed in the URL. Decoded JWTs are unsigned views only — the signature is not checked, so treat the claims as untrusted input.
References & standards
Related tools
AES Encryption
Encrypt and decrypt text with AES-GCM and a passphrase, fully in your browser. Uses PBKDF2 key derivation and the Web Crypto API — your data and keys never leave your device.
Android Network Security Config Builder
Generate network_security_config.xml with cleartext rules, trust anchors, certificate pinning and debug-only CAs — plus the manifest snippet and file placement checklist.
Ansible Vault Encrypt/Decrypt
Encrypt secrets into $ANSIBLE_VAULT;1.1;AES256 format or decrypt vault content with its password — locally in your browser, drop-in compatible with ansible-vault.
Argon2 Hash Generator & Verifier
Generate Argon2id/2i/2d hashes with proper m/t/p parameters and verify PHC strings — reference algorithm in your browser, nothing uploaded.
AWS Signature V4 Builder
Build AWS Signature V4 headers and presigned URLs from a canonical request — signed curl, key chain and debug diff, computed locally in your browser.
Basic Auth Generator
Generate an HTTP Basic Authentication header from a username and password. Produces the Authorization header and ready-to-use curl and fetch snippets. Runs fully client-side.