[PR #5934] [MERGED] Update webauthn-rs to 0.5.x #7328

Closed
opened 2026-03-07 21:15:17 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/dani-garcia/vaultwarden/pull/5934
Author: @zUnixorn
Created: 6/6/2025
Status: Merged
Merged: 8/8/2025
Merged by: @dani-garcia

Base: mainHead: update_webauthn_rs


📝 Commits (10+)

  • d91d74e update webauthn to 0.5
  • f2593a8 add basic migration impl
  • b4cc006 fix clippy warnings
  • a7bc501 clear up COSEKeyType::EC_OKP case
  • 82f3de2 fix TODOs
  • 2ec66ab use same timeout as in webauthn 0.3 impl
  • be39c6a fix: clippy warnings and formatting
  • 562b23f Update Cargo.toml
  • a1e78a5 Update src/api/core/two_factor/webauthn.rs
  • 7ab565a Update src/api/core/two_factor/webauthn.rs

📊 Changes

7 files changed (+346 additions, -105 deletions)

View changed files

📝 Cargo.lock (+158 -14)
📝 Cargo.toml (+6 -1)
📝 src/api/core/two_factor/webauthn.rs (+96 -72)
📝 src/api/identity.rs (+16 -8)
📝 src/db/models/two_factor.rs (+66 -9)
📝 src/error.rs (+1 -1)
📝 src/main.rs (+3 -0)

📄 Description

Hello,

since there was a discussion in #5929 about upgrading webauthn-rs first, I tried to do this in this PR.

I tested it a few times and didn't have any problems on my machine. It also converts from the old webauthn credential to the new webauthn passkey. Currently this is done by trying to deserialize into the old credential, but this could also be checked via a new field in the DB or some other way.

Since I didn't remove the U2F migration for now, I could also test if that still works in combination with the new migration. Because U2F was used a long time ago, what version could I use, that uses U2F, to create the credentials, before updating to this branch for testing the migration?


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/dani-garcia/vaultwarden/pull/5934 **Author:** [@zUnixorn](https://github.com/zUnixorn) **Created:** 6/6/2025 **Status:** ✅ Merged **Merged:** 8/8/2025 **Merged by:** [@dani-garcia](https://github.com/dani-garcia) **Base:** `main` ← **Head:** `update_webauthn_rs` --- ### 📝 Commits (10+) - [`d91d74e`](https://github.com/dani-garcia/vaultwarden/commit/d91d74eebf1362254c9e672666e073307a6e364a) update webauthn to 0.5 - [`f2593a8`](https://github.com/dani-garcia/vaultwarden/commit/f2593a87e1a84c542c8548e6cf645f816942d1e8) add basic migration impl - [`b4cc006`](https://github.com/dani-garcia/vaultwarden/commit/b4cc0069488885eb399b8e11578fb704ac928790) fix clippy warnings - [`a7bc501`](https://github.com/dani-garcia/vaultwarden/commit/a7bc5017c09805bbe516eedbff3374585a00425c) clear up `COSEKeyType::EC_OKP` case - [`82f3de2`](https://github.com/dani-garcia/vaultwarden/commit/82f3de25ac473464a02983f03d33741a30ef3f85) fix TODOs - [`2ec66ab`](https://github.com/dani-garcia/vaultwarden/commit/2ec66abb365d4bf8d7288a9684c08c56ba4f917a) use same timeout as in webauthn 0.3 impl - [`be39c6a`](https://github.com/dani-garcia/vaultwarden/commit/be39c6aab17618fe7b76c2501a16471d194fceae) fix: clippy warnings and formatting - [`562b23f`](https://github.com/dani-garcia/vaultwarden/commit/562b23f194ee558ee1cb6da09c167e728e97649b) Update Cargo.toml - [`a1e78a5`](https://github.com/dani-garcia/vaultwarden/commit/a1e78a52a339aef75770e065e639593c0c4e0f91) Update src/api/core/two_factor/webauthn.rs - [`7ab565a`](https://github.com/dani-garcia/vaultwarden/commit/7ab565a7de6cf114eb7fb6a4d0d42bde53d1738c) Update src/api/core/two_factor/webauthn.rs ### 📊 Changes **7 files changed** (+346 additions, -105 deletions) <details> <summary>View changed files</summary> 📝 `Cargo.lock` (+158 -14) 📝 `Cargo.toml` (+6 -1) 📝 `src/api/core/two_factor/webauthn.rs` (+96 -72) 📝 `src/api/identity.rs` (+16 -8) 📝 `src/db/models/two_factor.rs` (+66 -9) 📝 `src/error.rs` (+1 -1) 📝 `src/main.rs` (+3 -0) </details> ### 📄 Description Hello, since there was a discussion in #5929 about upgrading webauthn-rs first, I tried to do this in this PR. I tested it a few times and didn't have any problems on my machine. It also converts from the old webauthn credential to the new webauthn passkey. Currently this is done by trying to deserialize into the old credential, but this could also be checked via a new field in the DB or some other way. Since I didn't remove the U2F migration for now, I could also test if that still works in combination with the new migration. Because U2F was used a long time ago, what version could I use, that uses U2F, to create the credentials, before updating to this branch for testing the migration? --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-07 21:15:17 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vaultwarden#7328