diff options
| author | dev <dev@example> | 2026-11-13 20:33:51 +0000 |
|---|---|---|
| committer | dev <dev@example> | 2026-11-13 20:34:17 +0000 |
| commit | 1fd64267f678b8c6d17b2bcae702d577df1fc9e4 (patch) | |
| tree | 01a7d8a235c8e78c80c511dbee8cf738f7646053 /src/glob.c | |
| parent | f87a792743227ea06cfa1580f8d30a618b4d1a04 (diff) | |
| download | access-control-1fd64267f678b8c6d17b2bcae702d577df1fc9e4.tar.gz access-control-1fd64267f678b8c6d17b2bcae702d577df1fc9e4.zip | |
A refusal names the level held on the ref in question
"carol has force on team; refs/heads/main needs force", said while refusing
carol a force push to main, is a sentence nobody can act on: her force is on
refs/heads/feature/*, and the message reported the strongest level she holds
somewhere in the repository rather than the one she holds on the ref that was
refused. scope() now records both, and the refusal uses the level that covers
the ref, with a separate sentence for the case where nothing covers it at all -
"a rule for team but nothing on this ref" is a different problem from "not
enough for this ref", and the person pushing cannot tell them apart without
reading the file the way the matcher does.
Also: a policy that could not be opened is remembered (unreadable), so
validate reports "every push is denied until it is mounted" instead of
announcing that an empty policy is in force, and /etc/passwd is split by its
seven fields rather than eight - the old loop marked the colons as the fields
and so never found the git account at all, which meant a login shell for git
passed validation.
Both were found by driving the binary the way a receive hook is driven; that
suite is in a later commit of this series.
Diffstat (limited to 'src/glob.c')
0 files changed, 0 insertions, 0 deletions
