vaultwarden/src
Stefan Melmuk 2c36993792
enforce 2FA policy on removal of second factor and login (#3803)
* enforce 2fa policy on removal of second factor

users should be revoked when their second factors are removed.

we want to revoke users so they don't have to be invited again and
organization admins and owners are aware that they no longer have
access.

we make an exception for non-confirmed users to speed up the invitation
process as they would have to be restored before they can accept their
invitation or be confirmed.

if email is enabled, invited users have to add a second factor before
they can accept the invitation to an organization with 2fa policy.
and if it is not enabled that check is done when confirming the user.

* use &str instead of String in log_event()

* enforce the 2fa policy on login

if a user doesn't have a second factor check if they are in an
organization that has the 2fa policy enabled to revoke their access
2024-01-01 19:41:40 +01:00
..
api enforce 2FA policy on removal of second factor and login (#3803) 2024-01-01 19:41:40 +01:00
db enforce 2FA policy on removal of second factor and login (#3803) 2024-01-01 19:41:40 +01:00
static Add Protected Actions Check (#4067) 2023-11-12 22:15:44 +01:00
auth.rs Decrease JWT Refresh/Auth token (#4163) 2023-12-13 17:49:35 +01:00
config.rs US or EU Data Region Selection (#3752) 2024-01-01 16:01:57 +01:00
crypto.rs Remove get_random_64() 2022-11-13 10:03:06 +01:00
error.rs Update crates (#4074) 2023-11-15 10:41:14 +01:00
mail.rs Add Protected Actions Check (#4067) 2023-11-12 22:15:44 +01:00
main.rs tokio::signal::unix::SignalKind::hangup().as_raw_value() insted of 1 2023-10-21 17:14:03 +02:00
ratelimit.rs Basic ratelimit for user login (including 2FA) and admin login 2021-12-22 21:48:49 +01:00
util.rs Allow customizing the featureStates (#4168) 2024-01-01 15:44:02 +01:00