feat: add current password field to password reset (#11534)

<!--
Please inform yourself about the contribution guidelines on submitting a
PR here:
https://github.com/zitadel/zitadel/blob/main/CONTRIBUTING.md#submit-a-pull-request-pr.
Take note of how PR/commit titles should be written and replace the
template texts in the sections below. Don't remove any of the sections.
It is important that the commit history clearly shows what is changed
and why.
Important: By submitting a contribution you agree to the terms from our
Licensing Policy as described here:
https://github.com/zitadel/zitadel/blob/main/LICENSING.md#community-contributions.
-->

# Which Problems Are Solved

The password change flow in Login V2 does not ask the user to confirm
their current password before setting a new one.

# How the Problems Are Solved

- Added a "Current Password" field to the change password form
- The current password is verified via a session password check before
the new password is set
- If the current password is incorrect, the user sees a clear error
message
- Removed the previous 5-minute session freshness check, which is no
longer needed since the current password is verified inline

# Additional Changes

Added translations for the new field labels and error messages across
all supported languages

# Additional Context

- Closes #11533

---------

Co-authored-by: Max Peintner <[email protected]>
This commit is contained in:
Liam Neville
2026-02-18 10:05:26 +00:00
committed by GitHub
co-authored by Max Peintner
parent 11d48edd84
commit 64065bbe3c
16 changed files with 271 additions and 104 deletions
+3
View File
@@ -109,14 +109,17 @@
"description": "تعيين كلمة المرور لحسابك",
"submit": "متابعة",
"labels": {
"currentPassword": "كلمة المرور الحالية",
"newPassword": "كلمة المرور الجديدة",
"confirmPassword": "تأكيد كلمة المرور"
},
"required": {
"currentPassword": "عليك تقديم كلمة المرور الحالية!",
"newPassword": "عليك تقديم كلمة مرور جديدة!",
"confirmPassword": "هذا الحقل مطلوب"
},
"errors": {
"currentPasswordInvalid": "كلمة المرور الحالية غير صحيحة.",
"couldNotChangePassword": "تعذر تغيير كلمة المرور",
"couldNotVerifyPassword": "تعذر التحقق من كلمة المرور",
"unknownError": "خطأ غير معروف"