Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/git/vole.git

Write over SSH with a registered key:

git clone ssh://git@0.0.0.0:2222/vole.git

A free and open-source forge that lives in your Git repo.

Close the approval-forgery hole: check every write, not just additions

362932289cfbecbca4f9937def07b21671bc1aee · Keenan Nemetz · 17d ago · parent 1eeca4e6

Close the approval-forgery hole: check every write, not just additions

The check that an approval is written by the principal it names used
`--diff-filter=A`, so it only looked at newly added files. An approval that already
existed could simply be edited: approve commit A, then rewrite approvals/<me>.json
to name commit B and land B with the approver's name on it. A test now demonstrates
that exact forgery before the fix and refuses it after.

The check is now driven by the change status of every path: any non-deletion on
`approvals/<name>.json` requires the actor to be `<name>`, and the first push (no
old commit to diff, so every approval in the tree is new) is checked the same way.
Deletion is limited to the owner, because removing someone else's approval forges
nothing but erases their statement; an admin may still do it, and that is written to
the audit log rather than happening silently.

Renames land in the same net: without rename detection a move appears as an add,
which the check sees, and the destination path is what the check reads.

Also worth recording what the enforcement actually rests on, since the file name is
the only name that carries authority: the SSH handshake resolves the presented key
to a user through data/trusted_keys/<user>.keys, that mapping is one-to-one (a key
already owned by another user is refused at add time and fatal at load), and the
resolved name reaches the hook as VOLE_ACTOR, which the client cannot set because
the exec surface is a two-entry whitelist. `author` fields in meta.json remain
display-only and decide nothing.

The remaining limitation is honest: this is enforcement at push time, not proof at
read time. A clone shows that an approval file exists, not that the server saw its
owner write it. Signed attestations in Phase 7 are what would make it verifiable
offline.

docs/roadmap.md +7−1

@@ -201,6 +201,11 @@ requests/<ulid>/approvals/<principal>.json base + head + created
201 201 too, at the CLI and again in validation.
202 202 - **View**: list and detail pages, current versus stale approvals, and the file list the
203 203 request would change.
204 - **Limitation, stated plainly**: ownership is enforced at push time, not verifiable at
205 read time. Someone holding a clone can see that `approvals/keenan.json` exists but not
206 prove the server saw keenan write it; that rests on `data/audit.log` and on the gate
207 having refused forgeries. Publishing signed attestations (Phase 7) is what would make
208 it verifiable offline.
204 209
205 210 Deferred to later phases:
206 211
@@ -354,7 +359,8 @@ Filled in as phases land. Append; don't rewrite.
354 359 | 2026-10-22 | Issues and requests share `refs/heads/vole`; linear history, no merges | One ref, one push, atomic cross-cutting edits; entities are separate files so a re-apply never conflicts |
355 360 | 2026-10-22 | Force-push to metadata is admin-only and audited | Redaction is a real need, but it must never be silent |
356 361 | 2026-10-22 | Approvals name a commit and a branch; the merge is a push | A branch-moving head makes "approve once" meaningless, and a push needs no new write surface |
357 | 2026-10-22 | Only the named principal may add an approval file | A filename is not authentication; the hook compares it to the SSH identity |
362 | 2026-10-22 | Only the named principal may write their own approval file | A filename is not authentication; the hook compares it to the SSH identity resolved at handshake |
363 | 2026-10-22 | Approval ownership checks cover modify/rename, not just add | A file that already exists can be edited to name a different commit; `--diff-filter=A` alone is bypassable |
358 364 | 2026-10-22 | CLI accepts options after arguments, as git does | Refusing them is a local dialect; `git commit -m x path` is the shape people type |
359 365
360 366 ## Open questions