Skip to content

Document fail-closed rejection of empty permission route segments - #462

Merged
smiggleworth merged 8 commits into
developfrom
fix/permission-empty-segment-docs
Oct 11, 2026
Merged

smiggleworth merged 8 commits into
developfrom
fix/permission-empty-segment-docs

Conversation

@smiggleworth

@smiggleworth smiggleworth commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

Documents the existing permission parser contract: empty route path segments invalidate a grant, and one invalid grant in the selected permission source rejects that whole claim. Authentication does not keep the other grants or fall back to a lower-priority source. Unused lower-priority sources are not parsed.

Client/Auth0 guidance describes refused CONNECT authentication; MCP OAuth guidance describes invalid fitz_permissions provisioning as 403 insufficient_scope. Explicit malformed path examples avoid confusion with the scheme separator.

A regression mixes valid grants with kv://#read and a valid lower-priority scope, then requires normalization to fail. There are no production code changes.

Validation

  • Preparation passed 38 claims and 5 OAuth tests.
  • RED: bypassing the parser's empty-segment rejection made the whole-claim regression accept the malformed grant; restoring it passed.
  • Preparation format, diff and full locked/all-target/all-feature pedantic Clippy passed; compiled worktree paths and the new regression were audited.
  • Independent preparation review found the docs consistent with source and selected-source behavior.
  • Final candidate bb7491a is based on merged develop c241d45. Its four-file +47/-2 patch and blobs match reviewed preparation; merged UI is preserved, with no unmerged Refresh dirty admin projections before bounded admin snapshots #464 changes.
  • Fresh 38 claims and 5 OAuth tests passed. Full locked workspace passed 2,835 tests across 49 parent targets (7 ignored; unit 2,151 passed, 3 ignored). Format, diff and full locked/all-target/all-feature pedantic Clippy passed.
  • Independent final review is clean; MCP malformed-grant HTTP behavior is source-verified, without claiming a new runtime test.
  • Fresh exact-head CI passed backend, frontend and both native AMD64/ARM64 container jobs. CodeQL passed Rust, JavaScript/TypeScript and Actions analyses.
  • Stream run 38159000765 attempt 1 passed both complete 32-workload default-sampling campaigns, all eight original budgets in each campaign and all four unchanged controls. Independent timing recomputation and artifact provenance audit are clean. All three benchmark executables are byte-identical across phases; both full source-mode timing campaigns still ran (228 captures).
  • Immutable Stream artifact 11710574729 ZIP SHA256: 29025f8492696a131f5205902f09bda4a2e77f062c94d8fa2b81edf0a1732ac1, matching the GitHub digest. The audit checks fresh recorded Rust inputs/build artifacts and the original budgets; three embedded Markdown resources are Git-blob verified, without claiming workflow-recorded build-time hashes.

AI assistance: Codex clarified documentation and independently reviewed existing behavior.

Fixes #430

#372 made any permission route with an empty path segment (for example
kv://#read, a trailing slash, or //) invalid, and one invalid grant fails
the whole permission claim and with it token authentication. That is the
intended fail-closed behaviour, but neither the grammar rule nor the
failure mode was documented.

Document both in the client permission spec, the Auth0 troubleshooting
guide, and the MCP OAuth provider guide, and pin whole-claim rejection
(with no fallback to a lower-priority source) in a claims test.

@smiggleworth smiggleworth left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adversarial source review of 9f40c8b. Reviewed fail-closed permission normalization and source precedence; docs match authentication path. Integration with the latest develop and fresh hosted checks remain required before merge.

@smiggleworth
smiggleworth merged commit 2919201 into develop Oct 11, 2026
10 checks passed
@smiggleworth
smiggleworth deleted the fix/permission-empty-segment-docs branch October 11, 2026 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document empty permission route segments failing the whole claim

1 participant