Configuration Precedence & Saved Tool Approvals: Technical Notes from AgentConform and Stay-Safe (#109)
Source-attributed engineering notes documenting multi-layer permission resolution in Codex 0.167.0 and Goose 1.57.0, negative-control design and remediation regressions.
Layered Permission Resolution in Coding Agents
Open-source coding agents rarely store effective authorization policy in a single flat flag. Instead, runtime behavior emerges from the composition of user profiles, project-scoped overrides, command rules, CLI arguments, and persisted per-tool decision stores1.
Let denote a layered configuration state, a candidate configuration repair, the intended confirmation or utility postcondition, and the preservation invariant over unrelated explicit restrictions. A valid targeted repair requires satisfying the conjunction:
Whenever holds but fails, or when an observation surface omits interactive approval verification, treating syntax validity as a pass masks real regressions.
Case 1: Higher-Layer Sandbox Advice Overriding a Read-Only Profile
In accepted Challenge 2 on chalkbadger/stay-safe#109 (evaluated at commit 27b77dd against pinned Codex 0.167.0 / 086ccc8), a user configured a strict read-only profile in their user layer alongside a project config disabling prompts:
# User configuration layer
default_permissions = ":read-only"
# Project configuration layer (triggers commands_without_prompts warning)
approval_policy = "never"
When remediating the missing prompt, adding sandbox_mode = "workspace-write" to the higher-precedence file restores prompt checks while overriding the lower layer’s :read-only profile. Maintainer reproduction confirmed the precedence interaction on 086ccc8, leading to updated remediation logic and credited regression coverage on main1.
Case 2: Persisted Tool Decisions vs. Mode Changes and Resets (AC-002)
In AgentConform case family AC-002 on pinned Goose 1.57.0 (30bba951), initial persisted tool permissions contain both an overly permissive edit rule (always_allow) and an intentional destructive-action safeguard (never_allow on fixture__delete)2:
| Repair Arm | fixture__edit Effective State |
fixture__delete Effective State |
Dispatch Outcome | Replay Verdict |
|---|---|---|---|---|
mode_only (Control) |
always_allow retained |
never_allow preserved |
Edit ran unprompted | Fail |
targeted_repair |
ask_before restored |
never_allow preserved |
Edit prompted; delete blocked (0 prompts) | Pass |
reset_all (Control) |
ask_before restored |
Explicit denial lost | Delete prompted instead of staying denied | Fail |
Replaying Normalized Traces Against OWASP Assertions
Rather than maintaining a custom assertion dialect, AgentConform projects recorded probe and dispatch observations into normalized trace records evaluated by the unchanged OWASP Agent Security Regression Harness3:
# Verify input SHA-256 digests and execute Phase 1 OWASP assertion replay
python3 phase1_replay.py --owasp-src audit/owasp/src
Crucially, configuration reload inspection and end-to-end tool dispatch remain distinct evidence surfaces: where interactive approval RPCs were not exercised in AC-001, the replay engine emits Inconclusive rather than Pass.
Footnotes
-
Public rulings and fix links are archived in
chalkbadger/stay-safe#109. ↩ ↩2 -
Phase 2 extension
AC-004subsequently verified survival across a full OS process exit and fresh observer PID startup on Debian. ↩ -
Pinned to
OWASP/Agent-Security-Regression-Harnesscommit970158c10b7e36ae00f12de4ba2a41ca61acabca. ↩
Referenced Artifacts & Sources
- Stay-Safe Issue #109: Accepted Codex safety report challenges and PR #120 regression fixes. [https://github.com/chalkbadger/stay-safe/issues/109] ↗
- AgentConform Public Evidence Manifest v1.0.0 (asOfDate 2026-11-27). [https://alhibb.github.io/agentconform-website/] ↗
- OWASP Agent Security Regression Harness (pinned commit 970158c1). [https://github.com/OWASP/Agent-Security-Regression-Harness] ↗