Skip to content

change-password writes a private key to disk on locked machines - #10

Open
dipeshbabu wants to merge 3 commits into
subconscious-systems:mainfrom
dipeshbabu:fix/password-retention
Open

dipeshbabu wants to merge 3 commits into
subconscious-systems:mainfrom
dipeshbabu:fix/password-retention

Conversation

@dipeshbabu

Copy link
Copy Markdown

Changing an encryption password uses local?.privateKey ?? pair.privateKey, so a locked machine or one with no local key silently starts remembering the plaintext private key. A different cached key can also be retained under the new public key.

Preserve the locked or remembered state, and retain only the matching verified key. Tests cover no local key, locked, remembered, and mismatched cached keys and verify decryption using the new password.

Validation: frozen-lockfile dependencies, typecheck, full tests, npm build, and bundled CLI version/help smoke checks. Ubuntu/Windows Node 20/22 CI passed before PR creation on this exact head commit (cb53fa1): https://github.com/dipeshbabu/vibi-cli/actions/runs/37263012167

This branch includes the CI foundation from #2; merging that PR first removes the common CI changes from this diff.

Closes #9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

change-password writes a private key to disk on locked machines

1 participant