1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
use uuid::Uuid;
use webauthn_rs::prelude::AuthenticationResult;
pub enum DelayedAction {
PwUpgrade(PasswordUpgrade),
UnixPwUpgrade(UnixPasswordUpgrade),
WebauthnCounterIncrement(WebauthnCounterIncrement),
BackupCodeRemoval(BackupCodeRemoval),
Oauth2ConsentGrant(Oauth2ConsentGrant),
}
pub struct PasswordUpgrade {
pub target_uuid: Uuid,
pub existing_password: String,
}
pub struct UnixPasswordUpgrade {
pub target_uuid: Uuid,
pub existing_password: String,
}
pub struct WebauthnCounterIncrement {
pub target_uuid: Uuid,
pub auth_result: AuthenticationResult,
}
pub struct BackupCodeRemoval {
pub target_uuid: Uuid,
pub code_to_remove: String,
}
pub struct Oauth2ConsentGrant {
pub target_uuid: Uuid,
pub oauth2_rs_uuid: Uuid,
pub scopes: Vec<String>,
}