Skip to content

confirmation: fail closed on malformed tool-confirmation responses #4576

@davidahmann

Description

@davidahmann

Problem
Malformed tool-confirmation payloads can traverse edge parsing paths that are treated as implicit allow instead of hard deny. This weakens confirmation as a safety control.

Why now
Tool confirmation is a core policy boundary for sensitive tool execution. Any permissive fallback on malformed responses creates avoidable safety risk.

Evidence packet

  • commit under test: 223d9a7
  • runtime environment: macOS 26.3; Python 3.14.0
  • minimal repro:
    1. Return malformed confirmation payload (wrong shape/type or missing required allow/deny signal).
    2. Invoke tool flow requiring confirmation.
    3. Observe execution decision.
  • expected: malformed payload always blocks execution with explicit denial reason.
  • actual: some malformed cases can be interpreted permissively.

Why current behavior is insufficient
Safety controls must fail closed. Parsing ambiguity that defaults to allow violates expected tool execution boundaries.

Acceptance criteria

  • Confirmation parser rejects malformed payloads with explicit reason classification.
  • Tool execution is blocked for all malformed confirmation responses.
  • Unit tests in runner/tool-confirmation paths lock fail-closed behavior.

Metadata

Metadata

Labels

answered[Status] This issue has been answered by the maintainercore[Component] This issue is related to the core interface and implementation

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions