Skip to content

chore: release v0.12.0#333

Open
lroolle wants to merge 1 commit into
mainfrom
release/v0.12.0
Open

chore: release v0.12.0#333
lroolle wants to merge 1 commit into
mainfrom
release/v0.12.0

Conversation

@lroolle
Copy link
Copy Markdown
Member

@lroolle lroolle commented May 27, 2026

Summary

  • deva status: Docker-native workspace inspection (containers, mounts, agent homes, health)
  • Agent context injection: container-awareness to .claude/CLAUDE.md + AGENTS.md before agent start
  • Replace atlas-cli with ccx (thevibeworks/ccx v0.7.0)
  • 47 new tests

Test plan

  • bash scripts/test-workspace-context.sh (25/25)
  • bash scripts/test-status-helpers.sh (22/22)
  • bash scripts/test-container-slug.sh (59/59)
  • bash tests/test_release_utils.sh (55/55)
  • deva status / deva status -g / deva status --verbose
  • ccx binary verified in rebuilt image (v0.7.0)
  • Context injection verified in live workspace

- Add `deva status` command: Docker-native workspace inspection
  with container state, categorized mounts, agent homes, health
- Add agent context injection: container-awareness instructions
  written to .claude/CLAUDE.md and AGENTS.md before agent start
- Replace atlas-cli with ccx (thevibeworks/ccx v0.7.0)
- 47 new tests across status helpers and context injection

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings May 27, 2026 08:52
@claude-yolo
Copy link
Copy Markdown
Contributor

claude-yolo Bot commented May 27, 2026

Claude finished @lroolle's task in 3m 3s —— View job


🔒 Security Audit: deva v0.12.0

Status: ⚠️ CONDITIONAL APPROVAL with critical fixes required


🚨 BLOCKING Security Issues

1. Shell Injection in Config Processing (CRITICAL)

Location: process_volume_config() lines 2485-2487, process_var_config() lines 2548-2549

value="${value//\$(pwd)/$PWD}"    # Direct PWD expansion without escaping
value="${value/#\~/$HOME}"        # HOME expansion without validation

Attack Vector: Malicious .deva files with crafted paths containing shell metacharacters
Impact: Code execution during container launch
Fix: Fix this →

2. Path Traversal in dangerous_directory() (HIGH)

Location: Lines 444-456

bad_dirs=("$HOME" "/" "/etc" "/usr" "/var" "/bin" "/sbin" "/lib" "/lib64" "/boot" "/dev" "/proc" "/sys" "/tmp" "/root" "/mnt" "/media" "/srv")

Gaps: Missing /opt, /usr/local, .git/, Docker data dirs, symlink resolution
Attack Vector: Symlinks to sensitive dirs, relative path traversal
Impact: Host filesystem exposure
Fix: Fix this →

⚠️ High-Risk Design Decisions

3. Container Root Access (BY DESIGN)

Location: Dockerfile lines 172-174, docker-entrypoint.sh line 249

echo "$DEVA_USER ALL=(ALL) NOPASSWD: ALL" > "/etc/sudoers.d/$DEVA_USER"
chmod 666 /var/run/docker.sock  # Full Docker control

Impact: Complete container+host escape capability
Status: ✅ Documented as intentional for dev environments

4. Authentication Bypass Enforcement (BY DESIGN)

Location: docker-entrypoint.sh lines 345-368

claude --dangerously-skip-permissions  # Always injected
codex --dangerously-bypass-approvals-and-sandbox

Impact: Bypasses agent-level security controls
Status: ✅ Core architectural decision - container IS the sandbox


🔍 Security Assessment: New Features

✅ Context Injection (inject_workspace_context())

  • Security: Input sanitization via HTML comment markers
  • Risk: Low - controlled content injection
  • Validation: Proper marker-based replacement prevents accumulation

✅ Status Command (cmd_status())

  • Security: Implements credential redaction for env vars
  • Info Disclosure: Minimal - only shows container metadata
  • Validation: Proper masking of *KEY*|*TOKEN*|*SECRET*|*PASSWORD*|*CREDENTIALS*

✅ CCX Binary Replacement

  • Security: SHA256 verification for releases, pinned versions
  • Supply Chain: Uses GitHub releases with checksums
  • Validation: Binary verification via --help execution

📋 Required Tests Before Merge

  • Shell Injection Test: Verify config with VOLUME=$(whoami) fails safely
  • Path Traversal Test: Verify symlinks to /etc are rejected
  • Mount Validation: Test duplicate mount detection with edge cases
  • Credential Redaction: Verify secrets masked in logs/status output

🛡️ Security Hardening Recommendations

  1. Config Validation: Implement stricter regex validation for paths/env vars
  2. Mount Restrictions: Canonical path resolution before mount checks
  3. Audit Logging: Log mount attempts from dangerous directories
  4. Binary Verification: Consider GPG signature verification for ccx downloads

Recommendation: 🔴 BLOCK MERGE until shell injection and path traversal fixes applied.

The container-escape-by-design model is acceptable for development environments, but config processing vulnerabilities create uncontrolled attack surface.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ee46f05da3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

grep -F "Installing ccx pinned to $CCX_VERSION" <<<"$output" >/dev/null
grep -F "falling back to pinned go install" <<<"$output" >/dev/null
grep -F "atlas-cli installed" <<<"$output" >/dev/null
grep -F "ccx installed" <<<"$output" >/dev/null
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Update fake installer to produce ccx

In the CI smoke path, bash scripts/test-install-agent-tooling.sh now exits before this assertion because the fake go install above still writes $GOBIN/atl, while install_ccx verifies $DEVA_HOME/.local/bin/ccx --help; the captured output never reaches ccx installed. Updating the fake binary and final executable check from atl to ccx is needed to keep the smoke test green.

Useful? React with 👍 / 👎.

Comment thread tests/version-upgrade.sh
"--build-arg CODEX_VERSION=0.117.0" \
"--build-arg GEMINI_CLI_VERSION=0.35.3" \
"--build-arg ATLAS_CLI_VERSION=v0.1.4" \
"--build-arg CCX_VERSION=v0.1.4" \
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Fix stale ccx version expectation

The version-upgrade unit test still expects the old atlas pin after the switch to ccx; running bash tests/version-upgrade.sh fails with main build missing expected arg: --build-arg CCX_VERSION=v0.1.4 because the fake current image and new ccx pin are v0.7.0. This assertion should match the ccx version the test setup now advertises, or CI's Unit tests (version-upgrade.sh) job remains red.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Release bump to v0.12.0 introducing Docker-native workspace inspection (deva status), runtime agent context injection into workspace instruction files, and replacing atlas-cli with ccx across build/pin/label plumbing.

Changes:

  • Add deva status implementation backed by docker inspect, plus helper/test scripts for status formatting and mount categorization.
  • Inject container-awareness context into .claude/CLAUDE.md and AGENTS.md on startup (idempotent, replace semantics).
  • Replace atlas-cli with ccx throughout version pins, tool registry, Docker build args/labels, and installer logic.

Reviewed changes

Copilot reviewed 21 out of 21 changed files in this pull request and generated 13 comments.

Show a summary per file
File Description
versions.env Replace ATLAS_CLI_VERSION pin with CCX_VERSION.
tests/version-upgrade.sh Update fake docker/gh expectations for ccx version upgrade flow.
tests/test_release_utils.sh Update tool registry expectations from atlas-cli to ccx.
scripts/version-upgrade.sh Replace atlas env wiring with ccx and add build manifest output.
scripts/version-pins.sh Update pinned environment variable list to include CCX_VERSION.
scripts/update-version-pins.sh Refresh pins from thevibeworks/ccx instead of atlas-cli.
scripts/toolchain-report.sh Report CCX version instead of Atlas CLI.
scripts/test-workspace-context.sh New test script validating workspace context injection behavior.
scripts/test-version-targets.sh Update version override expectations to CCX_VERSION.
scripts/test-status-helpers.sh New tests for status helper functions extracted from deva.sh.
scripts/test-install-agent-tooling.sh Adjust installer test to look for ccx install output/version var.
scripts/resolve-tool-versions.sh Resolve ccx_version instead of atlas_cli_version.
scripts/release-utils.sh Replace tool registry entry and display-name mapping for ccx.
scripts/install-agent-tooling.sh Replace atlas installer with ccx release/go-install + skill install.
scripts/agent-context.md New reference content for container context injected into workspace files.
Makefile Replace atlas build arg/version override plumbing with ccx equivalents.
docs/devlog/20260524-status-and-agent-context.org New devlog describing status + context injection design.
Dockerfile.rust Replace atlas ARG/LABEL with ccx ARG/LABEL.
Dockerfile Replace atlas ARG/LABEL with ccx ARG/LABEL.
deva.sh Bump version, replace old status with docker-native cmd_status, and inject workspace context before agent start.
CHANGELOG.md Add v0.12.0 release notes covering status, context injection, and ccx switch.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Makefile
@echo " CODEX_VERSION Codex CLI version (default: $(CODEX_VERSION))"
@echo " GEMINI_CLI_VERSION Gemini CLI version (default: $(GEMINI_CLI_VERSION))"
@echo " ATLAS_CLI_VERSION Atlas CLI version (default: $(ATLAS_CLI_VERSION))"
@echo " CCX_VERSION Atlas CLI version (default: $(CCX_VERSION))"
Comment on lines +60 to +61
first_char=$(head -c1 "$ws1/AGENTS.md")
if [ "$first_char" != "" ]; then pass "no leading blank"; else fail "leading blank"; fi
Comment on lines +166 to +169
for _line in ${_lines_upgrade[@]+"${_lines_upgrade[@]}"}; do echo -e "$_line"; done
for _line in ${_lines_pinned[@]+"${_lines_pinned[@]}"}; do echo -e "$_line"; done
for _line in ${_lines_current[@]+"${_lines_current[@]}"}; do echo -e "$_line"; done
for _line in ${_lines_new[@]+"${_lines_new[@]}"}; do echo -e "$_line"; done
Comment thread tests/version-upgrade.sh
Comment on lines 101 to 104
case "${2:-}" in
repos/lroolle/atlas-cli/releases/latest)
echo "v0.1.4"
repos/lroolle/ccx/releases/latest)
echo "v0.7.0"
;;
Comment thread tests/version-upgrade.sh
echo "0ea08febdd7e3e055b03dd298bf57e669500b5c1"
;;
repos/lroolle/atlas-cli/releases/tags/v0.1.4)
repos/lroolle/ccx/releases/tags/v0.1.4)
Comment thread Makefile
CODEX_VERSION ?= 0.131.0
GEMINI_CLI_VERSION ?= 0.42.0
ATLAS_CLI_VERSION ?= v0.1.4
CCX_VERSION ?= v0.1.4
Replaced with workspace injection (=inject_workspace_context()=, 27
lines in docker-entrypoint.sh):
- Claude: append marked block to =.claude/CLAUDE.md= (gitignored)
- Codex: append to existing =AGENTS.md= (only if file exists)
Comment on lines +113 to +118
ccx_platform() {
local os arch
os="$(uname -s)"
arch="$(uname -m)"
case "$arch" in
x86_64) arch="x86_64" ;;
Comment on lines +146 to +148
grep -F "Installing ccx pinned to $CCX_VERSION" <<<"$output" >/dev/null
grep -F "falling back to pinned go install" <<<"$output" >/dev/null
grep -F "atlas-cli installed" <<<"$output" >/dev/null
grep -F "ccx installed" <<<"$output" >/dev/null
Comment thread scripts/release-utils.sh
github-commit)
local branch="master"
[[ $source == "lroolle/atlas-cli" ]] && branch="main"
[[ $source == "thevibeworks/ccx" ]] && branch="main"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants