You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(security): the async process runner redacts telemetry and kills the process group on timeout #780
priority/p1-highPriority P1: high-impact work for the next planned milestonescope/cliCore CLI framework, Typer subcommands, options, and tablestype/securityType security: a vulnerability or a leak
run_subprocess_async (core/process.py:345-498) has drifted from run_subprocess. It puts the first eight raw argv items into its telemetry summary (:380), where the sync path calls _sanitize_command_for_telemetry (:239), so a token passed as an argument can reach traces. On timeout it calls proc.kill() on the direct child only (:421), which can leave grandchildren such as pytest workers running.
Scope & Deliverables
Deliverable: the async path sanitizes the telemetry command the same way as the sync path, and a timeout kills the whole process group. Tests cover a secret-bearing argv and a child that starts its own child.
Consolidation (2026-10-03): this item is a sub-issue of #775 (one process runner) and its first stage. P1 and v0.2.28 are unchanged, and it ships on its own schedule.
Proposed widening, for a person to accept: the sync path's subprocess.run(timeout=) also kills only the direct child. A group kill in the async path alone would add a new divergence between the two runners. Proposed criterion:
Move the guarded _terminate_process_group from sandbox/host.py:58-72 into core/process.
Use it in both runners' timeout paths, with the child started under start_new_session=True.
Route both runners' telemetry through _sanitize_command_for_telemetry.
A new session stops a terminal Ctrl-C from reaching the child. So the change either forwards SIGINT and SIGTERM to the group, or applies only on the timeout path.
run_subprocess_async in src/devops_cli/core/process.py had drifted from run_subprocess:
It joined the first eight raw argv elements directly into cmd_summary without sanitization, leaking sensitive arguments or credentials into telemetry trace attributes.
On timeout, it called proc.kill() solely on the direct child process without isolating the child into a dedicated session, leaving grandchild processes running as orphaned background leaks.
priority/p1-highPriority P1: high-impact work for the next planned milestonescope/cliCore CLI framework, Typer subcommands, options, and tablestype/securityType security: a vulnerability or a leak
Activity
dan-petty commentedon Oct 3, 2026
Consolidation (2026-10-03): this item is a sub-issue of #775 (one process runner) and its first stage. P1 and v0.2.28 are unchanged, and it ships on its own schedule.
Proposed widening, for a person to accept: the sync path's
subprocess.run(timeout=)also kills only the direct child. A group kill in the async path alone would add a new divergence between the two runners. Proposed criterion:_terminate_process_groupfromsandbox/host.py:58-72intocore/process.start_new_session=True._sanitize_command_for_telemetry.A new session stops a terminal Ctrl-C from reaching the child. So the change either forwards SIGINT and SIGTERM to the group, or applies only on the timeout path.
fix(security): redact telemetry and kill process group on timeout in …
dan-petty-bot commentedon Oct 6, 2026
What changed
#1264, merged into
release/v0.2.28as d178417.4 file(s) changed.
How it was verified
Check runs at 1132d1f:
Acceptance Criteria of
docs/agent/tasks/task-780-async-process-runner-telemetry-redaction-and-pgid-kill.md:No Acceptance Criteria section.
feat(release): v0.2.28 (#1283)