openrod 0.0.0 → 0.1.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/LICENSE +201 -0
- package/NOTICE +8 -0
- package/README.md +58 -2
- package/SETUPS.md +75 -0
- package/THIRD_PARTY_NOTICES.md +15823 -0
- package/dist/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
- package/dist/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
- package/dist/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
- package/dist/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
- package/dist/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
- package/dist/assets/index-CEZ0R3YS.js +522 -0
- package/dist/assets/index-DYjVZRjW.css +1 -0
- package/dist/assets/index.esm-BVqeoYDn.js +376 -0
- package/dist/assets/index.esm-CXAOoF3i.js +16 -0
- package/dist/assets/index.esm-D0s8MSqt.js +1666 -0
- package/dist/assets/pixelify-sans-cyrillic-wght-normal-BfQLqnEI.woff2 +0 -0
- package/dist/assets/pixelify-sans-latin-ext-wght-normal-CsF3XSp0.woff2 +0 -0
- package/dist/assets/pixelify-sans-latin-wght-normal-Cbhn5ptY.woff2 +0 -0
- package/dist/assets/terminal-view-6GBZ9nXN.css +32 -0
- package/dist/assets/terminal-view-CkPFNoXi.js +40 -0
- package/dist/favicon.png +0 -0
- package/dist/index.html +16 -0
- package/dist/logos/SOURCES.md +133 -0
- package/dist/logos/agents/aider.svg +1 -0
- package/dist/logos/agents/antigravity.svg +1 -0
- package/dist/logos/agents/claudecode.svg +1 -0
- package/dist/logos/agents/codex.svg +1 -0
- package/dist/logos/agents/copilot.svg +1 -0
- package/dist/logos/agents/cursor.svg +1 -0
- package/dist/logos/agents/factory.svg +1 -0
- package/dist/logos/agents/gemini.svg +1 -0
- package/dist/logos/agents/kiro.svg +1 -0
- package/dist/logos/agents/openclaw-color.svg +1 -0
- package/dist/logos/agents/opencode.svg +1 -0
- package/dist/logos/agents/pi.svg +1 -0
- package/dist/logos/anthropic.svg +1 -0
- package/dist/logos/aws-bedrock.svg +1 -0
- package/dist/logos/aws-s3.svg +1 -0
- package/dist/logos/aws.svg +1 -0
- package/dist/logos/claude-code.svg +1 -0
- package/dist/logos/codex.svg +1 -0
- package/dist/logos/copilot.svg +1 -0
- package/dist/logos/cursor.svg +1 -0
- package/dist/logos/deepinfra.svg +1 -0
- package/dist/logos/github.svg +1 -0
- package/dist/logos/google-cloud.svg +1 -0
- package/dist/logos/google-vertex-ai.svg +1 -0
- package/dist/logos/nvidia.svg +1 -0
- package/dist/logos/openai.svg +1 -0
- package/dist/logos/openrouter.svg +1 -0
- package/dist/logos/pypi.svg +1 -0
- package/dist/logos/templates/debian.svg +1 -0
- package/dist/logos/templates/nodejs.svg +1 -0
- package/dist/logos/templates/python.svg +1 -0
- package/dist/logos/templates/ubuntu.svg +1 -0
- package/dist/logos/vscode.svg +1 -0
- package/dist/openrod.png +0 -0
- package/node_modules/@bufbuild/protobuf/README.md +41 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/clone.d.ts +6 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/clone.js +66 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/boot.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/boot.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/enum.js +31 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/extension.js +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/file.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/file.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/index.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/message.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/message.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/service.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/symbols.d.ts +140 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/symbols.js +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/types.d.ts +79 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/boot.d.ts +63 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/boot.js +105 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/embed.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/embed.js +244 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/enum.d.ts +29 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/enum.js +58 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/extension.js +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/file.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/file.js +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/index.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/message.d.ts +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/message.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/restore-json-names.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/restore-json-names.js +29 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/scalar.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/scalar.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/service.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/symbols.d.ts +145 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/symbols.js +74 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/types.d.ts +85 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/create.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/create.js +296 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/descriptors.d.ts +634 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/descriptors.js +53 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/equals.d.ts +46 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/equals.js +209 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/extensions.d.ts +60 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/extensions.js +168 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/fields.d.ts +23 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/fields.js +45 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-binary.d.ts +48 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-binary.js +415 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-json.d.ts +73 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-json.js +1037 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/index.js +55 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/is-message.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/is-message.js +33 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/json-value.d.ts +16 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/json-value.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/merge.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/merge.js +70 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/package.json +4 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/proto-int64.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/proto-int64.js +131 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/error.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/error.js +36 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/guard.d.ts +20 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/guard.js +78 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/index.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/index.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/message.d.ts +49 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/message.js +157 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/names.d.ts +30 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/names.js +115 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/nested-types.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/nested-types.js +110 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/path.d.ts +107 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/path.js +376 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-check.d.ts +45 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-check.js +292 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-types.d.ts +217 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-types.js +16 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect.js +469 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/scalar.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/scalar.js +129 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/unsafe.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/unsafe.js +149 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/registry.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/registry.js +954 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-binary.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-binary.js +437 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-json.d.ts +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-json.js +625 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/from-text.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/from-text.js +684 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/index.d.ts +4 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/index.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/is-group-like.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/is-group-like.js +47 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/reader.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/reader.js +481 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/to-text.d.ts +34 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/to-text.js +358 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/writer.d.ts +76 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/writer.js +220 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/types.d.ts +135 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/unknown-enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/unknown-enum.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/base64-encoding.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/base64-encoding.js +188 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/binary-encoding.d.ts +286 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/binary-encoding.js +726 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/index.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/index.js +37 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/size-delimited.d.ts +69 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/size-delimited.js +191 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-encoding.d.ts +53 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-encoding.js +106 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-format.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-format.js +199 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/varint.d.ts +70 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/varint.js +334 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/any.d.ts +38 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/any.js +75 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/duration.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/duration.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/any_pb.d.ts +238 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/any_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/api_pb.d.ts +537 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/api_pb.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +490 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/compiler/plugin_pb.js +68 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/cpp_features_pb.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/cpp_features_pb.js +60 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/descriptor_pb.d.ts +4143 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/descriptor_pb.js +892 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/duration_pb.d.ts +161 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/duration_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/empty_pb.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/empty_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/field_mask_pb.d.ts +424 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/field_mask_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/go_features_pb.d.ts +189 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/go_features_pb.js +126 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/java_features_pb.d.ts +194 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/java_features_pb.js +106 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/source_context_pb.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/source_context_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/struct_pb.d.ts +195 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/struct_pb.js +59 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/timestamp_pb.d.ts +222 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/timestamp_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/type_pb.d.ts +722 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/type_pb.js +242 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/wrappers_pb.d.ts +330 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/wrappers_pb.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/index.js +48 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/json.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/json.js +44 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/timestamp.d.ts +21 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/timestamp.js +57 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/wrappers.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/wrappers.js +66 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/clone.d.ts +6 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/clone.js +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/boot.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/boot.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/enum.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/extension.js +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/file.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/file.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/index.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/message.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/message.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/service.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/symbols.d.ts +140 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/symbols.js +40 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/types.d.ts +79 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/boot.d.ts +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/boot.js +101 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/embed.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/embed.js +239 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/enum.d.ts +29 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/enum.js +53 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/extension.js +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/file.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/file.js +32 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/index.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/message.d.ts +15 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/message.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/restore-json-names.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/restore-json-names.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/scalar.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/scalar.js +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/service.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/symbols.d.ts +145 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/symbols.js +71 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/types.d.ts +85 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/create.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/create.js +293 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/descriptors.d.ts +634 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/descriptors.js +50 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/equals.d.ts +46 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/equals.js +206 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/extensions.d.ts +60 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/extensions.js +159 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/fields.d.ts +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/fields.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-binary.d.ts +48 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-binary.js +409 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-json.d.ts +73 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-json.js +1029 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/index.js +29 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/is-message.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/is-message.js +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/json-value.d.ts +16 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/json-value.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/merge.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/merge.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/package.json +4 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/proto-int64.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/proto-int64.js +128 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/error.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/error.js +31 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/guard.d.ts +20 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/guard.js +71 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/index.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/index.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/message.d.ts +49 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/message.js +152 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/names.d.ts +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/names.js +109 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/nested-types.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/nested-types.js +105 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/path.d.ts +107 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/path.js +369 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-check.d.ts +45 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-check.js +284 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-types.d.ts +217 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect.js +464 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/scalar.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/scalar.js +124 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/unsafe.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/unsafe.js +140 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/registry.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/registry.js +948 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-binary.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-binary.js +433 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-json.d.ts +67 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-json.js +620 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/from-text.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/from-text.js +680 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/index.d.ts +4 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/index.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/is-group-like.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/is-group-like.js +44 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/reader.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/reader.js +477 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/to-text.d.ts +34 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/to-text.js +355 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/writer.d.ts +76 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/writer.js +214 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/types.d.ts +135 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/unknown-enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/unknown-enum.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/base64-encoding.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/base64-encoding.js +184 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/binary-encoding.d.ts +286 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/binary-encoding.js +721 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/index.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/index.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/size-delimited.d.ts +69 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/size-delimited.js +186 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-encoding.d.ts +53 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-encoding.js +101 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-format.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-format.js +195 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/varint.d.ts +70 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/varint.js +325 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/any.d.ts +38 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/any.js +69 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/duration.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/duration.js +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/any_pb.d.ts +238 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/any_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/api_pb.d.ts +537 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/api_pb.js +36 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +490 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.js +65 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/cpp_features_pb.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/cpp_features_pb.js +57 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/descriptor_pb.d.ts +4143 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/descriptor_pb.js +888 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/duration_pb.d.ts +161 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/duration_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/empty_pb.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/empty_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/field_mask_pb.d.ts +424 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/field_mask_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/go_features_pb.d.ts +189 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/go_features_pb.js +123 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/java_features_pb.d.ts +194 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/java_features_pb.js +103 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/source_context_pb.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/source_context_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/struct_pb.d.ts +195 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/struct_pb.js +56 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/timestamp_pb.d.ts +222 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/timestamp_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/type_pb.d.ts +722 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/type_pb.js +239 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/wrappers_pb.d.ts +330 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/wrappers_pb.js +64 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/index.js +32 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/json.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/json.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/timestamp.d.ts +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/timestamp.js +50 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/wrappers.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/wrappers.js +61 -0
- package/node_modules/@bufbuild/protobuf/package.json +147 -0
- package/node_modules/@connectrpc/connect/README.md +62 -0
- package/node_modules/@connectrpc/connect/dist/cjs/any-client.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/any-client.js +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/call-options.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/call-options.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/callback-client.d.ts +31 -0
- package/node_modules/@connectrpc/connect/dist/cjs/callback-client.js +116 -0
- package/node_modules/@connectrpc/connect/dist/cjs/code.d.ts +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/code.js +92 -0
- package/node_modules/@connectrpc/connect/dist/cjs/connect-error.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/cjs/connect-error.js +141 -0
- package/node_modules/@connectrpc/connect/dist/cjs/context-values.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/context-values.js +41 -0
- package/node_modules/@connectrpc/connect/dist/cjs/cors.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/cjs/cors.js +82 -0
- package/node_modules/@connectrpc/connect/dist/cjs/http-headers.d.ts +37 -0
- package/node_modules/@connectrpc/connect/dist/cjs/http-headers.js +63 -0
- package/node_modules/@connectrpc/connect/dist/cjs/implementation.d.ts +159 -0
- package/node_modules/@connectrpc/connect/dist/cjs/implementation.js +78 -0
- package/node_modules/@connectrpc/connect/dist/cjs/index.d.ts +22 -0
- package/node_modules/@connectrpc/connect/dist/cjs/index.js +46 -0
- package/node_modules/@connectrpc/connect/dist/cjs/interceptor.d.ts +170 -0
- package/node_modules/@connectrpc/connect/dist/cjs/interceptor.js +30 -0
- package/node_modules/@connectrpc/connect/dist/cjs/package.json +1 -0
- package/node_modules/@connectrpc/connect/dist/cjs/promise-client.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/cjs/promise-client.js +135 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/async-iterable.d.ts +527 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/async-iterable.js +913 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/compression.d.ts +48 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/compression.js +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/content-type-matcher.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/content-type-matcher.js +43 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/create-method-url.d.ts +17 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/create-method-url.js +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/envelope.d.ts +90 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/envelope.js +214 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/index.d.ts +25 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/index.js +95 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/invoke-implementation.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/invoke-implementation.js +178 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/limit-io.d.ts +24 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/limit-io.js +80 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/normalize.d.ts +11 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/normalize.js +55 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-handler-factory.d.ts +18 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-handler-factory.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-headers.d.ts +9 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-headers.js +67 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/run-call.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/run-call.js +125 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/serialization.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/serialization.js +149 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/signals.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/signals.js +100 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/transport-options.d.ts +98 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/transport-options.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-fetch.d.ts +35 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-fetch.js +150 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler-client.d.ts +7 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler-client.js +88 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler.d.ts +167 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler.js +130 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal.d.ts +102 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal.js +78 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/code-string.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/code-string.js +52 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/content-type.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/content-type.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/end-stream.d.ts +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/end-stream.js +137 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/error-json.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/error-json.js +166 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/get-request.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/get-request.js +66 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/handler-factory.js +296 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/headers.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/headers.js +32 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/http-status.d.ts +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/http-status.js +90 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/index.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/index.js +81 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/parse-timeout.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/query-params.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/query-params.js +24 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/request-header.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/request-header.js +70 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/trailer-mux.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/trailer-mux.js +53 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/transport.js +210 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/validate-response.d.ts +30 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/validate-response.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/version.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/version.js +58 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/content-type.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/content-type.js +38 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/gen/status_pb.d.ts +91 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/gen/status_pb.js +27 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/handler-factory.js +124 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/headers.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/headers.js +29 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/http-status.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/http-status.js +46 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/index.d.ts +10 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/index.js +61 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/parse-timeout.js +53 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/request-header.js +56 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/trailer-status.d.ts +28 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/trailer-status.js +118 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/transport.js +185 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-response.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-response.js +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-trailer.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-trailer.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/content-type.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/content-type.js +41 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/handler-factory.js +130 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/headers.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/headers.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/index.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/index.js +61 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/request-header.js +59 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/trailer.d.ts +27 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/trailer.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/transport.js +234 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/validate-response.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/validate-response.js +73 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router-transport.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router-transport.js +32 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router.d.ts +81 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router.js +68 -0
- package/node_modules/@connectrpc/connect/dist/cjs/transport.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/transport.js +15 -0
- package/node_modules/@connectrpc/connect/dist/esm/any-client.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/any-client.js +30 -0
- package/node_modules/@connectrpc/connect/dist/esm/call-options.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/call-options.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/callback-client.d.ts +31 -0
- package/node_modules/@connectrpc/connect/dist/esm/callback-client.js +113 -0
- package/node_modules/@connectrpc/connect/dist/esm/code.d.ts +75 -0
- package/node_modules/@connectrpc/connect/dist/esm/code.js +89 -0
- package/node_modules/@connectrpc/connect/dist/esm/connect-error.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/esm/connect-error.js +137 -0
- package/node_modules/@connectrpc/connect/dist/esm/context-values.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/context-values.js +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/cors.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/esm/cors.js +79 -0
- package/node_modules/@connectrpc/connect/dist/esm/http-headers.d.ts +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/http-headers.js +58 -0
- package/node_modules/@connectrpc/connect/dist/esm/implementation.d.ts +159 -0
- package/node_modules/@connectrpc/connect/dist/esm/implementation.js +73 -0
- package/node_modules/@connectrpc/connect/dist/esm/index.d.ts +22 -0
- package/node_modules/@connectrpc/connect/dist/esm/index.js +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/interceptor.d.ts +170 -0
- package/node_modules/@connectrpc/connect/dist/esm/interceptor.js +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/promise-client.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/promise-client.js +128 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/async-iterable.d.ts +527 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/async-iterable.js +891 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/compression.d.ts +48 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/compression.js +71 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/content-type-matcher.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/content-type-matcher.js +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/create-method-url.d.ts +17 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/create-method-url.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/envelope.d.ts +90 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/envelope.js +206 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/index.d.ts +25 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/index.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/invoke-implementation.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/invoke-implementation.js +173 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/limit-io.d.ts +24 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/limit-io.js +75 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/normalize.d.ts +11 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/normalize.js +51 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-handler-factory.d.ts +18 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-handler-factory.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-headers.d.ts +9 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-headers.js +64 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/run-call.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/run-call.js +121 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/serialization.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/serialization.js +141 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/signals.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/signals.js +95 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/transport-options.d.ts +98 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/transport-options.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-fetch.d.ts +35 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-fetch.js +142 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler-client.d.ts +7 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler-client.js +85 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler.d.ts +167 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler.js +124 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal.d.ts +102 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal.js +74 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/code-string.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/code-string.js +48 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/content-type.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/content-type.js +66 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/end-stream.d.ts +44 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/end-stream.js +131 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/error-json.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/error-json.js +160 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/get-request.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/get-request.js +63 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/handler-factory.js +293 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/headers.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/headers.js +29 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/http-status.d.ts +15 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/http-status.js +86 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/index.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/index.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/parse-timeout.js +41 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/query-params.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/query-params.js +21 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/request-header.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/request-header.js +66 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/trailer-mux.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/trailer-mux.js +49 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/transport.js +207 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/validate-response.d.ts +30 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/validate-response.js +67 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/version.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/version.js +53 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/content-type.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/content-type.js +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/gen/status_pb.d.ts +91 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/gen/status_pb.js +24 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/handler-factory.js +121 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/headers.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/headers.js +26 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/http-status.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/http-status.js +43 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/index.d.ts +10 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/index.js +28 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/parse-timeout.js +50 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/request-header.js +52 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/trailer-status.d.ts +28 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/trailer-status.js +113 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/transport.js +182 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-response.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-response.js +71 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-trailer.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-trailer.js +41 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/content-type.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/content-type.js +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/handler-factory.js +127 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/headers.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/headers.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/index.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/index.js +26 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/request-header.js +55 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/trailer.d.ts +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/trailer.js +65 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/transport.js +231 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/validate-response.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/validate-response.js +69 -0
- package/node_modules/@connectrpc/connect/dist/esm/router-transport.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/router-transport.js +29 -0
- package/node_modules/@connectrpc/connect/dist/esm/router.d.ts +81 -0
- package/node_modules/@connectrpc/connect/dist/esm/router.js +65 -0
- package/node_modules/@connectrpc/connect/dist/esm/transport.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/transport.js +14 -0
- package/node_modules/@connectrpc/connect/package.json +67 -0
- package/node_modules/@connectrpc/connect-node/README.md +144 -0
- package/node_modules/@connectrpc/connect-node/buf.gen.yaml +10 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/compression.d.ts +15 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/compression.js +96 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-node-adapter.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-node-adapter.js +60 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-transport.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-transport.js +25 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-transport.d.ts +95 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-transport.js +24 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-web-transport.d.ts +96 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-web-transport.js +25 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/http2-session-manager.d.ts +146 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/http2-session-manager.js +543 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/index.d.ts +14 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/index.js +34 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-error.d.ts +45 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-error.js +153 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-transport-options.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-transport-options.js +58 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-client.d.ts +54 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-client.js +347 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-handler.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-handler.js +225 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-header.d.ts +20 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-header.js +117 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/package.json +1 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/compression.d.ts +15 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/compression.js +93 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-node-adapter.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-node-adapter.js +57 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-transport.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-transport.js +22 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-transport.d.ts +95 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-transport.js +21 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-web-transport.d.ts +96 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-web-transport.js +22 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/http2-session-manager.d.ts +146 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/http2-session-manager.js +539 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/index.d.ts +14 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/index.js +21 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-error.d.ts +45 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-error.js +146 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-transport-options.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-transport-options.js +55 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-client.d.ts +54 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-client.js +344 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-handler.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-handler.js +221 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-header.d.ts +20 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-header.js +113 -0
- package/node_modules/@connectrpc/connect-node/package.json +44 -0
- package/node_modules/@nvidia/openshell-sdk/README.md +303 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.d.ts +1243 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.js +1321 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.d.ts +35 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.js +79 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.d.ts +301 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.js +69 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.d.ts +581 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.js +90 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.d.ts +9131 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.js +1898 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.d.ts +58 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.js +24 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.d.ts +1203 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.js +277 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.d.ts +7 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.js +6 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.d.ts +14 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.js +177 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.d.ts +6 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.js +15 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.d.ts +11 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.js +58 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.d.ts +35 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.js +97 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/package.json +58 -0
- package/package.json +93 -4
- package/server/activity-delivery.js +143 -0
- package/server/activity-store.js +168 -0
- package/server/agent-inventory.js +76 -0
- package/server/agent-resources.py +60 -0
- package/server/api.js +648 -0
- package/server/cli.js +168 -0
- package/server/cloud-connections.js +56 -0
- package/server/cloud-origin.js +11 -0
- package/server/cloud-proxy.js +122 -0
- package/server/cloud-ssh-proxy.cjs +73 -0
- package/server/cloud-ssh.js +135 -0
- package/server/cloud-transfer.js +221 -0
- package/server/compute.js +50 -0
- package/server/editor.js +114 -0
- package/server/egress.js +204 -0
- package/server/files.js +489 -0
- package/server/gateway-install.js +64 -0
- package/server/gateway.js +415 -0
- package/server/image-templates.js +393 -0
- package/server/ingress.js +185 -0
- package/server/launch-token.js +55 -0
- package/server/local-catalog.js +111 -0
- package/server/local-cloud-native.js +152 -0
- package/server/local-cloud.js +123 -0
- package/server/location-inventory.js +94 -0
- package/server/machines.js +84 -0
- package/server/openshell-cli.js +144 -0
- package/server/org.js +536 -0
- package/server/orphan-processes.js +42 -0
- package/server/paths.js +28 -0
- package/server/policy-template-store.js +92 -0
- package/server/policy.js +583 -0
- package/server/remote-gateway-state.js +123 -0
- package/server/remote-gateway.js +420 -0
- package/server/remote-hosts.js +354 -0
- package/server/remote-http.js +14 -0
- package/server/remote-image-engine.js +47 -0
- package/server/remote-runtime.js +65 -0
- package/server/remote-runtime.py +162 -0
- package/server/sandbox-identity.js +14 -0
- package/server/security.js +139 -0
- package/server/session-revocations.js +20 -0
- package/server/setup-artifact-installer.py +54 -0
- package/server/setup-artifacts.js +23 -0
- package/server/setup-auth-discovery.js +24 -0
- package/server/setup-credentials.js +54 -0
- package/server/setup-deployment.js +299 -0
- package/server/setup-discovery.js +289 -0
- package/server/setup-egress.js +133 -0
- package/server/setup-http.js +47 -0
- package/server/setup-installer.py +289 -0
- package/server/setup-json.py +8 -0
- package/server/setup-members.js +77 -0
- package/server/setup-packages.js +214 -0
- package/server/setup-preparation.js +144 -0
- package/server/setup-python.js +8 -0
- package/server/setup-remote-check.js +35 -0
- package/server/setup-transfer.js +17 -0
- package/server/setup-verifier.cjs +43 -0
- package/server/setups.js +172 -0
- package/server/ssh-hosts.js +184 -0
- package/server/ssh.js +153 -0
- package/server/start.js +71 -0
- package/server/terminal.js +173 -0
- package/server/worker-auth.js +18 -0
- package/shared/agent-access.js +103 -0
- package/shared/antigravity-network-guidance.js +9 -0
- package/shared/group-membership.js +33 -0
- package/shared/group-network.js +29 -0
- package/shared/policy-templates.js +79 -0
- package/shared/secret-fields.js +35 -0
- package/shared/setup-launch.js +25 -0
- package/shared/setup-targets.js +11 -0
- package/shared/setup-targets.json +12 -0
- package/src/lib/activity-export.js +52 -0
- package/src/lib/activity-inventory.js +45 -0
- package/src/lib/agents.js +41 -0
- package/src/lib/api.js +173 -0
- package/src/lib/cloud-machine.js +9 -0
- package/src/lib/cloud-origin.js +6 -0
- package/src/lib/cloud-transfer.js +22 -0
- package/src/lib/compute-target.js +46 -0
- package/src/lib/delete-network-policies.js +15 -0
- package/src/lib/egress-groups.js +24 -0
- package/src/lib/egress.js +28 -0
- package/src/lib/files.js +24 -0
- package/src/lib/fleet.js +100 -0
- package/src/lib/format.js +24 -0
- package/src/lib/groups.js +16 -0
- package/src/lib/image-templates.js +139 -0
- package/src/lib/import-setup.js +36 -0
- package/src/lib/local-cloud.js +118 -0
- package/src/lib/location-inventory.js +20 -0
- package/src/lib/locations.js +5 -0
- package/src/lib/placement.js +9 -0
- package/src/lib/policy-editor.js +58 -0
- package/src/lib/policy-sources.js +33 -0
- package/src/lib/quick-setup.js +110 -0
- package/src/lib/sandbox-creations.js +59 -0
- package/src/lib/sandbox-images.js +38 -0
- package/src/lib/sandbox-session.js +140 -0
- package/src/lib/sandboxes.js +78 -0
- package/src/lib/secret-inventory.js +26 -0
- package/src/lib/services.js +41 -0
- package/src/lib/setup-import-jobs.js +62 -0
- package/src/lib/setup-imports.js +4 -0
- package/src/lib/setup-network.js +39 -0
- package/src/lib/setup-template-build.js +17 -0
- package/src/lib/utils.js +6 -0
- package/vendor/OPENSHELL-LICENSE +203 -0
- package/vendor/nvidia-openshell-sdk-0.0.0.tgz +0 -0
package/server/policy.js
ADDED
|
@@ -0,0 +1,583 @@
|
|
|
1
|
+
import { createTemplateStore } from './policy-template-store.js'
|
|
2
|
+
import { BUILTIN_TEMPLATES, normalizeAccessTemplates } from '../shared/policy-templates.js'
|
|
3
|
+
export { BUILTIN_TEMPLATES } from '../shared/policy-templates.js'
|
|
4
|
+
import { validateSecretCredentials } from '../shared/secret-fields.js'
|
|
5
|
+
import { randomUUID } from 'node:crypto'
|
|
6
|
+
import { execFile } from 'node:child_process'
|
|
7
|
+
import { promisify } from 'node:util'
|
|
8
|
+
import { gateway, iso, policyView, providerView, sandboxView } from './gateway.js'
|
|
9
|
+
import { policyDirectory } from './paths.js'
|
|
10
|
+
import { blockedBy, isManaged, managedOpsFor, readOrg, serializeOrgWrite } from './org.js'
|
|
11
|
+
|
|
12
|
+
const exec = promisify(execFile)
|
|
13
|
+
const fail = (message, status = 400) => Object.assign(new Error(message), { status })
|
|
14
|
+
|
|
15
|
+
// ---- rule specs: the console's own small JSON shape → proto ---------------
|
|
16
|
+
//
|
|
17
|
+
// A rule is { name, binaries: [path], endpoints: [{ host, ports, protocol,
|
|
18
|
+
// access | allow/deny, enforcement, allowedIps }] }. It is validated here
|
|
19
|
+
// rather than trusted from the browser, and the gateway validates it again.
|
|
20
|
+
|
|
21
|
+
const RULE_NAME = /^[a-z0-9][a-z0-9_-]{0,63}$/
|
|
22
|
+
const HOST = /^(\*\*?\.)?[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i
|
|
23
|
+
const BINARY = /^\/[\w.+@*?/[\]-]{1,255}$/
|
|
24
|
+
const PROTOCOLS = ['tcp', 'rest', 'websocket', 'graphql', 'mcp', 'json-rpc']
|
|
25
|
+
const L7_PROTOCOLS = PROTOCOLS.filter((p) => p !== 'tcp')
|
|
26
|
+
const ACCESS = { 'read-only': 1, 'read-write': 2, full: 3 }
|
|
27
|
+
const METHODS = ['GET', 'HEAD', 'OPTIONS', 'POST', 'PUT', 'PATCH', 'DELETE', '*']
|
|
28
|
+
const CIDR = /^[0-9a-f:.]+(\/\d{1,3})?$/i
|
|
29
|
+
|
|
30
|
+
function l7Match(input, where) {
|
|
31
|
+
const method = String(input.method ?? '').toUpperCase()
|
|
32
|
+
const pathGlob = String(input.path ?? '')
|
|
33
|
+
if (!METHODS.includes(method)) throw fail(`${where}: unsupported method "${input.method}".`)
|
|
34
|
+
if (!pathGlob.startsWith('/') || pathGlob.length > 512) throw fail(`${where}: a path must start with "/".`)
|
|
35
|
+
return { method, path: pathGlob }
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function ruleToProto(spec) {
|
|
39
|
+
const name = String(spec.name ?? '').trim()
|
|
40
|
+
if (!RULE_NAME.test(name)) throw fail('Rule names use lowercase letters, digits, "-" and "_".')
|
|
41
|
+
if (name.startsWith('_provider_')) throw fail('Names starting with _provider_ are reserved for secrets.')
|
|
42
|
+
const binaries = (spec.binaries ?? []).map(String)
|
|
43
|
+
if (!binaries.length) throw fail('Choose at least one program. A rule with no programs matches nothing.')
|
|
44
|
+
for (const b of binaries) if (!BINARY.test(b)) throw fail(`"${b}" is not an absolute program path.`)
|
|
45
|
+
const endpoints = (spec.endpoints ?? []).map((e, i) => {
|
|
46
|
+
const where = `Destination ${i + 1}`
|
|
47
|
+
const host = String(e.host ?? '').trim().toLowerCase()
|
|
48
|
+
if (!HOST.test(host)) throw fail(`${where}: "${e.host}" is not a host name (wildcards: *.example.com or **.example.com).`)
|
|
49
|
+
const ports = (e.ports ?? []).map(Number)
|
|
50
|
+
if (!ports.length || ports.some((p) => !Number.isInteger(p) || p < 1 || p > 65535)) throw fail(`${where}: ports must be 1–65535.`)
|
|
51
|
+
const protocol = e.protocol ?? 'tcp'
|
|
52
|
+
if (!PROTOCOLS.includes(protocol)) throw fail(`${where}: unknown protocol.`)
|
|
53
|
+
const allow = (e.allow ?? []).map((r) => l7Match(r, where))
|
|
54
|
+
const deny = (e.deny ?? []).map((r) => l7Match(r, where))
|
|
55
|
+
const access = e.access && !allow.length ? ACCESS[e.access] : 0
|
|
56
|
+
if (protocol === 'tcp' && (allow.length || deny.length || access)) throw fail(`${where}: plain TCP cannot inspect requests. Pick an HTTP protocol to add request rules.`)
|
|
57
|
+
if (e.tlsSkip && protocol !== 'tcp') throw fail(`${where}: TLS passthrough requires plain TCP without request inspection.`)
|
|
58
|
+
if (L7_PROTOCOLS.includes(protocol) && !access && !allow.length) throw fail(`${where}: choose an access level or add at least one allowed request.`)
|
|
59
|
+
const allowedIps = (e.allowedIps ?? []).map(String).filter(Boolean)
|
|
60
|
+
for (const ip of allowedIps) if (!CIDR.test(ip)) throw fail(`${where}: "${ip}" is not an IP or CIDR.`)
|
|
61
|
+
return {
|
|
62
|
+
host,
|
|
63
|
+
...(ports.length === 1 ? { port: ports[0] } : { ports }),
|
|
64
|
+
protocol: protocol === 'tcp' ? '' : protocol,
|
|
65
|
+
...(e.tlsSkip ? { tls: 1 } : {}),
|
|
66
|
+
enforcement: e.enforcement === 'audit' ? 2 : 1,
|
|
67
|
+
access,
|
|
68
|
+
rules: allow.map((a) => ({ allow: a })),
|
|
69
|
+
denyRules: deny,
|
|
70
|
+
allowedIps,
|
|
71
|
+
}
|
|
72
|
+
})
|
|
73
|
+
if (!endpoints.length) throw fail('Add at least one destination.')
|
|
74
|
+
return { name, rule: { name, endpoints, binaries: binaries.map((p) => ({ path: p })) } }
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// ---- sandbox policy ---------------------------------------------------------
|
|
78
|
+
|
|
79
|
+
const REVISION_STATUS = ['unspecified', 'pending', 'loaded', 'failed', 'superseded']
|
|
80
|
+
const SOURCE = ['unspecified', 'sandbox', 'global']
|
|
81
|
+
|
|
82
|
+
function revisionView(r) {
|
|
83
|
+
return {
|
|
84
|
+
version: r.version,
|
|
85
|
+
hash: r.policyHash,
|
|
86
|
+
status: REVISION_STATUS[r.status] ?? 'unspecified',
|
|
87
|
+
loadError: r.loadError || null,
|
|
88
|
+
createdAt: iso(r.createdTime),
|
|
89
|
+
loadedAt: iso(r.loadedTime),
|
|
90
|
+
provenance: r.provenance ?? {},
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
async function policyOf(sandbox) {
|
|
95
|
+
const { client, workspaceScope } = await gateway()
|
|
96
|
+
const [status, config, list] = await Promise.all([
|
|
97
|
+
client.raw.getSandboxPolicyStatus({ sandbox, workspaceScope: workspaceScope }),
|
|
98
|
+
client.raw.getSandboxConfig({ name: sandbox, workspaceScope: workspaceScope }),
|
|
99
|
+
client.raw.listSandboxPolicies({ sandbox, workspaceScope: workspaceScope, pageSize: 50 }),
|
|
100
|
+
])
|
|
101
|
+
return {
|
|
102
|
+
sandbox,
|
|
103
|
+
source: SOURCE[config.policySource] ?? 'sandbox',
|
|
104
|
+
activeVersion: status.activeVersion,
|
|
105
|
+
latest: status.revision ? revisionView(status.revision) : null,
|
|
106
|
+
// Base: what this console edits. Effective: base + one rule per attached secret.
|
|
107
|
+
base: policyView(status.revision?.policy),
|
|
108
|
+
effective: policyView(config.policy),
|
|
109
|
+
admitted: config.configurationAdmitted,
|
|
110
|
+
configurationError: config.configurationError || null,
|
|
111
|
+
failureMode: config.policyValidationFailureMode || null,
|
|
112
|
+
globalPolicyVersion: config.globalPolicyVersion || 0,
|
|
113
|
+
revisions: list.revisions.map(revisionView),
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// Every sandbox's effective rules in one reading, for the fleet summary.
|
|
118
|
+
async function fleet() {
|
|
119
|
+
const { client, workspaceScope } = await gateway()
|
|
120
|
+
const list = await client.raw.listSandboxes({ workspaceScope: workspaceScope })
|
|
121
|
+
const sandboxes = list.sandboxes.map(sandboxView).filter((s) => s.phase !== 'deleting')
|
|
122
|
+
const rows = await Promise.all(sandboxes.map(async (s) => {
|
|
123
|
+
try {
|
|
124
|
+
const [config, status] = await Promise.all([
|
|
125
|
+
client.raw.getSandboxConfig({ name: s.name, workspaceScope: workspaceScope }),
|
|
126
|
+
client.raw.getSandboxPolicyStatus({ sandbox: s.name, workspaceScope: workspaceScope }),
|
|
127
|
+
])
|
|
128
|
+
return {
|
|
129
|
+
name: s.name, phase: s.phase, labels: s.labels,
|
|
130
|
+
source: SOURCE[config.policySource] ?? 'sandbox',
|
|
131
|
+
version: status.revision?.version ?? null,
|
|
132
|
+
status: status.revision ? REVISION_STATUS[status.revision.status] ?? 'unspecified' : null,
|
|
133
|
+
rules: policyView(config.policy)?.rules ?? [],
|
|
134
|
+
}
|
|
135
|
+
} catch (error) {
|
|
136
|
+
return { name: s.name, phase: s.phase, labels: s.labels, error: error.rawMessage ?? error.message, rules: [] }
|
|
137
|
+
}
|
|
138
|
+
}))
|
|
139
|
+
return { sandboxes: rows }
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
async function revisionPolicy(sandbox, version) {
|
|
143
|
+
const { client, workspaceScope } = await gateway()
|
|
144
|
+
const status = await client.raw.getSandboxPolicyStatus({ sandbox, version, workspaceScope: workspaceScope })
|
|
145
|
+
return { revision: revisionView(status.revision), policy: status.revision.policy }
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
// UI operations → the gateway's server-side patch operations. Each targets
|
|
149
|
+
// the base policy; the gateway rejects anything that would not validate.
|
|
150
|
+
function mergeOp(op) {
|
|
151
|
+
const ruleName = String(op.ruleName ?? '')
|
|
152
|
+
if (op.kind !== 'addRule' && !RULE_NAME.test(ruleName)) throw fail('Unknown rule.')
|
|
153
|
+
// Policy and organization rules are changed where they are defined, so one
|
|
154
|
+
// sandbox cannot drift from the policies that apply to it.
|
|
155
|
+
const target = op.kind === 'addRule' ? String(op.rule?.name ?? '') : ruleName
|
|
156
|
+
if (isManaged(target)) throw fail('This rule comes from a network rule or the organization. Change it on the Network page.', 403)
|
|
157
|
+
switch (op.kind) {
|
|
158
|
+
case 'addRule': {
|
|
159
|
+
const { name, rule } = ruleToProto(op.rule)
|
|
160
|
+
return { operation: { case: 'addRule', value: { ruleName: name, rule } } }
|
|
161
|
+
}
|
|
162
|
+
case 'removeRule':
|
|
163
|
+
return { operation: { case: 'removeRule', value: { ruleName } } }
|
|
164
|
+
case 'removeEndpoint': {
|
|
165
|
+
const host = String(op.host ?? '')
|
|
166
|
+
if (!HOST.test(host)) throw fail('Unknown destination.')
|
|
167
|
+
return { operation: { case: 'removeEndpoint', value: { ruleName, host, port: Number(op.port) || 0 } } }
|
|
168
|
+
}
|
|
169
|
+
case 'removeBinary':
|
|
170
|
+
if (!BINARY.test(String(op.binary))) throw fail('Unknown program.')
|
|
171
|
+
return { operation: { case: 'removeBinary', value: { ruleName, binaryPath: op.binary } } }
|
|
172
|
+
case 'addAllow':
|
|
173
|
+
case 'addDeny': {
|
|
174
|
+
const host = String(op.host ?? '')
|
|
175
|
+
const ports = (op.ports ?? []).map(Number)
|
|
176
|
+
const binaries = (op.binaries ?? []).map(String)
|
|
177
|
+
if (!HOST.test(host) || !ports.length || !binaries.length) throw fail('Unknown destination.')
|
|
178
|
+
const match = l7Match(op.match ?? {}, 'Request rule')
|
|
179
|
+
// The gateway requires the rule's complete program list, so a new
|
|
180
|
+
// permission can never quietly reach a program the operator didn't name.
|
|
181
|
+
const target = { ruleName, host, ports, binaries: binaries.map((p) => ({ path: p })) }
|
|
182
|
+
return op.kind === 'addAllow'
|
|
183
|
+
? { operation: { case: 'addAllowRules', value: { target, rules: [{ allow: match }] } } }
|
|
184
|
+
: { operation: { case: 'addDenyRules', value: { target, denyRules: [match] } } }
|
|
185
|
+
}
|
|
186
|
+
default:
|
|
187
|
+
throw fail('Unknown operation.')
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
function applyOps(sandbox, ops) {
|
|
192
|
+
return serializeOrgWrite(() => applyOpsWhileLocked(sandbox, ops))
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
async function applyOpsWhileLocked(sandbox, ops) {
|
|
196
|
+
if (!Array.isArray(ops) || !ops.length || ops.length > 20) throw fail('Nothing to apply.')
|
|
197
|
+
const org = await readOrg()
|
|
198
|
+
for (const op of ops) {
|
|
199
|
+
const hosts = op.kind === 'addRule' ? (op.rule?.endpoints ?? []).map((e) => e.host) : op.kind === 'addAllow' ? [op.host] : []
|
|
200
|
+
const hit = blockedBy(org, hosts)
|
|
201
|
+
if (hit) throw fail(`${hit.host} is blocked by organization policy (${hit.pattern}).`, 403)
|
|
202
|
+
}
|
|
203
|
+
const { client, target, workspaceScope } = await gateway()
|
|
204
|
+
// A block covers every port the sandbox opens, so a rule that opens a new
|
|
205
|
+
// port takes the recomputed blocks along in the same revision.
|
|
206
|
+
const opened = ops.flatMap((op) => (op.kind === 'addRule' ? (op.rule?.endpoints ?? []).flatMap((e) => e.ports ?? []) : ['addAllow', 'addDeny'].includes(op.kind) ? op.ports ?? [] : [])).map(Number)
|
|
207
|
+
const managed = opened.some((p) => ![443, 80].includes(p)) ? await managedOpsFor(client, workspaceScope, sandbox, opened, target.endpoint) : []
|
|
208
|
+
const response = await client.raw.updateConfig({
|
|
209
|
+
sandbox, workspaceScope: workspaceScope, global: false,
|
|
210
|
+
mergeOperations: [...ops.map(mergeOp), ...managed],
|
|
211
|
+
annotations: { 'console.openshell/change': ops.map((o) => `${o.kind}:${o.ruleName ?? o.rule?.name ?? ''}`).join(',').slice(0, 200) },
|
|
212
|
+
requestId: randomUUID(),
|
|
213
|
+
})
|
|
214
|
+
return { version: response.version, hash: response.policyHash }
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
// Restoring sends the old revision's complete policy. Static fields (files,
|
|
218
|
+
// landlock, process) are identical across a sandbox's revisions, so only the
|
|
219
|
+
// network section actually changes.
|
|
220
|
+
async function restore(sandbox, version) {
|
|
221
|
+
const { client, workspaceScope } = await gateway()
|
|
222
|
+
const { policy } = await revisionPolicy(sandbox, version)
|
|
223
|
+
const response = await client.raw.updateConfig({
|
|
224
|
+
sandbox, workspaceScope: workspaceScope, global: false, policy,
|
|
225
|
+
annotations: { 'console.openshell/change': `restore:v${version}` },
|
|
226
|
+
requestId: randomUUID(),
|
|
227
|
+
})
|
|
228
|
+
return { version: response.version, hash: response.policyHash }
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
async function globalPolicy() {
|
|
232
|
+
const { client } = await gateway()
|
|
233
|
+
const list = await client.raw.listSandboxPolicies({ global: true, pageSize: 50 })
|
|
234
|
+
let active = null
|
|
235
|
+
if (list.revisions.length) {
|
|
236
|
+
const status = await client.raw.getSandboxPolicyStatus({ global: true }).catch(() => null)
|
|
237
|
+
active = status?.revision ? { revision: revisionView(status.revision), policy: policyView(status.revision.policy) } : null
|
|
238
|
+
}
|
|
239
|
+
const config = await client.raw.getGatewayConfig({})
|
|
240
|
+
return {
|
|
241
|
+
active: Boolean(active && config.settings?.policy),
|
|
242
|
+
current: active,
|
|
243
|
+
revisions: list.revisions.map(revisionView),
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
async function removeGlobal() {
|
|
248
|
+
const { client } = await gateway()
|
|
249
|
+
await client.raw.updateConfig({ global: true, settingKey: 'policy', deleteSetting: true, requestId: randomUUID() })
|
|
250
|
+
return { ok: true }
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
// ---- guardrail settings -----------------------------------------------------
|
|
254
|
+
|
|
255
|
+
export const SETTINGS = {
|
|
256
|
+
ocsf_json_enabled: { type: 'bool', default: false },
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
const settingValue = (v) => (v?.value?.case ? v.value.value : null)
|
|
260
|
+
|
|
261
|
+
async function settings(sandbox) {
|
|
262
|
+
const { client, workspaceScope } = await gateway()
|
|
263
|
+
const globalConfig = await client.raw.getGatewayConfig({})
|
|
264
|
+
const global = Object.fromEntries(Object.keys(SETTINGS).map((key) => [key, settingValue(globalConfig.settings?.[key])]))
|
|
265
|
+
if (!sandbox) return { global }
|
|
266
|
+
const config = await client.raw.getSandboxConfig({ name: sandbox, workspaceScope: workspaceScope })
|
|
267
|
+
const effective = Object.fromEntries(Object.keys(SETTINGS).map((key) => {
|
|
268
|
+
const entry = config.settings?.[key]
|
|
269
|
+
return [key, { value: settingValue(entry?.value), scope: ['default', 'sandbox', 'global'][entry?.scope ?? 0] ?? 'default' }]
|
|
270
|
+
}))
|
|
271
|
+
return { global, sandbox: effective }
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
async function setSetting({ sandbox, key, value, clear }) {
|
|
275
|
+
const spec = SETTINGS[key]
|
|
276
|
+
if (!spec) throw fail('Unknown setting.')
|
|
277
|
+
const { client, workspaceScope } = await gateway()
|
|
278
|
+
const scope = sandbox ? { sandbox, workspaceScope: workspaceScope, global: false } : { global: true }
|
|
279
|
+
if (clear) {
|
|
280
|
+
await client.raw.updateConfig({ ...scope, settingKey: key, deleteSetting: true, requestId: randomUUID() })
|
|
281
|
+
return { ok: true }
|
|
282
|
+
}
|
|
283
|
+
if (spec.type === 'bool' && typeof value !== 'boolean') throw fail('Expected on or off.')
|
|
284
|
+
if (spec.type === 'string' && !spec.values.includes(value)) throw fail('Unsupported value.')
|
|
285
|
+
const settingValue = spec.type === 'bool' ? { value: { case: 'boolValue', value } } : { value: { case: 'stringValue', value } }
|
|
286
|
+
await client.raw.updateConfig({ ...scope, settingKey: key, settingValue, requestId: randomUUID() })
|
|
287
|
+
return { ok: true }
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
// ---- secrets (providers) and profiles --------------------------------------
|
|
291
|
+
|
|
292
|
+
const CATEGORY = ['unspecified', 'other', 'inference', 'agent', 'source_control', 'messaging', 'data', 'knowledge']
|
|
293
|
+
const AUTH_ACCESS = ['', 'read-only', 'read-write', 'full']
|
|
294
|
+
|
|
295
|
+
function profileView(p) {
|
|
296
|
+
return {
|
|
297
|
+
id: p.id,
|
|
298
|
+
name: p.displayName || p.id,
|
|
299
|
+
description: p.description || null,
|
|
300
|
+
category: CATEGORY[p.category] ?? 'other',
|
|
301
|
+
source: p.source || null,
|
|
302
|
+
scope: p.scope || null,
|
|
303
|
+
credentials: (p.credentials ?? []).map((c) => ({
|
|
304
|
+
name: c.name, description: c.description || null, envVars: c.envVars ?? [], required: Boolean(c.required),
|
|
305
|
+
authStyle: c.authStyle || null, headerName: c.headerName || null, queryParam: c.queryParam || null,
|
|
306
|
+
refresh: c.refresh?.strategy ? true : false,
|
|
307
|
+
})),
|
|
308
|
+
endpoints: (p.endpoints ?? []).map((e) => ({ host: e.host, port: e.port || e.ports?.[0] || null, access: AUTH_ACCESS[e.access] || null, protocol: e.protocol || 'tcp' })),
|
|
309
|
+
binaries: (p.binaries ?? []).map((b) => b.path),
|
|
310
|
+
resourceVersion: p.resourceVersion?.toString?.() ?? null,
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
// NVIDIA's published profiles at the gateway's release. Imported through the
|
|
315
|
+
// `openshell` CLI, which already knows how to turn profile YAML into the
|
|
316
|
+
// gateway's shape; the console only ever passes one of these fixed URLs.
|
|
317
|
+
export const PROFILE_CATALOG = [
|
|
318
|
+
['claude-code', 'Claude Code', 'agent'], ['codex', 'Codex', 'agent'], ['copilot', 'GitHub Copilot', 'agent'], ['cursor', 'Cursor', 'agent'],
|
|
319
|
+
['anthropic', 'Anthropic', 'inference'], ['openai', 'OpenAI', 'inference'], ['openrouter', 'OpenRouter', 'inference'], ['nvidia', 'NVIDIA', 'inference'],
|
|
320
|
+
['deepinfra', 'DeepInfra', 'inference'], ['google-vertex-ai', 'Google Vertex AI', 'inference'], ['aws-bedrock', 'AWS Bedrock', 'inference'],
|
|
321
|
+
['github', 'GitHub', 'source_control'], ['pypi', 'PyPI', 'data'],
|
|
322
|
+
['aws', 'AWS', 'other'], ['aws-s3', 'AWS S3', 'other'], ['google-cloud', 'Google Cloud', 'other'],
|
|
323
|
+
].map(([id, name, category]) => ({ id, name, category }))
|
|
324
|
+
|
|
325
|
+
async function secrets() {
|
|
326
|
+
const { client, target, workspaceScope } = await gateway()
|
|
327
|
+
const [providers, profiles, sandboxes] = await Promise.all([
|
|
328
|
+
client.raw.listProviders({ workspaceScope: workspaceScope, pageSize: 200 }),
|
|
329
|
+
client.raw.listProviderProfiles({ workspaceScope: workspaceScope, pageSize: 200 }),
|
|
330
|
+
client.raw.listSandboxes({ workspaceScope: workspaceScope }),
|
|
331
|
+
])
|
|
332
|
+
const attached = {}
|
|
333
|
+
for (const s of sandboxes.sandboxes) for (const p of s.spec?.providers ?? []) (attached[p] ??= []).push(s.metadata.name)
|
|
334
|
+
return {
|
|
335
|
+
gateway: target.name,
|
|
336
|
+
providers: providers.providers.map((p) => ({
|
|
337
|
+
...providerView(p),
|
|
338
|
+
expires: Object.fromEntries(Object.entries(p.credentialExpirationTimes ?? {}).map(([k, t]) => [k, iso(t)])),
|
|
339
|
+
attachedTo: attached[p.metadata?.name] ?? [],
|
|
340
|
+
resourceVersion: p.metadata?.resourceVersion?.toString?.() ?? null,
|
|
341
|
+
})),
|
|
342
|
+
profiles: profiles.profiles.map(profileView),
|
|
343
|
+
catalog: PROFILE_CATALOG,
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
const SECRET_NAME = /^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/
|
|
348
|
+
const ENV_KEY = /^[A-Z_][A-Z0-9_]{0,127}$/
|
|
349
|
+
|
|
350
|
+
function credentialMap(input, { allowEmpty = false } = {}) {
|
|
351
|
+
const out = {}
|
|
352
|
+
for (const [key, value] of Object.entries(input ?? {})) {
|
|
353
|
+
if (!ENV_KEY.test(key)) throw fail(`"${key}" is not a valid credential name.`)
|
|
354
|
+
const v = String(value ?? '')
|
|
355
|
+
if (v.length > 8192) throw fail(`${key} is too long.`)
|
|
356
|
+
if (!v && !allowEmpty) continue
|
|
357
|
+
out[key] = v
|
|
358
|
+
}
|
|
359
|
+
return out
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
async function createSecret(input) {
|
|
363
|
+
const { client, workspaceScope, workspace } = await gateway()
|
|
364
|
+
const name = String(input.name ?? '').trim()
|
|
365
|
+
if (!SECRET_NAME.test(name)) throw fail('Use lowercase letters, digits and dashes for the name.')
|
|
366
|
+
const profiles = await client.raw.listProviderProfiles({ workspaceScope: workspaceScope, pageSize: 200 })
|
|
367
|
+
const profile = profiles.profiles.find((p) => p.id === input.type)
|
|
368
|
+
if (!profile) throw fail('Import this profile first.')
|
|
369
|
+
let credentials
|
|
370
|
+
try { credentials = validateSecretCredentials(profile, input.credentials) }
|
|
371
|
+
catch (error) { throw fail(error.message) }
|
|
372
|
+
await client.raw.createProvider({
|
|
373
|
+
workspaceScope: workspaceScope, requestId: randomUUID(),
|
|
374
|
+
provider: { metadata: { name }, type: profile.id, profileWorkspace: profile.scope === 'workspace' ? workspace : '', credentials, config: {} },
|
|
375
|
+
})
|
|
376
|
+
return { name }
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
async function rotateSecret(name, input) {
|
|
380
|
+
const { client, workspaceScope } = await gateway()
|
|
381
|
+
const current = await client.raw.getProvider({ name, workspaceScope: workspaceScope })
|
|
382
|
+
const credentials = credentialMap(input.credentials)
|
|
383
|
+
if (!Object.keys(credentials).length) throw fail('Enter a new value.')
|
|
384
|
+
const known = Object.keys(current.provider.credentials ?? {})
|
|
385
|
+
for (const key of Object.keys(credentials)) if (!known.includes(key)) throw fail(`${key} is not a credential of this secret.`)
|
|
386
|
+
const response = await client.raw.updateProvider({
|
|
387
|
+
workspaceScope: workspaceScope, requestId: randomUUID(),
|
|
388
|
+
provider: { metadata: { name }, type: current.provider.type, credentials, config: {} },
|
|
389
|
+
})
|
|
390
|
+
return { ok: true, sandboxesNotified: response.targetReceipts?.length ?? 0 }
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
async function setExpiry(name, input) {
|
|
394
|
+
const { client, workspaceScope } = await gateway()
|
|
395
|
+
const current = await client.raw.getProvider({ name, workspaceScope: workspaceScope })
|
|
396
|
+
const key = String(input.key ?? '')
|
|
397
|
+
if (!(key in (current.provider.credentials ?? {}))) throw fail('Unknown credential.')
|
|
398
|
+
const base = { workspaceScope: workspaceScope, requestId: randomUUID(), provider: { metadata: { name }, type: current.provider.type, credentials: {}, config: {} } }
|
|
399
|
+
if (!input.expiresAt) {
|
|
400
|
+
await client.raw.updateProvider({ ...base, clearCredentialExpirationKeys: [key] })
|
|
401
|
+
} else {
|
|
402
|
+
const t = Date.parse(input.expiresAt)
|
|
403
|
+
if (!Number.isFinite(t) || t < Date.now()) throw fail('Pick a date in the future.')
|
|
404
|
+
await client.raw.updateProvider({ ...base, credentialExpirationTimes: { [key]: { seconds: BigInt(Math.floor(t / 1000)), nanos: 0 } } })
|
|
405
|
+
}
|
|
406
|
+
return { ok: true }
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
async function deleteSecret(name) {
|
|
410
|
+
const { client, workspaceScope } = await gateway()
|
|
411
|
+
await client.raw.deleteProvider({ name, workspaceScope: workspaceScope })
|
|
412
|
+
return { ok: true }
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
async function attachment(sandbox, provider, attach) {
|
|
416
|
+
const { client, workspaceScope } = await gateway()
|
|
417
|
+
const request = { sandbox, provider, workspaceScope: workspaceScope, requestId: randomUUID() }
|
|
418
|
+
const response = attach ? await client.raw.attachSandboxProvider(request) : await client.raw.detachSandboxProvider(request)
|
|
419
|
+
return { changed: attach ? response.attached : response.detached }
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
async function importProfile(id) {
|
|
423
|
+
if (!PROFILE_CATALOG.some((p) => p.id === id)) throw fail('Unknown profile.')
|
|
424
|
+
const { target, workspace } = await gateway()
|
|
425
|
+
const url = `https://raw.githubusercontent.com/NVIDIA/OpenShell/v0.1.2/providers/${id}.yaml`
|
|
426
|
+
try {
|
|
427
|
+
const { stdout } = await exec('openshell', ['--gateway', target.name, '--workspace', workspace, 'profile', 'import', '--url', url], { timeout: 30000, maxBuffer: 1 << 20 })
|
|
428
|
+
return { ok: true, message: stdout.trim() }
|
|
429
|
+
} catch (error) {
|
|
430
|
+
throw fail((error.stderr || error.message).toString().split('\n').filter(Boolean).slice(-3).join(' '), 502)
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
// ---- create-time policy templates ------------------------------------------
|
|
435
|
+
//
|
|
436
|
+
// Files, Landlock and process identity are fixed when a sandbox is created, so
|
|
437
|
+
// they live in templates the New sandbox dialog applies. Stored as JSON next
|
|
438
|
+
// to the console so they can be reviewed and committed like code.
|
|
439
|
+
|
|
440
|
+
const TEMPLATE_ID = /^[a-z0-9][a-z0-9-]{0,47}$/
|
|
441
|
+
const ABS = /^\/[\w.@+-][\w./@+-]{0,255}$/
|
|
442
|
+
const SYSTEM_RO = ['/bin', '/usr', '/lib', '/proc', '/dev/urandom', '/etc', '/var/log']
|
|
443
|
+
|
|
444
|
+
// Hidden compatibility presets for existing saved references and imported images.
|
|
445
|
+
const LEGACY_TEMPLATES = [
|
|
446
|
+
{
|
|
447
|
+
id: 'claude-subscription', builtin: true, name: 'Claude Code subscription',
|
|
448
|
+
description: 'Sign in with your Claude subscription. Allows Claude Code to reach Anthropic API and sign-in endpoints without an API-key provider. Run claude and choose your subscription account after connecting.',
|
|
449
|
+
filesystem: { workdir: true, readOnly: SYSTEM_RO, readWrite: ['/tmp', '/dev/null'] }, landlock: 'best_effort',
|
|
450
|
+
rules: [
|
|
451
|
+
{ name: 'claude-subscription', binaries: ['/usr/bin/claude', '/usr/local/bin/claude'],
|
|
452
|
+
endpoints: ['api.anthropic.com', 'platform.claude.com', 'claude.ai'].map((host) => (
|
|
453
|
+
{ host, ports: [443], protocol: 'rest', access: 'read-write', enforcement: 'enforce' }
|
|
454
|
+
)) },
|
|
455
|
+
],
|
|
456
|
+
},
|
|
457
|
+
{
|
|
458
|
+
id: 'claude-github-readonly', builtin: true, name: 'Claude Code + GitHub read-only',
|
|
459
|
+
description: 'Claude can clone and read public GitHub repos but cannot push, open issues or reach any other code host.',
|
|
460
|
+
filesystem: { workdir: true, readOnly: SYSTEM_RO, readWrite: ['/tmp', '/dev/null'] }, landlock: 'best_effort',
|
|
461
|
+
rules: [
|
|
462
|
+
{ name: 'github-read', binaries: ['/usr/lib/git-core/git-remote-http', '/usr/lib/git-core/git-remote-https', '/usr/local/bin/claude'],
|
|
463
|
+
endpoints: [
|
|
464
|
+
// git clone and fetch POST to git-upload-pack, so GET-only would block them.
|
|
465
|
+
// Pushing POSTs to git-receive-pack, which stays denied.
|
|
466
|
+
{ host: 'github.com', ports: [443], protocol: 'rest', enforcement: 'enforce',
|
|
467
|
+
allow: [
|
|
468
|
+
{ method: 'GET', path: '/**' }, { method: 'HEAD', path: '/**' }, { method: 'OPTIONS', path: '/**' },
|
|
469
|
+
{ method: 'POST', path: '/*/*/git-upload-pack' },
|
|
470
|
+
],
|
|
471
|
+
deny: [{ method: '*', path: '/*/*/git-receive-pack' }] },
|
|
472
|
+
{ host: 'api.github.com', ports: [443], protocol: 'rest', access: 'read-only', enforcement: 'enforce' },
|
|
473
|
+
{ host: 'codeload.github.com', ports: [443], protocol: 'rest', access: 'read-only', enforcement: 'enforce' },
|
|
474
|
+
] },
|
|
475
|
+
],
|
|
476
|
+
},
|
|
477
|
+
]
|
|
478
|
+
|
|
479
|
+
export function validateTemplate(input) {
|
|
480
|
+
const id = String(input.id ?? '').trim()
|
|
481
|
+
if (!TEMPLATE_ID.test(id)) throw fail('Template ids use lowercase letters, digits and dashes.')
|
|
482
|
+
const builtin = [...BUILTIN_TEMPLATES, ...LEGACY_TEMPLATES].find((t) => t.id === id)
|
|
483
|
+
const kind = builtin?.kind ?? (['access', 'baseline'].includes(input.kind) ? input.kind : undefined)
|
|
484
|
+
const list = (v) => (Array.isArray(v) ? v.map(String).map((s) => s.trim()).filter(Boolean) : [])
|
|
485
|
+
const readOnly = list(input.filesystem?.readOnly)
|
|
486
|
+
const readWrite = list(input.filesystem?.readWrite)
|
|
487
|
+
if (readWrite.includes('/')) throw fail('The root folder cannot be writable.')
|
|
488
|
+
for (const p of [...readOnly, ...readWrite]) if (p !== '/' && (!ABS.test(p) || p.includes('..'))) throw fail(`"${p}" must be an absolute path without "..".`)
|
|
489
|
+
if (readOnly.length + readWrite.length > 256) throw fail('Too many paths.')
|
|
490
|
+
const landlock = input.landlock === 'hard_requirement' ? 'hard_requirement' : 'best_effort'
|
|
491
|
+
let accessTemplates
|
|
492
|
+
// Validate persisted reference shapes here. The store and launch composition
|
|
493
|
+
// resolve their existence and access type against the destination catalog,
|
|
494
|
+
// which also contains imported presets with remapped ids.
|
|
495
|
+
const references = input.accessTemplates ?? []
|
|
496
|
+
if (!Array.isArray(references) || references.some(reference => typeof reference !== 'string' || !TEMPLATE_ID.test(reference))) throw fail('Choose valid additional access templates.')
|
|
497
|
+
try { accessTemplates = normalizeAccessTemplates(references, references.map(reference => ({ id: reference, kind: 'access' }))) } catch (error) { throw fail(error.message) }
|
|
498
|
+
const rules = (input.rules ?? []).map((r) => { ruleToProto(r); return r })
|
|
499
|
+
if (kind === 'access' && accessTemplates.length) throw fail('An access policy cannot include other access policies.')
|
|
500
|
+
if (new Set(rules.map((r) => r.name)).size !== rules.length) throw fail('Rule names must be unique.')
|
|
501
|
+
// Services to open when the sandbox starts, each with an optional auto-close.
|
|
502
|
+
const ingress = (input.ingress ?? []).map((d) => {
|
|
503
|
+
const name = String(d.name ?? '')
|
|
504
|
+
const port = Number(d.port)
|
|
505
|
+
const minutes = d.closeAfterMinutes === null || d.closeAfterMinutes === undefined ? null : Number(d.closeAfterMinutes)
|
|
506
|
+
if (!/^([a-z0-9]([a-z0-9-]{0,30}[a-z0-9])?)?$/.test(name)) throw fail('Service names use lowercase letters, digits and dashes.')
|
|
507
|
+
if (!Number.isInteger(port) || port < 1 || port > 65535) throw fail('Service ports are 1–65535.')
|
|
508
|
+
if (minutes !== null && (!Number.isInteger(minutes) || minutes < 5 || minutes > 10080)) throw fail('Auto-close must be 5 minutes to 7 days.')
|
|
509
|
+
return { name, port, closeAfterMinutes: minutes }
|
|
510
|
+
})
|
|
511
|
+
if (new Set(ingress.map((d) => d.name)).size !== ingress.length) throw fail('Each opened service needs its own name.')
|
|
512
|
+
return {
|
|
513
|
+
id,
|
|
514
|
+
builtin: Boolean(builtin),
|
|
515
|
+
...(kind ? { kind } : {}),
|
|
516
|
+
name: String(input.name ?? id).slice(0, 80),
|
|
517
|
+
description: String(input.description ?? '').slice(0, 400),
|
|
518
|
+
filesystem: { workdir: input.filesystem?.workdir !== false, readOnly, readWrite },
|
|
519
|
+
landlock,
|
|
520
|
+
accessTemplates,
|
|
521
|
+
rules,
|
|
522
|
+
ingress,
|
|
523
|
+
}
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
export function templateToPolicy(template) {
|
|
527
|
+
return {
|
|
528
|
+
version: 1,
|
|
529
|
+
filesystem: { includeWorkdir: template.filesystem.workdir, readOnly: template.filesystem.readOnly, readWrite: template.filesystem.readWrite },
|
|
530
|
+
landlock: { compatibility: template.landlock },
|
|
531
|
+
networkPolicies: Object.fromEntries(template.rules.map((r) => { const { name, rule } = ruleToProto(r); return [name, rule] })),
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
const templateStores = new Map()
|
|
536
|
+
async function templateStore() {
|
|
537
|
+
const directory = await policyDirectory()
|
|
538
|
+
if (!templateStores.has(directory)) {
|
|
539
|
+
templateStores.set(directory, createTemplateStore({ directory, builtins: BUILTIN_TEMPLATES, legacy: LEGACY_TEMPLATES, validate: validateTemplate }))
|
|
540
|
+
}
|
|
541
|
+
return templateStores.get(directory)
|
|
542
|
+
}
|
|
543
|
+
export const listTemplates = async () => (await templateStore()).list()
|
|
544
|
+
export const findTemplate = async (id) => (await templateStore()).find(id)
|
|
545
|
+
const saveTemplate = async (input) => (await templateStore()).save(input)
|
|
546
|
+
const deleteTemplate = async (id) => (await templateStore()).deleteMany([id])
|
|
547
|
+
|
|
548
|
+
// ---- routes -----------------------------------------------------------------
|
|
549
|
+
|
|
550
|
+
const SANDBOX = /^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/
|
|
551
|
+
|
|
552
|
+
export async function policyRoute(method, parts, input) {
|
|
553
|
+
const [area, a, b, c] = parts
|
|
554
|
+
if (method === 'GET') {
|
|
555
|
+
if (area === 'policy' && a === 'fleet') return fleet()
|
|
556
|
+
if (area === 'policy' && a === 'global') return globalPolicy()
|
|
557
|
+
if (area === 'policy' && SANDBOX.test(a ?? '') && !b) return policyOf(a)
|
|
558
|
+
if (area === 'policy' && SANDBOX.test(a ?? '') && b === 'revisions' && /^\d+$/.test(c ?? '')) {
|
|
559
|
+
const { revision, policy } = await revisionPolicy(a, Number(c))
|
|
560
|
+
return { revision, policy: policyView(policy) }
|
|
561
|
+
}
|
|
562
|
+
if (area === 'settings') return settings(a && SANDBOX.test(a) ? a : null)
|
|
563
|
+
if (area === 'secrets') return secrets()
|
|
564
|
+
if (area === 'templates') return listTemplates()
|
|
565
|
+
return undefined
|
|
566
|
+
}
|
|
567
|
+
if (area === 'policy' && a === 'global' && b === 'remove') return removeGlobal()
|
|
568
|
+
if (area === 'policy' && SANDBOX.test(a ?? '') && b === 'ops') return applyOps(a, input.ops)
|
|
569
|
+
if (area === 'policy' && SANDBOX.test(a ?? '') && b === 'restore') return restore(a, Number(input.version))
|
|
570
|
+
if (area === 'settings') return setSetting({ ...input, sandbox: input.sandbox && SANDBOX.test(input.sandbox) ? input.sandbox : null })
|
|
571
|
+
if (area === 'secrets' && !a) return createSecret(input)
|
|
572
|
+
if (area === 'secrets' && SECRET_NAME.test(a ?? '')) {
|
|
573
|
+
if (b === 'rotate') return rotateSecret(a, input)
|
|
574
|
+
if (b === 'expiry') return setExpiry(a, input)
|
|
575
|
+
if (b === 'delete') return deleteSecret(a)
|
|
576
|
+
if ((b === 'attach' || b === 'detach') && SANDBOX.test(input.sandbox ?? '')) return attachment(input.sandbox, a, b === 'attach')
|
|
577
|
+
}
|
|
578
|
+
if (area === 'profiles' && a === 'import') return importProfile(String(input.id ?? ''))
|
|
579
|
+
if (area === 'templates' && !a) return saveTemplate(input)
|
|
580
|
+
if (area === 'templates' && a === 'delete' && !b) return (await templateStore()).deleteMany(input.ids)
|
|
581
|
+
if (area === 'templates' && a && b === 'delete') return deleteTemplate(a)
|
|
582
|
+
return undefined
|
|
583
|
+
}
|