Skip to content

Conversation

@varunkasyap
Copy link
Contributor

@varunkasyap varunkasyap commented Nov 20, 2025

Trac ticket number

ticket-36767

Branch description

This PR fixes a issue where HttpResponseRedirect and HttpResponsePermanentRedirect enforced a strict 2048-character limit on URLs. The limit is now increased to 16384.

Checklist

  • This PR targets the main branch.
  • The commit message is written in past tense, mentions the ticket number, and ends with a period.
  • I have added or updated relevant tests.
  • I have checked the "Has patch" ticket flag in the Trac system.
  • I have added or updated relevant docs, including release notes if applicable.
  • I have attached screenshots in both light and dark modes for any UI changes.

@varunkasyap varunkasyap marked this pull request as draft November 20, 2025 06:00
@varunkasyap varunkasyap force-pushed the ticket-36743 branch 2 times, most recently from 3d80d51 to 090533c Compare November 20, 2025 06:18
Copy link
Member

@jacobtylerwalls jacobtylerwalls left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! This will be backported to prior versions. Can you add a release note for 5.2.9.txt? A merger can then copy this to the other versions that will be backported.

@varunkasyap varunkasyap marked this pull request as ready for review November 22, 2025 06:13
@varunkasyap varunkasyap changed the title Fixed #36743 -- Increased max redirect URL length to 8192. Fixed #36743 -- Increased max redirect URL length to 16384. Nov 22, 2025
@varunkasyap varunkasyap force-pushed the ticket-36743 branch 4 times, most recently from 99c97df to 1b91137 Compare November 22, 2025 12:46
@jacobtylerwalls
Copy link
Member

Merged in #20331, thanks!

@nessita
Copy link
Contributor

nessita commented Dec 2, 2025

Merged in #20331, thanks!

I only merged the first commit, the second one would need some work still. I'm reopening on that basis, I can rebased onto main to show the pending work.

@nessita nessita reopened this Dec 2, 2025
…mit overridable.

This change allows overrides for the redirect URL max length used in
HttpResponseRedirectBase and children via an optional max_length
instance creation parameter.

Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
@nessita nessita changed the title Fixed #36743 -- Increased max redirect URL length to 16384. Fixed #36767 -- Increased max redirect URL length to 16384. Dec 2, 2025
@nessita nessita changed the title Fixed #36767 -- Increased max redirect URL length to 16384. Fixed #36767 -- Allowed max redirect URL length to be set on HttpResponseRedirect. Dec 2, 2025
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.

3 participants