mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-03-01 11:19:52 +03:00
[PR #2886] [MERGED] redirect to admin login page when forward fails #3145
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/dani-garcia/vaultwarden/pull/2886
Author: @stefan0xC
Created: 11/2/2022
Status: ✅ Merged
Merged: 12/2/2022
Merged by: @dani-garcia
Base:
main← Head:forward-to-admin-login📝 Commits (2)
fa7dbedredirect to admin login page when forward fails0aa33a2don't use param for passing the redirect info📊 Changes
5 files changed (+57 additions, -53 deletions)
View changed files
📝
src/api/admin.rs(+44 -51)📝
src/api/mod.rs(+1 -0)📝
src/main.rs(+1 -0)📝
src/static/templates/admin/diagnostics.hbs(+7 -1)📝
src/static/templates/admin/login.hbs(+4 -1)📄 Description
Currently, if the admin guard fails the user will get a 404 page instead of being forwarded to the login page.
This change addresses issues like #2880 and #2883 by implementing a default forward catcher for all admin pages so this comment is correct:
f60a6929a9/src/api/admin.rs (L656)🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.