Skip to content

Fix CodeQL ReDoS and log-injection alerts - #6

Merged
bahriy-dev merged 1 commit into
mainfrom
fix/codeql-alerts
Nov 12, 2026
Merged

bahriy-dev merged 1 commit into
mainfrom
fix/codeql-alerts

Conversation

@bahriy-dev

@bahriy-dev bahriy-dev commented Nov 12, 2026 •

Copy link
Copy Markdown
Owner
  • bearerToken matches \S+ instead of .+ after \s+, so a header like Bearer followed by thousands of spaces no longer backtracks polynomially (tokens never contain whitespace).
  • The optional request log JSON-encodes the URL so control characters cannot forge log lines.

27/27 tests pass locally.

- `bearerToken` matches `\S+` instead of `.+` after `\s+`, so a header like `Bearer` followed by thousands of spaces no longer backtracks polynomially (tokens never contain whitespace).
- The optional request log JSON-encodes the URL so control characters cannot forge log lines.

27/27 tests pass locally.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-12T18:42:40.763457Z 7c123f1 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@bahriy-dev
bahriy-dev merged commit 27db50c into main Nov 12, 2026
4 checks passed
@bahriy-dev
bahriy-dev deleted the fix/codeql-alerts branch November 12, 2026 18:49
bahriy-dev added a commit that referenced this pull request Nov 12, 2026
- `bearerToken` matches `\S+` instead of `.+` after `\s+`, so a header
like `Bearer` followed by thousands of spaces no longer backtracks
polynomially (tokens never contain whitespace).
- The optional request log JSON-encodes the URL so control characters
cannot forge log lines.

27/27 tests pass locally.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Bahri Yilmaz <mail_adresin@example.com>
bahriy-dev added a commit that referenced this pull request Nov 12, 2026
- `bearerToken` matches `\S+` instead of `.+` after `\s+`, so a header
like `Bearer` followed by thousands of spaces no longer backtracks
polynomially (tokens never contain whitespace).
- The optional request log JSON-encodes the URL so control characters
cannot forge log lines.

27/27 tests pass locally.


Co-authored-by: Bahri Yilmaz <mail_adresin@example.com>
bahriy-dev added a commit that referenced this pull request Nov 13, 2026
- `bearerToken` matches `\S+` instead of `.+` after `\s+`, so a header
like `Bearer` followed by thousands of spaces no longer backtracks
polynomially (tokens never contain whitespace).
- The optional request log JSON-encodes the URL so control characters
cannot forge log lines.

27/27 tests pass locally.


Co-authored-by: Bahri Yilmaz <mail_adresin@example.com>
bahriy-dev added a commit that referenced this pull request Nov 13, 2026
- `bearerToken` matches `\S+` instead of `.+` after `\s+`, so a header
like `Bearer` followed by thousands of spaces no longer backtracks
polynomially (tokens never contain whitespace).
- The optional request log JSON-encodes the URL so control characters
cannot forge log lines.

27/27 tests pass locally.


Co-authored-by: Bahri Yilmaz <mail_adresin@example.com>
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