Skip to content

Coding-agent CLI honours managed configuration from a world-writable shared path

coding-agent-shared-config-trust is a high severity check in the ai category, written in shell. Its source is templates/ai/coding-agent/coding-agent-shared-config-trust.sh in cert-x-gen-templates.

Plants an identical benign managed-settings file in two shared config roots that differ only in permissions - one 0700, one world-writable 0777 - and runs the coding-agent CLI against each. Honouring the 0700 copy establishes that the tool reads system-wide settings at all; honouring the 0777 copy as well proves it applies configuration from a directory any local user can write to, with no ownership, permission or approval gate. That is local privilege escalation into the agent (CVE-2026-35603 class).

Field Value
Id coding-agent-shared-config-trust
Severity high
Language shell
Category ai
Author CERT-X-GEN Security Team
Template version not recorded
Confidence 95
CVSS not recorded
Weakness CWE-732
Tags ai, coding-agent, cli, config-trust, privilege-escalation, hooks, cwe-732, cwe-276, cwe-15, cve-2026-35603
Target kind cli
Oracle property

Declared in the header. cxg parses @references and then discards it, and nothing at scan time reads it, so this is the only place the links a template cites are surfaced.

To see what the copy on your machine says about itself, and to confirm it is installed at all:

Terminal window
cxg template info coding-agent-shared-config-trust

The id it prints is the one to pass anywhere a template is selected. See cxg template for the rest of the subcommand, Scan a target for running a scan, and A match is not a finding for how to read what comes back.