[PR #3831] [MERGED] Fix Login With Device without MasterPassword #25562

Closed
opened 2026-05-29 04:38:50 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/dani-garcia/vaultwarden/pull/3831
Author: @BlackDex
Created: 9/1/2023
Status: Merged
Merged: 9/2/2023
Merged by: @dani-garcia

Base: mainHead: fix-3819


📝 Commits (2)

  • d6e0ace Fix Login With Device without MasterPassword
  • d18b793 Merge branch 'main' into fix-3819

📊 Changes

11 files changed (+53 additions, -12 deletions)

View changed files

migrations/mysql/2023-09-01-170620_update_auth_request_table/down.sql (+0 -0)
migrations/mysql/2023-09-01-170620_update_auth_request_table/up.sql (+5 -0)
migrations/postgresql/2023-09-01-170620_update_auth_request_table/down.sql (+0 -0)
migrations/postgresql/2023-09-01-170620_update_auth_request_table/up.sql (+5 -0)
migrations/sqlite/2023-09-01-170620_update_auth_request_table/down.sql (+0 -0)
migrations/sqlite/2023-09-01-170620_update_auth_request_table/up.sql (+29 -0)
📝 src/api/core/accounts.rs (+2 -2)
📝 src/db/models/auth_request.rs (+4 -4)
📝 src/db/schemas/mysql/schema.rs (+3 -2)
📝 src/db/schemas/postgresql/schema.rs (+3 -2)
📝 src/db/schemas/sqlite/schema.rs (+2 -2)

📄 Description

It looks like either something changed in the latest v2023.8.x versions, or when using Biometrics to login, but the MasterPasswordHash is an optional value during the Approve action.

This PR makes the MasterPasswordHash an optional value which resolves this issues. Bitwarden works the same way.

I also changed the EncKey to an Option in the database since empty strings as a default value is not nice in databases, better to use null in these cases.

Fixes #3819


🔄 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/3831 **Author:** [@BlackDex](https://github.com/BlackDex) **Created:** 9/1/2023 **Status:** ✅ Merged **Merged:** 9/2/2023 **Merged by:** [@dani-garcia](https://github.com/dani-garcia) **Base:** `main` ← **Head:** `fix-3819` --- ### 📝 Commits (2) - [`d6e0ace`](https://github.com/dani-garcia/vaultwarden/commit/d6e0ace192c294d31da21984833816d8e91f5791) Fix Login With Device without MasterPassword - [`d18b793`](https://github.com/dani-garcia/vaultwarden/commit/d18b793c71542da3e8b4b80efac789ddc3bc9932) Merge branch 'main' into fix-3819 ### 📊 Changes **11 files changed** (+53 additions, -12 deletions) <details> <summary>View changed files</summary> ➕ `migrations/mysql/2023-09-01-170620_update_auth_request_table/down.sql` (+0 -0) ➕ `migrations/mysql/2023-09-01-170620_update_auth_request_table/up.sql` (+5 -0) ➕ `migrations/postgresql/2023-09-01-170620_update_auth_request_table/down.sql` (+0 -0) ➕ `migrations/postgresql/2023-09-01-170620_update_auth_request_table/up.sql` (+5 -0) ➕ `migrations/sqlite/2023-09-01-170620_update_auth_request_table/down.sql` (+0 -0) ➕ `migrations/sqlite/2023-09-01-170620_update_auth_request_table/up.sql` (+29 -0) 📝 `src/api/core/accounts.rs` (+2 -2) 📝 `src/db/models/auth_request.rs` (+4 -4) 📝 `src/db/schemas/mysql/schema.rs` (+3 -2) 📝 `src/db/schemas/postgresql/schema.rs` (+3 -2) 📝 `src/db/schemas/sqlite/schema.rs` (+2 -2) </details> ### 📄 Description It looks like either something changed in the latest v2023.8.x versions, or when using Biometrics to login, but the MasterPasswordHash is an optional value during the Approve action. This PR makes the MasterPasswordHash an optional value which resolves this issues. Bitwarden works the same way. I also changed the EncKey to an Option in the database since empty strings as a default value is not nice in databases, better to use `null` in these cases. Fixes #3819 --- <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-05-29 04:38:50 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vaultwarden#25562