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
Agent Host auto-approves sed in-place edits #328901
bugIssue identified by VS Code Team member as probable buginsiders-releasedPatch has been released in VS Code Insidersterminal-auto-approveRelated to the terminal's auto approve logic
Agent Host's terminal auto-approval rules allow normal sed commands, but do not distinguish in-place editing forms such as:
sed -i 's/foo/bar/' file.txt
sed --in-place 's/foo/bar/' file.txt
These forms modify files through command arguments rather than shell redirects, so the existing redirect write check does not see them. As a result, a recognized sed command can be auto-approved even though it edits a file directly.
Workbench already detects canonical sed in-place forms through its command-specific file-write parser.
Expected
Agent Host should require confirmation for canonical sed in-place forms, including -i, -I, clustered/backup-suffix variants, BSD empty suffixes, and --in-place.
A configured full-command allow rule should not override this check.
Normal non-in-place sed commands should retain their existing auto-approval behavior.
Workbench file-write behavior and settings should remain unchanged.
Broader shell-dialect and dynamic-option hardening is tracked separately in #328898.
bugIssue identified by VS Code Team member as probable buginsiders-releasedPatch has been released in VS Code Insidersterminal-auto-approveRelated to the terminal's auto approve logic
Activity