@fuzdev/fuz_app 0.135.0 → 0.137.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/actions/CLAUDE.md +2 -2
- package/dist/actions/action_spec.d.ts +0 -48
- package/dist/actions/action_spec.d.ts.map +1 -1
- package/dist/actions/transports_ws_backend.d.ts +1 -1
- package/dist/actions/transports_ws_backend.js +1 -1
- package/dist/auth/CLAUDE.md +8 -2
- package/dist/auth/account_action_specs.d.ts +7 -0
- package/dist/auth/account_action_specs.d.ts.map +1 -1
- package/dist/auth/account_action_specs.js +12 -3
- package/dist/auth/account_schema.d.ts +1 -6
- package/dist/auth/account_schema.d.ts.map +1 -1
- package/dist/auth/account_schema.js +1 -0
- package/dist/auth/actor_search_action_specs.d.ts +1 -1
- package/dist/auth/actor_search_action_specs.d.ts.map +1 -1
- package/dist/auth/actor_search_action_specs.js +3 -6
- package/dist/auth/audit_emitter.d.ts +4 -0
- package/dist/auth/audit_emitter.d.ts.map +1 -1
- package/dist/auth/audit_emitter.js +18 -2
- package/dist/auth/cell_action_specs.d.ts +11 -1
- package/dist/auth/cell_action_specs.d.ts.map +1 -1
- package/dist/auth/cell_action_specs.js +18 -5
- package/dist/auth/cell_item_action_specs.d.ts.map +1 -1
- package/dist/auth/cell_item_action_specs.js +2 -4
- package/dist/auth/password.d.ts +2 -2
- package/dist/auth/password.d.ts.map +1 -1
- package/dist/auth/password.js +10 -12
- package/dist/auth/role_grant_offer_action_specs.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_action_specs.js +9 -9
- package/dist/auth/role_grant_offer_notifications.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_notifications.js +2 -1
- package/dist/auth/role_grant_offer_schema.d.ts +1 -1
- package/dist/auth/role_grant_offer_schema.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_schema.js +4 -7
- package/dist/auth/role_schema.d.ts.map +1 -1
- package/dist/auth/role_schema.js +5 -4
- package/dist/auth/scope_kind_schema.d.ts +10 -0
- package/dist/auth/scope_kind_schema.d.ts.map +1 -1
- package/dist/auth/scope_kind_schema.js +15 -3
- package/dist/cli/args.d.ts +21 -15
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +40 -16
- package/dist/cli/daemon.d.ts +0 -5
- package/dist/cli/daemon.d.ts.map +1 -1
- package/dist/cli/help.d.ts +45 -6
- package/dist/cli/help.d.ts.map +1 -1
- package/dist/cli/help.js +81 -4
- package/dist/env/load.d.ts +1 -1
- package/dist/env/load.js +1 -1
- package/dist/http/CLAUDE.md +1 -1
- package/dist/http/auth_shape.d.ts +0 -27
- package/dist/http/auth_shape.d.ts.map +1 -1
- package/dist/http/body_limit.d.ts +27 -14
- package/dist/http/body_limit.d.ts.map +1 -1
- package/dist/http/body_limit.js +29 -16
- package/dist/http/db_routes.d.ts.map +1 -1
- package/dist/http/db_routes.js +5 -3
- package/dist/primitive_schemas.d.ts +38 -4
- package/dist/primitive_schemas.d.ts.map +1 -1
- package/dist/primitive_schemas.js +77 -13
- package/dist/server/x_accel.d.ts +0 -1
- package/dist/server/x_accel.d.ts.map +1 -1
- package/dist/testing/CLAUDE.md +36 -19
- package/dist/testing/audit_drift_guard.d.ts +18 -5
- package/dist/testing/audit_drift_guard.d.ts.map +1 -1
- package/dist/testing/audit_drift_guard.js +24 -8
- package/dist/testing/cross_backend/action_manifest.d.ts +0 -14
- package/dist/testing/cross_backend/action_manifest.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size.d.ts +18 -5
- package/dist/testing/cross_backend/body_size.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size.js +233 -34
- package/dist/testing/cross_backend/body_size_smuggling.d.ts +0 -12
- package/dist/testing/cross_backend/body_size_smuggling.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size_smuggling.js +92 -147
- package/dist/testing/cross_backend/capabilities.d.ts +3 -24
- package/dist/testing/cross_backend/capabilities.d.ts.map +1 -1
- package/dist/testing/cross_backend/capabilities.js +1 -4
- package/dist/testing/cross_backend/cell_crud.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_crud.js +31 -2
- package/dist/testing/cross_backend/conformance_case.d.ts +3 -3
- package/dist/testing/cross_backend/credential_header_robustness.d.ts.map +1 -1
- package/dist/testing/cross_backend/credential_header_robustness.js +18 -54
- package/dist/testing/cross_backend/default_backend_configs.d.ts.map +1 -1
- package/dist/testing/cross_backend/default_backend_configs.js +2 -8
- package/dist/testing/cross_backend/testing_backdoor.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_backdoor.js +2 -0
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +5 -9
- package/dist/testing/cross_backend/testing_reset_actions.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.js +5 -0
- package/dist/testing/cross_backend/token_lifetime.d.ts.map +1 -1
- package/dist/testing/cross_backend/token_lifetime.js +34 -1
- package/dist/testing/cross_backend/ts_spine_backend_config.d.ts.map +1 -1
- package/dist/testing/cross_backend/ts_spine_backend_config.js +7 -14
- package/dist/testing/cross_backend/ws_outbound_overflow.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_outbound_overflow.js +65 -0
- package/dist/testing/schema_introspect.d.ts +24 -4
- package/dist/testing/schema_introspect.d.ts.map +1 -1
- package/dist/testing/schema_introspect.js +27 -4
- package/dist/testing/transports/raw_http.d.ts +78 -0
- package/dist/testing/transports/raw_http.d.ts.map +1 -0
- package/dist/testing/transports/raw_http.js +141 -0
- package/package.json +7 -5
- package/dist/env/resolve.d.ts +0 -163
- package/dist/env/resolve.d.ts.map +0 -1
- package/dist/env/resolve.js +0 -267
package/dist/actions/CLAUDE.md
CHANGED
|
@@ -159,13 +159,13 @@ if a consumer genuinely owns protocol actions in their typed API.
|
|
|
159
159
|
|
|
160
160
|
**Consumer tiers.** Single-source consumers (zzz) drop into the helpers
|
|
161
161
|
and accept the default `* as specs` namespace import. Multi-source
|
|
162
|
-
consumers (
|
|
162
|
+
consumers (fuz_forge, visiones — stitching local specs with
|
|
163
163
|
`all_admin_action_specs` / `all_role_grant_offer_action_specs` /
|
|
164
164
|
`all_account_action_specs` / `all_self_service_role_action_specs` from
|
|
165
165
|
fuz_app) call `create_namespace_qualifier` once, then pass the returned
|
|
166
166
|
`qualify_spec` callback to multi-source helpers.
|
|
167
167
|
|
|
168
|
-
**Tier 1** (HTTP-only
|
|
168
|
+
**Tier 1** (HTTP-only) emits a smaller surface — typically
|
|
169
169
|
`ActionMethod` + `FrontendActionsApi` + `ActionInputs` / `ActionOutputs`.
|
|
170
170
|
Never calls `generate_typed_action_event_alias` or
|
|
171
171
|
`generate_frontend_action_handlers`. **Tier 2** (`TypedActionEvent`-aware,
|
|
@@ -37,18 +37,6 @@ export declare const ActionSpec: z.ZodObject<{
|
|
|
37
37
|
frontend: "frontend";
|
|
38
38
|
backend: "backend";
|
|
39
39
|
}>;
|
|
40
|
-
/**
|
|
41
|
-
* The flat auth shape (canonical schema in `http/auth_shape.ts`).
|
|
42
|
-
* `null` for `remote_notification` and `local_call` — those don't
|
|
43
|
-
* dispatch through the request/response auth gate.
|
|
44
|
-
*
|
|
45
|
-
* See `http/auth_shape.ts` for the design rationale (orthogonal
|
|
46
|
-
* authentication / account-resolution / actor-resolution / role-and-
|
|
47
|
-
* credential authorization axes). `required_scope` is the one field an
|
|
48
|
-
* action may not set — `compile_action_registry` rejects it, since
|
|
49
|
-
* nothing on the RPC path mounts a guard from it; the dispatcher derives
|
|
50
|
-
* the same `rpc:<method>` capability from `spec.method` instead.
|
|
51
|
-
*/
|
|
52
40
|
auth: z.ZodNullable<z.ZodObject<{
|
|
53
41
|
account: z.ZodEnum<{
|
|
54
42
|
optional: "optional";
|
|
@@ -69,44 +57,8 @@ export declare const ActionSpec: z.ZodObject<{
|
|
|
69
57
|
output: z.ZodCustom<z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>, z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>>;
|
|
70
58
|
async: z.ZodBoolean;
|
|
71
59
|
description: z.ZodString;
|
|
72
|
-
/**
|
|
73
|
-
* Names the notification method this action emits as request-scoped
|
|
74
|
-
* progress. Forward-compatible handshake — transport-agnostic, does not
|
|
75
|
-
* imply a specific delivery mechanism. Registry-time validation (e.g.,
|
|
76
|
-
* ensuring the named method is a `remote_notification` spec) is a
|
|
77
|
-
* consumer-side concern.
|
|
78
|
-
*/
|
|
79
60
|
streams: z.ZodOptional<z.ZodString>;
|
|
80
|
-
/**
|
|
81
|
-
* Error reason codes this action may surface via `error.data.reason` on
|
|
82
|
-
* failure. Declarative metadata mirroring the `streams` precedent —
|
|
83
|
-
* codegen, UI form-state matching, and docs read it off the spec instead
|
|
84
|
-
* of scanning handler implementations. Reuses the same `as const` string
|
|
85
|
-
* constants the handler throws (e.g. `ERROR_ROLE_GRANT_OFFER_*`) so call sites can
|
|
86
|
-
* import either side. Optional — actions that surface only standard
|
|
87
|
-
* transport errors leave it unset.
|
|
88
|
-
*/
|
|
89
61
|
error_reasons: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
|
|
90
|
-
/**
|
|
91
|
-
* Rate limit key the RPC dispatcher consults for this action. Optional —
|
|
92
|
-
* actions without it skip the rate-limit hook entirely.
|
|
93
|
-
*
|
|
94
|
-
* - `'ip'` — keyed on the resolved client IP (`get_client_ip(c)`).
|
|
95
|
-
* - `'account'` — keyed on the post-auth account id (`request_context.account.id`).
|
|
96
|
-
* Registration-time error if paired with `auth.account !== 'required'`
|
|
97
|
-
* (no account to key on).
|
|
98
|
-
* - `'both'` — both checks run; either can block.
|
|
99
|
-
*
|
|
100
|
-
* Throttle-requests semantics — every invocation records, regardless of
|
|
101
|
-
* outcome (different from REST login's throttle-failures, which resets
|
|
102
|
-
* on success). Suits admin mutation oracles (`invite_create` account-
|
|
103
|
-
* existence probe) where the *successful* invocation is the threat.
|
|
104
|
-
*
|
|
105
|
-
* Today only `RequestResponseActionSpec` is consulted by the RPC
|
|
106
|
-
* dispatcher. The field is on the base for shape symmetry with
|
|
107
|
-
* `streams` and `error_reasons`; remote_notification / local_call
|
|
108
|
-
* dispatchers don't read it.
|
|
109
|
-
*/
|
|
110
62
|
rate_limit: z.ZodOptional<z.ZodEnum<{
|
|
111
63
|
account: "account";
|
|
112
64
|
ip: "ip";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"action_spec.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/actions/action_spec.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,UAAU;;;;EAAoE,CAAC;AAC5F,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAEpD,eAAO,MAAM,eAAe;;;;EAA0C,CAAC;AACvE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,UAAU
|
|
1
|
+
{"version":3,"file":"action_spec.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/actions/action_spec.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,UAAU;;;;EAAoE,CAAC;AAC5F,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAEpD,eAAO,MAAM,eAAe;;;;EAA0C,CAAC;AACvE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBA6DrB,CAAC;AACH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAEpD,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAIpC,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC;AAElF,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;kBAMvC,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAExF;;;GAGG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;kBAG9B,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBAI1B,CAAC;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,gHAAgH;AAChH,eAAO,MAAM,cAAc,GAAI,OAAO,OAAO,KAAG,KAAK,IAAI,eAKoB,CAAC;AAE9E,eAAO,MAAM,gBAAgB;;;;;;;;;;EAU3B,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC"}
|
|
@@ -409,7 +409,7 @@ export declare class BackendWebsocketTransport implements FilterableBroadcastTra
|
|
|
409
409
|
* registration pending admission is skipped before the predicate runs.
|
|
410
410
|
*
|
|
411
411
|
* Used by the broadcast API when a consumer supplies a subscription ACL hook
|
|
412
|
-
* (e.g.
|
|
412
|
+
* (e.g. an event that only reaches the account that owns the resource it reports).
|
|
413
413
|
* When no ACL is needed, callers should prefer `send(message)` / `#broadcast`
|
|
414
414
|
* to skip the per-connection predicate overhead.
|
|
415
415
|
*
|
|
@@ -634,7 +634,7 @@ export class BackendWebsocketTransport {
|
|
|
634
634
|
* registration pending admission is skipped before the predicate runs.
|
|
635
635
|
*
|
|
636
636
|
* Used by the broadcast API when a consumer supplies a subscription ACL hook
|
|
637
|
-
* (e.g.
|
|
637
|
+
* (e.g. an event that only reaches the account that owns the resource it reports).
|
|
638
638
|
* When no ACL is needed, callers should prefer `send(message)` / `#broadcast`
|
|
639
639
|
* to skip the per-connection predicate overhead.
|
|
640
640
|
*
|
package/dist/auth/CLAUDE.md
CHANGED
|
@@ -58,7 +58,7 @@ Convention — `*_schema.ts` is Zod-only; `*_ddl.ts` holds DDL strings.
|
|
|
58
58
|
|
|
59
59
|
- `auth/account_schema.ts` — `Account`, `Actor`, `RoleGrant`, `AuthSession`, `ApiToken` + client-safe JSON shapes. Grant predicates over wire fields: `is_role_grant_active` (not revoked, not expired) and `has_global_role(role_grants, role, now?)` (an active grant of the role with `scope_id === null` — the bare-list form of `has_scoped_role(ctx, role, null)`, used client-side by `AuthState`).
|
|
60
60
|
- `auth/role_schema.ts` — `RoleName` (lowercase letters and underscores, no leading or trailing underscore, at most `ROLE_NAME_LENGTH_MAX` = 64 characters — the grammar every `role` input and every registered role holds, twin of the Rust `is_valid_role_name`), `RoleSpec`, `ROLE_KEEPER`, `ROLE_ADMIN`, `is_builtin_role`, `create_role_schema`, `builtin_role_specs_by_name`, `role_has_grant_path`, `list_roles_with_grant_path`.
|
|
61
|
-
- `auth/scope_kind_schema.ts` — `ScopeKindName`, `create_scope_kind_schema` (open registry, no builtins).
|
|
61
|
+
- `auth/scope_kind_schema.ts` — `ScopeKindName`, `create_scope_kind_schema` (open registry, no builtins), `SCOPE_KIND_LENGTH_MAX` (64 — bounds a registered name and the `scope_kind` on `role_grant_offer_create` / `role_grant_assign`, which is copied into the row and its audit metadata).
|
|
62
62
|
- `auth/credential_type_schema.ts` — `CredentialTypeName`, `CREDENTIAL_TYPE_SESSION` / `_API_TOKEN` / `_DAEMON_TOKEN`, `create_credential_type_schema`.
|
|
63
63
|
- `auth/grant_path_schema.ts` — `GrantPathName`, `GRANT_PATH_ADMIN` / `_SELF_SERVICE` / `_SYSTEM` / `_BOOTSTRAP`, `create_grant_path_schema`.
|
|
64
64
|
- `auth/token_lifetime.ts` — the temporal axis of a minted token: `TokenLifetimeInput` (required union on `account_token_create` — `{kind:'eternal'}` or `{kind:'ttl', days}`), `token_lifetime_to_expires_at`, `TOKEN_TTL_DAYS_MAX`. No default — `expires_at IS NULL` always means "deliberately eternal".
|
|
@@ -168,6 +168,10 @@ compile until it declares its scope. Both revocation listeners
|
|
|
168
168
|
and `audit_unknown_event_type_failures` are process-wide, fail-open
|
|
169
169
|
(write the row anyway). Independent in implementation; under the factory
|
|
170
170
|
they track the same config. Sample via `get_*`; `reset_*` are test-only.
|
|
171
|
+
Another counter lives with the emitter (`auth/audit_emitter.ts`,
|
|
172
|
+
`get_audit_write_failures` / `reset_audit_write_failures`): rows the bound
|
|
173
|
+
emitter's pool write failed to insert. That write is fail-open too — logged,
|
|
174
|
+
counted, the request proceeds — so the count is how a lost row is seen.
|
|
171
175
|
|
|
172
176
|
### Routes
|
|
173
177
|
|
|
@@ -239,6 +243,8 @@ consumer's `validate_data` pass-through callback on `CellActionDeps`.
|
|
|
239
243
|
`visibility` / `path`), the write-once capability/identity axis; a stray
|
|
240
244
|
`kind` inside `data` is rejected fail-loud (`ERROR_CELL_KIND_IN_DATA`).
|
|
241
245
|
- `auth/cell_action_specs.ts` — `CellVisibility` enum, `CellPath` brand,
|
|
246
|
+
`CELL_KIND_LENGTH_MAX` (64 — the wire `kind` on `cell_create` and the
|
|
247
|
+
`cell_list` filter; the tag is copied into the cell's audit rows),
|
|
242
248
|
`CellJson`, the generic verb specs (`cell_create / get / update /
|
|
243
249
|
delete / list / clone / moderate`), error reasons, and `all_cell_action_specs`
|
|
244
250
|
(spreads in the grant / field / item / audit registries so codegen + UI
|
|
@@ -770,7 +776,7 @@ Options: `roles?: RoleSchemaResult` (drives admin-grant-path lookup),
|
|
|
770
776
|
- `account_session_list_action_spec` — read; input `z.void()`; output `{sessions}`.
|
|
771
777
|
- `account_session_revoke_action_spec` — mutation; input `{session_id}`; output `{ok, revoked}`.
|
|
772
778
|
- `account_session_revoke_all_action_spec` — mutation; input `z.void()`; output `{ok, count}`.
|
|
773
|
-
- `account_token_create_action_spec` — mutation; input `{name?, scope, lifetime}` (both `scope` and `lifetime` required — default-deny at mint on both axes); output `{ok, token, id, name, expires_at}`.
|
|
779
|
+
- `account_token_create_action_spec` — mutation; input `{name?, scope, lifetime}` (both `scope` and `lifetime` required — default-deny at mint on both axes; `name` at most `API_TOKEN_NAME_LENGTH_MAX` = 255 characters, since it is copied into the audit row); output `{ok, token, id, name, expires_at}`.
|
|
774
780
|
- `account_token_list_action_spec` — read; input `z.void()`; output `{tokens}`.
|
|
775
781
|
- `account_token_revoke_action_spec` — mutation; input `{token_id}`; output `{ok, revoked}`.
|
|
776
782
|
|
|
@@ -45,6 +45,13 @@ export declare const SessionRevokeAllOutput: z.ZodObject<{
|
|
|
45
45
|
count: z.ZodNumber;
|
|
46
46
|
}, z.core.$strict>;
|
|
47
47
|
export type SessionRevokeAllOutput = z.infer<typeof SessionRevokeAllOutput>;
|
|
48
|
+
/**
|
|
49
|
+
* Maximum length of an API token's `name`, in UTF-16 code units (what
|
|
50
|
+
* `String.length` measures; enforced by `bounded_string`). The name is copied into the
|
|
51
|
+
* `token_create` audit row, so it is bounded where it enters. Same value as
|
|
52
|
+
* the Rust spine's `API_TOKEN_NAME_LENGTH_MAX`.
|
|
53
|
+
*/
|
|
54
|
+
export declare const API_TOKEN_NAME_LENGTH_MAX = 255;
|
|
48
55
|
/**
|
|
49
56
|
* Input for `account_token_create`.
|
|
50
57
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/account_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"account_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/account_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AAW3E,6EAA6E;AAC7E,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAEtD,uDAAuD;AACvD,eAAO,MAAM,gBAAgB,WAAW,CAAC;AACzC,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE,yCAAyC;AACzC,eAAO,MAAM,iBAAiB;;;;;;;kBAE5B,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,2EAA2E;AAC3E,eAAO,MAAM,kBAAkB;;kBAE7B,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEpE,iFAAiF;AACjF,eAAO,MAAM,mBAAmB;;;kBAG9B,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,6DAA6D;AAC7D,eAAO,MAAM,qBAAqB,W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,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;CAUR,CAAC;AAKtC,eAAO,MAAM,kCAAkC;;;;;;;;;;;;;;;;;;;CAUV,CAAC;AAGtC,eAAO,MAAM,sCAAsC;;;;;;;;;;;;;;;;;CAUd,CAAC;AAEtC;;;;;;;;;GASG;AACH,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWR,CAAC;AAEtC,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;;;CAUN,CAAC;AAGtC,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;CAUR,CAAC;AAEtC;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,EAAE,KAAK,CAAC,yBAAyB,CAQrE,CAAC"}
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* @module
|
|
9
9
|
*/
|
|
10
10
|
import { z } from 'zod';
|
|
11
|
+
import { bounded_string } from '../primitive_schemas.js';
|
|
11
12
|
import { TokenScopeInput } from './token_scope.js';
|
|
12
13
|
import { TokenLifetimeInput } from './token_lifetime.js';
|
|
13
14
|
import { AuthSessionJson, ClientApiTokenJson, SessionAccountJson, SessionId } from './account_schema.js';
|
|
@@ -37,6 +38,13 @@ export const SessionRevokeAllOutput = z.strictObject({
|
|
|
37
38
|
ok: z.literal(true),
|
|
38
39
|
count: z.number()
|
|
39
40
|
});
|
|
41
|
+
/**
|
|
42
|
+
* Maximum length of an API token's `name`, in UTF-16 code units (what
|
|
43
|
+
* `String.length` measures; enforced by `bounded_string`). The name is copied into the
|
|
44
|
+
* `token_create` audit row, so it is bounded where it enters. Same value as
|
|
45
|
+
* the Rust spine's `API_TOKEN_NAME_LENGTH_MAX`.
|
|
46
|
+
*/
|
|
47
|
+
export const API_TOKEN_NAME_LENGTH_MAX = 255;
|
|
40
48
|
/**
|
|
41
49
|
* Input for `account_token_create`.
|
|
42
50
|
*
|
|
@@ -52,10 +60,11 @@ export const SessionRevokeAllOutput = z.strictObject({
|
|
|
52
60
|
* "deliberately eternal" (see `auth/token_lifetime.ts`).
|
|
53
61
|
*/
|
|
54
62
|
export const TokenCreateInput = z.strictObject({
|
|
55
|
-
name:
|
|
56
|
-
.string()
|
|
63
|
+
name: bounded_string({ max: API_TOKEN_NAME_LENGTH_MAX })
|
|
57
64
|
.default('CLI token')
|
|
58
|
-
.meta({
|
|
65
|
+
.meta({
|
|
66
|
+
description: `Human-friendly label; shown in the token list. At most ${API_TOKEN_NAME_LENGTH_MAX} characters.`
|
|
67
|
+
}),
|
|
59
68
|
scope: TokenScopeInput.meta({
|
|
60
69
|
description: "What the token may do. `{kind:'full'}` for full account authority, or " +
|
|
61
70
|
"`{kind:'methods',methods:[…]}` to narrow it to named RPC methods — a " +
|
|
@@ -70,6 +70,7 @@ export interface Actor {
|
|
|
70
70
|
* revoked role_grant. Bounds the value at the schema layer so both the admin
|
|
71
71
|
* input (when the route surfaces a reason field) and the revokee-facing
|
|
72
72
|
* `role_grant_revoke` WS notification validate against the same ceiling.
|
|
73
|
+
* Counted in UTF-16 code units.
|
|
73
74
|
*/
|
|
74
75
|
export declare const ROLE_GRANT_REVOKED_REASON_LENGTH_MAX = 500;
|
|
75
76
|
/** Role grant — time-bounded, revocable grant of a role to an actor. */
|
|
@@ -209,12 +210,6 @@ export declare const ClientApiTokenJson: z.ZodObject<{
|
|
|
209
210
|
last_used_at: z.ZodNullable<z.ZodString>;
|
|
210
211
|
last_used_ip: z.ZodNullable<z.ZodString>;
|
|
211
212
|
created_at: z.ZodString;
|
|
212
|
-
/**
|
|
213
|
-
* Human-readable scope label (`full` / `full (grandfathered)` /
|
|
214
|
-
* `N methods`). A label rather than the document so the list stays a display
|
|
215
|
-
* surface — nothing authorizes off this, and a grandfathered token reads
|
|
216
|
-
* differently from a deliberately-full one.
|
|
217
|
-
*/
|
|
218
213
|
scope: z.ZodString;
|
|
219
214
|
}, z.core.$strict>;
|
|
220
215
|
export type ClientApiTokenJson = z.infer<typeof ClientApiTok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BAAkB,GAAI,SAAS,OAAO,KAAG,cAMpD,CAAC;AAEH;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,GAAI,SAAS,OAAO,KAAG,gBAKlD,CAAC"}
|
|
@@ -26,6 +26,7 @@ import { is_iso8601_seconds_live } from '../timestamp.js';
|
|
|
26
26
|
* revoked role_grant. Bounds the value at the schema layer so both the admin
|
|
27
27
|
* input (when the route surfaces a reason field) and the revokee-facing
|
|
28
28
|
* `role_grant_revoke` WS notification validate against the same ceiling.
|
|
29
|
+
* Counted in UTF-16 code units.
|
|
29
30
|
*/
|
|
30
31
|
export const ROLE_GRANT_REVOKED_REASON_LENGTH_MAX = 500;
|
|
31
32
|
/**
|
|
@@ -81,7 +81,7 @@ export declare const ACTOR_SEARCH_LIMIT_MAX = 50;
|
|
|
81
81
|
/** Default `limit` when the caller omits it. */
|
|
82
82
|
export declare const ACTOR_SEARCH_LIMIT_DEFAULT = 20;
|
|
83
83
|
/**
|
|
84
|
-
* Hard cap on the query string length. Long inputs offer no extra search
|
|
84
|
+
* Hard cap on the query string length, in UTF-16 code units. Long inputs offer no extra search
|
|
85
85
|
* value once they exceed `actor.name` realistic lengths, and a low cap
|
|
86
86
|
* keeps the per-request work bounded for pathological inputs.
|
|
87
87
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"actor_search_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/actor_search_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwEG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"actor_search_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/actor_search_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwEG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,KAAK,CAAC;AAEzC,gDAAgD;AAChD,eAAO,MAAM,0BAA0B,KAAK,CAAC;AAE7C;;;;GAIG;AACH,eAAO,MAAM,6BAA6B,KAAK,CAAC;AAEhD;;;;GAIG;AACH,eAAO,MAAM,iCAAiC,EAAG,6BAAsC,CAAC;AAExF,eAAO,MAAM,gBAAgB;;;;kBAqB3B,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE,eAAO,MAAM,iBAAiB;;;;;;kBAE5B,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;CAcA,CAAC;AAEtC;;;;GAIG;AACH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;EAAsC,CAAC"}
|
|
@@ -73,6 +73,7 @@
|
|
|
73
73
|
*/
|
|
74
74
|
import { z } from 'zod';
|
|
75
75
|
import { Uuid } from '@fuzdev/fuz_util/id.ts';
|
|
76
|
+
import { bounded_string } from '../primitive_schemas.js';
|
|
76
77
|
import { ActorLookupEntryJson } from './actor_lookup_action_specs.js';
|
|
77
78
|
/**
|
|
78
79
|
* Hard cap on the number of rows returned per call. Bounds the search-result
|
|
@@ -83,7 +84,7 @@ export const ACTOR_SEARCH_LIMIT_MAX = 50;
|
|
|
83
84
|
/** Default `limit` when the caller omits it. */
|
|
84
85
|
export const ACTOR_SEARCH_LIMIT_DEFAULT = 20;
|
|
85
86
|
/**
|
|
86
|
-
* Hard cap on the query string length. Long inputs offer no extra search
|
|
87
|
+
* Hard cap on the query string length, in UTF-16 code units. Long inputs offer no extra search
|
|
87
88
|
* value once they exceed `actor.name` realistic lengths, and a low cap
|
|
88
89
|
* keeps the per-request work bounded for pathological inputs.
|
|
89
90
|
*/
|
|
@@ -95,11 +96,7 @@ export const ACTOR_SEARCH_QUERY_LENGTH_MAX = 50;
|
|
|
95
96
|
*/
|
|
96
97
|
export const ERROR_ACTOR_SEARCH_SCOPE_REQUIRED = 'actor_search_scope_required';
|
|
97
98
|
export const ActorSearchInput = z.strictObject({
|
|
98
|
-
query:
|
|
99
|
-
.string()
|
|
100
|
-
.min(1)
|
|
101
|
-
.max(ACTOR_SEARCH_QUERY_LENGTH_MAX)
|
|
102
|
-
.meta({
|
|
99
|
+
query: bounded_string({ min: 1, max: ACTOR_SEARCH_QUERY_LENGTH_MAX }).meta({
|
|
103
100
|
description: `Case-insensitive prefix match against \`actor.name\`. Length 1–${ACTOR_SEARCH_QUERY_LENGTH_MAX}.`
|
|
104
101
|
}),
|
|
105
102
|
scope_ids: z.array(Uuid).optional().meta({
|
|
@@ -285,6 +285,10 @@ export interface CreateAuditEmitterOptions {
|
|
|
285
285
|
*/
|
|
286
286
|
track_inflight?: boolean;
|
|
287
287
|
}
|
|
288
|
+
/** Number of audit rows an emitter failed to write since process start. */
|
|
289
|
+
export declare const get_audit_write_failures: () => number;
|
|
290
|
+
/** Reset the counter — for tests only. */
|
|
291
|
+
export declare const reset_audit_write_failures: () => void;
|
|
288
292
|
/**
|
|
289
293
|
* Build a bound `AuditEmitter`. Typical caller is the consumer's
|
|
290
294
|
* `audit_factory` callback on `CreateAppBackendOptions` —
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"audit_emitter.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/audit_emitter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACtD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;;;;;OAOG;IACH,cAAc,CAAC,EAAE,aAAa,CAAC;IAC/B;;;;;;;;;OASG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;CACzB;AAYD,2EAA2E;AAC3E,eAAO,MAAM,wBAAwB,QAAO,MAA8B,CAAC;AAE3E,0CAA0C;AAC1C,eAAO,MAAM,0BAA0B,QAAO,IAE7C,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,oBAAoB,GAAI,SAAS,yBAAyB,KAAG,YA8IzE,CAAC"}
|
|
@@ -68,6 +68,21 @@
|
|
|
68
68
|
import { emit_after_commit } from '../http/pending_effects.js';
|
|
69
69
|
import { query_audit_log } from './audit_log_queries.js';
|
|
70
70
|
import { builtin_audit_log_config } from './audit_log_schema.js';
|
|
71
|
+
/**
|
|
72
|
+
* Process-wide counter for audit rows an emitter failed to write. The pool
|
|
73
|
+
* write behind `emit` / `emit_pool` / `emit_role_grant_target` is fail-open —
|
|
74
|
+
* a refused `INSERT` is logged and the request proceeds — so a lost row is
|
|
75
|
+
* otherwise visible only in the log. Same posture and lifetime as the drift
|
|
76
|
+
* counters in `auth/audit_log_queries.ts`: in-process, resets on restart, and
|
|
77
|
+
* asserted zero per test by `install_audit_drift_guard`.
|
|
78
|
+
*/
|
|
79
|
+
let audit_write_failures = 0;
|
|
80
|
+
/** Number of audit rows an emitter failed to write since process start. */
|
|
81
|
+
export const get_audit_write_failures = () => audit_write_failures;
|
|
82
|
+
/** Reset the counter — for tests only. */
|
|
83
|
+
export const reset_audit_write_failures = () => {
|
|
84
|
+
audit_write_failures = 0;
|
|
85
|
+
};
|
|
71
86
|
/**
|
|
72
87
|
* Build a bound `AuditEmitter`. Typical caller is the consumer's
|
|
73
88
|
* `audit_factory` callback on `CreateAppBackendOptions` —
|
|
@@ -101,13 +116,14 @@ export const create_audit_emitter = (options) => {
|
|
|
101
116
|
}
|
|
102
117
|
}
|
|
103
118
|
};
|
|
104
|
-
// The pool write. Never rejects: a failed write is logged and
|
|
105
|
-
// `null`, so there is no row to announce.
|
|
119
|
+
// The pool write. Never rejects: a failed write is logged, counted, and
|
|
120
|
+
// resolves `null`, so there is no row to announce.
|
|
106
121
|
const write = async (input) => {
|
|
107
122
|
try {
|
|
108
123
|
return await query_audit_log({ db }, input, audit_log_config);
|
|
109
124
|
}
|
|
110
125
|
catch (err) {
|
|
126
|
+
audit_write_failures++;
|
|
111
127
|
log.error('Audit log write failed:', err);
|
|
112
128
|
return null;
|
|
113
129
|
}
|
|
@@ -113,7 +113,7 @@ export declare const ERROR_CELL_LIST_SHARED_WITH_REQUIRES_AUTH: "cell_list_share
|
|
|
113
113
|
* At the spec level we only enforce that the value is a non-empty string
|
|
114
114
|
* with a sane upper bound — the cell layer is generic and doesn't impose
|
|
115
115
|
* a path grammar. App-side curation (well-known names like `/map/main`,
|
|
116
|
-
* `/site/events`) is admin-driven.
|
|
116
|
+
* `/site/events`) is admin-driven. The bound is in UTF-16 code units.
|
|
117
117
|
*/
|
|
118
118
|
export declare const CELL_PATH_LENGTH_MAX = 256;
|
|
119
119
|
/**
|
|
@@ -126,6 +126,16 @@ export declare const CELL_PATH_LENGTH_MAX = 256;
|
|
|
126
126
|
*/
|
|
127
127
|
export declare const CellPath: z.core.$ZodBranded<z.ZodString, "CellPath", "out">;
|
|
128
128
|
export type CellPath = z.infer<typeof CellPath>;
|
|
129
|
+
/**
|
|
130
|
+
* Maximum length of a cell `kind` on the wire, in UTF-16 code units (what
|
|
131
|
+
* `String.length` measures; enforced by `bounded_string`) — on `cell_create`,
|
|
132
|
+
* and on the `cell_list` filter. The cell layer imposes no grammar on `kind`; the bound
|
|
133
|
+
* is there because the tag is copied into every audit row the cell's
|
|
134
|
+
* mutations write. The same bound a cell field name carries
|
|
135
|
+
* (`CELL_FIELD_NAME_REGEX`), the cell layer's other machine-readable tag,
|
|
136
|
+
* and the same value as the Rust spine's `CELL_KIND_LENGTH_MAX`.
|
|
137
|
+
*/
|
|
138
|
+
export declare const CELL_KIND_LENGTH_MAX = 64;
|
|
129
139
|
/**
|
|
130
140
|
* Soft cap on the size of a `cell.list` request page. Larger pages chew
|
|
131
141
|
* memory both server- and client-side; combined with the visibility
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"cell_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,OAAO,EAEN,6BAA6B,EAC7B,6BAA6B,EAC7B,2BAA2B,EAE3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAEN,0BAA0B,EAC1B,6BAA6B,EAC7B,2BAA2B,EAE3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAEN,4BAA4B,EAC5B,0BAA0B,EAC1B,4BAA4B,EAC5B,0BAA0B,EAE1B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAEN,2BAA2B,EAC3B,MAAM,8BAA8B,CAAC;AAGtC;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc;;;EAAgC,CAAC;AAC5D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAO5D,OAAO,EACN,6BAA6B,EAC7B,6BAA6B,EAC7B,2BAA2B,EAC3B,CAAC;AACF,OAAO,EAAE,0BAA0B,EAAE,6BAA6B,EAAE,2BAA2B,EAAE,CAAC;AAClG,OAAO,EACN,4BAA4B,EAC5B,0BAA0B,EAC1B,4BAA4B,EAC5B,0BAA0B,EAC1B,CAAC;AACF,OAAO,EAAE,2BAA2B,EAAE,CAAC;AAIvC,uEAAuE;AACvE,eAAO,MAAM,o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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAYxB,CAAC"}
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
import { z } from 'zod';
|
|
9
9
|
import { Uuid } from '@fuzdev/fuz_util/id.ts';
|
|
10
10
|
import { FactHashSchema } from '@fuzdev/fuz_util/hash_schemas.ts';
|
|
11
|
+
import { bounded_string } from '../primitive_schemas.js';
|
|
11
12
|
import { ActingActor } from '../http/auth_shape.js';
|
|
12
13
|
import { all_cell_grant_action_specs, cell_grant_create_action_spec, cell_grant_revoke_action_spec, cell_grant_list_action_spec, GrantJson } from './cell_grant_action_specs.js';
|
|
13
14
|
import { all_cell_field_action_specs, cell_field_set_action_spec, cell_field_delete_action_spec, cell_field_list_action_spec, FieldJson } from './cell_field_action_specs.js';
|
|
@@ -120,7 +121,7 @@ export const ERROR_CELL_LIST_SHARED_WITH_REQUIRES_AUTH = 'cell_list_shared_with_
|
|
|
120
121
|
* At the spec level we only enforce that the value is a non-empty string
|
|
121
122
|
* with a sane upper bound — the cell layer is generic and doesn't impose
|
|
122
123
|
* a path grammar. App-side curation (well-known names like `/map/main`,
|
|
123
|
-
* `/site/events`) is admin-driven.
|
|
124
|
+
* `/site/events`) is admin-driven. The bound is in UTF-16 code units.
|
|
124
125
|
*/
|
|
125
126
|
export const CELL_PATH_LENGTH_MAX = 256;
|
|
126
127
|
/**
|
|
@@ -131,7 +132,17 @@ export const CELL_PATH_LENGTH_MAX = 256;
|
|
|
131
132
|
* point. Frontend callers handing a raw string to `api.cell_*` cast at the
|
|
132
133
|
* callsite (`as CellPath`) — the runtime check still runs server-side.
|
|
133
134
|
*/
|
|
134
|
-
export const CellPath =
|
|
135
|
+
export const CellPath = bounded_string({ min: 1, max: CELL_PATH_LENGTH_MAX }).brand('CellPath');
|
|
136
|
+
/**
|
|
137
|
+
* Maximum length of a cell `kind` on the wire, in UTF-16 code units (what
|
|
138
|
+
* `String.length` measures; enforced by `bounded_string`) — on `cell_create`,
|
|
139
|
+
* and on the `cell_list` filter. The cell layer imposes no grammar on `kind`; the bound
|
|
140
|
+
* is there because the tag is copied into every audit row the cell's
|
|
141
|
+
* mutations write. The same bound a cell field name carries
|
|
142
|
+
* (`CELL_FIELD_NAME_REGEX`), the cell layer's other machine-readable tag,
|
|
143
|
+
* and the same value as the Rust spine's `CELL_KIND_LENGTH_MAX`.
|
|
144
|
+
*/
|
|
145
|
+
export const CELL_KIND_LENGTH_MAX = 64;
|
|
135
146
|
/**
|
|
136
147
|
* Soft cap on the size of a `cell.list` request page. Larger pages chew
|
|
137
148
|
* memory both server- and client-side; combined with the visibility
|
|
@@ -201,8 +212,10 @@ export const CellCreateInput = z.strictObject({
|
|
|
201
212
|
data: CellData.meta({
|
|
202
213
|
description: 'Cell content. Base fields (label / summary) typed; extras loose. A `kind` key here is rejected (`ERROR_CELL_KIND_IN_DATA`) — kind is the top-level field. Per-kind shape is sub-API.'
|
|
203
214
|
}),
|
|
204
|
-
kind:
|
|
205
|
-
|
|
215
|
+
kind: bounded_string({ max: CELL_KIND_LENGTH_MAX })
|
|
216
|
+
.nullish()
|
|
217
|
+
.meta({
|
|
218
|
+
description: `Capability / identity tag, written to the top-level \`cell.kind\` column (not \`data\`). Write-once — fixed at birth, not updatable. Non-empty when present (an empty string is rejected \`ERROR_CELL_KIND_EMPTY\`) and at most ${CELL_KIND_LENGTH_MAX} characters; omit / null for a typeless cell. A creation authorizer (if mounted) gates on this.`
|
|
206
219
|
}),
|
|
207
220
|
visibility: CellVisibility.optional().meta({
|
|
208
221
|
description: "Access-control tag. Top-level column (not in `data`). Default `'private'` when omitted."
|
|
@@ -306,7 +319,7 @@ export const CellListInput = z
|
|
|
306
319
|
.max(CELL_LIST_LIMIT_MAX)
|
|
307
320
|
.optional()
|
|
308
321
|
.meta({ description: 'Batch-fetch by id. Visibility predicate still applies.' }),
|
|
309
|
-
kind:
|
|
322
|
+
kind: bounded_string({ max: CELL_KIND_LENGTH_MAX }).optional().meta({
|
|
310
323
|
description: 'Match `cell.kind = ?`. An empty string matches nothing — no cell carries an empty kind.'
|
|
311
324
|
}),
|
|
312
325
|
visibility: CellVisibility.optional().meta({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_item_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_item_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"cell_item_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_item_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAaxB,8EAA8E;AAC9E,eAAO,MAAM,6CAA6C,EACzD,yCAAkD,CAAC;AAEpD;;;;;;;;;GASG;AACH,eAAO,MAAM,8BAA8B,EAAG,0BAAmC,CAAC;AAIlF;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,4DAEF,CAAC;AAC5B,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;;;;;;;GASG;AACH,eAAO,MAAM,QAAQ;;;;;kBAKnB,CAAC;AACH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAIhD;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB;;;;;kBAO9B,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,oBAAoB;;;;;;;kBAAqC,CAAC;AACvE,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAIxE;;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;;;;;;;;;;;;;;EAK7B,CAAC"}
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
import { z } from 'zod';
|
|
13
13
|
import { Uuid } from '@fuzdev/fuz_util/id.ts';
|
|
14
14
|
import { FRACTIONAL_INDEX_LENGTH_MAX, FRACTIONAL_INDEX_REGEX } from '@fuzdev/fuz_util/fractional_index.ts';
|
|
15
|
+
import { bounded_string } from '../primitive_schemas.js';
|
|
15
16
|
import { ActingActor } from '../http/auth_shape.js';
|
|
16
17
|
// -- Error reasons ----------------------------------------------------------
|
|
17
18
|
/** Error reason — `cell_item_list` got neither `parent_id` nor `child_id`. */
|
|
@@ -36,10 +37,7 @@ export const ERROR_CELL_ITEM_POSITION_TAKEN = 'cell_item_position_taken';
|
|
|
36
37
|
* contract; the no-trailing-`'0'` invariant lives in the helper, not the
|
|
37
38
|
* wire.
|
|
38
39
|
*/
|
|
39
|
-
export const CellItemPosition =
|
|
40
|
-
.string()
|
|
41
|
-
.min(1)
|
|
42
|
-
.max(FRACTIONAL_INDEX_LENGTH_MAX)
|
|
40
|
+
export const CellItemPosition = bounded_string({ min: 1, max: FRACTIONAL_INDEX_LENGTH_MAX })
|
|
43
41
|
.regex(FRACTIONAL_INDEX_REGEX)
|
|
44
42
|
.brand('CellItemPosition');
|
|
45
43
|
/**
|
package/dist/auth/password.d.ts
CHANGED
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
* @module
|
|
8
8
|
*/
|
|
9
9
|
import { z } from 'zod';
|
|
10
|
-
/** Minimum password length (OWASP recommendation). */
|
|
10
|
+
/** Minimum password length, in UTF-16 code units (OWASP recommendation). */
|
|
11
11
|
export declare const PASSWORD_LENGTH_MIN = 12;
|
|
12
|
-
/** Maximum password length. Caps hashing cost to prevent DoS via oversized passwords. */
|
|
12
|
+
/** Maximum password length, in UTF-16 code units. Caps hashing cost to prevent DoS via oversized passwords. */
|
|
13
13
|
export declare const PASSWORD_LENGTH_MAX = 300;
|
|
14
14
|
/** Password for account creation or password change — enforces current length policy. Also usable for client-side UX validation. */
|
|
15
15
|
export declare const Password: z.ZodString;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"password.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/password.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"password.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/password.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,4EAA4E;AAC5E,eAAO,MAAM,mBAAmB,KAAK,CAAC;AAEtC,+GAA+G;AAC/G,eAAO,MAAM,mBAAmB,MAAM,CAAC;AAEvC,oIAAoI;AACpI,eAAO,MAAM,QAAQ,aAGa,CAAC;AACnC,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAEhD,iIAAiI;AACjI,eAAO,MAAM,gBAAgB,aAE3B,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;;;;;;;;;;;GAaG;AACH,MAAM,WAAW,gBAAgB;IAChC,aAAa,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IACrD,eAAe,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;IAC/E,YAAY,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;CACrD"}
|
package/dist/auth/password.js
CHANGED
|
@@ -7,19 +7,17 @@
|
|
|
7
7
|
* @module
|
|
8
8
|
*/
|
|
9
9
|
import { z } from 'zod';
|
|
10
|
-
|
|
10
|
+
import { bounded_string } from '../primitive_schemas.js';
|
|
11
|
+
/** Minimum password length, in UTF-16 code units (OWASP recommendation). */
|
|
11
12
|
export const PASSWORD_LENGTH_MIN = 12;
|
|
12
|
-
/** Maximum password length. Caps hashing cost to prevent DoS via oversized passwords. */
|
|
13
|
+
/** Maximum password length, in UTF-16 code units. Caps hashing cost to prevent DoS via oversized passwords. */
|
|
13
14
|
export const PASSWORD_LENGTH_MAX = 300;
|
|
14
15
|
/** Password for account creation or password change — enforces current length policy. Also usable for client-side UX validation. */
|
|
15
|
-
export const Password =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
.meta({ sensitivity: 'secret' });
|
|
16
|
+
export const Password = bounded_string({
|
|
17
|
+
min: PASSWORD_LENGTH_MIN,
|
|
18
|
+
max: PASSWORD_LENGTH_MAX
|
|
19
|
+
}).meta({ sensitivity: 'secret' });
|
|
20
20
|
/** Password submitted for login or verification — minimal validation for forward-compatibility if length requirements change. */
|
|
21
|
-
export const PasswordProvided =
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
.max(PASSWORD_LENGTH_MAX)
|
|
25
|
-
.meta({ sensitivity: 'secret' });
|
|
21
|
+
export const PasswordProvided = bounded_string({ min: 1, max: PASSWORD_LENGTH_MAX }).meta({
|
|
22
|
+
sensitivity: 'secret'
|
|
23
|
+
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role_grant_offer_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/role_grant_offer_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"role_grant_offer_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/role_grant_offer_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,CAAC,EAAE,MA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