[BUG] Network requests outside of sandbox don't trigger `PermissionRequest` hook

Resolved 💬 5 comments Opened Feb 5, 2026 by fongandrew Closed Mar 12, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

If I tell Claude to use sandboxed bash to do something which triggers a network request outside of the sandbox, I get a permission prompt. Any PermissionRequest hook I have for this does not get called.

<img width="842" height="606" alt="Image" src="https://github.com/user-attachments/assets/4f2e6bcf-d2ee-4119-bb8c-97bc053a273f" />

What Should Happen?

The PermissionRequest hook should be triggered so it has a chance to auto-approve or deny network requests without user intervention.

Steps to Reproduce

  1. Clone repro at https://github.com/fongandrew/claude-sandbox-network-request. This just has a PermissionRequest hook that spits out a log file.
  2. Run Claude Code there
  3. Tell Claude Code to "use sandboxed bash to curl example.com"
  4. Wait until permission request pops up
  5. Check file system to see no log file appears

If you try the same thing with "use unsandboxed bash to curl example.com", it should generate the log file though.

Claude Model

Not sure / Multiple models

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.31 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗