Open redirect to another domain after login with next query #6781

Closed
opened 2025-12-29 19:45:21 +01:00 by adam · 0 comments
Owner

Originally created by @pellepelle3 on GitHub (Aug 8, 2022).

Originally assigned to: @jeremystretch on GitHub.

NetBox version

v3.2.7

Python version

3.9

Steps to Reproduce

On login the query string next can redirect to another domain with //www.google.com
/login/?next={path}
/login/?next=/home
/login/?next=//www.google.com

Expected Behavior

Only redirect to a Path of the current domain.
/login/?next=/home (success)
/login/?next=//www.google.com (should fail and redirect to home)

Observed Behavior

/login/?next=/home (success)
/login/?next=//www.google.com (success)

Originally created by @pellepelle3 on GitHub (Aug 8, 2022). Originally assigned to: @jeremystretch on GitHub. ### NetBox version v3.2.7 ### Python version 3.9 ### Steps to Reproduce On login the query string next can redirect to another domain with //www.google.com /login/?next={path} /login/?next=/home /login/?next=//www.google.com ### Expected Behavior Only redirect to a Path of the current domain. /login/?next=/home (success) /login/?next=//www.google.com (should fail and redirect to home) ### Observed Behavior /login/?next=/home (success) /login/?next=//www.google.com (success)
adam added the type: bugstatus: accepted labels 2025-12-29 19:45:21 +01:00
adam closed this issue 2025-12-29 19:45:21 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#6781