mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-02-24 19:07:44 +03:00
[PR #4448] [MERGED] Use async verify for Yubikey #3405
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/dani-garcia/vaultwarden/pull/4448
Author: @dani-garcia
Created: 3/23/2024
Status: ✅ Merged
Merged: 3/23/2024
Merged by: @dani-garcia
Base:
main← Head:yubico-async📝 Commits (1)
f6803bfUse async verify for Yubikey📊 Changes
1 file changed (+5 additions, -12 deletions)
View changed files
📝
src/api/core/two_factor/yubikey.rs(+5 -12)📄 Description
While looking through the crates that we have that use reqwest 0.11, I discovered that the yubico crate can do async verification, so we can avoid the spawn_blocking. I've also changed the error handling a bit to properly log any returned errors.
I've tried it with my yubikeys and seems to work fine.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.