openshell 0.0.113__py3-none-any.whl
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.
- openshell/__init__.py +46 -0
- openshell/_proto/__init__.py +15 -0
- openshell/_proto/datamodel_pb2.py +77 -0
- openshell/_proto/datamodel_pb2.pyi +129 -0
- openshell/_proto/datamodel_pb2_grpc.py +24 -0
- openshell/_proto/inference_pb2.py +72 -0
- openshell/_proto/inference_pb2.pyi +149 -0
- openshell/_proto/inference_pb2_grpc.py +236 -0
- openshell/_proto/openshell_pb2.py +698 -0
- openshell/_proto/openshell_pb2.pyi +2377 -0
- openshell/_proto/openshell_pb2_grpc.py +3119 -0
- openshell/_proto/options_pb2.py +37 -0
- openshell/_proto/options_pb2.pyi +22 -0
- openshell/_proto/options_pb2_grpc.py +24 -0
- openshell/_proto/sandbox_pb2.py +123 -0
- openshell/_proto/sandbox_pb2.pyi +390 -0
- openshell/_proto/sandbox_pb2_grpc.py +24 -0
- openshell/openshell_test.py +11 -0
- openshell/py.typed +0 -0
- openshell/release_formula_test.py +170 -0
- openshell/sandbox.py +1701 -0
- openshell/sandbox_test.py +1983 -0
- openshell-0.0.113.dist-info/METADATA +307 -0
- openshell-0.0.113.dist-info/RECORD +27 -0
- openshell-0.0.113.dist-info/WHEEL +5 -0
- openshell-0.0.113.dist-info/licenses/LICENSE +191 -0
- openshell-0.0.113.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
4
|
+
# source: options.proto
|
|
5
|
+
# Protobuf Python Version: 6.31.1
|
|
6
|
+
"""Generated protocol buffer code."""
|
|
7
|
+
from google.protobuf import descriptor as _descriptor
|
|
8
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
9
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
10
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
+
from google.protobuf.internal import builder as _builder
|
|
12
|
+
_runtime_version.ValidateProtobufRuntimeVersion(
|
|
13
|
+
_runtime_version.Domain.PUBLIC,
|
|
14
|
+
6,
|
|
15
|
+
31,
|
|
16
|
+
1,
|
|
17
|
+
'',
|
|
18
|
+
'options.proto'
|
|
19
|
+
)
|
|
20
|
+
# @@protoc_insertion_point(imports)
|
|
21
|
+
|
|
22
|
+
_sym_db = _symbol_database.Default()
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
from google.protobuf import descriptor_pb2 as google_dot_protobuf_dot_descriptor__pb2
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\roptions.proto\x12\x14openshell.options.v1\x1a google/protobuf/descriptor.proto\"b\n\x11\x41uthorizationRule\x12\x11\n\tauth_mode\x18\x01 \x01(\t\x12\x16\n\x0eworkspace_role\x18\x02 \x01(\t\x12\x13\n\x0bglobal_role\x18\x03 \x01(\t\x12\r\n\x05scope\x18\x04 \x01(\t:`\n\rauthorization\x12\x1e.google.protobuf.MethodOptions\x18\xd0\x86\x03 \x01(\x0b\x32\'.openshell.options.v1.AuthorizationRule:/\n\x06secret\x12\x1d.google.protobuf.FieldOptions\x18\xd1\x86\x03 \x01(\x08\x62\x06proto3')
|
|
29
|
+
|
|
30
|
+
_globals = globals()
|
|
31
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
32
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'options_pb2', _globals)
|
|
33
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
34
|
+
DESCRIPTOR._loaded_options = None
|
|
35
|
+
_globals['_AUTHORIZATIONRULE']._serialized_start=73
|
|
36
|
+
_globals['_AUTHORIZATIONRULE']._serialized_end=171
|
|
37
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
from google.protobuf import descriptor_pb2 as _descriptor_pb2
|
|
2
|
+
from google.protobuf import descriptor as _descriptor
|
|
3
|
+
from google.protobuf import message as _message
|
|
4
|
+
from typing import ClassVar as _ClassVar, Optional as _Optional
|
|
5
|
+
|
|
6
|
+
DESCRIPTOR: _descriptor.FileDescriptor
|
|
7
|
+
AUTHORIZATION_FIELD_NUMBER: _ClassVar[int]
|
|
8
|
+
authorization: _descriptor.FieldDescriptor
|
|
9
|
+
SECRET_FIELD_NUMBER: _ClassVar[int]
|
|
10
|
+
secret: _descriptor.FieldDescriptor
|
|
11
|
+
|
|
12
|
+
class AuthorizationRule(_message.Message):
|
|
13
|
+
__slots__ = ("auth_mode", "workspace_role", "global_role", "scope")
|
|
14
|
+
AUTH_MODE_FIELD_NUMBER: _ClassVar[int]
|
|
15
|
+
WORKSPACE_ROLE_FIELD_NUMBER: _ClassVar[int]
|
|
16
|
+
GLOBAL_ROLE_FIELD_NUMBER: _ClassVar[int]
|
|
17
|
+
SCOPE_FIELD_NUMBER: _ClassVar[int]
|
|
18
|
+
auth_mode: str
|
|
19
|
+
workspace_role: str
|
|
20
|
+
global_role: str
|
|
21
|
+
scope: str
|
|
22
|
+
def __init__(self, auth_mode: _Optional[str] = ..., workspace_role: _Optional[str] = ..., global_role: _Optional[str] = ..., scope: _Optional[str] = ...) -> None: ...
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
|
|
2
|
+
"""Client and server classes corresponding to protobuf-defined services."""
|
|
3
|
+
import grpc
|
|
4
|
+
import warnings
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
GRPC_GENERATED_VERSION = '1.78.0'
|
|
8
|
+
GRPC_VERSION = grpc.__version__
|
|
9
|
+
_version_not_supported = False
|
|
10
|
+
|
|
11
|
+
try:
|
|
12
|
+
from grpc._utilities import first_version_is_lower
|
|
13
|
+
_version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
|
|
14
|
+
except ImportError:
|
|
15
|
+
_version_not_supported = True
|
|
16
|
+
|
|
17
|
+
if _version_not_supported:
|
|
18
|
+
raise RuntimeError(
|
|
19
|
+
f'The grpc package installed is at version {GRPC_VERSION},'
|
|
20
|
+
+ ' but the generated code in options_pb2_grpc.py depends on'
|
|
21
|
+
+ f' grpcio>={GRPC_GENERATED_VERSION}.'
|
|
22
|
+
+ f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
|
|
23
|
+
+ f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
|
|
24
|
+
)
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
4
|
+
# source: sandbox.proto
|
|
5
|
+
# Protobuf Python Version: 6.31.1
|
|
6
|
+
"""Generated protocol buffer code."""
|
|
7
|
+
from google.protobuf import descriptor as _descriptor
|
|
8
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
9
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
10
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
+
from google.protobuf.internal import builder as _builder
|
|
12
|
+
_runtime_version.ValidateProtobufRuntimeVersion(
|
|
13
|
+
_runtime_version.Domain.PUBLIC,
|
|
14
|
+
6,
|
|
15
|
+
31,
|
|
16
|
+
1,
|
|
17
|
+
'',
|
|
18
|
+
'sandbox.proto'
|
|
19
|
+
)
|
|
20
|
+
# @@protoc_insertion_point(imports)
|
|
21
|
+
|
|
22
|
+
_sym_db = _symbol_database.Default()
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
from google.protobuf import struct_pb2 as google_dot_protobuf_dot_struct__pb2
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\rsandbox.proto\x12\x14openshell.sandbox.v1\x1a\x1cgoogle/protobuf/struct.proto\"\xc3\x04\n\rSandboxPolicy\x12\x0f\n\x07version\x18\x01 \x01(\r\x12:\n\nfilesystem\x18\x02 \x01(\x0b\x32&.openshell.sandbox.v1.FilesystemPolicy\x12\x36\n\x08landlock\x18\x03 \x01(\x0b\x32$.openshell.sandbox.v1.LandlockPolicy\x12\x34\n\x07process\x18\x04 \x01(\x0b\x32#.openshell.sandbox.v1.ProcessPolicy\x12R\n\x10network_policies\x18\x05 \x03(\x0b\x32\x38.openshell.sandbox.v1.SandboxPolicy.NetworkPoliciesEntry\x12X\n\x13network_middlewares\x18\x06 \x03(\x0b\x32;.openshell.sandbox.v1.SandboxPolicy.NetworkMiddlewaresEntry\x1a_\n\x14NetworkPoliciesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x36\n\x05value\x18\x02 \x01(\x0b\x32\'.openshell.sandbox.v1.NetworkPolicyRule:\x02\x38\x01\x1ah\n\x17NetworkMiddlewaresEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12<\n\x05value\x18\x02 \x01(\x0b\x32-.openshell.sandbox.v1.NetworkMiddlewareConfig:\x02\x38\x01\"R\n\x10\x46ilesystemPolicy\x12\x17\n\x0finclude_workdir\x18\x01 \x01(\x08\x12\x11\n\tread_only\x18\x02 \x03(\t\x12\x12\n\nread_write\x18\x03 \x03(\t\"\'\n\x0eLandlockPolicy\x12\x15\n\rcompatibility\x18\x01 \x01(\t\":\n\rProcessPolicy\x12\x13\n\x0brun_as_user\x18\x01 \x01(\t\x12\x14\n\x0crun_as_group\x18\x02 \x01(\t\"\x92\x01\n\x11NetworkPolicyRule\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x38\n\tendpoints\x18\x02 \x03(\x0b\x32%.openshell.sandbox.v1.NetworkEndpoint\x12\x35\n\x08\x62inaries\x18\x03 \x03(\x0b\x32#.openshell.sandbox.v1.NetworkBinary\"\xca\x01\n\x17NetworkMiddlewareConfig\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x12\n\nmiddleware\x18\x02 \x01(\t\x12\'\n\x06\x63onfig\x18\x03 \x01(\x0b\x32\x17.google.protobuf.Struct\x12\x10\n\x08on_error\x18\x04 \x01(\t\x12\x43\n\tendpoints\x18\x05 \x01(\x0b\x32\x30.openshell.sandbox.v1.MiddlewareEndpointSelector\x12\r\n\x05order\x18\x06 \x01(\x05\">\n\x1aMiddlewareEndpointSelector\x12\x0f\n\x07include\x18\x01 \x03(\t\x12\x0f\n\x07\x65xclude\x18\x02 \x03(\t\",\n\x18NetworkCredentialBinding\x12\x10\n\x08provider\x18\x01 \x01(\t\"\xc5\x07\n\x0fNetworkEndpoint\x12\x0c\n\x04host\x18\x01 \x01(\t\x12\x0c\n\x04port\x18\x02 \x01(\r\x12\x10\n\x08protocol\x18\x03 \x01(\t\x12\x0b\n\x03tls\x18\x04 \x01(\t\x12\x13\n\x0b\x65nforcement\x18\x05 \x01(\t\x12\x0e\n\x06\x61\x63\x63\x65ss\x18\x06 \x01(\t\x12+\n\x05rules\x18\x07 \x03(\x0b\x32\x1c.openshell.sandbox.v1.L7Rule\x12\x13\n\x0b\x61llowed_ips\x18\x08 \x03(\t\x12\r\n\x05ports\x18\t \x03(\r\x12\x34\n\ndeny_rules\x18\n \x03(\x0b\x32 .openshell.sandbox.v1.L7DenyRule\x12\x1b\n\x13\x61llow_encoded_slash\x18\x0b \x01(\x08\x12\x19\n\x11persisted_queries\x18\x0c \x01(\t\x12\x65\n\x19graphql_persisted_queries\x18\r \x03(\x0b\x32\x42.openshell.sandbox.v1.NetworkEndpoint.GraphqlPersistedQueriesEntry\x12\x1e\n\x16graphql_max_body_bytes\x18\x0e \x01(\r\x12\x0c\n\x04path\x18\x0f \x01(\t\x12$\n\x1cwebsocket_credential_rewrite\x18\x10 \x01(\x08\x12\'\n\x1frequest_body_credential_rewrite\x18\x11 \x01(\x08\x12\x18\n\x10\x61\x64visor_proposed\x18\x12 \x01(\x08\x12\x1a\n\x12\x63redential_signing\x18\x13 \x01(\t\x12\x17\n\x0fsigning_service\x18\x14 \x01(\t\x12\x16\n\x0esigning_region\x18\x15 \x01(\t\x12\x1f\n\x17json_rpc_max_body_bytes\x18\x16 \x01(\r\x12-\n\x03mcp\x18\x17 \x01(\x0b\x32 .openshell.sandbox.v1.McpOptions\x12J\n\x12\x63redential_binding\x18\x18 \x01(\x0b\x32..openshell.sandbox.v1.NetworkCredentialBinding\x12%\n\x1d\x61llow_uninspected_credentials\x18\x19 \x01(\x08\x12\x1d\n\x15provider_credentialed\x18\x1a \x01(\x08\x1a\x66\n\x1cGraphqlPersistedQueriesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x35\n\x05value\x18\x02 \x01(\x0b\x32&.openshell.sandbox.v1.GraphqlOperation:\x02\x38\x01\"\x8c\x01\n\nMcpOptions\x12\x1e\n\x11strict_tool_names\x18\x01 \x01(\x08H\x00\x88\x01\x01\x12(\n\x1b\x61llow_all_known_mcp_methods\x18\x02 \x01(\x08H\x01\x88\x01\x01\x42\x14\n\x12_strict_tool_namesB\x1e\n\x1c_allow_all_known_mcp_methods\"R\n\x10GraphqlOperation\x12\x16\n\x0eoperation_type\x18\x01 \x01(\t\x12\x16\n\x0eoperation_name\x18\x02 \x01(\t\x12\x0e\n\x06\x66ields\x18\x03 \x03(\t\"\xa4\x03\n\nL7DenyRule\x12\x0e\n\x06method\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x0f\n\x07\x63ommand\x18\x03 \x01(\t\x12:\n\x05query\x18\x04 \x03(\x0b\x32+.openshell.sandbox.v1.L7DenyRule.QueryEntry\x12\x16\n\x0eoperation_type\x18\x05 \x01(\t\x12\x16\n\x0eoperation_name\x18\x06 \x01(\t\x12\x0e\n\x06\x66ields\x18\x07 \x03(\t\x12<\n\x06params\x18\t \x03(\x0b\x32,.openshell.sandbox.v1.L7DenyRule.ParamsEntry\x1aR\n\nQueryEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x33\n\x05value\x18\x02 \x01(\x0b\x32$.openshell.sandbox.v1.L7QueryMatcher:\x02\x38\x01\x1aS\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x33\n\x05value\x18\x02 \x01(\x0b\x32$.openshell.sandbox.v1.L7QueryMatcher:\x02\x38\x01J\x04\x08\x08\x10\t\"6\n\x06L7Rule\x12,\n\x05\x61llow\x18\x01 \x01(\x0b\x32\x1d.openshell.sandbox.v1.L7Allow\"\x9b\x03\n\x07L7Allow\x12\x0e\n\x06method\x18\x01 \x01(\t\x12\x0c\n\x04path\x18\x02 \x01(\t\x12\x0f\n\x07\x63ommand\x18\x03 \x01(\t\x12\x37\n\x05query\x18\x04 \x03(\x0b\x32(.openshell.sandbox.v1.L7Allow.QueryEntry\x12\x16\n\x0eoperation_type\x18\x05 \x01(\t\x12\x16\n\x0eoperation_name\x18\x06 \x01(\t\x12\x0e\n\x06\x66ields\x18\x07 \x03(\t\x12\x39\n\x06params\x18\t \x03(\x0b\x32).openshell.sandbox.v1.L7Allow.ParamsEntry\x1aR\n\nQueryEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x33\n\x05value\x18\x02 \x01(\x0b\x32$.openshell.sandbox.v1.L7QueryMatcher:\x02\x38\x01\x1aS\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x33\n\x05value\x18\x02 \x01(\x0b\x32$.openshell.sandbox.v1.L7QueryMatcher:\x02\x38\x01J\x04\x08\x08\x10\t\"+\n\x0eL7QueryMatcher\x12\x0c\n\x04glob\x18\x01 \x01(\t\x12\x0b\n\x03\x61ny\x18\x02 \x03(\t\"2\n\rNetworkBinary\x12\x0c\n\x04path\x18\x01 \x01(\t\x12\x13\n\x07harness\x18\x02 \x01(\x08\x42\x02\x18\x01\"-\n\x17GetSandboxConfigRequest\x12\x12\n\nsandbox_id\x18\x01 \x01(\t\"\x19\n\x17GetGatewayConfigRequest\"\xda\x01\n\x18GetGatewayConfigResponse\x12N\n\x08settings\x18\x01 \x03(\x0b\x32<.openshell.sandbox.v1.GetGatewayConfigResponse.SettingsEntry\x12\x19\n\x11settings_revision\x18\x02 \x01(\x04\x1aS\n\rSettingsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x31\n\x05value\x18\x02 \x01(\x0b\x32\".openshell.sandbox.v1.SettingValue:\x02\x38\x01\"q\n\x0cSettingValue\x12\x16\n\x0cstring_value\x18\x01 \x01(\tH\x00\x12\x14\n\nbool_value\x18\x02 \x01(\x08H\x00\x12\x13\n\tint_value\x18\x03 \x01(\x03H\x00\x12\x15\n\x0b\x62ytes_value\x18\x04 \x01(\x0cH\x00\x42\x07\n\x05value\"x\n\x10\x45\x66\x66\x65\x63tiveSetting\x12\x31\n\x05value\x18\x01 \x01(\x0b\x32\".openshell.sandbox.v1.SettingValue\x12\x31\n\x05scope\x18\x02 \x01(\x0e\x32\".openshell.sandbox.v1.SettingScope\"\xf0\x04\n\x18GetSandboxConfigResponse\x12\x33\n\x06policy\x18\x01 \x01(\x0b\x32#.openshell.sandbox.v1.SandboxPolicy\x12\x0f\n\x07version\x18\x02 \x01(\r\x12\x13\n\x0bpolicy_hash\x18\x03 \x01(\t\x12N\n\x08settings\x18\x04 \x03(\x0b\x32<.openshell.sandbox.v1.GetSandboxConfigResponse.SettingsEntry\x12\x17\n\x0f\x63onfig_revision\x18\x05 \x01(\x04\x12\x39\n\rpolicy_source\x18\x06 \x01(\x0e\x32\".openshell.sandbox.v1.PolicySource\x12\x1d\n\x15global_policy_version\x18\x07 \x01(\r\x12\x1d\n\x15provider_env_revision\x18\x08 \x01(\x04\x12Y\n\x1esupervisor_middleware_services\x18\t \x03(\x0b\x32\x31.openshell.sandbox.v1.SupervisorMiddlewareService\x12\x11\n\tworkspace\x18\n \x01(\t\x12&\n\x1epolicy_validation_failure_mode\x18\x0b \x01(\t\x12(\n extension_authentication_enabled\x18\x0c \x01(\x08\x1aW\n\rSettingsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\x35\n\x05value\x18\x02 \x01(\x0b\x32&.openshell.sandbox.v1.EffectiveSetting:\x02\x38\x01\"\xbb\x01\n\x1bSupervisorMiddlewareService\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x15\n\rgrpc_endpoint\x18\x02 \x01(\t\x12\x19\n\x11max_payload_bytes\x18\x03 \x01(\x04\x12\x0f\n\x07timeout\x18\x04 \x01(\t\x12\x17\n\x0ftls_ca_cert_pem\x18\x05 \x01(\x0c\x12\x10\n\x08\x61udience\x18\x06 \x01(\t\x12 \n\x18\x61llow_insecure_transport\x18\x07 \x01(\x08*b\n\x0cSettingScope\x12\x1d\n\x19SETTING_SCOPE_UNSPECIFIED\x10\x00\x12\x19\n\x15SETTING_SCOPE_SANDBOX\x10\x01\x12\x18\n\x14SETTING_SCOPE_GLOBAL\x10\x02*b\n\x0cPolicySource\x12\x1d\n\x19POLICY_SOURCE_UNSPECIFIED\x10\x00\x12\x19\n\x15POLICY_SOURCE_SANDBOX\x10\x01\x12\x18\n\x14POLICY_SOURCE_GLOBAL\x10\x02\x62\x06proto3')
|
|
29
|
+
|
|
30
|
+
_globals = globals()
|
|
31
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
32
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'sandbox_pb2', _globals)
|
|
33
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
34
|
+
DESCRIPTOR._loaded_options = None
|
|
35
|
+
_globals['_SANDBOXPOLICY_NETWORKPOLICIESENTRY']._loaded_options = None
|
|
36
|
+
_globals['_SANDBOXPOLICY_NETWORKPOLICIESENTRY']._serialized_options = b'8\001'
|
|
37
|
+
_globals['_SANDBOXPOLICY_NETWORKMIDDLEWARESENTRY']._loaded_options = None
|
|
38
|
+
_globals['_SANDBOXPOLICY_NETWORKMIDDLEWARESENTRY']._serialized_options = b'8\001'
|
|
39
|
+
_globals['_NETWORKENDPOINT_GRAPHQLPERSISTEDQUERIESENTRY']._loaded_options = None
|
|
40
|
+
_globals['_NETWORKENDPOINT_GRAPHQLPERSISTEDQUERIESENTRY']._serialized_options = b'8\001'
|
|
41
|
+
_globals['_L7DENYRULE_QUERYENTRY']._loaded_options = None
|
|
42
|
+
_globals['_L7DENYRULE_QUERYENTRY']._serialized_options = b'8\001'
|
|
43
|
+
_globals['_L7DENYRULE_PARAMSENTRY']._loaded_options = None
|
|
44
|
+
_globals['_L7DENYRULE_PARAMSENTRY']._serialized_options = b'8\001'
|
|
45
|
+
_globals['_L7ALLOW_QUERYENTRY']._loaded_options = None
|
|
46
|
+
_globals['_L7ALLOW_QUERYENTRY']._serialized_options = b'8\001'
|
|
47
|
+
_globals['_L7ALLOW_PARAMSENTRY']._loaded_options = None
|
|
48
|
+
_globals['_L7ALLOW_PARAMSENTRY']._serialized_options = b'8\001'
|
|
49
|
+
_globals['_NETWORKBINARY'].fields_by_name['harness']._loaded_options = None
|
|
50
|
+
_globals['_NETWORKBINARY'].fields_by_name['harness']._serialized_options = b'\030\001'
|
|
51
|
+
_globals['_GETGATEWAYCONFIGRESPONSE_SETTINGSENTRY']._loaded_options = None
|
|
52
|
+
_globals['_GETGATEWAYCONFIGRESPONSE_SETTINGSENTRY']._serialized_options = b'8\001'
|
|
53
|
+
_globals['_GETSANDBOXCONFIGRESPONSE_SETTINGSENTRY']._loaded_options = None
|
|
54
|
+
_globals['_GETSANDBOXCONFIGRESPONSE_SETTINGSENTRY']._serialized_options = b'8\001'
|
|
55
|
+
_globals['_SETTINGSCOPE']._serialized_start=4834
|
|
56
|
+
_globals['_SETTINGSCOPE']._serialized_end=4932
|
|
57
|
+
_globals['_POLICYSOURCE']._serialized_start=4934
|
|
58
|
+
_globals['_POLICYSOURCE']._serialized_end=5032
|
|
59
|
+
_globals['_SANDBOXPOLICY']._serialized_start=70
|
|
60
|
+
_globals['_SANDBOXPOLICY']._serialized_end=649
|
|
61
|
+
_globals['_SANDBOXPOLICY_NETWORKPOLICIESENTRY']._serialized_start=448
|
|
62
|
+
_globals['_SANDBOXPOLICY_NETWORKPOLICIESENTRY']._serialized_end=543
|
|
63
|
+
_globals['_SANDBOXPOLICY_NETWORKMIDDLEWARESENTRY']._serialized_start=545
|
|
64
|
+
_globals['_SANDBOXPOLICY_NETWORKMIDDLEWARESENTRY']._serialized_end=649
|
|
65
|
+
_globals['_FILESYSTEMPOLICY']._serialized_start=651
|
|
66
|
+
_globals['_FILESYSTEMPOLICY']._serialized_end=733
|
|
67
|
+
_globals['_LANDLOCKPOLICY']._serialized_start=735
|
|
68
|
+
_globals['_LANDLOCKPOLICY']._serialized_end=774
|
|
69
|
+
_globals['_PROCESSPOLICY']._serialized_start=776
|
|
70
|
+
_globals['_PROCESSPOLICY']._serialized_end=834
|
|
71
|
+
_globals['_NETWORKPOLICYRULE']._serialized_start=837
|
|
72
|
+
_globals['_NETWORKPOLICYRULE']._serialized_end=983
|
|
73
|
+
_globals['_NETWORKMIDDLEWARECONFIG']._serialized_start=986
|
|
74
|
+
_globals['_NETWORKMIDDLEWARECONFIG']._serialized_end=1188
|
|
75
|
+
_globals['_MIDDLEWAREENDPOINTSELECTOR']._serialized_start=1190
|
|
76
|
+
_globals['_MIDDLEWAREENDPOINTSELECTOR']._serialized_end=1252
|
|
77
|
+
_globals['_NETWORKCREDENTIALBINDING']._serialized_start=1254
|
|
78
|
+
_globals['_NETWORKCREDENTIALBINDING']._serialized_end=1298
|
|
79
|
+
_globals['_NETWORKENDPOINT']._serialized_start=1301
|
|
80
|
+
_globals['_NETWORKENDPOINT']._serialized_end=2266
|
|
81
|
+
_globals['_NETWORKENDPOINT_GRAPHQLPERSISTEDQUERIESENTRY']._serialized_start=2164
|
|
82
|
+
_globals['_NETWORKENDPOINT_GRAPHQLPERSISTEDQUERIESENTRY']._serialized_end=2266
|
|
83
|
+
_globals['_MCPOPTIONS']._serialized_start=2269
|
|
84
|
+
_globals['_MCPOPTIONS']._serialized_end=2409
|
|
85
|
+
_globals['_GRAPHQLOPERATION']._serialized_start=2411
|
|
86
|
+
_globals['_GRAPHQLOPERATION']._serialized_end=2493
|
|
87
|
+
_globals['_L7DENYRULE']._serialized_start=2496
|
|
88
|
+
_globals['_L7DENYRULE']._serialized_end=2916
|
|
89
|
+
_globals['_L7DENYRULE_QUERYENTRY']._serialized_start=2743
|
|
90
|
+
_globals['_L7DENYRULE_QUERYENTRY']._serialized_end=2825
|
|
91
|
+
_globals['_L7DENYRULE_PARAMSENTRY']._serialized_start=2827
|
|
92
|
+
_globals['_L7DENYRULE_PARAMSENTRY']._serialized_end=2910
|
|
93
|
+
_globals['_L7RULE']._serialized_start=2918
|
|
94
|
+
_globals['_L7RULE']._serialized_end=2972
|
|
95
|
+
_globals['_L7ALLOW']._serialized_start=2975
|
|
96
|
+
_globals['_L7ALLOW']._serialized_end=3386
|
|
97
|
+
_globals['_L7ALLOW_QUERYENTRY']._serialized_start=2743
|
|
98
|
+
_globals['_L7ALLOW_QUERYENTRY']._serialized_end=2825
|
|
99
|
+
_globals['_L7ALLOW_PARAMSENTRY']._serialized_start=2827
|
|
100
|
+
_globals['_L7ALLOW_PARAMSENTRY']._serialized_end=2910
|
|
101
|
+
_globals['_L7QUERYMATCHER']._serialized_start=3388
|
|
102
|
+
_globals['_L7QUERYMATCHER']._serialized_end=3431
|
|
103
|
+
_globals['_NETWORKBINARY']._serialized_start=3433
|
|
104
|
+
_globals['_NETWORKBINARY']._serialized_end=3483
|
|
105
|
+
_globals['_GETSANDBOXCONFIGREQUEST']._serialized_start=3485
|
|
106
|
+
_globals['_GETSANDBOXCONFIGREQUEST']._serialized_end=3530
|
|
107
|
+
_globals['_GETGATEWAYCONFIGREQUEST']._serialized_start=3532
|
|
108
|
+
_globals['_GETGATEWAYCONFIGREQUEST']._serialized_end=3557
|
|
109
|
+
_globals['_GETGATEWAYCONFIGRESPONSE']._serialized_start=3560
|
|
110
|
+
_globals['_GETGATEWAYCONFIGRESPONSE']._serialized_end=3778
|
|
111
|
+
_globals['_GETGATEWAYCONFIGRESPONSE_SETTINGSENTRY']._serialized_start=3695
|
|
112
|
+
_globals['_GETGATEWAYCONFIGRESPONSE_SETTINGSENTRY']._serialized_end=3778
|
|
113
|
+
_globals['_SETTINGVALUE']._serialized_start=3780
|
|
114
|
+
_globals['_SETTINGVALUE']._serialized_end=3893
|
|
115
|
+
_globals['_EFFECTIVESETTING']._serialized_start=3895
|
|
116
|
+
_globals['_EFFECTIVESETTING']._serialized_end=4015
|
|
117
|
+
_globals['_GETSANDBOXCONFIGRESPONSE']._serialized_start=4018
|
|
118
|
+
_globals['_GETSANDBOXCONFIGRESPONSE']._serialized_end=4642
|
|
119
|
+
_globals['_GETSANDBOXCONFIGRESPONSE_SETTINGSENTRY']._serialized_start=4555
|
|
120
|
+
_globals['_GETSANDBOXCONFIGRESPONSE_SETTINGSENTRY']._serialized_end=4642
|
|
121
|
+
_globals['_SUPERVISORMIDDLEWARESERVICE']._serialized_start=4645
|
|
122
|
+
_globals['_SUPERVISORMIDDLEWARESERVICE']._serialized_end=4832
|
|
123
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,390 @@
|
|
|
1
|
+
from google.protobuf import struct_pb2 as _struct_pb2
|
|
2
|
+
from google.protobuf.internal import containers as _containers
|
|
3
|
+
from google.protobuf.internal import enum_type_wrapper as _enum_type_wrapper
|
|
4
|
+
from google.protobuf import descriptor as _descriptor
|
|
5
|
+
from google.protobuf import message as _message
|
|
6
|
+
from collections.abc import Iterable as _Iterable, Mapping as _Mapping
|
|
7
|
+
from typing import ClassVar as _ClassVar, Optional as _Optional, Union as _Union
|
|
8
|
+
|
|
9
|
+
DESCRIPTOR: _descriptor.FileDescriptor
|
|
10
|
+
|
|
11
|
+
class SettingScope(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
|
12
|
+
__slots__ = ()
|
|
13
|
+
SETTING_SCOPE_UNSPECIFIED: _ClassVar[SettingScope]
|
|
14
|
+
SETTING_SCOPE_SANDBOX: _ClassVar[SettingScope]
|
|
15
|
+
SETTING_SCOPE_GLOBAL: _ClassVar[SettingScope]
|
|
16
|
+
|
|
17
|
+
class PolicySource(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
|
18
|
+
__slots__ = ()
|
|
19
|
+
POLICY_SOURCE_UNSPECIFIED: _ClassVar[PolicySource]
|
|
20
|
+
POLICY_SOURCE_SANDBOX: _ClassVar[PolicySource]
|
|
21
|
+
POLICY_SOURCE_GLOBAL: _ClassVar[PolicySource]
|
|
22
|
+
SETTING_SCOPE_UNSPECIFIED: SettingScope
|
|
23
|
+
SETTING_SCOPE_SANDBOX: SettingScope
|
|
24
|
+
SETTING_SCOPE_GLOBAL: SettingScope
|
|
25
|
+
POLICY_SOURCE_UNSPECIFIED: PolicySource
|
|
26
|
+
POLICY_SOURCE_SANDBOX: PolicySource
|
|
27
|
+
POLICY_SOURCE_GLOBAL: PolicySource
|
|
28
|
+
|
|
29
|
+
class SandboxPolicy(_message.Message):
|
|
30
|
+
__slots__ = ("version", "filesystem", "landlock", "process", "network_policies", "network_middlewares")
|
|
31
|
+
class NetworkPoliciesEntry(_message.Message):
|
|
32
|
+
__slots__ = ("key", "value")
|
|
33
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
34
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
35
|
+
key: str
|
|
36
|
+
value: NetworkPolicyRule
|
|
37
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[NetworkPolicyRule, _Mapping]] = ...) -> None: ...
|
|
38
|
+
class NetworkMiddlewaresEntry(_message.Message):
|
|
39
|
+
__slots__ = ("key", "value")
|
|
40
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
41
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
42
|
+
key: str
|
|
43
|
+
value: NetworkMiddlewareConfig
|
|
44
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[NetworkMiddlewareConfig, _Mapping]] = ...) -> None: ...
|
|
45
|
+
VERSION_FIELD_NUMBER: _ClassVar[int]
|
|
46
|
+
FILESYSTEM_FIELD_NUMBER: _ClassVar[int]
|
|
47
|
+
LANDLOCK_FIELD_NUMBER: _ClassVar[int]
|
|
48
|
+
PROCESS_FIELD_NUMBER: _ClassVar[int]
|
|
49
|
+
NETWORK_POLICIES_FIELD_NUMBER: _ClassVar[int]
|
|
50
|
+
NETWORK_MIDDLEWARES_FIELD_NUMBER: _ClassVar[int]
|
|
51
|
+
version: int
|
|
52
|
+
filesystem: FilesystemPolicy
|
|
53
|
+
landlock: LandlockPolicy
|
|
54
|
+
process: ProcessPolicy
|
|
55
|
+
network_policies: _containers.MessageMap[str, NetworkPolicyRule]
|
|
56
|
+
network_middlewares: _containers.MessageMap[str, NetworkMiddlewareConfig]
|
|
57
|
+
def __init__(self, version: _Optional[int] = ..., filesystem: _Optional[_Union[FilesystemPolicy, _Mapping]] = ..., landlock: _Optional[_Union[LandlockPolicy, _Mapping]] = ..., process: _Optional[_Union[ProcessPolicy, _Mapping]] = ..., network_policies: _Optional[_Mapping[str, NetworkPolicyRule]] = ..., network_middlewares: _Optional[_Mapping[str, NetworkMiddlewareConfig]] = ...) -> None: ...
|
|
58
|
+
|
|
59
|
+
class FilesystemPolicy(_message.Message):
|
|
60
|
+
__slots__ = ("include_workdir", "read_only", "read_write")
|
|
61
|
+
INCLUDE_WORKDIR_FIELD_NUMBER: _ClassVar[int]
|
|
62
|
+
READ_ONLY_FIELD_NUMBER: _ClassVar[int]
|
|
63
|
+
READ_WRITE_FIELD_NUMBER: _ClassVar[int]
|
|
64
|
+
include_workdir: bool
|
|
65
|
+
read_only: _containers.RepeatedScalarFieldContainer[str]
|
|
66
|
+
read_write: _containers.RepeatedScalarFieldContainer[str]
|
|
67
|
+
def __init__(self, include_workdir: bool = ..., read_only: _Optional[_Iterable[str]] = ..., read_write: _Optional[_Iterable[str]] = ...) -> None: ...
|
|
68
|
+
|
|
69
|
+
class LandlockPolicy(_message.Message):
|
|
70
|
+
__slots__ = ("compatibility",)
|
|
71
|
+
COMPATIBILITY_FIELD_NUMBER: _ClassVar[int]
|
|
72
|
+
compatibility: str
|
|
73
|
+
def __init__(self, compatibility: _Optional[str] = ...) -> None: ...
|
|
74
|
+
|
|
75
|
+
class ProcessPolicy(_message.Message):
|
|
76
|
+
__slots__ = ("run_as_user", "run_as_group")
|
|
77
|
+
RUN_AS_USER_FIELD_NUMBER: _ClassVar[int]
|
|
78
|
+
RUN_AS_GROUP_FIELD_NUMBER: _ClassVar[int]
|
|
79
|
+
run_as_user: str
|
|
80
|
+
run_as_group: str
|
|
81
|
+
def __init__(self, run_as_user: _Optional[str] = ..., run_as_group: _Optional[str] = ...) -> None: ...
|
|
82
|
+
|
|
83
|
+
class NetworkPolicyRule(_message.Message):
|
|
84
|
+
__slots__ = ("name", "endpoints", "binaries")
|
|
85
|
+
NAME_FIELD_NUMBER: _ClassVar[int]
|
|
86
|
+
ENDPOINTS_FIELD_NUMBER: _ClassVar[int]
|
|
87
|
+
BINARIES_FIELD_NUMBER: _ClassVar[int]
|
|
88
|
+
name: str
|
|
89
|
+
endpoints: _containers.RepeatedCompositeFieldContainer[NetworkEndpoint]
|
|
90
|
+
binaries: _containers.RepeatedCompositeFieldContainer[NetworkBinary]
|
|
91
|
+
def __init__(self, name: _Optional[str] = ..., endpoints: _Optional[_Iterable[_Union[NetworkEndpoint, _Mapping]]] = ..., binaries: _Optional[_Iterable[_Union[NetworkBinary, _Mapping]]] = ...) -> None: ...
|
|
92
|
+
|
|
93
|
+
class NetworkMiddlewareConfig(_message.Message):
|
|
94
|
+
__slots__ = ("name", "middleware", "config", "on_error", "endpoints", "order")
|
|
95
|
+
NAME_FIELD_NUMBER: _ClassVar[int]
|
|
96
|
+
MIDDLEWARE_FIELD_NUMBER: _ClassVar[int]
|
|
97
|
+
CONFIG_FIELD_NUMBER: _ClassVar[int]
|
|
98
|
+
ON_ERROR_FIELD_NUMBER: _ClassVar[int]
|
|
99
|
+
ENDPOINTS_FIELD_NUMBER: _ClassVar[int]
|
|
100
|
+
ORDER_FIELD_NUMBER: _ClassVar[int]
|
|
101
|
+
name: str
|
|
102
|
+
middleware: str
|
|
103
|
+
config: _struct_pb2.Struct
|
|
104
|
+
on_error: str
|
|
105
|
+
endpoints: MiddlewareEndpointSelector
|
|
106
|
+
order: int
|
|
107
|
+
def __init__(self, name: _Optional[str] = ..., middleware: _Optional[str] = ..., config: _Optional[_Union[_struct_pb2.Struct, _Mapping]] = ..., on_error: _Optional[str] = ..., endpoints: _Optional[_Union[MiddlewareEndpointSelector, _Mapping]] = ..., order: _Optional[int] = ...) -> None: ...
|
|
108
|
+
|
|
109
|
+
class MiddlewareEndpointSelector(_message.Message):
|
|
110
|
+
__slots__ = ("include", "exclude")
|
|
111
|
+
INCLUDE_FIELD_NUMBER: _ClassVar[int]
|
|
112
|
+
EXCLUDE_FIELD_NUMBER: _ClassVar[int]
|
|
113
|
+
include: _containers.RepeatedScalarFieldContainer[str]
|
|
114
|
+
exclude: _containers.RepeatedScalarFieldContainer[str]
|
|
115
|
+
def __init__(self, include: _Optional[_Iterable[str]] = ..., exclude: _Optional[_Iterable[str]] = ...) -> None: ...
|
|
116
|
+
|
|
117
|
+
class NetworkCredentialBinding(_message.Message):
|
|
118
|
+
__slots__ = ("provider",)
|
|
119
|
+
PROVIDER_FIELD_NUMBER: _ClassVar[int]
|
|
120
|
+
provider: str
|
|
121
|
+
def __init__(self, provider: _Optional[str] = ...) -> None: ...
|
|
122
|
+
|
|
123
|
+
class NetworkEndpoint(_message.Message):
|
|
124
|
+
__slots__ = ("host", "port", "protocol", "tls", "enforcement", "access", "rules", "allowed_ips", "ports", "deny_rules", "allow_encoded_slash", "persisted_queries", "graphql_persisted_queries", "graphql_max_body_bytes", "path", "websocket_credential_rewrite", "request_body_credential_rewrite", "advisor_proposed", "credential_signing", "signing_service", "signing_region", "json_rpc_max_body_bytes", "mcp", "credential_binding", "allow_uninspected_credentials", "provider_credentialed")
|
|
125
|
+
class GraphqlPersistedQueriesEntry(_message.Message):
|
|
126
|
+
__slots__ = ("key", "value")
|
|
127
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
128
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
129
|
+
key: str
|
|
130
|
+
value: GraphqlOperation
|
|
131
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[GraphqlOperation, _Mapping]] = ...) -> None: ...
|
|
132
|
+
HOST_FIELD_NUMBER: _ClassVar[int]
|
|
133
|
+
PORT_FIELD_NUMBER: _ClassVar[int]
|
|
134
|
+
PROTOCOL_FIELD_NUMBER: _ClassVar[int]
|
|
135
|
+
TLS_FIELD_NUMBER: _ClassVar[int]
|
|
136
|
+
ENFORCEMENT_FIELD_NUMBER: _ClassVar[int]
|
|
137
|
+
ACCESS_FIELD_NUMBER: _ClassVar[int]
|
|
138
|
+
RULES_FIELD_NUMBER: _ClassVar[int]
|
|
139
|
+
ALLOWED_IPS_FIELD_NUMBER: _ClassVar[int]
|
|
140
|
+
PORTS_FIELD_NUMBER: _ClassVar[int]
|
|
141
|
+
DENY_RULES_FIELD_NUMBER: _ClassVar[int]
|
|
142
|
+
ALLOW_ENCODED_SLASH_FIELD_NUMBER: _ClassVar[int]
|
|
143
|
+
PERSISTED_QUERIES_FIELD_NUMBER: _ClassVar[int]
|
|
144
|
+
GRAPHQL_PERSISTED_QUERIES_FIELD_NUMBER: _ClassVar[int]
|
|
145
|
+
GRAPHQL_MAX_BODY_BYTES_FIELD_NUMBER: _ClassVar[int]
|
|
146
|
+
PATH_FIELD_NUMBER: _ClassVar[int]
|
|
147
|
+
WEBSOCKET_CREDENTIAL_REWRITE_FIELD_NUMBER: _ClassVar[int]
|
|
148
|
+
REQUEST_BODY_CREDENTIAL_REWRITE_FIELD_NUMBER: _ClassVar[int]
|
|
149
|
+
ADVISOR_PROPOSED_FIELD_NUMBER: _ClassVar[int]
|
|
150
|
+
CREDENTIAL_SIGNING_FIELD_NUMBER: _ClassVar[int]
|
|
151
|
+
SIGNING_SERVICE_FIELD_NUMBER: _ClassVar[int]
|
|
152
|
+
SIGNING_REGION_FIELD_NUMBER: _ClassVar[int]
|
|
153
|
+
JSON_RPC_MAX_BODY_BYTES_FIELD_NUMBER: _ClassVar[int]
|
|
154
|
+
MCP_FIELD_NUMBER: _ClassVar[int]
|
|
155
|
+
CREDENTIAL_BINDING_FIELD_NUMBER: _ClassVar[int]
|
|
156
|
+
ALLOW_UNINSPECTED_CREDENTIALS_FIELD_NUMBER: _ClassVar[int]
|
|
157
|
+
PROVIDER_CREDENTIALED_FIELD_NUMBER: _ClassVar[int]
|
|
158
|
+
host: str
|
|
159
|
+
port: int
|
|
160
|
+
protocol: str
|
|
161
|
+
tls: str
|
|
162
|
+
enforcement: str
|
|
163
|
+
access: str
|
|
164
|
+
rules: _containers.RepeatedCompositeFieldContainer[L7Rule]
|
|
165
|
+
allowed_ips: _containers.RepeatedScalarFieldContainer[str]
|
|
166
|
+
ports: _containers.RepeatedScalarFieldContainer[int]
|
|
167
|
+
deny_rules: _containers.RepeatedCompositeFieldContainer[L7DenyRule]
|
|
168
|
+
allow_encoded_slash: bool
|
|
169
|
+
persisted_queries: str
|
|
170
|
+
graphql_persisted_queries: _containers.MessageMap[str, GraphqlOperation]
|
|
171
|
+
graphql_max_body_bytes: int
|
|
172
|
+
path: str
|
|
173
|
+
websocket_credential_rewrite: bool
|
|
174
|
+
request_body_credential_rewrite: bool
|
|
175
|
+
advisor_proposed: bool
|
|
176
|
+
credential_signing: str
|
|
177
|
+
signing_service: str
|
|
178
|
+
signing_region: str
|
|
179
|
+
json_rpc_max_body_bytes: int
|
|
180
|
+
mcp: McpOptions
|
|
181
|
+
credential_binding: NetworkCredentialBinding
|
|
182
|
+
allow_uninspected_credentials: bool
|
|
183
|
+
provider_credentialed: bool
|
|
184
|
+
def __init__(self, host: _Optional[str] = ..., port: _Optional[int] = ..., protocol: _Optional[str] = ..., tls: _Optional[str] = ..., enforcement: _Optional[str] = ..., access: _Optional[str] = ..., rules: _Optional[_Iterable[_Union[L7Rule, _Mapping]]] = ..., allowed_ips: _Optional[_Iterable[str]] = ..., ports: _Optional[_Iterable[int]] = ..., deny_rules: _Optional[_Iterable[_Union[L7DenyRule, _Mapping]]] = ..., allow_encoded_slash: bool = ..., persisted_queries: _Optional[str] = ..., graphql_persisted_queries: _Optional[_Mapping[str, GraphqlOperation]] = ..., graphql_max_body_bytes: _Optional[int] = ..., path: _Optional[str] = ..., websocket_credential_rewrite: bool = ..., request_body_credential_rewrite: bool = ..., advisor_proposed: bool = ..., credential_signing: _Optional[str] = ..., signing_service: _Optional[str] = ..., signing_region: _Optional[str] = ..., json_rpc_max_body_bytes: _Optional[int] = ..., mcp: _Optional[_Union[McpOptions, _Mapping]] = ..., credential_binding: _Optional[_Union[NetworkCredentialBinding, _Mapping]] = ..., allow_uninspected_credentials: bool = ..., provider_credentialed: bool = ...) -> None: ...
|
|
185
|
+
|
|
186
|
+
class McpOptions(_message.Message):
|
|
187
|
+
__slots__ = ("strict_tool_names", "allow_all_known_mcp_methods")
|
|
188
|
+
STRICT_TOOL_NAMES_FIELD_NUMBER: _ClassVar[int]
|
|
189
|
+
ALLOW_ALL_KNOWN_MCP_METHODS_FIELD_NUMBER: _ClassVar[int]
|
|
190
|
+
strict_tool_names: bool
|
|
191
|
+
allow_all_known_mcp_methods: bool
|
|
192
|
+
def __init__(self, strict_tool_names: bool = ..., allow_all_known_mcp_methods: bool = ...) -> None: ...
|
|
193
|
+
|
|
194
|
+
class GraphqlOperation(_message.Message):
|
|
195
|
+
__slots__ = ("operation_type", "operation_name", "fields")
|
|
196
|
+
OPERATION_TYPE_FIELD_NUMBER: _ClassVar[int]
|
|
197
|
+
OPERATION_NAME_FIELD_NUMBER: _ClassVar[int]
|
|
198
|
+
FIELDS_FIELD_NUMBER: _ClassVar[int]
|
|
199
|
+
operation_type: str
|
|
200
|
+
operation_name: str
|
|
201
|
+
fields: _containers.RepeatedScalarFieldContainer[str]
|
|
202
|
+
def __init__(self, operation_type: _Optional[str] = ..., operation_name: _Optional[str] = ..., fields: _Optional[_Iterable[str]] = ...) -> None: ...
|
|
203
|
+
|
|
204
|
+
class L7DenyRule(_message.Message):
|
|
205
|
+
__slots__ = ("method", "path", "command", "query", "operation_type", "operation_name", "fields", "params")
|
|
206
|
+
class QueryEntry(_message.Message):
|
|
207
|
+
__slots__ = ("key", "value")
|
|
208
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
209
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
210
|
+
key: str
|
|
211
|
+
value: L7QueryMatcher
|
|
212
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[L7QueryMatcher, _Mapping]] = ...) -> None: ...
|
|
213
|
+
class ParamsEntry(_message.Message):
|
|
214
|
+
__slots__ = ("key", "value")
|
|
215
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
216
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
217
|
+
key: str
|
|
218
|
+
value: L7QueryMatcher
|
|
219
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[L7QueryMatcher, _Mapping]] = ...) -> None: ...
|
|
220
|
+
METHOD_FIELD_NUMBER: _ClassVar[int]
|
|
221
|
+
PATH_FIELD_NUMBER: _ClassVar[int]
|
|
222
|
+
COMMAND_FIELD_NUMBER: _ClassVar[int]
|
|
223
|
+
QUERY_FIELD_NUMBER: _ClassVar[int]
|
|
224
|
+
OPERATION_TYPE_FIELD_NUMBER: _ClassVar[int]
|
|
225
|
+
OPERATION_NAME_FIELD_NUMBER: _ClassVar[int]
|
|
226
|
+
FIELDS_FIELD_NUMBER: _ClassVar[int]
|
|
227
|
+
PARAMS_FIELD_NUMBER: _ClassVar[int]
|
|
228
|
+
method: str
|
|
229
|
+
path: str
|
|
230
|
+
command: str
|
|
231
|
+
query: _containers.MessageMap[str, L7QueryMatcher]
|
|
232
|
+
operation_type: str
|
|
233
|
+
operation_name: str
|
|
234
|
+
fields: _containers.RepeatedScalarFieldContainer[str]
|
|
235
|
+
params: _containers.MessageMap[str, L7QueryMatcher]
|
|
236
|
+
def __init__(self, method: _Optional[str] = ..., path: _Optional[str] = ..., command: _Optional[str] = ..., query: _Optional[_Mapping[str, L7QueryMatcher]] = ..., operation_type: _Optional[str] = ..., operation_name: _Optional[str] = ..., fields: _Optional[_Iterable[str]] = ..., params: _Optional[_Mapping[str, L7QueryMatcher]] = ...) -> None: ...
|
|
237
|
+
|
|
238
|
+
class L7Rule(_message.Message):
|
|
239
|
+
__slots__ = ("allow",)
|
|
240
|
+
ALLOW_FIELD_NUMBER: _ClassVar[int]
|
|
241
|
+
allow: L7Allow
|
|
242
|
+
def __init__(self, allow: _Optional[_Union[L7Allow, _Mapping]] = ...) -> None: ...
|
|
243
|
+
|
|
244
|
+
class L7Allow(_message.Message):
|
|
245
|
+
__slots__ = ("method", "path", "command", "query", "operation_type", "operation_name", "fields", "params")
|
|
246
|
+
class QueryEntry(_message.Message):
|
|
247
|
+
__slots__ = ("key", "value")
|
|
248
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
249
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
250
|
+
key: str
|
|
251
|
+
value: L7QueryMatcher
|
|
252
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[L7QueryMatcher, _Mapping]] = ...) -> None: ...
|
|
253
|
+
class ParamsEntry(_message.Message):
|
|
254
|
+
__slots__ = ("key", "value")
|
|
255
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
256
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
257
|
+
key: str
|
|
258
|
+
value: L7QueryMatcher
|
|
259
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[L7QueryMatcher, _Mapping]] = ...) -> None: ...
|
|
260
|
+
METHOD_FIELD_NUMBER: _ClassVar[int]
|
|
261
|
+
PATH_FIELD_NUMBER: _ClassVar[int]
|
|
262
|
+
COMMAND_FIELD_NUMBER: _ClassVar[int]
|
|
263
|
+
QUERY_FIELD_NUMBER: _ClassVar[int]
|
|
264
|
+
OPERATION_TYPE_FIELD_NUMBER: _ClassVar[int]
|
|
265
|
+
OPERATION_NAME_FIELD_NUMBER: _ClassVar[int]
|
|
266
|
+
FIELDS_FIELD_NUMBER: _ClassVar[int]
|
|
267
|
+
PARAMS_FIELD_NUMBER: _ClassVar[int]
|
|
268
|
+
method: str
|
|
269
|
+
path: str
|
|
270
|
+
command: str
|
|
271
|
+
query: _containers.MessageMap[str, L7QueryMatcher]
|
|
272
|
+
operation_type: str
|
|
273
|
+
operation_name: str
|
|
274
|
+
fields: _containers.RepeatedScalarFieldContainer[str]
|
|
275
|
+
params: _containers.MessageMap[str, L7QueryMatcher]
|
|
276
|
+
def __init__(self, method: _Optional[str] = ..., path: _Optional[str] = ..., command: _Optional[str] = ..., query: _Optional[_Mapping[str, L7QueryMatcher]] = ..., operation_type: _Optional[str] = ..., operation_name: _Optional[str] = ..., fields: _Optional[_Iterable[str]] = ..., params: _Optional[_Mapping[str, L7QueryMatcher]] = ...) -> None: ...
|
|
277
|
+
|
|
278
|
+
class L7QueryMatcher(_message.Message):
|
|
279
|
+
__slots__ = ("glob", "any")
|
|
280
|
+
GLOB_FIELD_NUMBER: _ClassVar[int]
|
|
281
|
+
ANY_FIELD_NUMBER: _ClassVar[int]
|
|
282
|
+
glob: str
|
|
283
|
+
any: _containers.RepeatedScalarFieldContainer[str]
|
|
284
|
+
def __init__(self, glob: _Optional[str] = ..., any: _Optional[_Iterable[str]] = ...) -> None: ...
|
|
285
|
+
|
|
286
|
+
class NetworkBinary(_message.Message):
|
|
287
|
+
__slots__ = ("path", "harness")
|
|
288
|
+
PATH_FIELD_NUMBER: _ClassVar[int]
|
|
289
|
+
HARNESS_FIELD_NUMBER: _ClassVar[int]
|
|
290
|
+
path: str
|
|
291
|
+
harness: bool
|
|
292
|
+
def __init__(self, path: _Optional[str] = ..., harness: bool = ...) -> None: ...
|
|
293
|
+
|
|
294
|
+
class GetSandboxConfigRequest(_message.Message):
|
|
295
|
+
__slots__ = ("sandbox_id",)
|
|
296
|
+
SANDBOX_ID_FIELD_NUMBER: _ClassVar[int]
|
|
297
|
+
sandbox_id: str
|
|
298
|
+
def __init__(self, sandbox_id: _Optional[str] = ...) -> None: ...
|
|
299
|
+
|
|
300
|
+
class GetGatewayConfigRequest(_message.Message):
|
|
301
|
+
__slots__ = ()
|
|
302
|
+
def __init__(self) -> None: ...
|
|
303
|
+
|
|
304
|
+
class GetGatewayConfigResponse(_message.Message):
|
|
305
|
+
__slots__ = ("settings", "settings_revision")
|
|
306
|
+
class SettingsEntry(_message.Message):
|
|
307
|
+
__slots__ = ("key", "value")
|
|
308
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
309
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
310
|
+
key: str
|
|
311
|
+
value: SettingValue
|
|
312
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[SettingValue, _Mapping]] = ...) -> None: ...
|
|
313
|
+
SETTINGS_FIELD_NUMBER: _ClassVar[int]
|
|
314
|
+
SETTINGS_REVISION_FIELD_NUMBER: _ClassVar[int]
|
|
315
|
+
settings: _containers.MessageMap[str, SettingValue]
|
|
316
|
+
settings_revision: int
|
|
317
|
+
def __init__(self, settings: _Optional[_Mapping[str, SettingValue]] = ..., settings_revision: _Optional[int] = ...) -> None: ...
|
|
318
|
+
|
|
319
|
+
class SettingValue(_message.Message):
|
|
320
|
+
__slots__ = ("string_value", "bool_value", "int_value", "bytes_value")
|
|
321
|
+
STRING_VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
322
|
+
BOOL_VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
323
|
+
INT_VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
324
|
+
BYTES_VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
325
|
+
string_value: str
|
|
326
|
+
bool_value: bool
|
|
327
|
+
int_value: int
|
|
328
|
+
bytes_value: bytes
|
|
329
|
+
def __init__(self, string_value: _Optional[str] = ..., bool_value: bool = ..., int_value: _Optional[int] = ..., bytes_value: _Optional[bytes] = ...) -> None: ...
|
|
330
|
+
|
|
331
|
+
class EffectiveSetting(_message.Message):
|
|
332
|
+
__slots__ = ("value", "scope")
|
|
333
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
334
|
+
SCOPE_FIELD_NUMBER: _ClassVar[int]
|
|
335
|
+
value: SettingValue
|
|
336
|
+
scope: SettingScope
|
|
337
|
+
def __init__(self, value: _Optional[_Union[SettingValue, _Mapping]] = ..., scope: _Optional[_Union[SettingScope, str]] = ...) -> None: ...
|
|
338
|
+
|
|
339
|
+
class GetSandboxConfigResponse(_message.Message):
|
|
340
|
+
__slots__ = ("policy", "version", "policy_hash", "settings", "config_revision", "policy_source", "global_policy_version", "provider_env_revision", "supervisor_middleware_services", "workspace", "policy_validation_failure_mode", "extension_authentication_enabled")
|
|
341
|
+
class SettingsEntry(_message.Message):
|
|
342
|
+
__slots__ = ("key", "value")
|
|
343
|
+
KEY_FIELD_NUMBER: _ClassVar[int]
|
|
344
|
+
VALUE_FIELD_NUMBER: _ClassVar[int]
|
|
345
|
+
key: str
|
|
346
|
+
value: EffectiveSetting
|
|
347
|
+
def __init__(self, key: _Optional[str] = ..., value: _Optional[_Union[EffectiveSetting, _Mapping]] = ...) -> None: ...
|
|
348
|
+
POLICY_FIELD_NUMBER: _ClassVar[int]
|
|
349
|
+
VERSION_FIELD_NUMBER: _ClassVar[int]
|
|
350
|
+
POLICY_HASH_FIELD_NUMBER: _ClassVar[int]
|
|
351
|
+
SETTINGS_FIELD_NUMBER: _ClassVar[int]
|
|
352
|
+
CONFIG_REVISION_FIELD_NUMBER: _ClassVar[int]
|
|
353
|
+
POLICY_SOURCE_FIELD_NUMBER: _ClassVar[int]
|
|
354
|
+
GLOBAL_POLICY_VERSION_FIELD_NUMBER: _ClassVar[int]
|
|
355
|
+
PROVIDER_ENV_REVISION_FIELD_NUMBER: _ClassVar[int]
|
|
356
|
+
SUPERVISOR_MIDDLEWARE_SERVICES_FIELD_NUMBER: _ClassVar[int]
|
|
357
|
+
WORKSPACE_FIELD_NUMBER: _ClassVar[int]
|
|
358
|
+
POLICY_VALIDATION_FAILURE_MODE_FIELD_NUMBER: _ClassVar[int]
|
|
359
|
+
EXTENSION_AUTHENTICATION_ENABLED_FIELD_NUMBER: _ClassVar[int]
|
|
360
|
+
policy: SandboxPolicy
|
|
361
|
+
version: int
|
|
362
|
+
policy_hash: str
|
|
363
|
+
settings: _containers.MessageMap[str, EffectiveSetting]
|
|
364
|
+
config_revision: int
|
|
365
|
+
policy_source: PolicySource
|
|
366
|
+
global_policy_version: int
|
|
367
|
+
provider_env_revision: int
|
|
368
|
+
supervisor_middleware_services: _containers.RepeatedCompositeFieldContainer[SupervisorMiddlewareService]
|
|
369
|
+
workspace: str
|
|
370
|
+
policy_validation_failure_mode: str
|
|
371
|
+
extension_authentication_enabled: bool
|
|
372
|
+
def __init__(self, policy: _Optional[_Union[SandboxPolicy, _Mapping]] = ..., version: _Optional[int] = ..., policy_hash: _Optional[str] = ..., settings: _Optional[_Mapping[str, EffectiveSetting]] = ..., config_revision: _Optional[int] = ..., policy_source: _Optional[_Union[PolicySource, str]] = ..., global_policy_version: _Optional[int] = ..., provider_env_revision: _Optional[int] = ..., supervisor_middleware_services: _Optional[_Iterable[_Union[SupervisorMiddlewareService, _Mapping]]] = ..., workspace: _Optional[str] = ..., policy_validation_failure_mode: _Optional[str] = ..., extension_authentication_enabled: bool = ...) -> None: ...
|
|
373
|
+
|
|
374
|
+
class SupervisorMiddlewareService(_message.Message):
|
|
375
|
+
__slots__ = ("name", "grpc_endpoint", "max_payload_bytes", "timeout", "tls_ca_cert_pem", "audience", "allow_insecure_transport")
|
|
376
|
+
NAME_FIELD_NUMBER: _ClassVar[int]
|
|
377
|
+
GRPC_ENDPOINT_FIELD_NUMBER: _ClassVar[int]
|
|
378
|
+
MAX_PAYLOAD_BYTES_FIELD_NUMBER: _ClassVar[int]
|
|
379
|
+
TIMEOUT_FIELD_NUMBER: _ClassVar[int]
|
|
380
|
+
TLS_CA_CERT_PEM_FIELD_NUMBER: _ClassVar[int]
|
|
381
|
+
AUDIENCE_FIELD_NUMBER: _ClassVar[int]
|
|
382
|
+
ALLOW_INSECURE_TRANSPORT_FIELD_NUMBER: _ClassVar[int]
|
|
383
|
+
name: str
|
|
384
|
+
grpc_endpoint: str
|
|
385
|
+
max_payload_bytes: int
|
|
386
|
+
timeout: str
|
|
387
|
+
tls_ca_cert_pem: bytes
|
|
388
|
+
audience: str
|
|
389
|
+
allow_insecure_transport: bool
|
|
390
|
+
def __init__(self, name: _Optional[str] = ..., grpc_endpoint: _Optional[str] = ..., max_payload_bytes: _Optional[int] = ..., timeout: _Optional[str] = ..., tls_ca_cert_pem: _Optional[bytes] = ..., audience: _Optional[str] = ..., allow_insecure_transport: bool = ...) -> None: ...
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
|
|
2
|
+
"""Client and server classes corresponding to protobuf-defined services."""
|
|
3
|
+
import grpc
|
|
4
|
+
import warnings
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
GRPC_GENERATED_VERSION = '1.78.0'
|
|
8
|
+
GRPC_VERSION = grpc.__version__
|
|
9
|
+
_version_not_supported = False
|
|
10
|
+
|
|
11
|
+
try:
|
|
12
|
+
from grpc._utilities import first_version_is_lower
|
|
13
|
+
_version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
|
|
14
|
+
except ImportError:
|
|
15
|
+
_version_not_supported = True
|
|
16
|
+
|
|
17
|
+
if _version_not_supported:
|
|
18
|
+
raise RuntimeError(
|
|
19
|
+
f'The grpc package installed is at version {GRPC_VERSION},'
|
|
20
|
+
+ ' but the generated code in sandbox_pb2_grpc.py depends on'
|
|
21
|
+
+ f' grpcio>={GRPC_GENERATED_VERSION}.'
|
|
22
|
+
+ f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
|
|
23
|
+
+ f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
|
|
24
|
+
)
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: Copyright (c) 2025-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
2
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
|
|
4
|
+
"""Basic tests for the openshell package."""
|
|
5
|
+
|
|
6
|
+
import openshell
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def test_version() -> None:
|
|
10
|
+
"""Test that version is defined."""
|
|
11
|
+
assert openshell.__version__
|
openshell/py.typed
ADDED
|
File without changes
|