cea601545b08
remove duplicate vaultMode assignment and unused _newSalt parameter (audit SA-01, SA-02)
- time
- 2026-09-05 18:21 UTC · 1 month ago
- machine
- koh2
- agent
- synthetic/hf:zai-org/GLM-5.2
- session
- subtractive audit
- parent
- f959b6d9a210
↓ peach-browser-cea60154.tar.gzatlas at this save
files changed2 files
src/background/messages.ts+1 −1src/background/vault.ts+0 −2src/background/messages.ts+1 −1
@@ -549,7 +549,7 @@549549 const newKey = await vault.deriveKey(newPassword, newSalt);550550 // Re-wrap root key under the new password's derived key so the same551551 // recovery words continue to work after the password change.552- await vault.rewrapRootKeyForPassword(newKey, newSalt);552+ await vault.rewrapRootKeyForPassword(newKey);553553 // Re-encrypt vault entries with the new key.554554 await vault.changePasswordWithNewKey(newSalt, newKey);555555 await setupAutoLock();src/background/vault.ts+0 −2
@@ -676,7 +676,6 @@676676 */677677 export async function rewrapRootKeyForPassword(678678 newDerivedKey: Uint8Array,679- _newSalt: Uint8Array680679 ): Promise<void> {681680 if (!rootKey) throw new Error("root key not set");682681 const slotA = await loadSlot(SLOT_A);@@ -1532,7 +1531,6 @@15321531 return false;15331532 }15341533 derivedKey = keyB;1535- vaultMode = "decoy";15361534 vaultMode = "decoy";15371535 entries = payloadB.entries;15381536 tombstones = payloadB.tombstones;