Skip to content

fix(vscode): clarify effective permissions - #12077

Merged
marius-kilocode merged 2 commits into
mainfrom
mixed-fruit
Jul 9, 2026
Merged

fix(vscode): clarify effective permissions#12077
marius-kilocode merged 2 commits into
mainfrom
mixed-fruit

Conversation

@marius-kilocode

@marius-kilocode marius-kilocode commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

The Auto-Approve settings currently present missing permission rules as Ask, even though the CLI allows most tools by default. This makes the UI promise protection that is not present in the effective backend configuration.

For example, this partial configuration only customizes Bash:

{
  "permission": {
    "bash": {
      "*": "ask",
      "git status *": "allow"
    }
  }
}

Before this change, the settings UI showed Edit as Ask. The config contains no Edit rule, however, so the CLI falls back to its default and evaluates Edit as Allow. Selecting Ask is also difficult because the dropdown already appears to be set to Ask.

This becomes especially confusing for external files. An Edit call first checks external_directory, which Kilo labeled Read External Directory. The resulting sequence looked like this:

  1. Kilo asks to Read External Directory /home/user/project/*.
  2. The user clicks Run, expecting to authorize a read.
  3. The pending Edit resumes.
  4. Because Edit has no explicit rule, it resolves to the CLI default Allow and changes the file without another prompt.

The backend is applying its configured rules correctly, but the settings value, permission wording, and action label make that behavior look like an Edit permission bypass.

This change makes the UI reflect the effective permission model. Global permission rows start from the CLI wildcard defaults and then apply configured rules in their existing order. Missing values are shown as inherited defaults rather than explicit choices. With the Bash-only configuration above, the UI now shows:

Permission Displayed value Effective behavior
External Directory Default (Ask) Ask before leaving the workspace
Bash Ask Use the explicit Bash rule
Edit Default (Allow) Use the CLI default
Doom Loop Default (Ask) Use the CLI default

Explicit rules remain explicit. For example:

{
  "permission": {
    "edit": "ask"
  }
}

Edit is displayed as Ask and the CLI requests a separate Edit approval before changing a file. Choosing Ask for a previously missing Edit rule now writes this explicit configuration instead of leaving the rule absent.

Ordered wildcard rules are reflected as well. In this configuration, the later broad rule wins and Edit is Ask:

{
  "permission": {
    "edit": "allow",
    "*": "ask"
  }
}

Reversing those entries makes the later explicit Edit rule win:

{
  "permission": {
    "*": "ask",
    "edit": "allow"
  }
}

External-directory requests now say Access External Directory, which accurately covers reads, edits, searches, and other path-based operations. The primary action is labeled Allow once instead of Run, while persistent Auto-Approve rule controls remain separate. Per-agent permission inheritance is unchanged.

@marius-kilocode
marius-kilocode enabled auto-merge July 9, 2026 15:49
@marius-kilocode
marius-kilocode merged commit 3684e7e into main Jul 9, 2026
23 checks passed
@marius-kilocode
marius-kilocode deleted the mixed-fruit branch July 9, 2026 16:10
t7tran pushed a commit to t7tran/kilocode that referenced this pull request Aug 14, 2026
fix(vscode): clarify effective permissions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants