Skip to content

feat: drop the CORS origin allow-list - #68

Merged
Wenzel merged 1 commit into
masterfrom
feat/drop-cors-allowlist
Aug 25, 2026
Merged

feat: drop the CORS origin allow-list#68
Wenzel merged 1 commit into
masterfrom
feat/drop-cors-allowlist

Conversation

@Wenzel

@Wenzel Wenzel commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

The allow-list protected nothing. The API is public, read-only and
unauthenticated: no cookies, no Authorization header, nothing a browser could
be tricked into attaching to a cross-origin request. CORS is a browser-side
policy, so it never constrained an attacker anyway; curl and any server-side
client ignore it entirely. All it did was break the local frontend on :5173 and
every third-party tool pointed at the API.

The access control that does matter is unchanged and server-side: rate limiting
(100/min), query complexity limits, result-set caps, disabled mutations, and
restricted-branch filtering.

Removes the ALLOWED_ORIGINS env var and opens all three mounts (/graphql, /blob,
/events). Verified: preflight from four unrelated origins returns
Access-Control-Allow-Origin: *, no Access-Control-Allow-Credentials is emitted,
and a cross-origin POST returns {"data":{"branches":[]}}.

Co-Authored-By: Claude Opus 5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01FNgjQ6o613ULuMRGhLnyUU

The allow-list protected nothing. The API is public, read-only and
unauthenticated: no cookies, no Authorization header, nothing a browser could
be tricked into attaching to a cross-origin request. CORS is a browser-side
policy, so it never constrained an attacker anyway; curl and any server-side
client ignore it entirely. All it did was break the local frontend on :5173 and
every third-party tool pointed at the API.

The access control that does matter is unchanged and server-side: rate limiting
(100/min), query complexity limits, result-set caps, disabled mutations, and
restricted-branch filtering.

Removes the ALLOWED_ORIGINS env var and opens all three mounts (/graphql, /blob,
/events). Verified: preflight from four unrelated origins returns
Access-Control-Allow-Origin: *, no Access-Control-Allow-Credentials is emitted,
and a cross-origin POST returns {"data":{"branches":[]}}.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FNgjQ6o613ULuMRGhLnyUU
@Wenzel
Wenzel merged commit 5aa9265 into master Aug 25, 2026
2 checks passed
@Wenzel
Wenzel deleted the feat/drop-cors-allowlist branch August 25, 2026 01:16
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