TL;DR: A host-written settings file can redirect a live Claude Cowork session through a PreToolUse hook, Bloom Security reports, without breaking the sandbox. For practitioners, that shifts control priority to host-path integrity and connector governance around agent sessions.
Editorial analysis by NHI Mgmt Group, based on content published by Bloom Security: “Poisoned Coworker: Hijacking Claude Cowork”.
Key questions
Q: Why can a host file control a live AI agent session?
A: A host file can redirect name resolution at the operating system level, so a live AI agent may be sent to a different endpoint than the one it intended to call.
Q: How do pre-execution hooks change agent security?
A: Pre-execution hooks add a policy checkpoint before an agent runs a tool, sends a request, or writes output.
Q: What should teams do first when an AI agent session is hijacked?
A: First, revoke the agent’s active session, invalidate any bearer tokens or API keys it is using, and block the tool connections it can still reach.
Practitioner guidance
- Monitor synced agent configuration paths Watch the host-side settings file and any adjacent sync directory for unexpected writes, especially from processes other than the agent itself.
- Restrict connector grants per task Limit every connector to the minimum scope needed for the current session and remove access when the task is complete.
- Shorten live agent session lifetime Force agent sessions to end when the work ends so approved authority, browser state, and background jobs do not persist beyond the task.
Bottom line: A live AI agent session can be redirected through its host-side configuration path even when the sandbox remains intact.
Glossary terms: Claude Cowork, PreToolUse Hook, Session Hijacking, Connector scope
Explore further
View Full Forum → | NHI Foundation Course → | Our Services → | Read the full analysis →
AI agent sessions are becoming privileged runtime identities, not just interactive tools. Bloom Security shows that the dangerous control point is the configuration path the session trusts, not the sandbox boundary it advertises. That shifts governance from prompt safety to runtime authority, file integrity, and delegated access scope. Practitioners should treat the session itself as a governed identity surface.
A question worth separating out:
Q: How should teams limit connector scope for AI agents?
A: Limit connector scope by granting each agent only the specific APIs, folders, data sets, and actions it needs, with separate credentials for each connector. Use short-lived tokens, explicit allowlists, and per-connector policy checks so one integration cannot laterally access others. Tight scoping also makes revocation and audit trails clearer when an agent is offboarded or compromised.
👉 Read our full editorial: Modified host settings file can hijack a Claude Cowork session