Allow per-session sandbox override for local VM and benchmark

Resolved 💬 3 comments Opened Apr 24, 2026 by oxsignal Closed Apr 24, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

What variant of Codex are you using?

CLI

What feature would you like to see?

I have encountered several issues when using Codex for I/O benchmarking involving QEMU/KVM.

Codex can edit and build code in my local workspace, but in some cases it cannot run the actual benchmark because the session sandbox blocks required host-side operations.

A concrete example is virtio-fs benchmarking with QEMU + virtiofsd. The workflow works from my normal shell, but Codex cannot complete it because the sandbox blocks the local socket/IPC setup needed by virtiofsd.

This makes systems and performance work harder than it needs to be. Codex can prepare the code and scripts, but I still have to run them manually and send the results back.

Requested improvement:

  • allow an explicit per-session sandbox override
  • make it opt-in and clearly visible
  • ideally support local VM/socket/process-heavy workflows without

requiring a separate environment

Thanks for your concern.

Additional information

_No response_

View original on GitHub ↗

3 Comments

github-actions[bot] contributor · 4 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #17660
  • #19015
  • #18005
  • #18113
  • #19256

Powered by Codex Action

oxsignal · 4 months ago

I’ve checked #17660 and noticed it covers part of my request. While I understand that lifting sandbox restrictions is risky, it would be great to have an opt-in feature for individual sessions with a proper disclaimer where no sensitive information is at stake. I’m wondering if the strict sandbox policy is mainly to prevent the development of abusive services using Codex.

oxsignal · 4 months ago

Indirectly bypassing sandbox restrictions via Remote Execution (SSH/SCP)

Even though this issue is closed, I’m sharing this for developers who are still struggling with sandbox limitations.
After some research, I have found a way to indirectly bypass the Codex sandbox environment. The core idea is to offload restricted tasks to an external development environment.

Steps to implement:

  1. Prepare a dedicated environment: Set up a remote VM, Docker container, or a separate lab environment for testing.
  2. Generate SSH keys: Create an SSH key pair specifically for Codex to use.
  3. Configure SSH access: Set up the target machine to allow authentication via the generated SSH key.
  4. Command Delegation: Direct Codex to transfer files via scp and execute commands via ssh, then retrieve the output.

By using this method, I was able to work around tasks that Codex cannot perform locally, such as VM-level file I/O operations.

---
⚠️ Important Security Note:
Please ensure that the remote machine Codex accesses is a strictly isolated environment. Do not use a machine that contains critical system information or sensitive data.