You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 3e677c9
Browse filesBrowse the repository at this point in the historyBrowse files
fix(media,git): tenant-bound Blossom server-domain; no publish on denied push
Two pre-merge blockers found by the PR #1321 merge-gate exercise, both
multi-tenant correctness bugs under the confirmed "many tenant-hosts per
relay" topology.
Media — non-primary tenant upload (conformance row 52):
The Blossom `server`-tag check validated against a single process-global
`server_domain` derived from RELAY_URL, so only the primary host accepted
stock-CLI (`buzz upload file`) uploads; every other tenant 401'd with
`server mismatch`. Validate instead against the per-request bound tenant
host (`TenantContext::host()`), normalized through the shared
`normalize_host` rule so a `server` tag and the bound host agree across
case, trailing dot, default ports, and an optional URL scheme/path. The
upload extractor now binds the tenant before auth verification (binding
only reads the Host header, so the pre-body auth-rejection guarantee is
preserved). Removes the now-dead `MediaConfig.server_domain` field, its
RELAY_URL derivation, its three config tests, and the dead
`BUZZ_MEDIA_SERVER_DOMAIN` env line in the Helm chart.
Git — denied push published a 30618:
`run_git_at` swallowed git's non-zero exit, so `finalize_push` ran the CAS
publish and emitted a relay-signed kind:30618 ref-state event even when the
pre-receive hook declined — falsely attributing the ref state to the denied
pusher and breaking "rejected push -> no published state". Carry the
receive-pack exit status on `PackOutput.ok` and short-circuit `finalize_push`
on a non-zero exit: skip the CAS publish and the derived 30618, returning
git's in-band rejection verbatim so the client still prints the decline.
Adds a regression unit test for the normalized tenant-host server-tag match.
Co-authored-by: Tyler Longwell <[email protected]>
Signed-off-by: Tyler Longwell <[email protected]>
0 commit comments