mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:31:09 +00:00
Add an authenticated Windows sandbox provisioning client (#42337)
## What changed - Add a client for the packaged Windows sandbox provisioning service that verifies the named-pipe server belongs to the running `CodexSandboxService` process before exchanging a versioned provisioning request. - Treat an absent, busy, timed-out, or disconnected service as unavailable while surfacing provisioning and authentication failures. - Send the complete `WindowsSandboxProvisioningSettings` and classify inherited HTTP and SOCKS proxy listeners separately for managed-policy validation. - Share bounded frame-readiness handling between runner and provisioning IPC. ## Testing - Extend proxy environment tests to cover network-enabled profiles, mixed HTTP and SOCKS listeners, explicit proxy-port overrides, case-insensitive schemes, and unclassified protocols. GitOrigin-RevId: 6ff6741fc3ecd76314a7a045523a8d7a7e7af686
This commit is contained in:
1 parent
301a7c5e01
commit
dcfcb570b2
7 files changed
+491
-58
No files matched your search
@@ -8,6 +8,9 @@ mod ssh_config_dependencies;
|
||||
use std::fmt;
|
||||
use std::sync::Arc;
|
||||
|
||||
use serde::Deserialize;
|
||||
use serde::Serialize;
|
||||
|
||||
/// Cancellation hook used by Windows sandbox capture backends.
|
||||
#[derive(Clone)]
|
||||
pub struct WindowsSandboxCancellationToken {
|
||||
@@ -38,7 +41,8 @@ impl fmt::Debug for WindowsSandboxCancellationToken {
|
||||
pub use codex_protocol::config_types::WindowsSandboxProxySettingsMode;
|
||||
|
||||
/// Network settings installed by an administrator during managed Windows sandbox setup.
|
||||
#[derive(Clone, Debug, Default, PartialEq, Eq)]
|
||||
#[derive(Clone, Debug, Default, Deserialize, Serialize, PartialEq, Eq)]
|
||||
#[serde(deny_unknown_fields)]
|
||||
pub struct WindowsSandboxProvisioningSettings {
|
||||
/// Loopback proxy ports permitted for the offline sandbox identity.
|
||||
pub proxy_ports: Vec<u16>,
|
||||
@@ -79,6 +83,8 @@ mod path_normalization;
|
||||
#[cfg(target_os = "windows")]
|
||||
mod process;
|
||||
#[cfg(target_os = "windows")]
|
||||
mod provisioning_client;
|
||||
#[cfg(target_os = "windows")]
|
||||
mod provisioning_protocol;
|
||||
#[cfg(target_os = "windows")]
|
||||
mod resolved_permissions;
|
||||
@@ -259,6 +265,10 @@ pub use process::read_handle_loop;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use process::spawn_process_with_pipes;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_client::WindowsSandboxProvisioningOutcome;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_client::provision_windows_sandbox_via_service;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::FramedProvisioningMessage;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::PROVISIONING_PROTOCOL_VERSION;
|
||||
@@ -271,6 +281,8 @@ pub use provisioning_protocol::SandboxProvisioningRequest;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::SandboxProvisioningResponse;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::WindowsSandboxProxyListeners;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::read_provisioning_frame;
|
||||
#[cfg(target_os = "windows")]
|
||||
pub use provisioning_protocol::write_provisioning_frame;
|
||||
|
||||
Reference in new issue
Block a user