mirror of
git://git.proxmox.com/git/pve-common.git
synced 2025-01-08 01:17:37 +03:00
add u2f challenge accessors to RESTEnvironment
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
34e75688f6
commit
61aca93afb
@ -217,6 +217,20 @@ sub get_user {
|
||||
die "user name not set\n";
|
||||
}
|
||||
|
||||
sub set_u2f_challenge {
|
||||
my ($self, $challenge) = @_;
|
||||
|
||||
$self->{u2f_challenge} = $challenge;
|
||||
}
|
||||
|
||||
sub get_u2f_challenge {
|
||||
my ($self, $noerr) = @_;
|
||||
|
||||
return $self->{u2f_challenge} if defined($self->{u2f_challenge}) || $noerr;
|
||||
|
||||
die "no active u2f challenge\n";
|
||||
}
|
||||
|
||||
sub is_worker {
|
||||
my ($class) = @_;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user