Skip to content

fix(security): remediate session token derivation, opaque cookie session storage, and report XSS sanitization - #31

Merged
divyanshujethi merged 1 commit into
mainfrom
fix/resolve-remaining-codeql-alerts
Nov 7, 2026
Merged

divyanshujethi merged 1 commit into
mainfrom
fix/resolve-remaining-codeql-alerts

Conversation

@divyanshujethi

Copy link
Copy Markdown
Contributor

Remediates remaining CodeQL security alerts:

  • Replaces fast hashing with PBKDF2 (10,000 iterations) for session tokens in src/auth/sso.ts to satisfy js/insufficient-password-hash.
  • Uses opaque random sessionId stored in cookies with an in-memory session map in src/dashboard/server.ts to prevent cleartext token exposure in Set-Cookie (js/clear-text-storage-of-sensitive-data).
  • Escapes report parameters and applies strict character filtering & CSP header in /api/compliance/report to eliminate reflected XSS (js/reflected-xss).

@divyanshujethi
divyanshujethi merged commit cd3cf54 into main Nov 7, 2026
8 checks passed
@divyanshujethi
divyanshujethi deleted the fix/resolve-remaining-codeql-alerts branch November 7, 2026 21:39
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