/** * Configuration for Sandbox Runtime * This is the main configuration interface that consumers pass to SandboxManager.initialize() */ import { z } from 'zod'; /** * Schema for MITM proxy configuration * Allows routing specific domains through an upstream MITM proxy via Unix socket */ declare const MitmProxyConfigSchema: z.ZodObject<{ socketPath: z.ZodString; domains: z.ZodArray, "many">; }, "strip", z.ZodTypeAny, { socketPath: string; domains: string[]; }, { socketPath: string; domains: string[]; }>; /** * Schema for upstream/parent HTTP proxy configuration. * Used when SRT itself runs behind a corporate proxy and cannot make direct * outbound connections. */ declare const ParentProxyConfigSchema: z.ZodObject<{ http: z.ZodOptional; https: z.ZodOptional; noProxy: z.ZodOptional; }, "strip", z.ZodTypeAny, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }>; /** * Network configuration schema for validation */ export declare const NetworkConfigSchema: z.ZodObject<{ allowedDomains: z.ZodArray, "many">; deniedDomains: z.ZodArray, "many">; allowUnixSockets: z.ZodOptional>; allowAllUnixSockets: z.ZodOptional; allowLocalBinding: z.ZodOptional; httpProxyPort: z.ZodOptional; socksProxyPort: z.ZodOptional; mitmProxy: z.ZodOptional, "many">; }, "strip", z.ZodTypeAny, { socketPath: string; domains: string[]; }, { socketPath: string; domains: string[]; }>>; parentProxy: z.ZodOptional; https: z.ZodOptional; noProxy: z.ZodOptional; }, "strip", z.ZodTypeAny, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }, { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }>; /** * Filesystem configuration schema for validation */ export declare const FilesystemConfigSchema: z.ZodObject<{ denyRead: z.ZodArray; allowRead: z.ZodOptional>; allowWrite: z.ZodArray; denyWrite: z.ZodArray; allowGitConfig: z.ZodOptional; }, "strip", z.ZodTypeAny, { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }, { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }>; /** * Configuration schema for ignoring specific sandbox violations * Maps command patterns to filesystem paths to ignore violations for. */ export declare const IgnoreViolationsConfigSchema: z.ZodRecord>; /** * Ripgrep configuration schema */ export declare const RipgrepConfigSchema: z.ZodObject<{ command: z.ZodString; args: z.ZodOptional>; argv0: z.ZodOptional; }, "strip", z.ZodTypeAny, { command: string; args?: string[] | undefined; argv0?: string | undefined; }, { command: string; args?: string[] | undefined; argv0?: string | undefined; }>; /** * Seccomp configuration schema (Linux only) * Allows specifying custom paths to seccomp binaries */ export declare const SeccompConfigSchema: z.ZodObject<{ bpfPath: z.ZodOptional; applyPath: z.ZodOptional; }, "strip", z.ZodTypeAny, { bpfPath?: string | undefined; applyPath?: string | undefined; }, { bpfPath?: string | undefined; applyPath?: string | undefined; }>; /** * Main configuration schema for Sandbox Runtime validation */ export declare const SandboxRuntimeConfigSchema: z.ZodObject<{ network: z.ZodObject<{ allowedDomains: z.ZodArray, "many">; deniedDomains: z.ZodArray, "many">; allowUnixSockets: z.ZodOptional>; allowAllUnixSockets: z.ZodOptional; allowLocalBinding: z.ZodOptional; httpProxyPort: z.ZodOptional; socksProxyPort: z.ZodOptional; mitmProxy: z.ZodOptional, "many">; }, "strip", z.ZodTypeAny, { socketPath: string; domains: string[]; }, { socketPath: string; domains: string[]; }>>; parentProxy: z.ZodOptional; https: z.ZodOptional; noProxy: z.ZodOptional; }, "strip", z.ZodTypeAny, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }, { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }, { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }>; filesystem: z.ZodObject<{ denyRead: z.ZodArray; allowRead: z.ZodOptional>; allowWrite: z.ZodArray; denyWrite: z.ZodArray; allowGitConfig: z.ZodOptional; }, "strip", z.ZodTypeAny, { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }, { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }>; ignoreViolations: z.ZodOptional>>; enableWeakerNestedSandbox: z.ZodOptional; enableWeakerNetworkIsolation: z.ZodOptional; ripgrep: z.ZodOptional>; argv0: z.ZodOptional; }, "strip", z.ZodTypeAny, { command: string; args?: string[] | undefined; argv0?: string | undefined; }, { command: string; args?: string[] | undefined; argv0?: string | undefined; }>>; mandatoryDenySearchDepth: z.ZodOptional; allowPty: z.ZodOptional; seccomp: z.ZodOptional; applyPath: z.ZodOptional; }, "strip", z.ZodTypeAny, { bpfPath?: string | undefined; applyPath?: string | undefined; }, { bpfPath?: string | undefined; applyPath?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { network: { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }; filesystem: { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }; ignoreViolations?: Record | undefined; enableWeakerNestedSandbox?: boolean | undefined; enableWeakerNetworkIsolation?: boolean | undefined; ripgrep?: { command: string; args?: string[] | undefined; argv0?: string | undefined; } | undefined; mandatoryDenySearchDepth?: number | undefined; allowPty?: boolean | undefined; seccomp?: { bpfPath?: string | undefined; applyPath?: string | undefined; } | undefined; }, { network: { allowedDomains: string[]; deniedDomains: string[]; allowUnixSockets?: string[] | undefined; allowAllUnixSockets?: boolean | undefined; allowLocalBinding?: boolean | undefined; httpProxyPort?: number | undefined; socksProxyPort?: number | undefined; mitmProxy?: { socketPath: string; domains: string[]; } | undefined; parentProxy?: { http?: string | undefined; https?: string | undefined; noProxy?: string | undefined; } | undefined; }; filesystem: { denyRead: string[]; allowWrite: string[]; denyWrite: string[]; allowRead?: string[] | undefined; allowGitConfig?: boolean | undefined; }; ignoreViolations?: Record | undefined; enableWeakerNestedSandbox?: boolean | undefined; enableWeakerNetworkIsolation?: boolean | undefined; ripgrep?: { command: string; args?: string[] | undefined; argv0?: string | undefined; } | undefined; mandatoryDenySearchDepth?: number | undefined; allowPty?: boolean | undefined; seccomp?: { bpfPath?: string | undefined; applyPath?: string | undefined; } | undefined; }>; export type MitmProxyConfig = z.infer; export type ParentProxyConfig = z.infer; export type NetworkConfig = z.infer; export type FilesystemConfig = z.infer; export type IgnoreViolationsConfig = z.infer; export type RipgrepConfig = z.infer; export type SeccompConfig = z.infer; export type SandboxRuntimeConfig = z.infer; export {}; //# sourceMappingURL=sandbox-config.d.ts.map