Skip to content

[Codex Security] Compromising DCDash can turn the next Ansible convergence into root code execution - #10

Draft
EmDecay wants to merge 1 commit into
mainfrom
codex-security/arp_89f34934b78fdbeaa4edaaccf20ddb67
Draft

EmDecay wants to merge 1 commit into
mainfrom
codex-security/arp_89f34934b78fdbeaa4edaaccf20ddb67

Conversation

@EmDecay

@EmDecay EmDecay commented Nov 18, 2026

Copy link
Copy Markdown
Collaborator

DCDash now runs from a root-owned application tree isolated from service-writable runtime data.

  • Privileged Git and pip consume only hamstack_dcdash_application_dir, so a compromised dcdash process cannot plant code for the next convergence.
  • Realpath-based overlap checks and fail-closed ownership checks reject aliased, symlinked, service-owned, or broadly writable build paths before privileged processing.
  • The systemd sandbox exposes only database, report, backup, and certificate directories for writes, preserving the service-to-root boundary.
  • Existing persistent paths, native TLS, Gunicorn launch, inventory controls, Gatus URL, restart handling, and /health behavior remain intact.

Static Verification Checks

  • Trusted build inputs isolated (Passed) — roles/services/dcdash/tasks/main.yml routes Git and pip through root-owned paths, closing service-to-root code injection.

  • Writable aliases rejected (Passed) — tasks/main.yml resolves aliases and rejects overlapping or writable application directories before privileged consumers can process them.

  • Runtime writes remain bounded (Passed) — dcdash.service.j2 omits application storage from ReadWritePaths, keeping source and virtualenv immutable to the DCDash account.

  • Service behavior remains intact (Passed) — dcdash.service.j2 and dcdash.env.j2 retain Gunicorn, native TLS, and persistent runtime paths, preserving normal startup behavior.

  • Health behavior remains intact (Passed) — tasks/main.yml retains restart and HTTPS health logic, preserving convergence signaling and external availability checks.

  • Inventory contract remains aligned (Passed) — defaults/main.yml and docs/variables.md declare matching application-directory defaults, preserving the public inventory contract.

  • Static scope respected (Passed) — Final diff inspection was source-only; runtime checks were not performed, establishing compliance with static verification scope.

  • Finding: acf_033550b0b4d76f69639b34dfb1e88f2e

  • Patch: arp_89f34934b78fdbeaa4edaaccf20ddb67

  • Base commit: 0ffb68937bc72420999f9d67bc8af90feb1ef617

  • Patch SHA-256: e19a4a044b4eb20b77878178f1047df3fc951cc3a4576d6f3621e2e284e8f27b

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.

1 participant