Skip to content

Remove legacy query parameter authentication fallback #3986

Closed

Description

@coderabbitai

Background

Currently, the web server authentication handler falls back to reading auth tokens from query parameters (?auth=) as a legacy compatibility feature. This poses security risks as credentials can leak through:

  • Server access logs
  • HTTP referrer headers
  • Browser history
  • Proxy caches
  • URL sharing

Current Location

The code is in packages/serverpod/lib/src/web_server/web_server.dart around lines 102-115:

authenticationKey ??= queryParameters['auth'];

Proposed Solution

Remove the query parameter fallback and rely only on:

  • Cookie-based authentication (auth cookie)
  • Authorization headers

This will improve security by preventing credential leakage while maintaining the more secure authentication methods.

References

Requested by: @nielsenko

Activity

  1. moved this from Inbox 📫 to Next Up 🎯 in Serverpod Frameworkson Sep 29, 2025
  2. added
    area: web server
    on Sep 29, 2025
  3. moved this from Next Up 🎯 to In Progress 🔥 in Serverpod Frameworkson Sep 29, 2025
  4. moved this from In Progress 🔥 to Done 🚀 in Serverpod Frameworkson Oct 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area: web server

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions