setup-devcontainer

Pass

Audited by Gen Agent Trust Hub on Oct 15, 2026

Risk Level: SAFECOMMAND_EXECUTIONREMOTE_CODE_EXECUTIONPRIVILEGE_ESCALATIONPERSISTENCEINDIRECT_PROMPT_INJECTIONDYNAMIC_EXECUTIONEXTERNAL_DOWNLOADS
Full Analysis
  • [COMMAND_EXECUTION]: The skill utilizes sudo, iptables, and ipset to implement a default-deny network firewall within the devcontainer. It also employs git for workspace initialization and docker commands to detect and remove stale containers from previous setups.
  • [REMOTE_CODE_EXECUTION]: The skill automates the installation of AI CLI tools by executing vendor-provided shell scripts (curl | sh). Additionally, it supports a "skill-sync" feature that uses npx -y skills add to fetch and install agent skills from user-specified remote sources during container startup.
  • [PRIVILEGE_ESCALATION]: Container runtime security is enforced via runArgs in devcontainer.json, which drops all capabilities by default and selectively grants only those required for the devcontainer's operation (e.g., CHOWN, DAC_OVERRIDE, NET_ADMIN). It also configures specifically scoped sudo rules for the firewall management scripts.
  • [PERSISTENCE]: The skill ensures consistent environment settings by modifying ~/.bashrc to load project environment variables and utilizing the postStartCommand to re-apply the network firewall and background refresh loop on every container session start.
  • [INDIRECT_PROMPT_INJECTION]: The skill possesses an attack surface for indirect injection through its ingestion of external data.
  • Ingestion points: Data is ingested from network-manifest.json, allowed-domains.local.txt, and external skill sources via the npx skills add command.
  • Boundary markers: The "Own-Block Contract" employs specific marker comments (e.g., # --- Claude Code ---) to delimit and protect tool-specific configurations within shared lifecycle scripts.
  • Capability inventory: The skill has capabilities for executing sudo commands, modifying the file system, and making outbound network requests.
  • Sanitization: External content is handled using structured JSON processing via jq and string-escaping logic within the rendering library.
  • [DYNAMIC_EXECUTION]: Utility scripts such as render-devcontainer.sh and patch-json-array-if-absent.sh are used to dynamically assemble shell scripts and modify JSON configuration files at runtime to tailor the devcontainer environment to the user's selections.
  • [EXTERNAL_DOWNLOADS]: The firewall system dynamically fetches current IP ranges from well-known services, including api.github.com and gstatic.com, to maintain a reliable and secure network allowlist for the agent environment.
Audit Metadata
Risk Level
SAFE
Analyzed
Oct 15, 2026, 07:20 AM