-
-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use safe redirect paths in admin redirects #3129
Conversation
This makes sure we only redirect internally in the /admin routing context and redirect to a given safe fallback location or the default admin route.
e97046f
to
6b064de
Compare
This makes sure all redirects we do in the admin via do_redirect_to uses a safe redirect url.
6b064de
to
7adefce
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3129 +/- ##
=======================================
Coverage 96.58% 96.58%
=======================================
Files 236 236
Lines 6347 6360 +13
=======================================
+ Hits 6130 6143 +13
Misses 217 217 ☔ View full report in Codecov by Sentry. |
💔 Some backports could not be created
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
What is this pull request for?
This makes sure all redirects we do in the admin via
do_redirect_to
uses a safe redirect url.Notable changes
Introduces
safe_redirect_path
method, that makes sure we only redirect internallyin the /admin routing context and redirect to a given safe fallback location or the
default admin route.
Checklist