Repository navigation
bench: present the account access token instead of exchanging for a jurisdiction token - #16
Merged
Merged
Conversation
…urisdiction token entire-core no longer issues jurisdiction tokens (ADR 20260729, entirehq/entiredb#4313). entiredb authorizes each push live on the account access token's subject, so the subject token ForgeMark already holds is the credential. Delete the RFC 8693 exchange and its refresh machinery; -token-url, -jurisdiction and -client-id stay as the Entire path selector so existing invocations keep working. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The account access token goes to every node, so an unvalidated X-Entire-Replicas header could redirect it to an arbitrary host. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Entire answers info/refs via the ALB with a 307 to a hosting replica, so refusing every redirect broke setup against the cluster entry URL. The probe now follows one hop, only to a node in the pinned X-Entire-Replicas set, with its own credential. Pushes still refuse redirects. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 5e54d50c1fc4
The preflight ran before discovery and counted only warmup+duration, so discovery, agent setup, the barrier and between-level cleanup could burn the token past expiry. Check after discovery, then again at each window for every level not yet started. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 5670e87ece59
Stripping the first label treated 127.0.0.1 as under 0.0.1, admitting 10.0.0.1, and tenant.github.io as under github.io. Use the public suffix list's eTLD+1 instead; IPs and bare names like localhost match only themselves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: df13dc9bb713
The expiry check read exp from any JWT-shaped secret, so a generic forge credential could be refused on semantics that are Entire's alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 45b8dea16c2c
Discovery errors quote server-controlled replica and Location URLs, so a server reflecting the credential could land it in the GUI, SSE and saved results; scrub every form of it at the endpoint boundary. Match the redirect by hostname and effective port so an explicit :443 is the same origin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: d4029c3b2c49
net/http reads proxy env once per process, so any earlier test that sent a request through newHTTPClient pinned an empty proxy config and failed TestNewHTTPClientUsesHTTPSProxy. Check the transport uses http.ProxyFromEnvironment instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: d345c84469b6
A session level whose window ends exactly at exp still runs its ref deletes afterwards, which would authenticate past expiry and leak refs. Reserve the 30s delete timeout per session level, plus 30s for clock skew. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 1bab49136deb
eTLD+1 alone widened node.cluster.customer.example.com to every host under example.com. Admit the entry host's parent domain, but never wider than its registrable domain. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: f9eab10d4158
A token refused after discovery, or a failed discovery, returned without closing the probe's idle connection. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 1266a01fad12
aws-us-east-2.entire.io admitted https://entire.io, a different service. Admit the entry host and siblings under its parent only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: c1665769b243
Contributor
Author
Live smoke test at
|
| strategy | c | ok | ops/s | p50 ms | p95 ms | errors |
|---|---|---|---|---|---|---|
| push | 1 | 65 | 6.5 | 149 | 158 | 0 |
| push | 2 | 127 | 12.7 | 150 | 200 | 0 |
| clone | 1 | 49 | 4.9 | 200 | 201 | 0 |
| clone | 2 | 96 | 9.6 | 205 | 210 | 0 |
- Direct-to-node run (
-remote https://cobar.aws-ap-southeast-2.entire.io) gave the same numbers, so the redirect hop costs nothing measurable. - stderr and stdout of every run scanned for the raw token: absent. Relevant because the ALB 307 embeds the caller's credential in
Location(server-side, tracked in COR-1992, present since May 2026, not a regression). go test ./...green on this tip.
bench: pin replicas to the registrable domain
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://entire.io/gh/entireio/forgemark/trails/5
Why
entire-core stops issuing jurisdiction tokens in https://github.com/entirehq/entiredb/pull/4313 (ADR 20260729). ForgeMark's Entire path still exchanged the subject token for one, so every Entire run would fail with
invalid_targetonce that deploys.What
-token-file/ACCESS_TOKENis the account access token; entiredb authorizes each push live on it, so it is presented as-is. The RFC 8693 exchange, its refresh goroutine and thesingleflightdependency are gone.-token-url,-jurisdictionand-client-idare still accepted: their presence selects the Entire path, so existing invocations (infra bootstrap,compare-local.sh, the GUI suggest endpoint) keep working. None of them is dialed.Note: the run is now bounded by the subject token's own lifetime (45m for a federated service-account session, 8h for a login). A sweep whose remaining levels outlast the token's
expis refused after discovery and again before each measured window. Gate findings added replica pinning (scheme, parent domain, port, bare origin, case-folded). Discovery follows Entire's ALB 307 one hop, only to a pinned replica, with its own credential; pushes and cleanup refuse redirects.Verification
go build ./...,go vet ./...,go test ./...pass.🤖 Generated with Claude Code
Note
Medium Risk
Changes authentication for Entire benchmarks (credential shape and lifetime); behavior is simpler but long runs are bounded by the access token TTL instead of exchanged jurisdiction tokens.
Overview
Aligns ForgeMark’s Entire target with ADR 20260729 (entiredb no longer issues jurisdiction tokens):
-token-file/ACCESS_TOKENis now sent as HTTP basic-auth as the account access token, with live authorization on each push, instead of exchanging it via RFC 8693.The
jurisdictionCredsimplementation is removed—no OAuth POST to-token-url, no refresh goroutine, nosingleflight—andsetupEntiredbwiresstaticCredslike other forges.-token-url,-jurisdiction, and-client-idstill select the Entire path for backward compatibility (scripts, GUI suggest); docs and flag help note they are not dialed.golang.org/x/syncdrops from directgo.modrequires.README and server audience-validation comments are updated to match the new model; long Entire credential tests are replaced with a
staticCredsunit test.Reviewed by Cursor Bugbot for commit 109aeee. Configure here.