Repository navigation
Prepare MCP acquisition checks and bound delegated token expiry - #53
antoinetoussaint-byte merged 3 commits into
Conversation
|
Merging this on the owner's instruction, having reviewed the diff. Recording what the review established, because the PR body is careful to say this is not the acceptance proof and that remains true. It grants no new authority, and that is structural rather than a matter of care. A client delegation sets The expiry change is a strict tightening.
Verified on the merged tree ( Not verified, and #52 stays open for it: nothing here has been exercised against a running edge. The first MCP 401 still carries no OAuth discovery, and DCR, the consent step, the code exchange and refresh are unwired, so no external MCP client can yet acquire a Work Context. The remaining order is on #52, along with the owner's three decisions. One non-blocking finding for whoever continues: in |
Refs #52. Draft: acquisition is still unavailable to an external MCP client; this PR must not close the issue or be treated as its acceptance proof.
A capability issued shortly before a delegation ends currently receives another local MaxTTL (15 minutes). This change caps the signed capability expiry at the delegation end, rechecks that bound after signing, and adds the assertion to the shared conformance suite. Core’s existing 30-second verifier tolerance and already-issued tokens are unchanged.
The independent protocol work is in
libraries/authority-core/go/oauthwire: protected-resource and authorization-server metadata from explicitly supplied public URLs, the initial 401 challenge value, S256 PKCE checks, exact resource comparison, and expiry reporting. These are stateless helpers with no production caller yet. They do not create a client registry, code/token store, sign-in path, grant resolver or minter.README.mddocuments the changed signed-expiry behavior.docs/mcp-acquisition.mdrecords the reuse audit, source-linked owner questions, scope/lifetime/refresh rules, and the pending acceptance recipe.Decisions and implementation still required
Delegaterequires an installed composed module; delegatedIssuerequires its attested workload and binding. An OAuth client ID alone cannot exercise that arm. Accounts already has an OAuth flow, but its code redemption mints Accounts sessions through its own transactional business/store path; host-owner reconciliation is still required.After those decisions: connect discovery and authorization endpoints to shared host code/storage and existing
SessionService/Delegate/Issue, implement edge admission and rotating refresh, and run a real URL-only MCP client through sign-in and all five tools, with cross-solution refusal. No new issues or tickets were filed; the remaining work stays in this PR and #52.Validation
Passed locally:
GOWORK=off go test -race -count=1 ./...andgo vet ./..., plus the signing-race regression after it was added../pkg/business/issuer ./plugins/authority ./plugins/registry_test. This runs core’s Work Context conformance kit and the shared authority conformance suite through the local adapter.The signed-expiry regression was observed failing before the fix (a default-TTL capability outlasted a delegation with 30 seconds remaining by 870 seconds).
Not proven: Accounts provider parity, an HTTP OAuth flow, a live composed MCP client, the five tool answers through acquired credentials, or cross-solution refusal at the real edge.
oauthwireunit tests do not establish any of these.