@cat-factory/worker 0.167.0 → 0.168.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -17
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/config/retention.d.ts.map +1 -1
- package/dist/infrastructure/config/retention.js +6 -0
- package/dist/infrastructure/config/retention.js.map +1 -1
- package/dist/infrastructure/container-assembly.d.ts.map +1 -1
- package/dist/infrastructure/container-assembly.js +14 -8
- package/dist/infrastructure/container-assembly.js.map +1 -1
- package/dist/infrastructure/env.d.ts +7 -0
- package/dist/infrastructure/env.d.ts.map +1 -1
- package/dist/infrastructure/env.js.map +1 -1
- package/dist/infrastructure/observability/logExport.d.ts.map +1 -1
- package/dist/infrastructure/observability/logExport.js +10 -4
- package/dist/infrastructure/observability/logExport.js.map +1 -1
- package/dist/infrastructure/observability/logSettings.d.ts +22 -0
- package/dist/infrastructure/observability/logSettings.d.ts.map +1 -0
- package/dist/infrastructure/observability/logSettings.js +42 -0
- package/dist/infrastructure/observability/logSettings.js.map +1 -0
- package/dist/infrastructure/repositories/D1AuditEventRepository.d.ts +1 -0
- package/dist/infrastructure/repositories/D1AuditEventRepository.d.ts.map +1 -1
- package/dist/infrastructure/repositories/D1AuditEventRepository.js +6 -0
- package/dist/infrastructure/repositories/D1AuditEventRepository.js.map +1 -1
- package/dist/infrastructure/repositories/D1UserRepository.d.ts +2 -0
- package/dist/infrastructure/repositories/D1UserRepository.d.ts.map +1 -1
- package/dist/infrastructure/repositories/D1UserRepository.js +26 -0
- package/dist/infrastructure/repositories/D1UserRepository.js.map +1 -1
- package/dist/infrastructure/workflows/BootstrapWorkflow.d.ts +1 -0
- package/dist/infrastructure/workflows/BootstrapWorkflow.d.ts.map +1 -1
- package/dist/infrastructure/workflows/BootstrapWorkflow.js +9 -2
- package/dist/infrastructure/workflows/BootstrapWorkflow.js.map +1 -1
- package/dist/infrastructure/workflows/EnvConfigRepairWorkflow.d.ts +1 -0
- package/dist/infrastructure/workflows/EnvConfigRepairWorkflow.d.ts.map +1 -1
- package/dist/infrastructure/workflows/EnvConfigRepairWorkflow.js +7 -2
- package/dist/infrastructure/workflows/EnvConfigRepairWorkflow.js.map +1 -1
- package/dist/infrastructure/workflows/EnvironmentTestWorkflow.d.ts +1 -0
- package/dist/infrastructure/workflows/EnvironmentTestWorkflow.d.ts.map +1 -1
- package/dist/infrastructure/workflows/EnvironmentTestWorkflow.js +7 -2
- package/dist/infrastructure/workflows/EnvironmentTestWorkflow.js.map +1 -1
- package/dist/infrastructure/workflows/ExecutionWorkflow.d.ts +1 -0
- package/dist/infrastructure/workflows/ExecutionWorkflow.d.ts.map +1 -1
- package/dist/infrastructure/workflows/ExecutionWorkflow.js +10 -2
- package/dist/infrastructure/workflows/ExecutionWorkflow.js.map +1 -1
- package/dist/infrastructure/workflows/GitHubBackfillWorkflow.d.ts.map +1 -1
- package/dist/infrastructure/workflows/GitHubBackfillWorkflow.js +11 -5
- package/dist/infrastructure/workflows/GitHubBackfillWorkflow.js.map +1 -1
- package/dist/infrastructure/workflows/logExport.d.ts +11 -0
- package/dist/infrastructure/workflows/logExport.d.ts.map +1 -0
- package/dist/infrastructure/workflows/logExport.js +110 -0
- package/dist/infrastructure/workflows/logExport.js.map +1 -0
- package/dist/infrastructure/workflows/retention.d.ts +12 -2
- package/dist/infrastructure/workflows/retention.d.ts.map +1 -1
- package/dist/infrastructure/workflows/retention.js +4 -1
- package/dist/infrastructure/workflows/retention.js.map +1 -1
- package/migrations/0084_user_session_generation.sql +22 -0
- package/package.json +18 -18
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
-- Per-user SESSION GENERATION: the one row write that revokes every bearer a person holds.
|
|
2
|
+
--
|
|
3
|
+
-- Sessions are stateless HMAC-signed tokens, so before this column there was nothing to revoke:
|
|
4
|
+
-- logout dropped the token client-side and a leaked (or offboarded) bearer stayed valid until it
|
|
5
|
+
-- expired. That is the gap enterprise SSO cannot close on its own — the whole offboarding promise
|
|
6
|
+
-- is "we disabled them in the IdP and they lost access", and re-reading the directory on sign-in
|
|
7
|
+
-- only stops a NEW session being minted, never the one they already hold.
|
|
8
|
+
--
|
|
9
|
+
-- A GENERATION rather than a token blocklist. The token carries the generation it was minted
|
|
10
|
+
-- under; verification compares that claim against this column and refuses a mismatch. Revoking
|
|
11
|
+
-- every session is therefore `session_generation + 1`, one write, with nothing to enumerate and no
|
|
12
|
+
-- second table to grow and prune. A blocklist would need a row per outstanding token, a retention
|
|
13
|
+
-- sweep of its own, and would still be unable to answer for a token it never saw minted.
|
|
14
|
+
--
|
|
15
|
+
-- DEFAULT 0 so every existing row is valid without a backfill. Note that existing TOKENS are not:
|
|
16
|
+
-- they carry no generation claim at all and are refused after this ships, which logs everyone out
|
|
17
|
+
-- once. That is the deliberate pre-1.0 internal break (CLAUDE.md → "Internals: backwards
|
|
18
|
+
-- compatibility is NOT a goal") rather than a dual-read that would leave a permanent
|
|
19
|
+
-- claim-less-means-valid hole — precisely the hole an attacker would aim at.
|
|
20
|
+
--
|
|
21
|
+
-- Mirrors the Drizzle `users.session_generation` column on the Node facade.
|
|
22
|
+
ALTER TABLE users ADD COLUMN session_generation INTEGER NOT NULL DEFAULT 0;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cat-factory/worker",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.168.0",
|
|
4
4
|
"description": "Reusable Cloudflare Worker library (Hono + D1) exposing the Agent Architecture Board core: the `createApp()` Hono factory, the default fetch/scheduled/queue handler, and the Durable Object + Workflow classes. Deployments (see deploy/backend) supply the wrangler.toml + config and re-export these.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -43,22 +43,22 @@
|
|
|
43
43
|
"pino": "^10.3.1",
|
|
44
44
|
"valibot": "^1.4.2",
|
|
45
45
|
"workers-ai-provider": "^4.0.0",
|
|
46
|
-
"@cat-factory/agents": "0.116.
|
|
47
|
-
"@cat-factory/caching": "0.
|
|
48
|
-
"@cat-factory/consensus": "0.14.
|
|
49
|
-
"@cat-factory/contracts": "0.
|
|
50
|
-
"@cat-factory/eks": "0.1.
|
|
51
|
-
"@cat-factory/gates": "0.9.
|
|
52
|
-
"@cat-factory/gitlab": "0.16.
|
|
53
|
-
"@cat-factory/
|
|
54
|
-
"@cat-factory/
|
|
55
|
-
"@cat-factory/observability-
|
|
56
|
-
"@cat-factory/
|
|
57
|
-
"@cat-factory/
|
|
58
|
-
"@cat-factory/prompt-fragments": "1.0.
|
|
59
|
-
"@cat-factory/provider-cloudflare": "0.7.
|
|
60
|
-
"@cat-factory/
|
|
61
|
-
"@cat-factory/
|
|
46
|
+
"@cat-factory/agents": "0.116.6",
|
|
47
|
+
"@cat-factory/caching": "0.17.0",
|
|
48
|
+
"@cat-factory/consensus": "0.14.43",
|
|
49
|
+
"@cat-factory/contracts": "0.261.0",
|
|
50
|
+
"@cat-factory/eks": "0.1.255",
|
|
51
|
+
"@cat-factory/gates": "0.9.23",
|
|
52
|
+
"@cat-factory/gitlab": "0.16.14",
|
|
53
|
+
"@cat-factory/integrations": "0.140.0",
|
|
54
|
+
"@cat-factory/kernel": "0.259.0",
|
|
55
|
+
"@cat-factory/observability-langfuse": "0.10.27",
|
|
56
|
+
"@cat-factory/observability-otel": "0.16.7",
|
|
57
|
+
"@cat-factory/orchestration": "0.228.0",
|
|
58
|
+
"@cat-factory/prompt-fragments": "1.0.7",
|
|
59
|
+
"@cat-factory/provider-cloudflare": "0.7.405",
|
|
60
|
+
"@cat-factory/server": "0.239.0",
|
|
61
|
+
"@cat-factory/spend": "0.15.25"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@cloudflare/vitest-pool-workers": "^0.20.1",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"typescript": "7.0.2",
|
|
67
67
|
"vitest": "^4.1.10",
|
|
68
68
|
"wrangler": "^4.118.0",
|
|
69
|
-
"@cat-factory/conformance": "0.31.
|
|
69
|
+
"@cat-factory/conformance": "0.31.19"
|
|
70
70
|
},
|
|
71
71
|
"scripts": {
|
|
72
72
|
"build": "tsc -b tsconfig.build.json",
|