1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-19 09:43:23 +00:00

[PM-25458] Add error handling stubs & logging for critical decrypt paths (#16284)

* Add error handling stubs for critical decrypt paths

* Fix collection name decrypt

* Update docs

* address feedback

---------

Co-authored-by: Jake Fink <jfink@bitwarden.com>
This commit is contained in:
Bernd Schoolmann
2025-09-09 23:19:00 +09:00
committed by GitHub
parent 15619c6265
commit 7985487d5b
7 changed files with 73 additions and 16 deletions

View File

@@ -50,7 +50,14 @@ export class Folder extends Domain {
const folderView = new FolderView();
folderView.id = this.id;
folderView.revisionDate = this.revisionDate;
folderView.name = await encryptService.decryptString(this.name, key);
try {
folderView.name = await encryptService.decryptString(this.name, key);
} catch (e) {
// Note: This should be replaced by the owning team with appropriate, domain-specific behavior.
// eslint-disable-next-line no-console
console.error("[Folder] Error decrypting folder", e);
throw e;
}
return folderView;
}