@fuzdev/fuz_app 0.150.0 → 0.151.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/README.md +1 -1
- package/dist/actions/CLAUDE.md +324 -299
- package/dist/actions/action_bridge.d.ts +5 -86
- package/dist/actions/action_bridge.d.ts.map +1 -1
- package/dist/actions/action_bridge.js +4 -84
- package/dist/actions/action_codegen.d.ts +8 -166
- package/dist/actions/action_codegen.d.ts.map +1 -1
- package/dist/actions/action_codegen.js +19 -95
- package/dist/actions/action_dispatcher.d.ts +10 -0
- package/dist/actions/action_dispatcher.d.ts.map +1 -1
- package/dist/actions/action_dispatcher.js +9 -6
- package/dist/actions/action_event.d.ts +1 -2
- package/dist/actions/action_event.d.ts.map +1 -1
- package/dist/actions/action_event.js +7 -13
- package/dist/actions/action_event_helpers.d.ts +1 -40
- package/dist/actions/action_event_helpers.d.ts.map +1 -1
- package/dist/actions/action_event_helpers.js +1 -25
- package/dist/actions/action_rpc.d.ts +10 -215
- package/dist/actions/action_rpc.d.ts.map +1 -1
- package/dist/actions/action_rpc.js +56 -111
- package/dist/actions/action_spec.d.ts +2 -2
- package/dist/actions/action_spec.js +2 -2
- package/dist/actions/action_types.d.ts +229 -8
- package/dist/actions/action_types.d.ts.map +1 -1
- package/dist/actions/action_types.js +56 -5
- package/dist/actions/broadcast_api.d.ts +22 -17
- package/dist/actions/broadcast_api.d.ts.map +1 -1
- package/dist/actions/broadcast_api.js +16 -27
- package/dist/actions/cancel.d.ts +4 -13
- package/dist/actions/cancel.d.ts.map +1 -1
- package/dist/actions/cancel.js +5 -17
- package/dist/actions/compile_action_registry.d.ts +1 -2
- package/dist/actions/compile_action_registry.d.ts.map +1 -1
- package/dist/actions/connection_closer.d.ts +120 -50
- package/dist/actions/connection_closer.d.ts.map +1 -1
- package/dist/actions/connection_closer.js +139 -31
- package/dist/actions/{transports_ws_backend.d.ts → connection_registry.d.ts} +120 -132
- package/dist/actions/connection_registry.d.ts.map +1 -0
- package/dist/actions/{transports_ws_backend.js → connection_registry.js} +149 -152
- package/dist/actions/frontend_rpc_client.d.ts +52 -2
- package/dist/actions/frontend_rpc_client.d.ts.map +1 -1
- package/dist/actions/frontend_rpc_client.js +42 -4
- package/dist/actions/peer_ping.d.ts +7 -9
- package/dist/actions/peer_ping.d.ts.map +1 -1
- package/dist/actions/peer_ping.js +6 -8
- package/dist/actions/peer_request.d.ts +6 -5
- package/dist/actions/peer_request.d.ts.map +1 -1
- package/dist/actions/peer_request.js +6 -5
- package/dist/actions/perform_action.d.ts +36 -28
- package/dist/actions/perform_action.d.ts.map +1 -1
- package/dist/actions/perform_action.js +60 -34
- package/dist/actions/protocol.d.ts +14 -0
- package/dist/actions/protocol.d.ts.map +1 -1
- package/dist/actions/protocol.js +18 -0
- package/dist/actions/register_action_ws.d.ts +137 -298
- package/dist/actions/register_action_ws.d.ts.map +1 -1
- package/dist/actions/register_action_ws.js +155 -923
- package/dist/actions/socket.svelte.d.ts +9 -0
- package/dist/actions/socket.svelte.d.ts.map +1 -1
- package/dist/actions/socket.svelte.js +16 -5
- package/dist/actions/transports.d.ts +88 -34
- package/dist/actions/transports.d.ts.map +1 -1
- package/dist/actions/transports.js +76 -76
- package/dist/actions/transports_http.d.ts +48 -12
- package/dist/actions/transports_http.d.ts.map +1 -1
- package/dist/actions/transports_http.js +75 -44
- package/dist/actions/transports_ws.d.ts +29 -0
- package/dist/actions/transports_ws.d.ts.map +1 -1
- package/dist/actions/transports_ws.js +34 -8
- package/dist/actions/ws_endpoint_spec.d.ts +52 -75
- package/dist/actions/ws_endpoint_spec.d.ts.map +1 -1
- package/dist/actions/ws_endpoint_spec.js +27 -10
- package/dist/actions/ws_outbound_writer.d.ts +3 -3
- package/dist/actions/ws_outbound_writer.js +3 -3
- package/dist/actions/ws_socket_session.d.ts +321 -0
- package/dist/actions/ws_socket_session.d.ts.map +1 -0
- package/dist/actions/ws_socket_session.js +783 -0
- package/dist/auth/CLAUDE.md +70 -44
- package/dist/auth/account_action_specs.d.ts +2 -0
- package/dist/auth/account_action_specs.d.ts.map +1 -1
- package/dist/auth/account_actions.d.ts +1 -1
- package/dist/auth/account_actions.d.ts.map +1 -1
- package/dist/auth/account_actions.js +9 -3
- package/dist/auth/account_queries.d.ts +10 -0
- package/dist/auth/account_queries.d.ts.map +1 -1
- package/dist/auth/account_queries.js +27 -17
- package/dist/auth/account_routes.d.ts +2 -1
- package/dist/auth/account_routes.d.ts.map +1 -1
- package/dist/auth/account_routes.js +14 -17
- package/dist/auth/account_schema.d.ts +5 -5
- package/dist/auth/account_schema.d.ts.map +1 -1
- package/dist/auth/account_schema.js +5 -2
- package/dist/auth/actor_lookup_actions.d.ts +1 -1
- package/dist/auth/actor_lookup_actions.d.ts.map +1 -1
- package/dist/auth/actor_lookup_actions.js +1 -1
- package/dist/auth/actor_search_action_specs.d.ts.map +1 -1
- package/dist/auth/actor_search_action_specs.js +2 -1
- package/dist/auth/actor_search_actions.d.ts +1 -1
- package/dist/auth/actor_search_actions.d.ts.map +1 -1
- package/dist/auth/actor_search_actions.js +1 -1
- package/dist/auth/actor_search_queries.d.ts +5 -5
- package/dist/auth/actor_search_queries.d.ts.map +1 -1
- package/dist/auth/actor_search_queries.js +7 -7
- package/dist/auth/admin_action_specs.d.ts.map +1 -1
- package/dist/auth/admin_action_specs.js +3 -1
- package/dist/auth/admin_actions.d.ts +1 -1
- package/dist/auth/admin_actions.d.ts.map +1 -1
- package/dist/auth/admin_actions.js +12 -42
- package/dist/auth/all_cell_actions.d.ts +6 -4
- package/dist/auth/all_cell_actions.d.ts.map +1 -1
- package/dist/auth/all_cell_actions.js +1 -1
- package/dist/auth/api_token_queries.d.ts +1 -0
- package/dist/auth/api_token_queries.d.ts.map +1 -1
- package/dist/auth/api_token_queries.js +1 -0
- package/dist/auth/audit_emitter.d.ts +3 -3
- package/dist/auth/audit_emitter.js +2 -2
- package/dist/auth/audit_log_route_schema.d.ts.map +1 -1
- package/dist/auth/audit_log_route_schema.js +3 -2
- package/dist/auth/audit_log_routes.d.ts +20 -11
- package/dist/auth/audit_log_routes.d.ts.map +1 -1
- package/dist/auth/audit_log_routes.js +49 -29
- package/dist/auth/audit_log_schema.d.ts +13 -21
- package/dist/auth/audit_log_schema.d.ts.map +1 -1
- package/dist/auth/audit_log_schema.js +10 -18
- package/dist/auth/bearer_auth.d.ts +7 -4
- package/dist/auth/bearer_auth.d.ts.map +1 -1
- package/dist/auth/bearer_auth.js +21 -15
- package/dist/auth/cell_action_helpers.d.ts +89 -0
- package/dist/auth/cell_action_helpers.d.ts.map +1 -0
- package/dist/auth/cell_action_helpers.js +113 -0
- package/dist/auth/cell_actions.d.ts +22 -13
- package/dist/auth/cell_actions.d.ts.map +1 -1
- package/dist/auth/cell_actions.js +105 -167
- package/dist/auth/cell_audit_actions.d.ts +1 -1
- package/dist/auth/cell_audit_actions.d.ts.map +1 -1
- package/dist/auth/cell_audit_actions.js +3 -12
- package/dist/auth/cell_audit_metadata.d.ts +1 -1
- package/dist/auth/cell_audit_metadata.js +1 -1
- package/dist/auth/cell_field_actions.d.ts +1 -1
- package/dist/auth/cell_field_actions.d.ts.map +1 -1
- package/dist/auth/cell_field_actions.js +16 -66
- package/dist/auth/cell_grant_action_specs.d.ts +2 -2
- package/dist/auth/cell_grant_action_specs.js +3 -3
- package/dist/auth/cell_grant_actions.d.ts +73 -11
- package/dist/auth/cell_grant_actions.d.ts.map +1 -1
- package/dist/auth/cell_grant_actions.js +63 -55
- package/dist/auth/cell_grant_audit_metadata.d.ts +6 -3
- package/dist/auth/cell_grant_audit_metadata.d.ts.map +1 -1
- package/dist/auth/cell_grant_audit_metadata.js +7 -4
- package/dist/auth/cell_item_actions.d.ts +1 -1
- package/dist/auth/cell_item_actions.d.ts.map +1 -1
- package/dist/auth/cell_item_actions.js +21 -82
- package/dist/auth/cleanup.d.ts +1 -1
- package/dist/auth/cleanup.d.ts.map +1 -1
- package/dist/auth/cleanup.js +6 -3
- package/dist/auth/credential_deadline.d.ts +3 -3
- package/dist/auth/credential_deadline.js +3 -3
- package/dist/auth/credential_type_schema.d.ts +5 -5
- package/dist/auth/credential_type_schema.js +5 -5
- package/dist/auth/daemon_token_middleware.d.ts +12 -6
- package/dist/auth/daemon_token_middleware.d.ts.map +1 -1
- package/dist/auth/daemon_token_middleware.js +28 -17
- package/dist/auth/deps.d.ts +4 -4
- package/dist/auth/fail_floor.d.ts +55 -0
- package/dist/auth/fail_floor.d.ts.map +1 -0
- package/dist/auth/fail_floor.js +63 -0
- package/dist/auth/invite_queries.d.ts +3 -15
- package/dist/auth/invite_queries.d.ts.map +1 -1
- package/dist/auth/invite_queries.js +3 -21
- package/dist/auth/middleware.d.ts +12 -7
- package/dist/auth/middleware.d.ts.map +1 -1
- package/dist/auth/middleware.js +42 -29
- package/dist/auth/migrations.d.ts +5 -33
- package/dist/auth/migrations.d.ts.map +1 -1
- package/dist/auth/migrations.js +9 -16
- package/dist/auth/request_context.d.ts +101 -71
- package/dist/auth/request_context.d.ts.map +1 -1
- package/dist/auth/request_context.js +137 -140
- package/dist/auth/resolved_auth.d.ts +122 -36
- package/dist/auth/resolved_auth.d.ts.map +1 -1
- package/dist/auth/resolved_auth.js +89 -38
- package/dist/auth/role_grant_offer_action_specs.d.ts +99 -14
- package/dist/auth/role_grant_offer_action_specs.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_action_specs.js +26 -13
- package/dist/auth/role_grant_offer_actions.d.ts +13 -7
- package/dist/auth/role_grant_offer_actions.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_actions.js +14 -12
- package/dist/auth/role_grant_offer_notifications.d.ts +3 -3
- package/dist/auth/role_grant_offer_notifications.js +1 -1
- package/dist/auth/role_grant_offer_queries.d.ts +0 -5
- package/dist/auth/role_grant_offer_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_queries.js +9 -41
- package/dist/auth/role_grant_queries.d.ts +17 -67
- package/dist/auth/role_grant_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_queries.js +34 -106
- package/dist/auth/role_grant_sql.d.ts +42 -0
- package/dist/auth/role_grant_sql.d.ts.map +1 -0
- package/dist/auth/role_grant_sql.js +54 -0
- package/dist/auth/scope_kind_schema.d.ts +1 -1
- package/dist/auth/scope_kind_schema.js +1 -1
- package/dist/auth/self_service_role_actions.d.ts +1 -1
- package/dist/auth/self_service_role_actions.d.ts.map +1 -1
- package/dist/auth/self_service_role_actions.js +1 -1
- package/dist/auth/session_queries.d.ts +2 -1
- package/dist/auth/session_queries.d.ts.map +1 -1
- package/dist/auth/session_queries.js +2 -1
- package/dist/auth/signup_routes.d.ts +2 -1
- package/dist/auth/signup_routes.d.ts.map +1 -1
- package/dist/auth/signup_routes.js +14 -13
- package/dist/auth/standard_rpc_actions.d.ts +1 -1
- package/dist/auth/standard_rpc_actions.d.ts.map +1 -1
- package/dist/auth/token_scope.d.ts +19 -46
- package/dist/auth/token_scope.d.ts.map +1 -1
- package/dist/auth/token_scope.js +23 -41
- package/dist/db/CLAUDE.md +9 -4
- package/dist/db/cell_ddl.d.ts +5 -142
- package/dist/db/cell_ddl.d.ts.map +1 -1
- package/dist/db/cell_ddl.js +17 -16
- package/dist/db/cell_field_queries.d.ts +0 -13
- package/dist/db/cell_field_queries.d.ts.map +1 -1
- package/dist/db/cell_field_queries.js +0 -16
- package/dist/db/cell_grant_queries.d.ts +10 -5
- package/dist/db/cell_grant_queries.d.ts.map +1 -1
- package/dist/db/cell_grant_queries.js +13 -7
- package/dist/db/cell_item_queries.d.ts +0 -7
- package/dist/db/cell_item_queries.d.ts.map +1 -1
- package/dist/db/cell_item_queries.js +0 -10
- package/dist/db/cell_queries.d.ts +12 -48
- package/dist/db/cell_queries.d.ts.map +1 -1
- package/dist/db/cell_queries.js +24 -55
- package/dist/db/cell_view_sql.d.ts +1 -6
- package/dist/db/cell_view_sql.d.ts.map +1 -1
- package/dist/db/cell_view_sql.js +1 -2
- package/dist/db/fact_ddl.d.ts +5 -30
- package/dist/db/fact_ddl.d.ts.map +1 -1
- package/dist/db/fact_ddl.js +14 -13
- package/dist/db/fact_store.d.ts +11 -0
- package/dist/db/fact_store.d.ts.map +1 -1
- package/dist/db/fact_store.js +4 -1
- package/dist/db/migrate.d.ts +44 -6
- package/dist/db/migrate.d.ts.map +1 -1
- package/dist/db/migrate.js +63 -4
- package/dist/dev/setup.d.ts +18 -14
- package/dist/dev/setup.d.ts.map +1 -1
- package/dist/dev/setup.js +42 -39
- package/dist/env/dotenv.d.ts +2 -2
- package/dist/env/dotenv.js +2 -2
- package/dist/env/update_env_variable.d.ts +33 -21
- package/dist/env/update_env_variable.d.ts.map +1 -1
- package/dist/env/update_env_variable.js +54 -35
- package/dist/hono_context.d.ts +15 -90
- package/dist/hono_context.d.ts.map +1 -1
- package/dist/hono_context.js +9 -56
- package/dist/http/CLAUDE.md +35 -20
- package/dist/http/auth_shape.d.ts +1 -8
- package/dist/http/auth_shape.d.ts.map +1 -1
- package/dist/http/auth_shape.js +6 -12
- package/dist/http/common_routes.d.ts.map +1 -1
- package/dist/http/common_routes.js +3 -2
- package/dist/http/db_routes.d.ts +3 -3
- package/dist/http/db_routes.js +3 -3
- package/dist/http/error_schemas.d.ts +1 -2
- package/dist/http/error_schemas.d.ts.map +1 -1
- package/dist/http/error_schemas.js +1 -2
- package/dist/http/health_schema.d.ts +16 -0
- package/dist/http/health_schema.d.ts.map +1 -0
- package/dist/http/health_schema.js +12 -0
- package/dist/http/jsonrpc_errors.d.ts +22 -2
- package/dist/http/jsonrpc_errors.d.ts.map +1 -1
- package/dist/http/jsonrpc_errors.js +41 -3
- package/dist/http/jsonrpc_helpers.d.ts +60 -17
- package/dist/http/jsonrpc_helpers.d.ts.map +1 -1
- package/dist/http/jsonrpc_helpers.js +67 -25
- package/dist/http/origin.d.ts +30 -1
- package/dist/http/origin.d.ts.map +1 -1
- package/dist/http/origin.js +46 -9
- package/dist/http/origin_wildcard.d.ts +97 -0
- package/dist/http/origin_wildcard.d.ts.map +1 -0
- package/dist/http/origin_wildcard.js +142 -0
- package/dist/http/pending_effects.d.ts +28 -0
- package/dist/http/pending_effects.d.ts.map +1 -1
- package/dist/http/pending_effects.js +32 -1
- package/dist/http/route_spec.d.ts +4 -3
- package/dist/http/route_spec.d.ts.map +1 -1
- package/dist/http/route_spec.js +54 -45
- package/dist/http/surface.d.ts +1 -1
- package/dist/http/surface.d.ts.map +1 -1
- package/dist/http/surface_query.d.ts +9 -50
- package/dist/http/surface_query.d.ts.map +1 -1
- package/dist/http/surface_query.js +48 -94
- package/dist/realtime/audit_log_sse.d.ts +180 -0
- package/dist/realtime/audit_log_sse.d.ts.map +1 -0
- package/dist/realtime/audit_log_sse.js +154 -0
- package/dist/realtime/sse.d.ts +21 -6
- package/dist/realtime/sse.d.ts.map +1 -1
- package/dist/realtime/sse.js +33 -10
- package/dist/realtime/sse_constants.d.ts +29 -2
- package/dist/realtime/sse_constants.d.ts.map +1 -1
- package/dist/realtime/sse_constants.js +35 -2
- package/dist/realtime/{subscriber_registry.d.ts → sse_registry.d.ts} +12 -12
- package/dist/realtime/sse_registry.d.ts.map +1 -0
- package/dist/realtime/{subscriber_registry.js → sse_registry.js} +4 -4
- package/dist/schema_meta.d.ts +30 -10
- package/dist/schema_meta.d.ts.map +1 -1
- package/dist/schema_meta.js +85 -21
- package/dist/sensitivity.d.ts +9 -3
- package/dist/sensitivity.d.ts.map +1 -1
- package/dist/sensitivity.js +3 -2
- package/dist/server/app_backend.d.ts +8 -5
- package/dist/server/app_backend.d.ts.map +1 -1
- package/dist/server/app_backend.js +6 -12
- package/dist/server/app_server.d.ts +62 -51
- package/dist/server/app_server.d.ts.map +1 -1
- package/dist/server/app_server.js +84 -71
- package/dist/server/app_server_context.d.ts +1 -1
- package/dist/server/app_server_context.d.ts.map +1 -1
- package/dist/server/env.d.ts +24 -20
- package/dist/server/env.d.ts.map +1 -1
- package/dist/server/env.js +24 -34
- package/dist/server/serve_fact_route.d.ts +12 -16
- package/dist/server/serve_fact_route.d.ts.map +1 -1
- package/dist/server/serve_fact_route.js +59 -34
- package/dist/server/static.d.ts.map +1 -1
- package/dist/server/static.js +2 -2
- package/dist/testing/CLAUDE.md +179 -158
- package/dist/testing/admin_integration.d.ts.map +1 -1
- package/dist/testing/admin_integration.js +10 -19
- package/dist/testing/adversarial_headers.d.ts.map +1 -1
- package/dist/testing/adversarial_headers.js +8 -0
- package/dist/testing/app_server.d.ts +9 -77
- package/dist/testing/app_server.d.ts.map +1 -1
- package/dist/testing/app_server.js +31 -112
- package/dist/testing/attack_surface.d.ts.map +1 -1
- package/dist/testing/attack_surface.js +3 -4
- package/dist/testing/audit_completeness.d.ts.map +1 -1
- package/dist/testing/audit_completeness.js +4 -5
- package/dist/testing/auth_apps.d.ts +3 -3
- package/dist/testing/auth_apps.d.ts.map +1 -1
- package/dist/testing/auth_apps.js +9 -6
- package/dist/testing/connection_closer_helpers.d.ts +8 -16
- package/dist/testing/connection_closer_helpers.d.ts.map +1 -1
- package/dist/testing/connection_closer_helpers.js +7 -20
- package/dist/testing/cross_backend/action_manifest.d.ts +15 -4
- package/dist/testing/cross_backend/action_manifest.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest.js +13 -3
- package/dist/testing/cross_backend/action_manifest_parity.d.ts +15 -7
- package/dist/testing/cross_backend/action_manifest_parity.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest_parity.js +8 -1
- package/dist/testing/cross_backend/body_size.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size.js +25 -22
- package/dist/testing/cross_backend/build_test_backend_paths.d.ts +22 -3
- package/dist/testing/cross_backend/build_test_backend_paths.d.ts.map +1 -1
- package/dist/testing/cross_backend/build_test_backend_paths.js +34 -11
- package/dist/testing/cross_backend/capabilities.d.ts +13 -7
- package/dist/testing/cross_backend/capabilities.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_grant_role.js +2 -2
- package/dist/testing/cross_backend/cell_grant_steward.d.ts +4 -0
- package/dist/testing/cross_backend/cell_grant_steward.d.ts.map +1 -0
- package/dist/testing/cross_backend/cell_grant_steward.js +120 -0
- package/dist/testing/cross_backend/cell_relations.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_relations.js +21 -0
- package/dist/testing/cross_backend/conformance_table.d.ts +1 -1
- package/dist/testing/cross_backend/conformance_table.d.ts.map +1 -1
- package/dist/testing/cross_backend/default_backend_configs.d.ts +18 -4
- package/dist/testing/cross_backend/default_backend_configs.d.ts.map +1 -1
- package/dist/testing/cross_backend/default_backend_configs.js +29 -9
- package/dist/testing/cross_backend/default_spine_surface.d.ts +7 -7
- package/dist/testing/cross_backend/default_spine_surface.js +2 -2
- package/dist/testing/cross_backend/fact_serving.d.ts.map +1 -1
- package/dist/testing/cross_backend/fact_serving.js +48 -0
- package/dist/testing/cross_backend/full_spine_mount.d.ts +3 -4
- package/dist/testing/cross_backend/full_spine_mount.d.ts.map +1 -1
- package/dist/testing/cross_backend/full_spine_mount.js +9 -2
- package/dist/testing/cross_backend/origin_scope.d.ts.map +1 -1
- package/dist/testing/cross_backend/origin_scope.js +5 -13
- package/dist/testing/cross_backend/peer_ping_ws.d.ts.map +1 -1
- package/dist/testing/cross_backend/peer_ping_ws.js +29 -4
- package/dist/testing/cross_backend/postgres_database.d.ts +32 -0
- package/dist/testing/cross_backend/postgres_database.d.ts.map +1 -1
- package/dist/testing/cross_backend/postgres_database.js +56 -1
- package/dist/testing/cross_backend/query_shape.d.ts.map +1 -1
- package/dist/testing/cross_backend/query_shape.js +18 -1
- package/dist/testing/cross_backend/role_grant_offer_lifecycle.d.ts.map +1 -1
- package/dist/testing/cross_backend/role_grant_offer_lifecycle.js +23 -1
- package/dist/testing/cross_backend/rpc_success_fixtures.js +2 -2
- package/dist/testing/cross_backend/rust_spine_consumer_surface.d.ts +1 -1
- package/dist/testing/cross_backend/rust_spine_consumer_surface.d.ts.map +1 -1
- package/dist/testing/cross_backend/rust_spine_stub_backend_config.d.ts +17 -5
- package/dist/testing/cross_backend/rust_spine_stub_backend_config.d.ts.map +1 -1
- package/dist/testing/cross_backend/rust_spine_stub_backend_config.js +5 -4
- package/dist/testing/cross_backend/session_cap.d.ts +8 -0
- package/dist/testing/cross_backend/session_cap.d.ts.map +1 -1
- package/dist/testing/cross_backend/session_cap.js +66 -2
- package/dist/testing/cross_backend/setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/setup.js +5 -4
- package/dist/testing/cross_backend/spine_suites.d.ts +4 -1
- package/dist/testing/cross_backend/spine_suites.d.ts.map +1 -1
- package/dist/testing/cross_backend/spine_suites.js +21 -0
- package/dist/testing/cross_backend/spine_surface_constants.d.ts +22 -7
- package/dist/testing/cross_backend/spine_surface_constants.d.ts.map +1 -1
- package/dist/testing/cross_backend/spine_surface_constants.js +22 -7
- package/dist/testing/cross_backend/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/cross_backend/sse_round_trip.js +4 -3
- package/dist/testing/cross_backend/standard.d.ts +6 -12
- package/dist/testing/cross_backend/standard.d.ts.map +1 -1
- package/dist/testing/cross_backend/test_cell_grant_steward_revoke_authorize.d.ts +8 -0
- package/dist/testing/cross_backend/test_cell_grant_steward_revoke_authorize.d.ts.map +1 -0
- package/dist/testing/cross_backend/test_cell_grant_steward_revoke_authorize.js +22 -0
- package/dist/testing/cross_backend/testing_backdoor.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_backdoor.js +4 -6
- package/dist/testing/cross_backend/testing_origin_check.d.ts +1 -1
- package/dist/testing/cross_backend/testing_origin_check.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_origin_check.js +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +10 -5
- package/dist/testing/cross_backend/testing_reset_actions.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.js +7 -6
- package/dist/testing/cross_backend/testing_server_bun.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_server_bun.js +5 -4
- package/dist/testing/cross_backend/testing_server_core.d.ts +6 -7
- package/dist/testing/cross_backend/testing_server_core.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_server_core.js +1 -1
- package/dist/testing/cross_backend/testing_server_node.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_server_node.js +13 -2
- package/dist/testing/cross_backend/token_lifetime.d.ts.map +1 -1
- package/dist/testing/cross_backend/token_lifetime.js +68 -0
- package/dist/testing/cross_backend/transport_composition.d.ts +1 -1
- package/dist/testing/cross_backend/transport_composition.d.ts.map +1 -1
- package/dist/testing/cross_backend/transport_composition.js +45 -3
- package/dist/testing/cross_backend/ts_spine_backend_config.d.ts +16 -2
- package/dist/testing/cross_backend/ts_spine_backend_config.d.ts.map +1 -1
- package/dist/testing/cross_backend/ts_spine_backend_config.js +11 -8
- package/dist/testing/cross_backend/ws_action_rate_limit.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_action_rate_limit.js +30 -12
- package/dist/testing/cross_backend/ws_connection_cap.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_connection_cap.js +5 -7
- package/dist/testing/cross_backend/ws_endpoint.d.ts +2 -3
- package/dist/testing/cross_backend/ws_endpoint.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_envelope.d.ts +17 -0
- package/dist/testing/cross_backend/ws_envelope.d.ts.map +1 -0
- package/dist/testing/cross_backend/ws_envelope.js +172 -0
- package/dist/testing/cross_backend/ws_inbound_dispatch.d.ts +16 -0
- package/dist/testing/cross_backend/ws_inbound_dispatch.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_inbound_dispatch.js +8 -4
- package/dist/testing/cross_backend/ws_outbound_overflow.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_outbound_overflow.js +5 -8
- package/dist/testing/cross_backend/ws_role_gated.js +2 -2
- package/dist/testing/cross_backend/ws_round_trip.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_round_trip.js +6 -4
- package/dist/{cli/daemon.d.ts → testing/daemon_info.d.ts} +15 -47
- package/dist/testing/daemon_info.d.ts.map +1 -0
- package/dist/testing/daemon_info.js +108 -0
- package/dist/testing/daemon_token_rotation.js +1 -1
- package/dist/testing/data_exposure.d.ts.map +1 -1
- package/dist/testing/data_exposure.js +3 -4
- package/dist/testing/db.js +2 -2
- package/dist/testing/integration.d.ts.map +1 -1
- package/dist/testing/integration.js +35 -65
- package/dist/testing/integration_helpers.d.ts +0 -15
- package/dist/testing/integration_helpers.d.ts.map +1 -1
- package/dist/testing/integration_helpers.js +2 -42
- package/dist/testing/middleware.d.ts +20 -12
- package/dist/testing/middleware.d.ts.map +1 -1
- package/dist/testing/middleware.js +49 -40
- package/dist/testing/rate_limiting.d.ts.map +1 -1
- package/dist/testing/rate_limiting.js +13 -22
- package/dist/testing/resolved_auth.d.ts +30 -0
- package/dist/testing/resolved_auth.d.ts.map +1 -0
- package/dist/testing/resolved_auth.js +41 -0
- package/dist/testing/rpc_envelope_cases.d.ts.map +1 -1
- package/dist/testing/rpc_envelope_cases.js +3 -0
- package/dist/testing/rpc_helpers.d.ts +1 -1
- package/dist/testing/rpc_helpers.d.ts.map +1 -1
- package/dist/testing/rpc_helpers.js +2 -1
- package/dist/testing/sse_round_trip.d.ts +5 -4
- package/dist/testing/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/sse_round_trip.js +2 -2
- package/dist/testing/stubs.d.ts +2 -2
- package/dist/testing/stubs.d.ts.map +1 -1
- package/dist/testing/stubs.js +24 -21
- package/dist/testing/test_origin.d.ts +25 -0
- package/dist/testing/test_origin.d.ts.map +1 -0
- package/dist/testing/test_origin.js +28 -0
- package/dist/testing/transports/raw_http.d.ts +54 -0
- package/dist/testing/transports/raw_http.d.ts.map +1 -1
- package/dist/testing/transports/raw_http.js +58 -0
- package/dist/testing/transports/ws_raw_client.d.ts +8 -0
- package/dist/testing/transports/ws_raw_client.d.ts.map +1 -1
- package/dist/testing/transports/ws_raw_client.js +13 -0
- package/dist/testing/transports/ws_transport.d.ts +15 -2
- package/dist/testing/transports/ws_transport.d.ts.map +1 -1
- package/dist/testing/transports/ws_transport.js +4 -2
- package/dist/testing/ws_round_trip.d.ts +27 -25
- package/dist/testing/ws_round_trip.d.ts.map +1 -1
- package/dist/testing/ws_round_trip.js +34 -26
- package/dist/ui/AccountSessions.svelte +48 -19
- package/dist/ui/AccountSessions.svelte.d.ts +2 -17
- package/dist/ui/AccountSessions.svelte.d.ts.map +1 -1
- package/dist/ui/AdminAccounts.svelte +6 -1
- package/dist/ui/AdminAuditLog.svelte +61 -22
- package/dist/ui/AdminAuditLog.svelte.d.ts.map +1 -1
- package/dist/ui/AdminInvites.svelte +1 -1
- package/dist/ui/AdminOverview.svelte +76 -37
- package/dist/ui/AdminOverview.svelte.d.ts.map +1 -1
- package/dist/ui/AdminRoleGrantHistory.svelte +6 -1
- package/dist/ui/AdminSessions.svelte +1 -1
- package/dist/ui/AppShell.svelte +3 -2
- package/dist/ui/AppShell.svelte.d.ts +3 -2
- package/dist/ui/AppShell.svelte.d.ts.map +1 -1
- package/dist/ui/CLAUDE.md +121 -35
- package/dist/ui/Datatable.svelte +33 -18
- package/dist/ui/Datatable.svelte.d.ts +2 -14
- package/dist/ui/Datatable.svelte.d.ts.map +1 -1
- package/dist/ui/OpenSignupToggle.svelte +10 -1
- package/dist/ui/OpenSignupToggle.svelte.d.ts.map +1 -1
- package/dist/ui/PopoverButton.svelte +13 -8
- package/dist/ui/PopoverButton.svelte.d.ts.map +1 -1
- package/dist/ui/RoleGrantOfferForm.svelte +3 -2
- package/dist/ui/RoleGrantOfferForm.svelte.d.ts +3 -2
- package/dist/ui/RoleGrantOfferForm.svelte.d.ts.map +1 -1
- package/dist/ui/RoleGrantOfferHistory.svelte +3 -3
- package/dist/ui/RoleGrantOfferInbox.svelte +19 -15
- package/dist/ui/RoleGrantOfferInbox.svelte.d.ts.map +1 -1
- package/dist/ui/SurfaceExplorer.svelte +66 -27
- package/dist/ui/SurfaceExplorer.svelte.d.ts.map +1 -1
- package/dist/ui/account_sessions_state.svelte.d.ts +7 -14
- package/dist/ui/account_sessions_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_accounts_state.svelte.d.ts +14 -9
- package/dist/ui/admin_accounts_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_accounts_state.svelte.js +6 -4
- package/dist/ui/admin_invites_state.svelte.d.ts +2 -2
- package/dist/ui/admin_invites_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_rpc_adapters.d.ts +9 -9
- package/dist/ui/admin_rpc_adapters.d.ts.map +1 -1
- package/dist/ui/admin_rpc_adapters.js +9 -9
- package/dist/ui/app_settings_state.svelte.d.ts +2 -2
- package/dist/ui/app_settings_state.svelte.d.ts.map +1 -1
- package/dist/ui/audit_log_state.svelte.d.ts +70 -13
- package/dist/ui/audit_log_state.svelte.d.ts.map +1 -1
- package/dist/ui/audit_log_state.svelte.js +239 -47
- package/dist/ui/backend_probe.svelte.d.ts +93 -0
- package/dist/ui/backend_probe.svelte.d.ts.map +1 -0
- package/dist/ui/backend_probe.svelte.js +140 -0
- package/dist/ui/format_scope.d.ts +7 -7
- package/dist/ui/format_scope.d.ts.map +1 -1
- package/dist/ui/format_scope.js +4 -4
- package/dist/ui/keyed_async_slot.svelte.d.ts +2 -2
- package/dist/ui/keyed_async_slot.svelte.js +2 -2
- package/dist/ui/popover.svelte.d.ts +18 -19
- package/dist/ui/popover.svelte.d.ts.map +1 -1
- package/dist/ui/popover.svelte.js +103 -16
- package/dist/ui/role_grant_offers_state.svelte.d.ts +41 -46
- package/dist/ui/role_grant_offers_state.svelte.d.ts.map +1 -1
- package/dist/ui/role_grant_offers_state.svelte.js +37 -19
- package/dist/ui/ui_format.d.ts +17 -0
- package/dist/ui/ui_format.d.ts.map +1 -1
- package/dist/ui/ui_format.js +20 -0
- package/package.json +2 -1
- package/dist/actions/register_ws_endpoint.d.ts +0 -79
- package/dist/actions/register_ws_endpoint.d.ts.map +0 -1
- package/dist/actions/register_ws_endpoint.js +0 -109
- package/dist/actions/transports_ws_auth_guard.d.ts +0 -96
- package/dist/actions/transports_ws_auth_guard.d.ts.map +0 -1
- package/dist/actions/transports_ws_auth_guard.js +0 -141
- package/dist/actions/transports_ws_backend.d.ts.map +0 -1
- package/dist/cli/args.d.ts +0 -55
- package/dist/cli/args.d.ts.map +0 -1
- package/dist/cli/args.js +0 -100
- package/dist/cli/config.d.ts +0 -47
- package/dist/cli/config.d.ts.map +0 -1
- package/dist/cli/config.js +0 -77
- package/dist/cli/daemon.d.ts.map +0 -1
- package/dist/cli/daemon.js +0 -181
- package/dist/cli/help.d.ts +0 -124
- package/dist/cli/help.d.ts.map +0 -1
- package/dist/cli/help.js +0 -215
- package/dist/cli/logger.d.ts +0 -46
- package/dist/cli/logger.d.ts.map +0 -1
- package/dist/cli/logger.js +0 -48
- package/dist/cli/util.d.ts +0 -36
- package/dist/cli/util.d.ts.map +0 -1
- package/dist/cli/util.js +0 -50
- package/dist/realtime/sse_auth_guard.d.ts +0 -197
- package/dist/realtime/sse_auth_guard.d.ts.map +0 -1
- package/dist/realtime/sse_auth_guard.js +0 -239
- package/dist/realtime/subscriber_registry.d.ts.map +0 -1
- package/dist/testing/bootstrap_success.d.ts +0 -29
- package/dist/testing/bootstrap_success.d.ts.map +0 -1
- package/dist/testing/bootstrap_success.js +0 -144
- package/dist/testing/mock_fs.d.ts +0 -20
- package/dist/testing/mock_fs.d.ts.map +0 -1
- package/dist/testing/mock_fs.js +0 -28
- package/dist/testing/standard.d.ts +0 -122
- package/dist/testing/standard.d.ts.map +0 -1
- package/dist/testing/standard.js +0 -73
- package/dist/testing/testing_rate_limiter.d.ts +0 -65
- package/dist/testing/testing_rate_limiter.d.ts.map +0 -1
- package/dist/testing/testing_rate_limiter.js +0 -80
|
@@ -2,44 +2,60 @@
|
|
|
2
2
|
* The account-grain credential a request resolved to, and the re-check a
|
|
3
3
|
* long-lived connection runs on it once it is registered.
|
|
4
4
|
*
|
|
5
|
-
* The auth middleware chain
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
5
|
+
* The auth middleware chain resolves at most one credential per request —
|
|
6
|
+
* daemon token, then session cookie, then bearer, the first that
|
|
7
|
+
* authenticates winning — and leaves it on the Hono context as one value,
|
|
8
|
+
* `ResolvedAuth` (`RESOLVED_AUTH_KEY`, read with `get_resolved_auth`). Every
|
|
9
|
+
* reader takes that value, so the connections that outlive their request — a
|
|
10
|
+
* WebSocket, an SSE stream — carry it past the handshake, re-read it with
|
|
11
|
+
* `revalidate_resolved_auth` (or the whole admission re-check,
|
|
12
|
+
* `recheck_admission`), and close at its `credential_deadline`.
|
|
11
13
|
*
|
|
12
14
|
* @module
|
|
13
15
|
*/
|
|
14
|
-
import {
|
|
15
|
-
import { query_account_by_id } from './account_queries.js';
|
|
16
|
+
import { RESOLVED_AUTH_KEY } from '../hono_context.js';
|
|
17
|
+
import { query_account_by_id, query_active_actors_by_account } from './account_queries.js';
|
|
16
18
|
import { query_api_token_live_account } from './api_token_queries.js';
|
|
17
|
-
import {
|
|
19
|
+
import { has_any_scoped_role, refresh_role_grants } from './request_context.js';
|
|
18
20
|
import { query_session_get_valid } from './session_queries.js';
|
|
21
|
+
import { token_scope_full } from './token_scope.js';
|
|
19
22
|
/**
|
|
20
|
-
*
|
|
23
|
+
* The credential's authority narrowing: an API token's own scope, `full` for a
|
|
24
|
+
* session or the daemon token (a browser session *is* full account authority —
|
|
25
|
+
* narrowing it is what role grants are for — and the daemon token is singular,
|
|
26
|
+
* filesystem-proved, and keeper-bound). `null` only for the anonymous caller,
|
|
27
|
+
* who holds no credential to narrow. Every token-scope gate reads this. The twin
|
|
28
|
+
* of the Rust spine's `ResolvedAuth::scope`.
|
|
21
29
|
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
|
|
25
|
-
|
|
30
|
+
* @param auth - the resolved credential, or `null` for an anonymous caller
|
|
31
|
+
* @returns the scope, or `null` for an anonymous caller
|
|
32
|
+
*/
|
|
33
|
+
export const resolved_auth_scope = (auth) => {
|
|
34
|
+
if (auth === null)
|
|
35
|
+
return null;
|
|
36
|
+
return auth.credential_type === 'api_token' ? auth.scope : token_scope_full();
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* The session hash of a session credential, `null` for any other (or none).
|
|
40
|
+
*
|
|
41
|
+
* @param auth - the resolved credential, or `null` for an anonymous caller
|
|
42
|
+
* @returns the `auth_session.id`, or `null`
|
|
43
|
+
*/
|
|
44
|
+
export const resolved_auth_session_hash = (auth) => auth?.credential_type === 'session' ? auth.session_hash : null;
|
|
45
|
+
/**
|
|
46
|
+
* The token id of an API token credential, `null` for any other (or none).
|
|
47
|
+
*
|
|
48
|
+
* @param auth - the resolved credential, or `null` for an anonymous caller
|
|
49
|
+
* @returns the `api_token.id`, or `null`
|
|
50
|
+
*/
|
|
51
|
+
export const resolved_auth_api_token_id = (auth) => auth?.credential_type === 'api_token' ? auth.api_token_id : null;
|
|
52
|
+
/**
|
|
53
|
+
* The credential the auth middleware resolved for this request.
|
|
26
54
|
*
|
|
27
55
|
* @param c - the request context, after the auth middleware chain
|
|
28
56
|
* @returns the resolved credential, or `null` for an unauthenticated request
|
|
29
57
|
*/
|
|
30
|
-
export const get_resolved_auth = (c) =>
|
|
31
|
-
const account_id = c.get(ACCOUNT_ID_KEY) ?? null;
|
|
32
|
-
const credential_type = c.get(CREDENTIAL_TYPE_KEY) ?? null;
|
|
33
|
-
if (account_id === null || credential_type === null)
|
|
34
|
-
return null;
|
|
35
|
-
return {
|
|
36
|
-
account_id,
|
|
37
|
-
credential_type,
|
|
38
|
-
token_hash: credential_type === 'session' ? (c.get(AUTH_SESSION_TOKEN_HASH_KEY) ?? null) : null,
|
|
39
|
-
api_token_id: credential_type === 'api_token' ? (c.get(AUTH_API_TOKEN_ID_KEY) ?? null) : null,
|
|
40
|
-
credential_deadline: credential_type === 'daemon_token' ? null : (c.get(CREDENTIAL_DEADLINE_KEY) ?? null)
|
|
41
|
-
};
|
|
42
|
-
};
|
|
58
|
+
export const get_resolved_auth = (c) => c.get(RESOLVED_AUTH_KEY) ?? null;
|
|
43
59
|
/**
|
|
44
60
|
* Re-check that a resolved credential still authenticates: `true` when it
|
|
45
61
|
* does, `false` when it has been revoked, has expired, or its account is gone.
|
|
@@ -48,8 +64,8 @@ export const get_resolved_auth = (c) => {
|
|
|
48
64
|
* and is authorized once, at open. Such a connection is closed on revocation
|
|
49
65
|
* by identity, but only once it is *registered*; between the credential read
|
|
50
66
|
* and the registration a revocation closes nothing. So the opener registers
|
|
51
|
-
* first (un-admitted — `
|
|
52
|
-
* `
|
|
67
|
+
* first (un-admitted — `ConnectionRegistry.register_pending` /
|
|
68
|
+
* `SseRegistry.subscribe_pending`), then calls this, then admits. A
|
|
53
69
|
* revocation that committed before this read is seen by it; one whose close
|
|
54
70
|
* ran after the registration found the pending entry.
|
|
55
71
|
*
|
|
@@ -85,10 +101,6 @@ export const get_resolved_auth = (c) => {
|
|
|
85
101
|
* `api_token.last_used_at` / `last_used_ip` — re-checking a credential is not
|
|
86
102
|
* using it — and it writes nothing else.
|
|
87
103
|
*
|
|
88
|
-
* A `ResolvedAuth` whose credential type lacks its own key (a session with no
|
|
89
|
-
* `token_hash`, a bearer with no `api_token_id`) is a shape the middleware
|
|
90
|
-
* never builds; it is answered `false`.
|
|
91
|
-
*
|
|
92
104
|
* The twin of the Rust spine's `revalidate_resolved_auth`.
|
|
93
105
|
*
|
|
94
106
|
* @param deps - query dependencies; the pool-level `Db`, not a snapshot transaction
|
|
@@ -102,15 +114,11 @@ export const revalidate_resolved_auth = async (deps, resolved) => {
|
|
|
102
114
|
let credential_is_live;
|
|
103
115
|
switch (resolved.credential_type) {
|
|
104
116
|
case 'session': {
|
|
105
|
-
|
|
106
|
-
return false;
|
|
107
|
-
const session = await query_session_get_valid(deps, resolved.token_hash);
|
|
117
|
+
const session = await query_session_get_valid(deps, resolved.session_hash);
|
|
108
118
|
credential_is_live = session?.account_id === account_id;
|
|
109
119
|
break;
|
|
110
120
|
}
|
|
111
121
|
case 'api_token': {
|
|
112
|
-
if (resolved.api_token_id === null)
|
|
113
|
-
return false;
|
|
114
122
|
const owner = await query_api_token_live_account(deps, resolved.api_token_id);
|
|
115
123
|
credential_is_live = owner === account_id;
|
|
116
124
|
break;
|
|
@@ -123,3 +131,46 @@ export const revalidate_resolved_auth = async (deps, resolved) => {
|
|
|
123
131
|
return false;
|
|
124
132
|
return (await query_account_by_id(deps, account_id)) !== undefined;
|
|
125
133
|
};
|
|
134
|
+
/**
|
|
135
|
+
* Re-read everything a long-lived connection's gates read, once the
|
|
136
|
+
* connection is registered pending — the admission step a WebSocket upgrade
|
|
137
|
+
* and the audit stream share (twin of the Rust spine's admission re-check).
|
|
138
|
+
*
|
|
139
|
+
* In order, stopping at the first refusal:
|
|
140
|
+
*
|
|
141
|
+
* 1. **The credential** (`revalidate_resolved_auth`) → `'credential_revoked'`.
|
|
142
|
+
* 2. **The acting actor** the gates resolved, when there is one: it must still
|
|
143
|
+
* be an active actor of the account → `'actor_inactive'`. A soft-deleted
|
|
144
|
+
* actor keeps its account's credentials and its own grant rows, so neither
|
|
145
|
+
* other re-read would refuse it.
|
|
146
|
+
* 3. **The role**, when `required_roles` is non-empty: the acting actor's
|
|
147
|
+
* grants read afresh (`refresh_role_grants`), a **global** grant of any
|
|
148
|
+
* listed role admitting → `'role_revoked'`. A scoped grant never admits at
|
|
149
|
+
* a role gate.
|
|
150
|
+
*
|
|
151
|
+
* Every read must see what committed before it started, so `deps.db` is the
|
|
152
|
+
* pool-level `Db` (see `revalidate_resolved_auth`).
|
|
153
|
+
*
|
|
154
|
+
* @param deps - query dependencies; the pool-level `Db`
|
|
155
|
+
* @param input - the credential, the gates' request context, and the required roles
|
|
156
|
+
* @returns `'admitted'`, or which check refused
|
|
157
|
+
* @throws Error propagated from the database. The caller must fail closed — an
|
|
158
|
+
* unchecked connection is not an admitted one.
|
|
159
|
+
*/
|
|
160
|
+
export const recheck_admission = async (deps, input) => {
|
|
161
|
+
const { resolved, request_context, required_roles } = input;
|
|
162
|
+
if (!(await revalidate_resolved_auth(deps, resolved)))
|
|
163
|
+
return 'credential_revoked';
|
|
164
|
+
const acting_actor = request_context.actor;
|
|
165
|
+
if (acting_actor) {
|
|
166
|
+
const active = await query_active_actors_by_account(deps, resolved.account_id);
|
|
167
|
+
if (!active.some((a) => a.id === acting_actor.id))
|
|
168
|
+
return 'actor_inactive';
|
|
169
|
+
}
|
|
170
|
+
if (required_roles.length > 0) {
|
|
171
|
+
const refreshed = await refresh_role_grants(request_context, deps);
|
|
172
|
+
if (!has_any_scoped_role(refreshed, required_roles, null))
|
|
173
|
+
return 'role_revoked';
|
|
174
|
+
}
|
|
175
|
+
return 'admitted';
|
|
176
|
+
};
|
|
@@ -196,11 +196,50 @@ export declare const RoleGrantOfferAcceptOutput: z.ZodObject<{
|
|
|
196
196
|
superseded_offer_ids: z.ZodArray<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
197
197
|
}, z.core.$strict>;
|
|
198
198
|
export type RoleGrantOfferAcceptOutput = z.infer<typeof RoleGrantOfferAcceptOutput>;
|
|
199
|
-
/** Output for `role_grant_offer_decline`
|
|
200
|
-
export declare const
|
|
201
|
-
|
|
199
|
+
/** Output for `role_grant_offer_decline` — the declined offer, as `accept` answers its own. */
|
|
200
|
+
export declare const RoleGrantOfferDeclineOutput: z.ZodObject<{
|
|
201
|
+
offer: z.ZodObject<{
|
|
202
|
+
id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
203
|
+
from_actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
204
|
+
to_account_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
205
|
+
to_actor_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
206
|
+
role: z.ZodString;
|
|
207
|
+
scope_kind: z.ZodNullable<z.ZodString>;
|
|
208
|
+
scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
209
|
+
message: z.ZodNullable<z.ZodString>;
|
|
210
|
+
created_at: z.ZodString;
|
|
211
|
+
expires_at: z.ZodString;
|
|
212
|
+
accepted_at: z.ZodNullable<z.ZodString>;
|
|
213
|
+
declined_at: z.ZodNullable<z.ZodString>;
|
|
214
|
+
decline_reason: z.ZodNullable<z.ZodString>;
|
|
215
|
+
retracted_at: z.ZodNullable<z.ZodString>;
|
|
216
|
+
superseded_at: z.ZodNullable<z.ZodString>;
|
|
217
|
+
resulting_role_grant_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
218
|
+
}, z.core.$strict>;
|
|
219
|
+
}, z.core.$strict>;
|
|
220
|
+
export type RoleGrantOfferDeclineOutput = z.infer<typeof RoleGrantOfferDeclineOutput>;
|
|
221
|
+
/** Output for `role_grant_offer_retract` — the retracted offer, as `accept` answers its own. */
|
|
222
|
+
export declare const RoleGrantOfferRetractOutput: z.ZodObject<{
|
|
223
|
+
offer: z.ZodObject<{
|
|
224
|
+
id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
225
|
+
from_actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
226
|
+
to_account_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
227
|
+
to_actor_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
228
|
+
role: z.ZodString;
|
|
229
|
+
scope_kind: z.ZodNullable<z.ZodString>;
|
|
230
|
+
scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
231
|
+
message: z.ZodNullable<z.ZodString>;
|
|
232
|
+
created_at: z.ZodString;
|
|
233
|
+
expires_at: z.ZodString;
|
|
234
|
+
accepted_at: z.ZodNullable<z.ZodString>;
|
|
235
|
+
declined_at: z.ZodNullable<z.ZodString>;
|
|
236
|
+
decline_reason: z.ZodNullable<z.ZodString>;
|
|
237
|
+
retracted_at: z.ZodNullable<z.ZodString>;
|
|
238
|
+
superseded_at: z.ZodNullable<z.ZodString>;
|
|
239
|
+
resulting_role_grant_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
240
|
+
}, z.core.$strict>;
|
|
202
241
|
}, z.core.$strict>;
|
|
203
|
-
export type
|
|
242
|
+
export type RoleGrantOfferRetractOutput = z.infer<typeof RoleGrantOfferRetractOutput>;
|
|
204
243
|
/** Output for `role_grant_offer_list`. */
|
|
205
244
|
export declare const RoleGrantOfferListOutput: z.ZodObject<{
|
|
206
245
|
offers: z.ZodArray<z.ZodObject<{
|
|
@@ -283,6 +322,17 @@ export type RoleGrantAssignOutput = z.infer<typeof RoleGrantAssignOutput>;
|
|
|
283
322
|
* `ERROR_ROLE_GRANT_OFFER_ACTOR_ACCOUNT_MISMATCH`) as an enumeration
|
|
284
323
|
* vector. Failure-outcome audit rows preserve the forensic trail; the
|
|
285
324
|
* rate cap closes the budget.
|
|
325
|
+
*
|
|
326
|
+
* `credential_types: ['session']` — see `docs/security.md` §Credential-channel
|
|
327
|
+
* gating. Offering spends the caller's authority to confer a role. Over a
|
|
328
|
+
* leaked API token that is a privilege pivot onto another account: the leak
|
|
329
|
+
* offers a role to an account its holder controls, that account accepts over
|
|
330
|
+
* its own session, and the resulting role_grant outlives revoking the token.
|
|
331
|
+
* Under a consumer `authorize` that delegates offering (a scoped holder
|
|
332
|
+
* offering roles in its scope), every such holder's token would be a
|
|
333
|
+
* role-minting credential. An offer is the grantor's consent act, as accepting
|
|
334
|
+
* is the recipient's; scripted conferral is `role_grant_assign`'s, admin-gated
|
|
335
|
+
* and narrowable by a token scope.
|
|
286
336
|
*/
|
|
287
337
|
export declare const role_grant_offer_create_action_spec: {
|
|
288
338
|
method: string;
|
|
@@ -291,6 +341,7 @@ export declare const role_grant_offer_create_action_spec: {
|
|
|
291
341
|
auth: {
|
|
292
342
|
account: "required";
|
|
293
343
|
actor: "required";
|
|
344
|
+
credential_types: string[];
|
|
294
345
|
};
|
|
295
346
|
side_effects: true;
|
|
296
347
|
input: z.ZodObject<{
|
|
@@ -333,14 +384,14 @@ export declare const role_grant_offer_create_action_spec: {
|
|
|
333
384
|
* without minting anything, so the account bucket is what bounds a loop of them.
|
|
334
385
|
*
|
|
335
386
|
* `credential_types: ['session']` — see `docs/security.md` §Credential-channel
|
|
336
|
-
* gating. The
|
|
337
|
-
*
|
|
338
|
-
*
|
|
339
|
-
*
|
|
340
|
-
*
|
|
341
|
-
*
|
|
342
|
-
*
|
|
343
|
-
*
|
|
387
|
+
* gating. The offer verb that moves the *caller's own* authority: accepting a
|
|
388
|
+
* pending admin offer over a leaked API token is a privilege pivot in the same
|
|
389
|
+
* family the credential-lifecycle mutations are gated to prevent (the token is
|
|
390
|
+
* account-wide and non-expiring, and the resulting role_grant outlives revoking
|
|
391
|
+
* it). Consent inherently belongs to a human at a browser, and no automation
|
|
392
|
+
* accepts an offer on its own behalf. `_create` carries the same gate (the
|
|
393
|
+
* grantor's side of the consent); `_decline` / `_retract` stay ungated
|
|
394
|
+
* deliberately — they destroy a pending offer and confer nothing.
|
|
344
395
|
*/
|
|
345
396
|
export declare const role_grant_offer_accept_action_spec: {
|
|
346
397
|
method: string;
|
|
@@ -398,7 +449,24 @@ export declare const role_grant_offer_decline_action_spec: {
|
|
|
398
449
|
acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
399
450
|
}, z.core.$strict>;
|
|
400
451
|
output: z.ZodObject<{
|
|
401
|
-
|
|
452
|
+
offer: z.ZodObject<{
|
|
453
|
+
id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
454
|
+
from_actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
455
|
+
to_account_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
456
|
+
to_actor_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
457
|
+
role: z.ZodString;
|
|
458
|
+
scope_kind: z.ZodNullable<z.ZodString>;
|
|
459
|
+
scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
460
|
+
message: z.ZodNullable<z.ZodString>;
|
|
461
|
+
created_at: z.ZodString;
|
|
462
|
+
expires_at: z.ZodString;
|
|
463
|
+
accepted_at: z.ZodNullable<z.ZodString>;
|
|
464
|
+
declined_at: z.ZodNullable<z.ZodString>;
|
|
465
|
+
decline_reason: z.ZodNullable<z.ZodString>;
|
|
466
|
+
retracted_at: z.ZodNullable<z.ZodString>;
|
|
467
|
+
superseded_at: z.ZodNullable<z.ZodString>;
|
|
468
|
+
resulting_role_grant_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
469
|
+
}, z.core.$strict>;
|
|
402
470
|
}, z.core.$strict>;
|
|
403
471
|
async: true;
|
|
404
472
|
description: string;
|
|
@@ -418,7 +486,24 @@ export declare const role_grant_offer_retract_action_spec: {
|
|
|
418
486
|
acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
419
487
|
}, z.core.$strict>;
|
|
420
488
|
output: z.ZodObject<{
|
|
421
|
-
|
|
489
|
+
offer: z.ZodObject<{
|
|
490
|
+
id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
491
|
+
from_actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
492
|
+
to_account_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
|
|
493
|
+
to_actor_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
494
|
+
role: z.ZodString;
|
|
495
|
+
scope_kind: z.ZodNullable<z.ZodString>;
|
|
496
|
+
scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
497
|
+
message: z.ZodNullable<z.ZodString>;
|
|
498
|
+
created_at: z.ZodString;
|
|
499
|
+
expires_at: z.ZodString;
|
|
500
|
+
accepted_at: z.ZodNullable<z.ZodString>;
|
|
501
|
+
declined_at: z.ZodNullable<z.ZodString>;
|
|
502
|
+
decline_reason: z.ZodNullable<z.ZodString>;
|
|
503
|
+
retracted_at: z.ZodNullable<z.ZodString>;
|
|
504
|
+
superseded_at: z.ZodNullable<z.ZodString>;
|
|
505
|
+
resulting_role_grant_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
|
|
506
|
+
}, z.core.$strict>;
|
|
422
507
|
}, z.core.$strict>;
|
|
423
508
|
async: true;
|
|
424
509
|
description: string;
|
|
@@ -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;AAGxB,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AAiB3E,oEAAoE;AACpE,eAAO,MAAM,kCAAkC,EAAG,8BAAuC,CAAC;AAC1F,kEAAkE;AAClE,eAAO,MAAM,+BAA+B,EAAG,2BAAoC,CAAC;AACpF,sDAAsD;AACtD,eAAO,MAAM,8BAA8B,EAAG,0BAAmC,CAAC;AAClF,wGAAwG;AACxG,eAAO,MAAM,gCAAgC,EAAG,4BAAqC,CAAC;AACtF,uIAAuI;AACvI,eAAO,MAAM,yCAAyC,EACrD,qCAA8C,CAAC;AAChD,gKAAgK;AAChK,eAAO,MAAM,qCAAqC,EAAG,iCAA0C,CAAC;AAChG,6FAA6F;AAC7F,eAAO,MAAM,qCAAqC,EAAG,iCAA0C,CAAC;AAChG,wHAAwH;AACxH,eAAO,MAAM,6CAA6C,EACzD,yCAAkD,CAAC;AACpD;;;;GAIG;AACH,eAAO,MAAM,+BAA+B,EAAG,2BAAoC,CAAC;AACpF;;;;;;GAMG;AACH,eAAO,MAAM,gCAAgC,EAA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AM,CAAC;AAEtD;;;;GAIG;AACH,eAAO,MAAM,0BAA0B;;;;;mBAe1B,CAAC;AACd,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAEpF,4CAA4C;AAC5C,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;kBAErC,CAAC;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAEpF,4CAA4C;AAC5C,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;kBAIrC,CAAC;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAEpF,
|
|
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;AAGxB,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AAiB3E,oEAAoE;AACpE,eAAO,MAAM,kCAAkC,EAAG,8BAAuC,CAAC;AAC1F,kEAAkE;AAClE,eAAO,MAAM,+BAA+B,EAAG,2BAAoC,CAAC;AACpF,sDAAsD;AACtD,eAAO,MAAM,8BAA8B,EAAG,0BAAmC,CAAC;AAClF,wGAAwG;AACxG,eAAO,MAAM,gCAAgC,EAAG,4BAAqC,CAAC;AACtF,uIAAuI;AACvI,eAAO,MAAM,yCAAyC,EACrD,qCAA8C,CAAC;AAChD,gKAAgK;AAChK,eAAO,MAAM,qCAAqC,EAAG,iCAA0C,CAAC;AAChG,6FAA6F;AAC7F,eAAO,MAAM,qCAAqC,EAAG,iCAA0C,CAAC;AAChG,wHAAwH;AACxH,eAAO,MAAM,6CAA6C,EACzD,yCAAk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KAAK,CAAC,yBAAyB,CAS9E,CAAC"}
|
|
@@ -189,8 +189,10 @@ export const RoleGrantOfferAcceptOutput = z.strictObject({
|
|
|
189
189
|
offer: RoleGrantOfferJson,
|
|
190
190
|
superseded_offer_ids: z.array(Uuid)
|
|
191
191
|
});
|
|
192
|
-
/** Output for `role_grant_offer_decline`
|
|
193
|
-
export const
|
|
192
|
+
/** Output for `role_grant_offer_decline` — the declined offer, as `accept` answers its own. */
|
|
193
|
+
export const RoleGrantOfferDeclineOutput = z.strictObject({ offer: RoleGrantOfferJson });
|
|
194
|
+
/** Output for `role_grant_offer_retract` — the retracted offer, as `accept` answers its own. */
|
|
195
|
+
export const RoleGrantOfferRetractOutput = z.strictObject({ offer: RoleGrantOfferJson });
|
|
194
196
|
/** Output for `role_grant_offer_list`. */
|
|
195
197
|
export const RoleGrantOfferListOutput = z.strictObject({ offers: z.array(RoleGrantOfferJson) });
|
|
196
198
|
/** Output for `role_grant_offer_history`. */
|
|
@@ -239,12 +241,23 @@ export const RoleGrantAssignOutput = z.strictObject({
|
|
|
239
241
|
* `ERROR_ROLE_GRANT_OFFER_ACTOR_ACCOUNT_MISMATCH`) as an enumeration
|
|
240
242
|
* vector. Failure-outcome audit rows preserve the forensic trail; the
|
|
241
243
|
* rate cap closes the budget.
|
|
244
|
+
*
|
|
245
|
+
* `credential_types: ['session']` — see `docs/security.md` §Credential-channel
|
|
246
|
+
* gating. Offering spends the caller's authority to confer a role. Over a
|
|
247
|
+
* leaked API token that is a privilege pivot onto another account: the leak
|
|
248
|
+
* offers a role to an account its holder controls, that account accepts over
|
|
249
|
+
* its own session, and the resulting role_grant outlives revoking the token.
|
|
250
|
+
* Under a consumer `authorize` that delegates offering (a scoped holder
|
|
251
|
+
* offering roles in its scope), every such holder's token would be a
|
|
252
|
+
* role-minting credential. An offer is the grantor's consent act, as accepting
|
|
253
|
+
* is the recipient's; scripted conferral is `role_grant_assign`'s, admin-gated
|
|
254
|
+
* and narrowable by a token scope.
|
|
242
255
|
*/
|
|
243
256
|
export const role_grant_offer_create_action_spec = {
|
|
244
257
|
method: 'role_grant_offer_create',
|
|
245
258
|
kind: 'request_response',
|
|
246
259
|
initiator: 'frontend',
|
|
247
|
-
auth: { account: 'required', actor: 'required' },
|
|
260
|
+
auth: { account: 'required', actor: 'required', credential_types: ['session'] },
|
|
248
261
|
side_effects: true,
|
|
249
262
|
input: RoleGrantOfferCreateInput,
|
|
250
263
|
output: RoleGrantOfferCreateOutput,
|
|
@@ -265,14 +278,14 @@ export const role_grant_offer_create_action_spec = {
|
|
|
265
278
|
* without minting anything, so the account bucket is what bounds a loop of them.
|
|
266
279
|
*
|
|
267
280
|
* `credential_types: ['session']` — see `docs/security.md` §Credential-channel
|
|
268
|
-
* gating. The
|
|
269
|
-
*
|
|
270
|
-
*
|
|
271
|
-
*
|
|
272
|
-
*
|
|
273
|
-
*
|
|
274
|
-
*
|
|
275
|
-
*
|
|
281
|
+
* gating. The offer verb that moves the *caller's own* authority: accepting a
|
|
282
|
+
* pending admin offer over a leaked API token is a privilege pivot in the same
|
|
283
|
+
* family the credential-lifecycle mutations are gated to prevent (the token is
|
|
284
|
+
* account-wide and non-expiring, and the resulting role_grant outlives revoking
|
|
285
|
+
* it). Consent inherently belongs to a human at a browser, and no automation
|
|
286
|
+
* accepts an offer on its own behalf. `_create` carries the same gate (the
|
|
287
|
+
* grantor's side of the consent); `_decline` / `_retract` stay ungated
|
|
288
|
+
* deliberately — they destroy a pending offer and confer nothing.
|
|
276
289
|
*/
|
|
277
290
|
export const role_grant_offer_accept_action_spec = {
|
|
278
291
|
method: 'role_grant_offer_accept',
|
|
@@ -302,7 +315,7 @@ export const role_grant_offer_decline_action_spec = {
|
|
|
302
315
|
auth: { account: 'required', actor: 'required' },
|
|
303
316
|
side_effects: true,
|
|
304
317
|
input: RoleGrantOfferDeclineInput,
|
|
305
|
-
output:
|
|
318
|
+
output: RoleGrantOfferDeclineOutput,
|
|
306
319
|
async: true,
|
|
307
320
|
description: 'Decline an offer. Recipient-only.',
|
|
308
321
|
error_reasons: [ERROR_ROLE_GRANT_OFFER_NOT_FOUND, ERROR_ROLE_GRANT_OFFER_TERMINAL]
|
|
@@ -314,7 +327,7 @@ export const role_grant_offer_retract_action_spec = {
|
|
|
314
327
|
auth: { account: 'required', actor: 'required' },
|
|
315
328
|
side_effects: true,
|
|
316
329
|
input: RoleGrantOfferRetractInput,
|
|
317
|
-
output:
|
|
330
|
+
output: RoleGrantOfferRetractOutput,
|
|
318
331
|
async: true,
|
|
319
332
|
description: 'Retract an offer. Grantor-only, pre-decision.',
|
|
320
333
|
error_reasons: [ERROR_ROLE_GRANT_OFFER_NOT_FOUND, ERROR_ROLE_GRANT_OFFER_TERMINAL]
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Role grant offer RPC action handlers — the consentful-role-grants action surface.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* The offer-lifecycle methods (create / accept / decline / retract / list /
|
|
5
|
+
* history) plus `role_grant_revoke` and `role_grant_assign` (both
|
|
6
|
+
* admin-only). All mount
|
|
7
7
|
* on a consumer's JSON-RPC endpoint via `create_rpc_endpoint`. The action
|
|
8
8
|
* specs themselves live in `auth/role_grant_offer_action_specs.ts`. Mutations
|
|
9
9
|
* declare `side_effects: true` so the RPC dispatcher wraps the handler in
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
* @module
|
|
52
52
|
*/
|
|
53
53
|
import type { Logger } from '@fuzdev/fuz_util/log.ts';
|
|
54
|
-
import { type ActionContext, type RpcAction } from '../actions/
|
|
54
|
+
import { type ActionContext, type RpcAction } from '../actions/action_types.js';
|
|
55
55
|
import { type RoleSchemaResult } from './role_schema.js';
|
|
56
56
|
import { type RequestContext } from './request_context.js';
|
|
57
57
|
import type { ActionFactoryDeps } from './deps.js';
|
|
@@ -68,6 +68,12 @@ import { type NotificationSender } from './role_grant_offer_notifications.js';
|
|
|
68
68
|
* with no offer — runs it too, so a policy over which grants may exist (a
|
|
69
69
|
* role that must be scoped, a scope that must be real) holds on both paths.
|
|
70
70
|
* Twin of the Rust `OfferCreateAuthorize`.
|
|
71
|
+
*
|
|
72
|
+
* `ctx` is the request's: both verbs have side effects, so `ctx.db` is the
|
|
73
|
+
* request transaction, and a callback needing the database (a scope-existence
|
|
74
|
+
* check, say) reads through it. **Read-only** — the callback decides, it never
|
|
75
|
+
* writes; a write would commit or roll back with the request, and nothing
|
|
76
|
+
* enforces this but the callback.
|
|
71
77
|
*/
|
|
72
78
|
export type RoleGrantOfferCreateAuthorize = (auth: RequestContext, input: {
|
|
73
79
|
to_account_id: string;
|
|
@@ -100,10 +106,10 @@ export interface RoleGrantOfferActionOptions {
|
|
|
100
106
|
authorize?: RoleGrantOfferCreateAuthorize;
|
|
101
107
|
}
|
|
102
108
|
/**
|
|
103
|
-
* Create the
|
|
104
|
-
*
|
|
109
|
+
* Create the role-grant-offer RPC actions: the offer-lifecycle methods plus
|
|
110
|
+
* `role_grant_revoke` and the immediate `role_grant_assign`.
|
|
105
111
|
*
|
|
106
|
-
* @param deps - `ActionFactoryDeps` (`log`, `audit`) plus optional `notification_sender` for WS fan-out — when absent, WS fan-out is silently skipped (DB-only side effects still happen). Consumers wiring `
|
|
112
|
+
* @param deps - `ActionFactoryDeps` (`log`, `audit`) plus optional `notification_sender` for WS fan-out — when absent, WS fan-out is silently skipped (DB-only side effects still happen). Consumers wiring `ConnectionRegistry` assign its instance directly (the registry's `send_to_account` signature accepts the broader `JsonrpcMessageFromServerToClient`, which is contravariantly compatible)
|
|
107
113
|
* @param options - role schema, default TTL, authorization override
|
|
108
114
|
* @returns the `RpcAction` array to spread into a `create_rpc_endpoint` call
|
|
109
115
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role_grant_offer_actions.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/role_grant_offer_actions.ts"],"names":[],"mappings":"AAAA;;;;;;;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cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;;;;;;OAQG;IACH,SAAS,CAAC,EAAE,6BAA6B,CAAC;CAC1C;AA6CD;;;;;;;GAOG;AACH,eAAO,MAAM,+BAA+B,GAC3C,MAAM,iBAAiB,GAAG;IACzB,mBAAmB,CAAC,EAAE,kBAAkB,GAAG,IAAI,CAAC;CAChD,EACD,UAAS,2BAAgC,KACvC,KAAK,CAAC,SAAS,CAksBjB,CAAC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Role grant offer RPC action handlers — the consentful-role-grants action surface.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* The offer-lifecycle methods (create / accept / decline / retract / list /
|
|
5
|
+
* history) plus `role_grant_revoke` and `role_grant_assign` (both
|
|
6
|
+
* admin-only). All mount
|
|
7
7
|
* on a consumer's JSON-RPC endpoint via `create_rpc_endpoint`. The action
|
|
8
8
|
* specs themselves live in `auth/role_grant_offer_action_specs.ts`. Mutations
|
|
9
9
|
* declare `side_effects: true` so the RPC dispatcher wraps the handler in
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
*
|
|
51
51
|
* @module
|
|
52
52
|
*/
|
|
53
|
-
import { rpc_action } from '../actions/
|
|
53
|
+
import { rpc_action } from '../actions/action_types.js';
|
|
54
54
|
import { jsonrpc_errors } from '../http/jsonrpc_errors.js';
|
|
55
55
|
import { emit_after_commit } from '../http/pending_effects.js';
|
|
56
56
|
import { builtin_role_specs_by_name, is_builtin_role, ROLE_ADMIN, ROLE_KEEPER, role_has_grant_path } from './role_schema.js';
|
|
@@ -99,10 +99,10 @@ const default_authorize = async (auth, _input, _deps, _ctx) => {
|
|
|
99
99
|
};
|
|
100
100
|
// -- Action factory ---------------------------------------------------------
|
|
101
101
|
/**
|
|
102
|
-
* Create the
|
|
103
|
-
*
|
|
102
|
+
* Create the role-grant-offer RPC actions: the offer-lifecycle methods plus
|
|
103
|
+
* `role_grant_revoke` and the immediate `role_grant_assign`.
|
|
104
104
|
*
|
|
105
|
-
* @param deps - `ActionFactoryDeps` (`log`, `audit`) plus optional `notification_sender` for WS fan-out — when absent, WS fan-out is silently skipped (DB-only side effects still happen). Consumers wiring `
|
|
105
|
+
* @param deps - `ActionFactoryDeps` (`log`, `audit`) plus optional `notification_sender` for WS fan-out — when absent, WS fan-out is silently skipped (DB-only side effects still happen). Consumers wiring `ConnectionRegistry` assign its instance directly (the registry's `send_to_account` signature accepts the broader `JsonrpcMessageFromServerToClient`, which is contravariantly compatible)
|
|
106
106
|
* @param options - role schema, default TTL, authorization override
|
|
107
107
|
* @returns the `RpcAction` array to spread into a `create_rpc_endpoint` call
|
|
108
108
|
*/
|
|
@@ -191,7 +191,7 @@ export const create_role_grant_offer_actions = (deps, options = {}) => {
|
|
|
191
191
|
}
|
|
192
192
|
// Offering a builtin role is global-admin authority, decided here rather
|
|
193
193
|
// than by the injected callback: a consumer callback answering by holding
|
|
194
|
-
// the role (a scope-blind
|
|
194
|
+
// the role (a scope-blind check) would otherwise let a scoped `admin`
|
|
195
195
|
// row offer a global `admin` to a second account it controls. Same denial
|
|
196
196
|
// the default callback gives.
|
|
197
197
|
if (is_builtin_role(input.role) && !has_scoped_role(auth, ROLE_ADMIN, null)) {
|
|
@@ -372,17 +372,18 @@ export const create_role_grant_offer_actions = (deps, options = {}) => {
|
|
|
372
372
|
reason: input.reason ?? undefined
|
|
373
373
|
}
|
|
374
374
|
});
|
|
375
|
+
const offer_json = to_role_grant_offer_json(declined);
|
|
375
376
|
if (notification_sender) {
|
|
376
377
|
// Grantor's account_id rides on `declined.from_account_id` from
|
|
377
378
|
// the decline RETURNING — no second SELECT needed. The decline
|
|
378
379
|
// reason rides along on `offer.decline_reason` — the DB set it
|
|
379
380
|
// in the RETURNING above.
|
|
380
|
-
const offer_json = to_role_grant_offer_json(declined);
|
|
381
381
|
emit_after_commit(ctx, () => {
|
|
382
382
|
notification_sender.send_to_account(declined.from_account_id, build_role_grant_offer_declined_notification({ offer: offer_json }));
|
|
383
383
|
});
|
|
384
384
|
}
|
|
385
|
-
|
|
385
|
+
// the terminal offer, as accept answers its own
|
|
386
|
+
return { offer: offer_json };
|
|
386
387
|
};
|
|
387
388
|
const retract_handler = async (input, ctx) => {
|
|
388
389
|
const auth = ctx.auth;
|
|
@@ -413,13 +414,14 @@ export const create_role_grant_offer_actions = (deps, options = {}) => {
|
|
|
413
414
|
scope_id: retracted.scope_id
|
|
414
415
|
}
|
|
415
416
|
});
|
|
417
|
+
const offer_json = to_role_grant_offer_json(retracted);
|
|
416
418
|
if (notification_sender) {
|
|
417
|
-
const offer_json = to_role_grant_offer_json(retracted);
|
|
418
419
|
emit_after_commit(ctx, () => {
|
|
419
420
|
notification_sender.send_to_account(retracted.to_account_id, build_role_grant_offer_retracted_notification({ offer: offer_json }));
|
|
420
421
|
});
|
|
421
422
|
}
|
|
422
|
-
|
|
423
|
+
// the terminal offer, as accept answers its own
|
|
424
|
+
return { offer: offer_json };
|
|
423
425
|
};
|
|
424
426
|
const list_handler = async (input, ctx) => {
|
|
425
427
|
const auth = ctx.auth;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Role grant offer WebSocket notification specs, builders, and the narrow
|
|
3
3
|
* `NotificationSender` interface that decouples offer/revoke send sites
|
|
4
|
-
* from `
|
|
4
|
+
* from `ConnectionRegistry`.
|
|
5
5
|
*
|
|
6
6
|
* Six `RemoteNotificationActionSpec`s cover the consentful-role-grants
|
|
7
7
|
* lifecycle events the server pushes to affected accounts:
|
|
@@ -37,11 +37,11 @@ import type { JsonrpcNotification } from '../http/jsonrpc.js';
|
|
|
37
37
|
* Narrow structural capability for sending a JSON-RPC notification to every
|
|
38
38
|
* socket bound to an account.
|
|
39
39
|
*
|
|
40
|
-
* `
|
|
40
|
+
* `ConnectionRegistry` satisfies this interface — its
|
|
41
41
|
* `send_to_account(account_id, message)` signature accepts the broader
|
|
42
42
|
* `JsonrpcMessageFromServerToClient` type, which is contravariantly
|
|
43
43
|
* compatible with `JsonrpcNotification` here. The interface stays local so
|
|
44
|
-
* handlers don't couple to the concrete
|
|
44
|
+
* handlers don't couple to the concrete registry, and tests can inject a
|
|
45
45
|
* capturing stub with no WS machinery.
|
|
46
46
|
*
|
|
47
47
|
* Returns the number of sockets the notification was sent to — callers
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Role grant offer WebSocket notification specs, builders, and the narrow
|
|
3
3
|
* `NotificationSender` interface that decouples offer/revoke send sites
|
|
4
|
-
* from `
|
|
4
|
+
* from `ConnectionRegistry`.
|
|
5
5
|
*
|
|
6
6
|
* Six `RemoteNotificationActionSpec`s cover the consentful-role-grants
|
|
7
7
|
* lifecycle events the server pushes to affected accounts:
|
|
@@ -187,11 +187,6 @@ export declare const query_role_grant_offer_list: (deps: QueryDeps, to_account_i
|
|
|
187
187
|
* Includes terminal offers — used by the grantor-side admin / history view.
|
|
188
188
|
*/
|
|
189
189
|
export declare const query_role_grant_offer_history_for_account: (deps: QueryDeps, account_id: string, limit?: number, offset?: number) => Promise<Array<RoleGrantOffer>>;
|
|
190
|
-
/**
|
|
191
|
-
* Look up a pending offer by id. Returns `null` if the offer is terminal,
|
|
192
|
-
* expired (server-side filter), or missing.
|
|
193
|
-
*/
|
|
194
|
-
export declare const query_role_grant_offer_find_pending: (deps: QueryDeps, offer_id: string) => Promise<RoleGrantOffer | null>;
|
|
195
190
|
/**
|
|
196
191
|
* Claim the pending offers whose `expires_at` has passed and whose expiry has
|
|
197
192
|
* not been audited yet, stamping `expire_audited_at` on each, and return them
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role_grant_offer_queries.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/role_grant_offer_queries.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,yBAAyB,CAAC;AAE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