A secret mv between vaults asks for the passphrase while holding the state directory lock #189

Open
opened 2026-10-15 07:32:21 +02:00 by clawbot · 0 comments
Collaborator

secret mv from one vault to another unlocks the source vault, and the destination vault where it needs to, while holding the state directory lock, so when the passphrase is asked for at the terminal every other command that changes anything waits silently until it is answered. #152 fixed the same thing for init, vault create, unlocker add and the forced add, import and generate secret (#188), and left this command out because that issue did not list it.

Where: moveSecretCrossVault in internal/cli/secrets.go.

Correct behaviour: as for the commands in #152, ask for what is needed and unlock the vaults before taking the lock, and check again under the lock what may have changed meanwhile.

Definition of done

  • A move between vaults asks nothing while holding the lock.
  • A regression test, on the in-memory filesystem, holds the lock and shows the unlock is reached while it is held; it fails before the fix.

Plan: as above, following the pattern #188 uses.

Model: opus-5-5

`secret mv` from one vault to another unlocks the source vault, and the destination vault where it needs to, while holding the state directory lock, so when the passphrase is asked for at the terminal every other command that changes anything waits silently until it is answered. https://git.eeqj.de/sneak/secret/issues/152 fixed the same thing for `init`, `vault create`, `unlocker add` and the forced `add`, `import` and `generate secret` (https://git.eeqj.de/sneak/secret/pulls/188), and left this command out because that issue did not list it. Where: `moveSecretCrossVault` in `internal/cli/secrets.go`. Correct behaviour: as for the commands in https://git.eeqj.de/sneak/secret/issues/152, ask for what is needed and unlock the vaults before taking the lock, and check again under the lock what may have changed meanwhile. **Definition of done** - A move between vaults asks nothing while holding the lock. - A regression test, on the in-memory filesystem, holds the lock and shows the unlock is reached while it is held; it fails before the fix. Plan: as above, following the pattern https://git.eeqj.de/sneak/secret/pulls/188 uses. Model: opus-5-5
clawbot added this to the 1.0.0 milestone 2026-10-15 07:32:21 +02:00
clawbot self-assigned this 2026-10-15 07:32:21 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/secret#189