diff options
author | Mathijs van Veluw <[email protected]> | 2023-11-12 22:15:44 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2023-11-12 22:15:44 +0100 |
commit | f863ffb89a0f2a0a682c67110af32c731b5b9fcb (patch) | |
tree | 81627867c69a41640985ec71c2a4464f8d197e4a /src/static | |
parent | 03c6ed2e07a187bc70c8aa348546f25594cd38bd (diff) | |
download | vaultwarden-f863ffb89a0f2a0a682c67110af32c731b5b9fcb.tar.gz vaultwarden-f863ffb89a0f2a0a682c67110af32c731b5b9fcb.zip |
Add Protected Actions Check (#4067)
Since the feature `Login with device` some actions done via the
web-vault need to be verified via an OTP instead of providing the MasterPassword.
This only happens if a user used the `Login with device` on a device
which uses either Biometrics login or PIN. These actions prevent the
athorizing device to send the MasterPasswordHash. When this happens, the
web-vault requests an OTP to be filled-in and this OTP is send to the
users email address which is the same as the email address to login.
The only way to bypass this is by logging in with the your password, in
those cases a password is requested instead of an OTP.
In case SMTP is not enabled, it will show an error message telling to
user to login using there password.
Fixes #4042
Diffstat (limited to 'src/static')
-rw-r--r-- | src/static/templates/email/protected_action.hbs | 6 | ||||
-rw-r--r-- | src/static/templates/email/protected_action.html.hbs | 16 |
2 files changed, 22 insertions, 0 deletions
diff --git a/src/static/templates/email/protected_action.hbs b/src/static/templates/email/protected_action.hbs new file mode 100644 index 00000000..98564199 --- /dev/null +++ b/src/static/templates/email/protected_action.hbs @@ -0,0 +1,6 @@ +Your Vaultwarden Verification Code +<!----------------> +Your email verification code is: {{token}} + +Use this code to complete the protected action in Vaultwarden. +{{> email/email_footer_text }} diff --git a/src/static/templates/email/protected_action.html.hbs b/src/static/templates/email/protected_action.html.hbs new file mode 100644 index 00000000..894447bc --- /dev/null +++ b/src/static/templates/email/protected_action.html.hbs @@ -0,0 +1,16 @@ +Your Vaultwarden Verification Code +<!----------------> +{{> email/email_header }} +<table width="100%" cellpadding="0" cellspacing="0" style="margin: 0; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 16px; color: #333; line-height: 25px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none;"> + <tr style="margin: 0; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 16px; color: #333; line-height: 25px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none;"> + <td class="content-block" style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 16px; color: #333; line-height: 25px; margin: 0; -webkit-font-smoothing: antialiased; padding: 0 0 10px; -webkit-text-size-adjust: none;" valign="top"> + Your email verification code is: <b>{{token}}</b> + </td> + </tr> + <tr style="margin: 0; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 16px; color: #333; line-height: 25px; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: none;"> + <td class="content-block" style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; box-sizing: border-box; font-size: 16px; color: #333; line-height: 25px; margin: 0; -webkit-font-smoothing: antialiased; padding: 0 0 10px; -webkit-text-size-adjust: none;" valign="top"> + Use this code to complete the protected action in Vaultwarden. + </td> + </tr> +</table> +{{> email/email_footer }} |