fix: use raw encoded wire path for MSign signature verification
_verify_msign used request.url.path, which Starlette/ASGI always presents decoded (%2F -> /) regardless of what was actually sent over the wire. The client signs the encoded form (muse.core.msign.build_msign_header), so any request whose path contains a client-encoded slash produced a signature mismatch and a 401 - concretely, muse push --delete <branch> for any branch name with a '/' (task/*, feat/*, fix/* - i.e. nearly every real branch in this workspace's naming convention).
A regression test file already existed (test_request_signing_raw_path.py) fully speccing out the correct fix, but it tested a hand-copied mirror function defined inside the test file itself, never wired into the real _verify_msign - so it passed while production stayed broken. Extracted the real logic into _extract_signed_path() in request_signing.py, wired it into _verify_msign, and pointed the existing tests at the real function instead of the disconnected copy.
Verified: reproduced the exact 401 against real staging (push+delete a slash-named branch), confirmed the fix end-to-end against localhost after applying it, and ran the full wire suite (56 passed) plus the full auth suite (123 passed) with zero regressions.
Semantic Changes
4 symbols
Files Changed
~2
997 in snapshot
0 comments
muse hub commit comment sha256:7a8e762b497ce66d76329d6b188134a114a863c80215bf3c0f279fdd425de49c --body "your comment"
No comments yet. Be the first to start the discussion.