credential-inventory: run the rules over sabotage fixtures too #21
No reviewers
Labels
No labels
blocked
bug
decision
duplicate
enhancement
handoff
help wanted
invalid
landed?
question
ready-to-merge
stale
wontfix
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
allod/secrets!21
Loading…
Reference in a new issue
No description provided.
Delete branch "agent/inventory-sabotage-fixture"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The credential inventory check now proves its own file-presence rules on every run: it evaluates the same rules over two built-in fixtures, one that must pass and one that must fail, and refuses if either comes out wrong. For the repository's real data nothing changes: the same rules, the same messages, the same pass. The one mechanical difference is that "does the ciphertext exist" is now answered while evaluating rather than in the build step, which is what lets a fixture answer it from a table. What proves it: the checks pass on this branch; inverting the rule in a copy makes the fixture assertion fail; and a copy with a committed ciphertext beside a pending entry fails with the same message as before. If it is wrong, revert; the previous check is one commit back.
Closes allod/secrets#20. The rule under test landed in allod/secrets#19; this is the standing witness that pass's manual sabotage lacked.
Risk
R1. The rules and messages are unchanged; the refactor moves them into a function and adds assertions that only ever read fixture data. The worst credible failure is a fixture assertion that is wrong in a way the real data also is, which the inverted-rule run rules out for both file rules.
Validation
nix flake checkon this branch: all checks passed.pendingrequires the file present): fails withcredential-inventory: fixture with the right files present was refused..agebeside apendingentry): fails withcredential-inventory: secrets/sabotage-pending.age exists but sabotage-pending is pending; land it with 'allod secret create sabotage-pending' or set rotation_state to active.