Key rotate writes the new passphrase to the wrong backend
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 70/100
Research direction
Start in bin/xenv at the two cited lines (around 1916 and 2000), then read lookup_key to see the file, keychain, pass order it uses. Set up a key in keys/<env>.key and a pass entry for the same env, run key rotate, then run get. Done when rotate writes the new key to the same backend lookup_key reads from, and get succeeds afterwards.
Written by the indexing model from the issue text.
Description
Files: bin/xenv:1916, bin/xenv:2000
Repro: Store the env key in keys/.key and also have a pass entry for the same env. lookup_key returns the file. Rotate then stores the new key in pass because the pass check runs last. The next get still reads the old file and fails the MAC.
Fix: Choose the backend the way lookup_key does: file, then keychain, then pass. Stop at the first hit.
Found at 6e8d2b4 by three runs of a whole-repo review team (deploystrata/offload), then hand-checked against the code by Grok. Lines marked Reproduced were also run by Claude.
- Dominant language
- Shell
- Stars
- 8
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ahoward/xenv
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
bug
Difficulty 1/5 1-3 hours Newbie friendliness 62/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
danielmiessler/LifeOS#2567 ·
Maintainers usually reply within 9 days
-
area:docs documentation good first issue priority:medium
Difficulty 1/5 Under an hour Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
PostHog/posthog-js#5524 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
paperclipai/paperclip#18671 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day