Skip to content

fix: Cookies without HttpOnly / SameSite / Secure - #18

Open
MBK-fr wants to merge 1 commit into
masterfrom
darkmoon/fix-insecure-cookie-flags
Open

MBK-fr wants to merge 1 commit into
masterfrom
darkmoon/fix-insecure-cookie-flags

Conversation

@MBK-fr

@MBK-fr MBK-fr commented Nov 21, 2026

Copy link
Copy Markdown

Findings

Darkmoon campaign camp_20261119_c80c95bf (DVGA demo target).

Finding Severity Title Endpoint
vuln_34ddb9 low Insecure Cookie Configuration - Missing Security Flags on env Cookie / (Set-Cookie header)
vuln_20d2ae low Cookie Without HttpOnly and Secure Flags - Client-Side Cookie Access / (Set-Cookie: env=graphiql:disable; Path=/)

Fix

The env cookie is set with HttpOnly and SameSite=Strict (Secure on HTTPS or when DVGA_COOKIE_SECURE=true), and the Flask session cookie defaults are hardened the same way.

Files changed:

  • app.py
  • core/views.py

Validation intent

Manual verification that the documented exploit path no longer succeeds, plus the project's existing test suite. Changed Python files pass python3 -m py_compile.

Opened for human review; never auto-merged.


Darkmoon finding reference: vuln_34ddb9, vuln_20d2ae.

The `env` cookie is set with HttpOnly and SameSite=Strict (Secure on HTTPS or when `DVGA_COOKIE_SECURE=true`), and the Flask session cookie defaults are hardened the same way.

Findings: vuln_34ddb9, vuln_20d2ae
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant