Skip to content
IOmergent

AI Security Reference ArchitecturesTrack B: Agent runtimes

B4 Developer AI

B4 covers AI that writes, reviews and ships code: assistants in the IDE, bots in CI, and autonomous agents working tickets in sandboxes. It's feasible today for a 50 to 500 person company. Attended and CI use is mostly buying tools and setting GitHub controls, and a vendor-hosted agent fleet is buy plus glue. A self-hosted fleet is mostly custom work and takes 8 to 16 weeks.

Buy + glue Owner: Eng + DevEx Control: Med to High Stand up: Days to 4 mos

Who it fits: Engineering teams using AI across the SDLC. Two variants that share one control set: attended work in the IDE plus bots in CI, and autonomous background agents.

Frameworks: AWS GenAI scope 2 and 3AWS agentic scope Prescribed (attended) to supervised (fleet)OWASP ASI01 Agent Goal Hijack, ASI04 Agentic Supply Chain Vulnerabilities, ASI05 Unexpected Code Execution

Last reviewed October 2026. Vendor tiers and features change often. Spot something out of date? Tell us.

FlowsPrompt / responseTool callIdentity / credentialTelemetryUnsafe pathBlocked
BoundariesYour boundaryThird party
2 variants
B4.1

Attended and CI

A developer drives the assistant in the IDE, and bots review pull requests in CI. The org sets the guardrails through managed settings and GitHub controls.
Developer workstation123456789ACTORDeveloperapproves each actionTELEMETRYSession telemetryEDR + OTel to SIEMSIMPLIFYMODELModel accessTrack A, via AI gatewayWORKLOADIDE / CLI assistantCursor, Copilot, ClaudeCONTROLManaged settingsvia MDM: permissions, MCPKEEPCONTROLEDR + inventoryAI module, MCP, skillsSIMPLIFYTOOLSApproved MCP toolsfrom the toolshedTOOLSLocal repo + shellno prod creds on boxKEEPTOOLSGitHubPRs through reviewWORKLOADCI botsOIDC, no fork secretsKEEP

Data flow

  1. 1The developer drives the assistant and approves actions as it works.
  2. 2Org-managed settings, delivered through MDM, fix the permission mode, allowed commands and which MCP servers can load. Server-side settings are skipped once a custom gateway URL is set.
  3. 3Model calls go through the AI gateway, not personal keys. For PHI, check BAA scope first: Claude Code's HIPAA setup excludes the IDE extensions, and Anthropic's pages indicate LLM gateways aren't covered.
  4. 4The assistant edits the local repo and runs commands. No prod creds live on the machine. Dev secrets come from a password manager CLI such as 1Password, from a vault that holds only low-privilege credentials.
  5. 5Only toolshed MCP servers are available: the approved list behind the MCP gateway (see B3).
  6. 6Changes ship as pull requests through normal review.
  7. 7Session telemetry and EDR feed the SIEM.
  8. 8Your EDR's AI module and endpoint inventory tools find local MCP servers, IDE extensions, skills and rules files. MCP servers and extensions can be blocked; skills and rules files can only be detected.
  9. 9Pull requests also trigger CI bots that review code and suggest fixes. The job signs in to the model with job-scoped OIDC, fork PRs run with no secrets, and the bot can only comment or push to a bot branch. GitHub settings and CODEOWNERS, not the bot's prompt, keep it from approving or merging.

Attended and CI: build or buy

Buy + glue

What you can buy for each box in the diagram, the open source option, and the part you still build yourself.

ComponentBuyOpen sourceYou buildMaturity
Developer approves actionsPolicy in the assistant's admin settings to turn off bypass and auto-accept modes·Usage policy and short trainingGA
IDE / CLI assistantClaude Team Premium or Enterprise, GitHub Copilot Business or Enterprise, Cursor Teams or EnterpriseCline, Continue, Aider·GA
Managed settingsClaude Code managed settings delivered by Intune, Jamf or Iru (formerly Kandji); Copilot MCP policy; Cursor Enterprise controlsAnthropic's MDM deployment templatesMDM profiles per OS, tested before rolloutGA
EDR + endpoint inventoryCrowdStrike Falcon Guardian (covers Claude Code through its hooks); SentinelOne AI Usage Control; StepSecurity Dev Machine Guard, Koi, BackslashStepSecurity dev-machine-guard scanner (small project)MDM script that finds MCP configs, extensions, skills and rules files and sends them to the SIEMGA
Model access via gatewayClaude apps gateway (self-hosted, included with Claude Code) or your Track A gatewayLiteLLMGateway hosting and IdP sign-in setupGA
Approved MCP toolsClaude Code managed MCP allowlist; Copilot MCP registry policyToolshed from B3Match servers by URL or command, not namePreview
Local repo, no prod creds1Password Business or similar password manager CLIAnthropic sandbox runtime (research preview)Move prod credentials off laptopsGA
Session telemetryClaude Code OpenTelemetry export; Elastic Claude Code integration; Copilot and Cursor audit logs on Enterprise tiersOpenTelemetry CollectorCollector, parsing and EDR correlationGA
CI bot (review comments, bot branch)Copilot code review, Claude Code GitHub Action, Codex code review GitHub App installation tokensanthropics/claude-code-actionBot config that runs on trusted events onlyGA
Fork PRs run without secretsGitHub Actions defaults for pull request eventszizmor, actionlintAudit workflows and remove pull_request_target jobs that check out PR codeGA
Job-scoped OIDCGitHub OIDC to AWS, GCP or Azure; Anthropic Workload Identity Federation·One federation rule per repo or workflowGA
Human review, protected mainGitHub rulesets with required reviews and CODEOWNERS··GA

Rollout steps

#StepWhoEffort
1Pick one or two sanctioned assistants, buy team seats and block personal accountsSecurity engineer2-3 days
2Write the managed policy and deliver it through MDM, plus the admin console as a backupPlatform engineer1-2 weeks
3Route model calls through the gateway and confirm policy still applies on each devicePlatform engineer3-5 days
4Roll out endpoint inventory for MCP servers, extensions, skills and rules filesSecurity engineer1 week
5Move dev secrets to a password manager CLI and remove prod credentials from laptopsPlatform engineer1-3 weeks
6Build SIEM alerts for unapproved MCP servers, bypass attempts and settings changesSecurity engineer1 week
7Set Actions tokens to read-only, stop Actions from approving PRs and require approval for fork workflowsPlatform engineer2-3 days
8Scan workflows with zizmor, remove risky pull_request_target jobs and pin actionsPlatform engineer2-5 days
9Set up workload identity federation for model calls and delete stored model keysPlatform engineer2-3 days
10Add rulesets requiring human and code owner review, with no bot self-mergePlatform engineer1-2 days

What you still build

  • MDM configuration profiles for macOS and Windows, tested per assistant
  • Inventory pipeline from developer machines to the SIEM if you don't buy one
  • Detection rules for skills and rules files, which no product blocks
  • Removing prod credentials from developer laptops
  • Workflow hardening pass across all repos
  • Workload identity federation rules per repo

Gotchas

  • Claude Code skips server-managed settings when it points at a custom base URL or a cloud provider, so a gateway setup needs MDM-delivered settings
  • Server-managed settings are a client-side control. Anthropic says they aren't a security boundary on unmanaged devices
  • Claude Code HIPAA coverage excludes the VS Code and JetBrains extensions, and per Anthropic's translated HIPAA pages, routing through an LLM gateway isn't eligible
  • Skills and rules files can only be detected, not blocked. Only MCP servers and VS Code extensions can be blocked
  • Copilot's registry-only MCP policy is in public preview, and Cursor's MCP controls need Enterprise
  • Command logging is off by default and captures sensitive content when on
  • The real fork risk is pull_request_target or workflow_run jobs that check out PR code. AI review bots tempt teams into this because they need a model key
  • A leftover Anthropic API key in the environment silently overrides workload identity federation
  • Enforce suggest-only with GitHub settings and CODEOWNERS, not the bot's prompt
B4.2

Autonomous fleet

Agents work tickets unattended in sandboxes. The merge gate is the control that matters most. Vendor-hosted agents are the fast path; self-hosting the fleet is 8 to 16 weeks of custom work.
12345678ACTORDeveloperassigns a ticketTELEMETRYSession auditcommands, reads to SIEMSIMPLIFYMODELModel accessTrack A, via AI gatewayWORKLOADCoding agentephemeral sandbox per taskSIMPLIFYIDENTITYOIDC + GitHub Appone repo, 1 hr tokensKEEPCONTROLEgress allowlistall else deniedKEEPTOOLSGitHubbranch protection onCONTROLCI + merge gatetests, scans, human reviewKEEPTOOLSApproved toolshedallowlisted MCP onlyTOOLSPackage registriesvia package firewallTOOLSUntrusted contentissues, deps, webWORKLOADProductiondeploys from CI only

Data flow

  1. 1A developer assigns a ticket. The agent starts in a fresh sandbox that is destroyed when the task ends.
  2. 2Credentials come from OIDC and a GitHub App, scoped to one repo. GitHub App tokens last one hour and can be revoked early.
  3. 3Model calls go through the AI gateway for logging, DLP and budgets.
  4. 4Issues, dependencies and web content are treated as untrusted data.
  5. 5The agent can only open a pull request. Branch protection blocks direct pushes.
  6. 6CI runs tests, secret scanning and SCA. A human approves before merge and deploy.
  7. 7Only allowlisted MCP tools from the toolshed are available.
  8. 8Egress is limited to the gateway and registries behind a package firewall. Every command and file read is logged.

Autonomous fleet: build or buy

Buy + glue

What you can buy for each box in the diagram, the open source option, and the part you still build yourself.

ComponentBuyOpen sourceYou buildMaturity
Ticket assignmentCopilot cloud agent, Cursor cloud agents, Claude Code on the web, OpenAI Codex·Ticket-to-sandbox orchestration if self-hostedGA
Ephemeral sandboxVendor-hosted agent sandboxes; E2B, Daytona, GitHub Codespaces or Coder for self-hostedAnthropic dev container with firewall, Anthropic sandbox runtimeSandbox image, lifecycle and guaranteed teardownGA
Per-task scoped credentialsBuilt into Copilot cloud agent; GitHub App installation tokensactions/create-github-app-tokenToken broker that mints one-repo tokens per task if self-hostedGA
Egress allowlistCopilot agent firewall, Codex internet access controls, Claude Code on the web network settings, Harden-RunnerDev container firewall script, Squid or Envoy, sandbox runtime proxiesEgress proxy and allowlist ownership if self-hostedGA
Branch protectionGitHub rulesets; Copilot pushes only to its own branch··GA
CI and merge gateThe Attended and CI variant's controls, plus GitHub Secret Protection and Code Securitygitleaks, TruffleHog, OSV-ScannerRequired checks on every agent PRGA
Package firewallSocket (Enterprise for self-hosted or custom registries), StepSecurity Secure Registry, JFrog CurationSocket Firewall free tier, Verdaccio, devpiPoint sandbox package config at the proxyGA
Untrusted contentNo product removes prompt injection·Limit tools, treat issues and web content as data, review outputNo product
Session auditCopilot session logs, Claude Code telemetry and hooks, sandbox provider logsOpenTelemetry CollectorHook that logs every command and file read to the SIEMPreview

Rollout steps

#StepWhoEffort
1Pilot one vendor-hosted agent on 3 to 5 repos and review its firewall defaultsPlatform engineer1 week
2Add rulesets requiring code owner review and passing checks on agent PRsPlatform engineer2-3 days
3Put a package firewall in front of registries and point the agent setup at itPlatform engineer1 week
4Reuse the CI merge gate from the Attended and CI variant as required checksPlatform engineer1-2 days
5Set limits on agent PR volume and size per developerEngineering managerOngoing
6Self-hosted only: build the token broker, sandbox image, egress proxy, orchestration and audit hooksPlatform engineer and security engineer8-16 weeks

What you still build

  • Per-task GitHub App token broker that checks the ticket and repo before minting
  • Egress proxy and a named owner for its allowlist
  • Ticket-to-sandbox orchestration with guaranteed teardown
  • Audit hooks that send every command and file read to the SIEM
  • PR volume policy so reviewers aren't swamped

Gotchas

  • Reviewer time on bot PRs is the real limit and a hidden cost that can exceed tool spend
  • Usage-billed agent work is the largest cost and swings with task volume and model choice
  • GitHub App installation tokens always last 1 hour. You can narrow repos and permissions but not shorten them
  • Anthropic's dev container doesn't stop a malicious project from exfiltrating what's inside, so use a persistent container only for trusted repos
  • Users report Claude Code on the web's trusted allowlist drifting from the hosts tools actually call
  • OpenAI now labels Codex Cloud as legacy in its docs
  • Self-hosting the fleet is mostly custom work and takes 8 to 16 weeks. Vendor-hosted agents are the fast path.

Common use cases

  • Pair programming in the IDE
  • PR review and test generation in CI
  • Dependency upgrades and migrations
  • Backlog tickets worked unattended

Key risks

  • Injection via issues, READMEs and dependencies
  • Malicious MCP servers, extensions, skills and rules files
  • Secrets exposed to fork or untrusted CI runs
  • Reviewer time on bot PRs, which can cost more than the tools
  • Token scope creep across repos

Fast path

  • SIMPLIFYPersistent dev container for trusted repos only, with no prod creds and allowlisted egress
  • KEEPShort-lived scoped tokens (GitHub App, OIDC)
  • KEEPBranch protection and human review
  • KEEPNo secrets on fork or untrusted runs
  • SIMPLIFYSession and job logs to bucket first

Sources

Vendor documentation and announcements we checked for this page. Products are examples of a category, not endorsements.

Not sure which pieces to buy and which to build?

Bring the AI tools your teams use today and the data they touch. In a 30-minute call we map you to these models and name the controls to add first. No sales pitch.

Talk to a CISO