Skip to content

Commit 1cc4fa2

Browse files
committed
test(dogfood): re-measure the authz census for the approval record-lock read
The record-lock route added one ledger row (80 -> 81, family `approvals`, blind spot 0) and one direct registration site in approvals-routes.ts outside registerMetadataEndpoints (rest-server.ts row 69/19/50 -> 70/19/51, register 62 -> 63, enforceAuth 115 -> 116; totals 64/69 -> 65/70). The matrix docblock's REST ledger figure moves to 81 rows / 18 families. Claude-Session: https://claude.ai/code/session_01WGufzfNhdx3xRKeaa8e7JB Co-authored-by: Claude <noreply@anthropic.com>
1 parent b33dd25 commit 1cc4fa2

2 files changed

Lines changed: 37 additions & 14 deletions

File tree

‎packages/qa/dogfood/test/authz-conformance.matrix.ts‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
// hand-curated regex table reaching 1 of 17 REST registrars and 4 of 17
2525
// dispatcher domain files.
2626
//
27-
// The population comes from `packages/rest/src/rest-route-ledger.ts` (80 rows
27+
// The population comes from `packages/rest/src/rest-route-ledger.ts` (81 rows
2828
// / 18 families) and `packages/runtime/src/route-ledger.ts` (105 rows / 23
2929
// domains) because those two are enumerated from a RUNNING server and guarded
3030
// in both directions by their own conformance tests — so a new family or
@@ -58,7 +58,9 @@
5858
// `family: packages`, which survives on the publish row. (91 → 83 rows and
5959
// 19 → 18 families later, when #20102 retired the whole `reports` family;
6060
// 81 → 80 rows, families unmoved, when #25104 retired the `/docs` viewer
61-
// page, whose `openapi` family survives on the document row.)
61+
// page, whose `openapi` family survives on the document row; 80 → 81 rows,
62+
// families unmoved, when #26361 added the approval record-lock read, whose
63+
// `approvals` family the other approval rows already carry.)
6264
// Two stale figures in
6365
// one docblock with two entirely different causes is the failure mode the pin
6466
// above ends. Widening a regex instead was refused: it rots on the next

‎packages/qa/dogfood/test/authz-probe-blind-spot.census.ts‎

Lines changed: 33 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -386,11 +386,17 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
386386
// viewer page row (`GET /api/v1/docs`) left the ledger with its route. It
387387
// carried `family: 'openapi'`, which the surviving document row still
388388
// carries, so `reachable` moves with `population` and `keys` stays 18.
389-
population: 80,
390-
reachable: 80,
389+
// [#26400] 80 / 80 / 0 -> 81 / 81 / 0: the approval record-lock read
390+
// (`GET /api/v1/approvals/records/:object/:recordId/lock`, landed in
391+
// #26361) joined the ledger with its route. It carries `family:
392+
// 'approvals'`, a family the other approval rows already carry, so
393+
// `reachable` moves with `population`, the blind spot stays 0 and `keys`
394+
// stays 18 (18 distinct families before and after, re-derived).
395+
population: 81,
396+
reachable: 81,
391397
blindSpot: 0,
392398
populationRule: 'ledger rows inside REST_ROUTE_LEDGER; reachable = rows carrying a `family` (each distinct value mints a key)',
393-
controls: { "route: '": 80, "family: '": 80, RestRouteLedgerEntry: 2 },
399+
controls: { "route: '": 81, "family: '": 81, RestRouteLedgerEntry: 2 },
394400
// [#22430] The `openapi` family is the second classified one, by the
395401
// `anonymous-deny-api-description` row; the note's 2 / 16 counts it.
396402
// [ADR-0138 E2] The `forms` family is the third, by the D2 class 1 row
@@ -401,7 +407,9 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
401407
'That guard is why this file can be a population source and a regex table cannot: a mounted route with no ' +
402408
'row here is already RED in another package, so a new family cannot be silently absent from this file, ' +
403409
'and therefore cannot be silently absent from the authz ratchet either. 18 families; 3 classified by ' +
404-
'matrix rows (metadata, openapi and forms), 15 enumerated in the shrink-only baseline. Re-measured 81 -> 80 when the ' +
410+
'matrix rows (metadata, openapi and forms), 15 enumerated in the shrink-only baseline. Re-measured 80 -> 81 when the ' +
411+
'approval record-lock read joined with its route; it carries `family: approvals`, which the other approval rows ' +
412+
'already carry. Earlier re-measured 81 -> 80 when the ' +
405413
'OpenAPI document viewer page row left with its route; it carried `family: openapi`, which the surviving document row ' +
406414
'still carries. Earlier re-measured 82 -> 81 when the permission-set ' +
407415
'overlay-discard row left with its route; it carried `family: security`, which the surviving security rows still carry. ' +
@@ -535,9 +543,9 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
535543
kinds: ['ROUTE_ENUMERATION', 'TRIPWIRE'],
536544
probes: 3,
537545
keys: 1,
538-
population: 69,
546+
population: 70,
539547
reachable: 19,
540-
blindSpot: 50,
548+
blindSpot: 51,
541549
populationRule:
542550
'route registration sites — `this.routeManager.register(` call sites, LESS the one inside ' +
543551
'`registerPerItemRoute` (the shared forwarder, not a route; its extent is bounded by the declaration\'s own ' +
@@ -952,13 +960,22 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
952960
// (`:2545`) and the two inline comments on the internal context keys in
953961
// `computeExecCtx` (`:3444`, `:3454`). `enforceAuth`'s own body gained a
954962
// comparison in lines that do not spell the term.
963+
// [#26400] 69 / 19 / 50 -> 70 / 19 / 51, and `enforceAuth` 115 -> 116: the
964+
// approval record-lock read (`GET {basePath}/approvals/records/:object/
965+
// :recordId/lock`, landed in #26361) is one new direct
966+
// `this.routeManager.register(` site (62 -> 63; 7 -> 8 in
967+
// `approvals-routes.ts`) inside `registerApprovalsEndpoints`, NOT inside
968+
// `registerMetadataEndpoints`, so it is a NEW BLIND SPOT, the same as its
969+
// seven siblings; its handler opens with `enforceAuth`, so that control
970+
// gains one. No registrar was added, so `private register*Endpoints(`
971+
// stays 16 and the registrar list stays 18.
955972
controls: {
956973
'private register*Endpoints(': 16,
957-
'this.routeManager.register(': 62,
974+
'this.routeManager.register(': 63,
958975
'registrar list length': 18,
959976
'data-action-routes.ts: this.routeManager.register(': 9,
960977
'batch-routes.ts: this.routeManager.register(': 5,
961-
'approvals-routes.ts: this.routeManager.register(': 7,
978+
'approvals-routes.ts: this.routeManager.register(': 8,
962979
'sharing-routes.ts: this.routeManager.register(': 8,
963980
'analytics-routes.ts: this.routeManager.register(': 1,
964981
'security-routes.ts: this.routeManager.register(': 6,
@@ -991,7 +1008,7 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
9911008
'registerPerItemRoute(': 8,
9921009
'const registerPerItemRoute =': 1,
9931010
'forwarder slice: this.routeManager.register(': 1,
994-
enforceAuth: 115,
1011+
enforceAuth: 116,
9951012
},
9961013
note:
9971014
'The single non-tripwire probe names ONE registrar of 16. The other 15 can never mint a key: ' +
@@ -1276,7 +1293,7 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
12761293
/**
12771294
* Entry points inside the probe table's OWN files that no mintable key can
12781295
* reach, counting only the route/handler surfaces the ratchet's completeness
1279-
* claim is about: rest-server.ts (50 static / 55 runtime), http-dispatcher.ts
1296+
* claim is about: rest-server.ts (51 static / 56 runtime), http-dispatcher.ts
12801297
* (13) and domains/mcp.ts (1).
12811298
*
12821299
* hono-plugin.ts's 6 mounts are deliberately EXCLUDED from this total and
@@ -1294,8 +1311,12 @@ export const PROBE_FILE_CENSUS: readonly ProbeFileReading[] = [
12941311
// [#25104] 65 / 70 -> 64 / 69: the retired `/docs` viewer page left
12951312
// `discovery-routes.ts` (on rest-server.ts's registrar list) as one blind-spot
12961313
// call site and one runtime mount.
1297-
export const BLIND_SPOT_TOTAL_STATIC = 64;
1298-
export const BLIND_SPOT_TOTAL_RUNTIME = 69;
1314+
// [#26400] 64 / 69 -> 65 / 70: the approval record-lock read joined
1315+
// `approvals-routes.ts` (on rest-server.ts's registrar list) as one blind-spot
1316+
// call site and one runtime mount (one ledger row, 80 -> 81: a direct
1317+
// registration, not a route factory, so static and runtime move together).
1318+
export const BLIND_SPOT_TOTAL_STATIC = 65;
1319+
export const BLIND_SPOT_TOTAL_RUNTIME = 70;
12991320

13001321
/**
13011322
* Re-measure every row above from the same sources the probes read.

0 commit comments

Comments
 (0)