[BUG] Network requests outside of sandbox don't trigger `PermissionRequest` hook
Status Closed — not planned
Reported on v2.1.31
Maintainer reply None cached
Activity 5 comments · opened Feb 5, 2026 · 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
- Clone repro at https://github.com/fongandrew/claude-sandbox-network-request. This just has a
PermissionRequesthook that spits out a log file. - Run Claude Code there
- Tell Claude Code to "use sandboxed bash to curl example.com"
- Wait until permission request pops up
- 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_
5 Comments
Also present in 2.1.32
This happen to me too
Closing for now — inactive for too long. Please open a new issue if this is still relevant.
This is still a thing in 2.1.76. It appears to fire a Notification prompt instead. I suspect this is so that the agent is not actually blocked and can keep working, but it's still weird and surprising
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.