Development record
fsutil.ReadDeclaration refuses a home-scoped declaration as replaced between its vetting and its read when another abcd process of the same user atomically renames a new version into place inside the lstat-to-open window, so two abcd processes on one machine (two sessions, or a hook and a verb) can make one refuse its own ~/.abcd/config.json, rules.json or credentials index; the merge-group macOS leg of PR 744 failed TestConcurrentConnectsKeepEveryKeyAndBlock on it.
issueresolvedminoriss-2609290518278152
fsutil.ReadDeclaration refuses a home-scoped declaration as replaced between its vetting and its read when another abcd process of the same user atomically renames a new version into place inside the lstat-to-open window, so two abcd processes on one machine (two sessions, or a hook and a verb) can make one refuse its own ~/.abcd/config.json, rules.json or credentials index; the merge-group macOS leg of PR 744 failed TestConcurrentConnectsKeepEveryKeyAndBlock on it.
Grounds
- pursued: two abcd processes on one machine no longer make one refuse its own ~/.abcd/config.json when the other rewrites it; TestReadDeclarationReadsABenignReplacementAfterRevetting or TestConcurrentConnectsKeepEveryKeyAndBlock failing with ErrDeclarationSwapped would show it wrong, and TestReadDeclarationRefusesANonBenignReplacement reading a symlink, FIFO, directory, group-writable or foreign-owned replacement would show the fix weakened the guard
Frontmatter
| id | iss-2609290518278152 |
|---|---|
| type | issue |
| lifecycle | resolved |
| severity | minor |
.abcd/work/issues/resolved/iss-2609290518278152-fsutil-readdeclaration-refuses-a-home.md
open on GitHub ↗ · commit history ↗
mentions1
- iss-2609291157309818fsutil.ReadHomeDeclaration still refuses a home-scoped declaration as replaced between its vetting and its read when a concurrent abcd renames a new version into place inside the lstat-to-open window: the re-vetting fix for iss-2609290518278152 (b342b2b29) went into the path-based ReadDeclaration, and the integration merge that landed it (24e78506b) kept the descriptor-based readDeclarationIn from a07ad672f, which every home-scoped reader (layered.Load, oracle, credential, rules, statusline) goes through and which refuses a replacement on sight; so iss-2609290518278152 regressed and TestConcurrentConnectsKeepEveryKeyAndBlock failed the Linux CI leg of PR 748 with ErrDeclarationSwapped from ~/.abcd/config.json